1 stick unsalted butter, plus more for pan
6 ounces bittersweet chocolate, chopped
2 cups all-purpose flour
1 teaspoon baking powder
1/4 teaspoon cayenne pepper
1/2 teaspoon salt
1 3/4 cups sugar
4 large eggs
1 tablespoon vanilla
1 1/4 cups solid-pack pumpkin
1/4 cup vegetable oil
1 teaspoon ground cinnamon
1/4 teaspoon ground nutmeg
1/2 cup chopped nuts
Preheat oven to 350 degrees. Butter a 9-inch square baking pan or dish. Line bottom of pan with parchment paper; butter lining. Melt chocolate and butter in a heatproof bowl set over a pan of simmering water, stirring occasionally until smooth.
Whisk together flour, baking powder, cayenne, and salt in a large bowl; set aside. Put sugar, eggs, and vanilla in the bowl of an electric mixer fitted with the paddle attachment; beat until fluffy and well combined, 3 to 5 minutes. Beat in flour mixture.
Divide batter between two medium bowls (about 2 cups per bowl). Stir chocolate mixture into one bowl. In other bowl, stir in pumpkin, oil, cinnamon, and nutmeg. Transfer half of chocolate batter to prepared pan smoothing top with a rubber spatula. Top with half of pumpkin batter. Repeat to make one more chocolate layer and one more pumpkin layer. Work quickly so batters don't set.
With a small spatula or a table knife, gently swirl the two batters to create a marbled effect. Sprinkle with nuts. Bake until set, 40 to 45 minutes. Let cool in pan on a wire rack. Cut into 16 squares.