01 - Preheat your oven to 400°F.
02 - In a large skillet over medium heat, heat the olive oil. Add the finely chopped onion and diced carrots, sautéing for 5 minutes until they begin to soften. Stir in the minced garlic and cook for an additional 1 minute until fragrant.
03 - Increase the heat to medium-high. Add the ground beef to the skillet and cook until thoroughly browned, breaking it apart with a spoon. Drain any excess fat from the skillet if necessary.
04 - Stir in the tomato paste and Worcestershire sauce, cooking for 2 minutes. Pour in the beef broth, then add the dried thyme, dried rosemary, bay leaf, salt, and black pepper. Bring the mixture to a simmer, then reduce the heat and let it cook for 15 minutes, stirring occasionally.
05 - Remove the bay leaf from the beef mixture. Stir in the frozen peas and cook for 2 minutes. Remove the skillet from the heat.
06 - Meanwhile, place the peeled and quartered potatoes in a large saucepan. Cover them with salted water and bring to a boil. Cook until the potatoes are fork-tender, which usually takes about 15–18 minutes. Drain the cooked potatoes thoroughly and return them to the pot.
07 - Mash the cooked potatoes with the unsalted butter and whole milk until smooth and creamy. Season with salt and white pepper to your preference. If desired, mix in the optional egg yolk for a richer, golden-brown topping.
08 - Spoon the prepared beef mixture into a large baking dish (such as a 9x13 inch casserole dish). Carefully spread the mashed potatoes evenly over the beef filling, ensuring full coverage. Use a fork to create decorative ridges on the potato topping.
09 - Bake the shepherds pie in the preheated oven for 25–30 minutes, or until the potato topping is lightly golden brown and the filling is bubbling around the edges.
10 - Allow the shepherds pie to rest for 10 minutes before slicing and serving. This resting period helps the filling set and makes for easier portioning.