Bring a large pot of salted water to a boil.
Add the broccoli, onion, and garlic to a large skillet. Cook until softened, about 10 minutes.
Add the pasta to the pot of water and cook until just al dente - the noodles will cook more when added back to the skillet. Reserve 1 cup of the pasta water from the pasta then drain and rinse the noodles.
Stir in ¾ cups of the reserved pasta water, spinach, cream cheese, nutritional yeast, basil leaves, lemon juice, salt, red pepper flakes, and pepper into the broccoli mixture. Cook 5-7 minutes, until the spinach is wilted and a sauce forms. Add the remaining ¼ cup of pasta water if there is not much liquid.
Transfer the mixture to a high speed blender and blend on high until smooth.
Pour the sauce back in the skillet and add the pasta and edamame. Cook on medium heat for 3-5 minutes.
Garnish with fresh basil and red pepper flakes.