What is JSON?
The Harvard Chan AI Glossary
In our classes, we often pause to explain the ideas behind AI and the language used to describe it. These posts grew out of those conversations. They’re for anyone who would like to understand AI better, with no technical background assumed.
JSON stands for JavaScript Object Notation. It is a text format for organizing information so that software can exchange and interpret it consistently. Despite its name, it is used by programs written in many languages, not only JavaScript. JSON describes how data is written, not what an application is allowed to do with it.
A simple example is {“location”:”Boston”,”temperature_c”:12}. The words in quotation marks identify fields, and the values after the colons supply their contents. A field is a named piece of information. The example has a text value for location and a numerical value for temperature.
JSON can also represent ordered lists, called arrays, and nested structures, where one record contains another. Its basic values include text, numbers, true or false, and null. Null represents the absence of a value in that position; it is not automatically the same as zero, an empty word or a confirmed negative answer.
This predictable structure is useful when two programs communicate. A weather application should not have to guess whether “twelve” refers to temperature, wind speed or the day of the month. Named fields make the intended organization explicit, although the meaning of those fields still needs agreement.
An API, or application programming interface, defines how software can request a capability. JSON is often the format used for the request or response. They are different things: the API is the agreed interaction, and JSON is one way of writing the information passed through it.
AI applications may ask a model—the trained component generating a response—to produce JSON so that other software can use the result. Correct formatting is only the first test. A perfectly formatted record can still contain the wrong amount, a missing customer or a fabricated date.
A clinic application might exchange a referral identifier, a status, the date last checked and the responsible team as JSON fields. A schema—an additional description of permitted fields and values—could require the identifier and restrict the status to agreed categories. That would catch a malformed response, not a false claim that authorization has been approved. Unknown status should remain distinguishable from a negative answer. Structured data makes the exchange easier to check; the underlying clinical or administrative facts still need a source.
Source: IETF — RFC 8259, The JSON Data Interchange Format.
If you would like to find out more about AI and improve your leadership skills, consider the AI in Health Care Certificate of Specialization from the Advanced Learning Academy at Harvard T.H. Chan School of Public Health. You can take an individual course or work toward the full certificate.
AI is a fast-moving field. This explanation reflects our class discussions and related material at the time of writing. Terminology, capabilities and tools may change.
For suggested additions or corrections, please email me at tpanch@hsph.harvard.edu.
Dr. Trishan Panch
Program Director, AI in Health Care
Harvard T.H. Chan School of Public Health — Advanced Learning Academy