Preheat the oven to 180°C / 350°F / Gas mark 4.
To make your own sweet potato puree, wash the potatoes well and remove the skin.
Bring a pot of water to the boil.
Chop the sweet potato into small squares then boil until soft.
Mash and set aside.Line a baking tray with greaseproof paper and set aside.
In a medium saucepan over low heat, melt the butter.
Remove the pan from heat, and stir in cocoa.
Let cool slightly.
Meanwhile, in a small bowl, whisk together the flour, baking powder, and salt.
Stir in the sugar and sweet-potato puree, then the egg.
In a small bowl, stir together the vanilla and add to cocoa mixture.
Add the flour mixture to the cocoa mixture and stir until the flour has dissolved.
Spoon into the prepared baking tray and smooth the top.
Bake for 20 minutes or until inserted knife comes out with a few moist crumbs.
Cool to room temperature before serving.