1. Preheat the oven to 350 degrees. Line a 12-hole muffin pan with paper liners.
2. Using a handheld or standing mixer, whisk the eggs and sugar for 5 minutes, until pale and quadrupled in size. Add the grated sweet potato and whisk again. Whisk in the ground almonds, flour, peppermint extract, salt, cocoa powder and baking powder until they are well combined. Add the chocolate chunks or chips, and using a spatula, mix so that they are evenly distributed.
3. Divide the batter evenly among the cupcake liners so that each liner is half-filled. This will give them enough space to puff up and rise to the top while baking.
4. Bake for 20 minutes. They will be somewhat flat on top rather than dome-shaped.
5. Once cooked, remove from the oven and cool for 15 minutes. Transfer to the refrigerator until the cupcakes are cold. The cupcakes will need to be cold to keep the icing from sliding off.
6. While the cupcakes are baking, make the icing: With a wooden spoon or mixer, beat the butter with one heaping tablespoon of the sugar, the peppermint extract and coloring for a minute until they are all incorporated and the butter has softened slightly. Add the confectioners' sugar one heaping tablespoon at a time, with half a teaspoon of water each time you add the sugar, and beat between each addition. Once all the sugar is added, you should have a soft green paste.
7. Ice each cold cupcake, using just over a tablespoon of frosting per cupcake. Finish by sprinkling dark chocolate shavings over the top of each one.