LLMs, however powerful, are inherently stateless. In a raw setting, you send a message, they respond, and then they immediately forget. If you were to interact with a bare, standalone model directly via an API, it would look like this:
You: Your name is Edison. Remember. LLM: Sure. My name is Edison. You: What is your name? LLM: I am Model X by Company Y. How can I help? (Zero memory of Edison)
Then how do apps like Gemini or Claude seem to remember everything?
An underlying application harness is doing the heavy lifting. It preserves the context for you. Even though it feels like a simple chat interface, there is a harness working behind the scenes.
For every new message in a conversation, the harness automatically appends the entire chat history before sending it back to the model. So conversation looks like this:
You: Your name is Edison. Remember. LLM: Sure. My name is Edison. You: What is your name? (+ Harness silently appends the previous message i.e. your name is Edison. Remember.) LLM: I am Edison.
This is 1st magic of agent harness i.e. context management — turning a stateless LLM into a continuous conversation (which feels personal to you or your work).
But there will be problem of huge context build up if harness keeps appending message history and sending it to LLM for a response. Isn't it? Will discuss how harness manages this & more in upcoming parts of harness posts.