Preheat the oven to 375F/190C. Line a baking dish, approx 19 x 14cm (7 ½ x 5 ½ in), with parchment paper.
Put the chia seeds in a small bowl with the water and stir. Leave them to swell up into a jelly while you get other things ready.
Blend the cooked sweet potato and dates in a food processor or with a hand mixer in a bowl.
Melt the coconut oil (either in small pan on stove or in a small bowl in the microwave at 20sec intervals) and add this to the sweet potato along with the maple syrup and vanilla and mix in.
Separately, whisk together the almond flour, rice flour, salt, cinnamon, chili (if using) and baking powder. Add the soaked chia seeds and sweet potato-date mixture and mix well (you can put all in your food processor if big enough, though try not to over-mix).
Bake for approx 25 minutes until a skewer comes out clean. They will still be soft (don't overcook so it loses this) but there will be a firmer top etc.
Allow to cool 5min or more before cutting into small chunks.