Bring a large pot of salted water to a boil. Add spaghetti and cook until al dente according to package directions. Reserve 1 cup of pasta water, then drain.
In a high-speed blender, combine edamame, nutritional yeast, lemon juice, half the lemon zest, red pepper flakes, a pinch of salt, and 2 tablespoons of the olive oil. Blend on high, adding reserved pasta water 2 tablespoons at a time until you reach a smooth, velvety consistency slightly thinner than pesto.
In a large skillet, warm the remaining 2 tablespoons olive oil over medium heat. Add minced garlic and cook for 30–60 seconds until fragrant and just golden, being careful not to burn.
Pour the edamame sauce into the skillet with garlic. Stir to combine, then add the drained pasta. Toss vigorously over low heat, adding more pasta water if needed to coat every strand. Season with black pepper and additional salt to taste.
Twirl pasta into bowls. Sprinkle with remaining lemon zest, toasted sesame seeds, red pepper flakes, torn basil, and a drizzle of chili oil. Serve immediately.