Close GH-4: Dynamically generate the JSON files. Fixes #2, Fixes #3