For the cottage pie filling, season the ribs with salt and freshly ground black pepper.
Heat a large casserole dish until hot, add half of the vegetable oil and then add the seasoned short ribs. Fry until browned on all sides.
Remove the ribs from the pan and place onto a wire rack suspended over a plate.
Add the carrots, leek, garlic, peppercorns, star anise and chopped onion (reserve the sliced onion) and fry for 4-5 minutes, or until golden-brown.
Add the red wine and port to the pan, bring to a boil and then reduce the heat to a simmer. Cook until syrup-like in consistency and reduced in volume by three-quarters.
Return the beef ribs to the pan, cover with the beef stock and bring to the boil. Cut out a greaseproof paper lid the size of the pan. Skim off any impurities from the surface of the liquid with a spoon, cover with the greaseproof paper lid, turn the heat down low and simmer for three hours, or until the meat is tender and falling off the bone.
When the beef is cooked, strain the liquid, pouring the sauce into a clean saucepan. Set the cooked meat aside.
Place the liquid onto the heat, bring to the boil and then immediately reduce the heat to a simmer. Continue to simmer until reduced by half, skimming off any excess fat with a spoon.
Meanwhile, pick the meat from the bones, discarding any fat and sinew. Remove the reduced sauce from the heat and add the picked meat to it. Mix well.
Heat a frying pan until hot, add the remaining vegetable oil to the pan and the sliced onion. Fry for 5-8 minutes until golden-brown and softened. Stir in the thyme leaves and set aside.
For the mash, place the potato pieces into a pan of salted water and bring to the boil. Simmer for 15-18 minutes, or until tender. Drain and return the potatoes to the pan to drive off any excess moisture.
Pass the potatoes through a ricer into a clean bowl (alternatively use a potato masher, though you will not get such as smooth finish).
Bring the milk and butter to a simmer in a separate pan. Add the hot milk and butter mixture to the potatoes and beat well. Season with salt and freshly ground black pepper and tip the mixture into a piping bag.
To finish the beef, preheat the oven to 200C/400F/Gas 6. Spoon the braised beef into 4-6 ovenproof dishes and top with the fried onions. Place a marrow bone in the centre of each dish and place the rosemary sprigs in the top of the bone. Pipe the mashed potato onto the meat.
Cook in the oven for 15-20 minutes, or until golden and bubbling.
Serve the braised short rib and onion cottage pie at once.