Skip to main content

What is state in software and AI?

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.

State is the information describing a system at a particular moment. It can include current values, saved progress, configuration and relevant history. State tells the software where it is in a process and what has already happened. It is not another word for intelligence or a claim that the system understands itself.

A shopping basket offers a simple example. The chosen products, quantities and delivery address are part of the current state. If the application forgets that information between clicks, the shopper cannot complete the purchase. If it records payment incorrectly, it may charge twice or claim that an order is complete when it is not.

An AI agent also needs state. It may record which documents have been read, which questions remain unanswered and whether a proposed action has received approval. An agent is software that selects actions toward a goal; without a reliable record, it may repeat steps or confuse an intended action with a completed one.

A stateless request does not automatically carry the history of earlier requests. The relevant information must be supplied with it or recovered by the surrounding application. Calling a model stateless is shorthand for this behavior across independent calls. It does not mean an application using the model cannot save conversations or maintain progress.

The harness—the software coordinating model calls and tools—can preserve state between calls. A tool is a callable operation such as searching files or updating a record. After a tool runs, the harness should record what actually happened, not simply what the model hoped would happen.

State and memory overlap but serve different explanatory purposes. State may be a precise record of this task’s current position, such as “draft prepared, approval pending.” Memory may contain information reused across tasks, such as an approved writing style. Mixing them can lead to errors, particularly when an old approval is mistaken for permission to take a new action.

For a referral, “document requested,” “document received,” “review pending” and “appointment confirmed” are different states. If a staff member receives the document while an agent is preparing a reminder, the system needs to reconcile that change before sending anything. A narrative saying that the referral is “being handled” is not enough. State gives the next person or agent a precise account of what has happened, what remains open and which actions have already been approved.

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