Preheat the oven to 325 degrees F. Line 2 muffin pans with cupcake liners.
In a medium bowl, sift together the flour, baking powder, baking soda, salt, cinnamon, ginger and nutmeg. Set aside.
In a large mixing bowl, cream together the butter and brown sugar until well blended using a hand held mixer. Scrape down the sides of the bowl, and then add the vanilla and one egg at a time, scraping down the sides of the bowl after each addition. Add the butternut squash and mix until well blended.
With the mixer on the lowest speed, add the dry ingredients and the milk, alternating between the two, beginning and ending with the flour, blending thoroughly after each addition. Stir in the chopped pecans if using.
Fill the cupcake liners two-thirds full with batter and bake until a wooden toothpick inserted in the center comes out clean, 18 to 20 minutes. Cool in the pans on a cooling rack for 10 minutes, and then remove the cupcakes from the pans and cool completely on the rack before filling and frosting.
To assemble: Core the center of each cooled cupcake using an apple corer. Spoon about 1 teaspoon of the cooled Cranberry Compote Filling into the cavity of each cupcake. Generously frost the top of each cupcake with the Sage-Cream Cheese Frosting.
Cranberry Compote Filling
Combine the granulated sugar and 1 cup water in a medium saucepan. Bring to a boil; add the cranberries and return to a boil. Reduce the heat and boil gently for 10 minutes, stirring occasionally.
Cover and cool completely at room temperature.
Sage-Cream Cheese Frosting
In the bowl of a stand mixer, cream the cream cheese and butter together on medium-high speed until smooth. Add the salt and vanilla extract. Beat until incorporated. Add the powdered sugar, 1/2 cup at a time, beating well after each addition. Beat in the juice from the Cranberry Compote, and then add the chopped sage and mix on low speed until fully incorporated.
This recipe was created by a contestant during a cooking competition. It has not been tested for home use.