Place noodles in a large bowl 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 bowl, stir together the fish sauce, brown sugar, rice vinegar, lime juice, tamarind paste and red pepper flakes.
Heat two tablespoons of the oil in a 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 one side of the pan.
In the empty side of the pan, 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.