Revert "Revert "Better JSON handling for Stanford code.""

This reverts commit dc6dbe403c942cef80a5d4500665ced28df0e7c1.