First, make the custard. Whisk the egg yolks in a bowl until just broken up – they shouldn’t be frothy. Pour the milk and sugar into a saucepan and warm over a low heat, stirring to dissolve the sugar, until almost boiling. Add the bay leaves, remove from the heat, and leave to infuse for 10 mins. If the milk mixture has cooled after this time, briefly warm it up again until just steaming, then remove from the heat. Discard the bay leaves and pour a little of the mixture into the whisked egg yolks. Whisk in the splash of milk, then pour the yolk mixture into the milk pan, whisking continuously to combine. Cook over a low-medium heat, stirring constantly, until the mixture is thick enough to coat the back of a spoon, and silky smooth. Strain through a sieve and set aside. The custard can be served warm or cold – you can chill it at this stage, or set aside to reheat later.
For the crumble topping, combine the flour, sugar, oats, pumpkin seeds, almonds, hazelnuts, spices and a pinch of salt in a bowl, then pour over the butter. Mix well. Heat the oven to 200C/180C fan/gas 6.
Butter a large ceramic baking dish. Combine the pears, sugar, lemon juice, cinnamon and knob of butter in a medium pan, then set over a low heat. Cook for 4-5 mins, gently stirring, until the pears have released some juice and are slightly softened, but not falling apart. Remove from the heat and tip into the dish along with half the cooking juices released into the pan. Dot the blackberries among the filling.
Scatter the crumble topping all over the filling, then bake for 25-30 mins until golden, crisp and bubbling at the edges. Leave to stand for 10 mins before serving with the custard, alongside the remaining pan juices.