Place noodles in a large bowl or baking dish and cover with boiling water. Let sit for 10 minutes, stirring occasionally. Prepare the rest of the ingredients while the noodles soften.
In a small mixing bowl, stir together the brown sugar, fish sauce, rice vinegar, lime juice, tamarind paste, and red pepper flakes.
Heat two tablespoons of the oil in a wok or 12-inch nonstick skillet over medium-high.
Add shallot and garlic and stir-fry for about two minutes, until very fragrant.
Add shrimp and cook, stirring only once or twice, until just opaque, a couple of minutes.
Drain noodles and add to pan with some water still clinging to them.
Pour in sauce and cook, stirring frequently, until noodles are tender and sauce has thickened enough to cling to noodles without any excess liquid in the pan.
Stir in tofu and bean sprouts.
Push the pad thai to sides of the pan to create some space in the center.
In the well you created, heat the remaining tablespoon oil and crack in the eggs. Break the yolks but otherwise leave eggs to set on the bottom.
After a minute or two, scramble the eggs a bit to just cook through, leaving whites and yolks distinct.
As soon as eggs are cooked, remove pan from heat and stir eggs into noodle mixture.
Stir in scallions, cilantro, and peanuts, reserving some to garnish if you like.
Divide among shallow bowls and serve with lime wedges and sriracha.