How do i convert from dialogflow to nlu.yml

Detailed example works but using markdown which is deprecated. the other example works directly on the json files without any conversion. However current docs, training and examples for version 2 use yaml so better to use that. And manually editing the json does not sound like much fun.

EDIT: not actually tested if it works on the json but the training finishes without error.