Lightly spray ramekins or a small air-fryer-safe casserole dish with cooking spray. Cut the sweet potatoes into 1- to 2-inch pieces.
Boil the sweet potatoes in a saucepan of water until fork-tender, about 10 to 15 minutes. Drain well.
Mash the sweet potatoes until smooth, then fold in the butter, brown sugar, heavy cream, salt, vanilla, cinnamon, and nutmeg.
Divide the mashed sweet potatoes evenly among the ramekins (or transfer to the casserole dish).
In a bowl, combine the flour, oats, brown sugar, melted butter, pecans, and cinnamon until crumbly. Sprinkle over the sweet potatoes. Add marshmallows now if using.
Air fry at 300°F for 10 to 15 minutes, until golden. Tent with foil if the top browns too quickly.
Rest a few minutes, then serve warm.