Automatic random glyphs alternates in inDesign

I made a custom font with glyphs and alternates for each letter. All good. Works with Photoshop and InDesign.

Now, I’m struggling to find or implement any code/script/way to modify my document:

how can I replace letters with their alternates in a random and automatic way in InDesign? I know there is the Find and Replace function, but I’m looking for something more “speedy and automatic”.