
Peel the shrimp and keep the shells and heads to make the stock. Use a knife to make a shallow slit along the back of the shrimp to devein (you can do this while simmering the stock in Step 2). The shrimp will also look prettier once cooked.
Place a pot over medium heat and once it is hot, add cooking oil to thinly coat the bottom. Add the shrimp shells and heads. Increase the heat and sauté until they are browned and smell flavorful, then add the water and salt. Bring it to a boil, then lower the heat to maintain a gentle simmer.
Cover the pot and simmer for 45-60 minutes. After that, remove all the shrimp heads and shells. Flavor the broth with tamarind paste, sugar and fish sauce to taste.
Add the pineapple pieces and simmer for 4-5 minutes to release their flavors and aroma.
Add the tomato wedges and let the soup come back to a rapid simmer. Increase the heat if needed. Then add the peeled shrimp and cook for 1-1½ minutes until they are just cooked through. Avoid overcooking which will make them rubbery.
Add the bean sprouts and let the soup boil rapidly. Then stir in the chopped herbs. Turn off the heat and transfer the soup to serving bowls right away.