write JSON files; notes to self elsewhere; docs