Start by soaking the dry rice noodles in water following the package instructions.
Cook the bacon in a pan over medium heat until it’s fully cooked, and the fat has rendered out. Remove the bacon, leaving the fat behind. If using another protein, substitute with 2 tablespoons of cooking oil.
Stir-fry the garlic and shallots for 20 seconds, or until they turn golden.
Add the soybean paste, dark soy sauce, tamarind sauce, fish sauce, palm sugar, and dried chili flakes to the pan. Stir thoroughly until the palm sugar dissolves completely.
Pour in water and bring the mixture to a simmer.
Add the noodles to the simmering sauce, mixing gently to ensure they don’t break. Make sure the noodles are well-coated with sauce.
Reintroduce the bacon to the pan, combining it well with the noodles.
Toss in the bean sprouts and green onions, give it a final stir, and serve hot.