Prep the ingredients. Wash your squash under running water, rubbing away any dirt. Chop the onion, garlic (if using), and mushrooms.
Start the vegetables. Turn the Instant Pot to Sauté and melt 2 tablespoons of butter. Add the onion, garlic, and mushrooms, stir, and cook for about 5 minutes until softened.
Pour in 1 cup of bone broth (or water). Scrape down the sides to loosen any bits, then turn off Sauté mode.
Cook the squash. Set the Instant Pot rack over the mushroom mixture and place the whole squash on top. Lock the lid and cook on Pressure Cook for 15 minutes (longer if your squash is larger).
Quick-release the pressure. Carefully remove the squash with the rack and set it aside to cool slightly.
Brown the meat. Heat a cast iron skillet over medium-high and melt 1 tablespoon of butter. Add the ground meat along with the mushroom mixture (and all its liquid) from the Instant Pot.
Stir in salt, pepper, and herbs (I like green onion, parsley, sage, and rosemary). Cook for about 10 minutes, stirring often, until most of the liquid has evaporated.
Prepare the topping. While the meat cooks, cut the squash in half. Scoop out the seeds and peel off the skin. Mash the flesh in a bowl with 3 tablespoons of butter, 1 egg yolk, and salt to taste until smooth and creamy. Preheat your oven to 350°F (175°C).
Assemble. Spread the meat mixture evenly in the skillet. Top with the mashed squash, smoothing it out with a spatula. Use a fork to create a rustic pattern if you like, and sprinkle with parmesan cheese (optional).
Bake for about 25 minutes, or until the top is golden brown. Serve warm.