Remove tails from shrimp and reserve. Pat shrimp dry with paper towel.
Heat 1 Tbsp olive oil in medium skillet until shimmering. Add shrimp tail shells and cook, stirring frequently until they begin to turn spotty brown, about 5 minutes. Remove skillet from heat and carefully add 1 cup of water. When bubbling subsides, return skillet to medium heat, stir to deglaze the pan, and simmer gently, stirring occasionally, for 5 minutes. Strain mixture through a colander and reserve liquid. (It should be about 1/4 cup).
In a large skillet, heat 2 Tbsp olive oil, then add the onion, garlic, anchovies, pepper flakes, 1/4 tsp salt and 1/8 tsp pepper. Cook, stirring occasionally, until onion is softened, about 5 minutes. Add both cans of beans (1 drained and 1 not drained), tomatoes and reserved shrimp stock , and bring to a simmer. Simmer, stirring occasionally, for 15 minutes.
Reduce heat to low and add shrimp to the skillet. Cover and cook until shrimp are opaque and just cooked through, stirring once during cooking, about 5-7 minutes. Remove skillet from heat and stir in basil and lemon juice. Add salt and pepper to taste. Drizzle with a tablespoon of extra virgin olive oil and top each serving with grated parmesan.
Enjoy!