To make the tamarind water, soak the tamarind paste in boiling water for 5 minutes breaking up any chunks with a spoon. Set aside until cool enough to handle. Pass the mixture through a sieve to get the tamarind water.
To make the tamarind sauce, in a bowl whisk together tamarind water, fish sauce, and sugar until well combined.
To prepare the crabs for steaming, freeze the crabs for 1 hour to immobilize them.
Put the crabs in a large pot. Add about an inch of water. Close the lid and steam them for 8-10 minutes. Remove the crabs from the pot with tongs. Give them a rinse under cool water to clean all the debris off.
With the heat turned up to high, in a large wok, add the oil, garlic, scallions, and shallots. Saute over medium heat for 1 minute or until fragrant.
Decrease the heat to medium-high. Add the peppercorns and crabs and toss for 2 minutes.
Pour the tamarind sauce over the crabs and cook for another 3 minutes.
Add 2 tbsps basil leaves and chilis and cook for another 2 minutes.
Remove the crabs and transfer them to a serving plate.
Let the sauce cook on high heat for 10 minutes until it reduces and becomes thicker.
Pour the sauce over the crabs. Garnish with more basil, chili, and cilantro and serve immediately.