Writing valid json everywhere in analysis.