Preheat oven to 400F. Cut spaghetti squash in half and de-seed. Submerge in water cut side up in a large microwave-safe bowl. Microwave for 7 minutes. Carefully turn over each squash half, return to water, and microwave another 5 minutes.
Place squash halves cut side up on a baking dish with high sides. Place 1/4 cup chopped leeks and 2 tablespoons in the center of each squash and season with a little bit of salt and pepper. Spoon water from microwaving into each half (about 2 or 3 tablespoons each) and add about 1 cup of reserved water to bottom of the baking dish, covering the bottom of the dish so that the skin of the squash does not burn. Bake squash for 20 minutes.
Toast pine nuts in a frying pan over medium heat. Watch carefully and remove from heat when they begin to brown.
Add pine nuts, basil, and olive oil to food processor. Shred garlic into food processor using fine grater. Chop ingredients until a fine paste is formed.
In a frying pan or wok, melt 2 tablespoons of butter. Once butter is melted, add shrimp, along with the lemon juice, and salt and pepper to taste.
Once shrimp is finished cooking, remove from heat, add pesto and toss.
Use tongs to carefully remove the squash halves, tipping the ingredients inside the squash out into the water. Place squash on a plate (or back into empty microwave-safe bowl from earlier). Use a fork to rake the squash, forming the spaghetti.
Put some spaghetti squash on each plate and top with shrimp mixture. Top with parmesan cheese. Enjoy!