Guide Overview
After this guide, you’ll be able to:- Rewind to any point in time
- See exactly what your AI saw when it made a decision
- Find where things went wrong in seconds, not hours
Why View Context History?
You know the feeling. Your agent does something unexpected. A user reports a bug. You open your logs and stare at a wall of JSON. Hundreds of messages across dozens of contexts. Timestamps everywhere. You scroll. And scroll. And scroll. Where do you even start? You feel powerless. The answer is somewhere in that mess, but finding it feels like searching for a needle in a haystack—blindfolded. Hours pass. Frustration builds. You start questioning your life choices. What if you could rewind to cherry-pick the exact moment things went wrong? You’d finally be in control of your agent. Understanding why it did what it did becomes trivial. This is why we built UltraContext. Every update or delete creates a version. Every append has a timestamp. Rewind to any moment—by version number, by timestamp, by message index—and see the exact state your AI saw. No more scrolling through logs. No more guessing. Just the facts you need. Like git, but for your context.How Versions Work
Versions are automatically created on updates and deletes only. Appends don’t create versions.v0: create → v1: msg1 updated → v2: msg2 deleted
Get Version History
You can get the version history of a context by passinghistory: true to the get method. This will return the current state of the context, the version number, and the version history.
Time Travel
Go back to any point: by version number, timestamp, or message index.By Version
Get exact state after a specific update or delete.By Index
Get first N messages (0 through index).By Timestamp
Get state at any moment, including between appends.Combine All
Audit Trail
Every update or delete automatically records:- version — sequential version number
- operation — create, update, or delete
- affected — which message IDs changed
- created_at — ISO timestamp
metadata to track other information about the change.
history: true:
Examples
Debug Agent Failure
Something went wrong. Trace back to see what context it had when it failed.Compare Prompt Versions
Prompt was updated at v2. Compare agent behavior before and after.Reconstruct User Session
Support ticket: “What did user X see at 3:42pm?”Next: Fork & Clone Contexts
Create copies from any point in history.