Bring a large pot of salted water to a rolling boil.
Meanwhile, pat shrimp dry with paper towels and mince garlic and chop parsley.
Cook squid ink pasta until al dente according to package directions, reserving 1 cup pasta water before draining.
Heat olive oil in a large skillet over medium-high heat, add garlic and red pepper flakes, and cook 30 seconds until fragrant.
Add shrimp in a single layer and sear 1–2 minutes per side until pink and opaque, then transfer shrimp to a plate.
Pour white wine or chicken broth into the skillet, scrape up browned bits, and simmer 1–2 minutes to reduce slightly.
Lower heat to medium-low, stir in butter until melted, then stir in chopped parsley.
Add drained pasta to the skillet, toss with sauce, adding reserved pasta water as needed to coat.
Return shrimp to the pan, toss gently to combine, and season with salt and pepper.
Serve immediately with a squeeze of lemon over each portion.