Preheat oven to 350°F. Line an 8x8-inch metal pan with parchment paper, leaving overhang on two sides so you can easily lift the bars out of the pan later.
In a large bowl, whisk together melted butter, peanut butter, brown sugar, and granulated sugar until smooth. Whisk in eggs, egg yolk, and vanilla.
Add flour, baking powder, salt, and baking soda. Stir until just combined. The dough will be thick and soft, almost like a peanut butter cookie dough/blondie batter.
Press about two-thirds of the peanut butter dough into the bottom of the pan. Use slightly damp hands or a spatula to press it into an even, compact layer.
In a small bowl, stir together the jam with lemon juice if the jam is a little sweet. If the jam is loose, stir in the cornstarch. Spread the jam evenly over the base, leaving about a ¼-inch border around the edges so it does not bubble too aggressively against the pan.
Dollop the remaining peanut butter dough over the jam in small pieces.
For the crumble, stir together flour, oats, brown sugar, and salt. Add melted butter and peanut butter. Mix until clumpy. Stir in chopped peanuts if using.
Scatter the crumble over the jam and peanut butter dollops, leaving a few little jam pockets visible.
Bake for 35–42 minutes, until the top is golden, the edges are set, and the center looks puffed and no longer wet. A toothpick inserted into a peanut butter section should come out with moist crumbs, not raw batter. Avoid testing through a jam pocket.
Cool completely in the pan, then chill for at least 1 hour before slicing. This is what makes them cut into thick, clean bars instead of collapsing.