Bring a large pot of salted water to a boil. Add the spaghetti and cook according to package directions, adding the carrots, snow peas and bell pepper during the last 2 minutes of cooking; reserve 1/2 cup pasta water and drain.
Combine the peanut butter, hoisin sauce, brown sugar, soy sauce, and vinegar in a bowl.
Heat the oil in a saucepan over medium-high heat. Add the ginger, garlic, and cayenne pepper; cook 30 seconds.
Stir in the peanut butter mixture and the reserved pasta water.
Cook 3 minutes, stir in the tofu, and continue to cook until hot, about 3 minutes longer.
Toss in a large bowl with the pasta and vegetables, then transfer to a serving platter and sprinkle with the peanuts and scallion.