Sauté the vegetables: In a medium saucepan over medium heat, cook the onions, carrots, and garlic until soft, about 5–7 minutes.
Add tomato paste and spices: Stir in tomato paste, brown sugar/molasses, vinegar, cumin, allspice, turmeric, black pepper, and salt. Cook for 2–3 minutes until fragrant.
Simmer: Pour in water, reduce heat to low, and simmer for 15–20 minutes, stirring occasionally.
Blend: Transfer the mixture to a blender or use an immersion blender until smooth. Be careful with hot liquids.
Cool and store: Pour the sauce into a sterilized glass jar or bottle. Let it cool completely, then refrigerate. The flavor improves after 24–48 hours.