History‑linked checkpoints and file state restore

Open 💬 5 comments Opened Aug 27, 2025 by mkusaka

What feature would you like to see?

Provide a mechanism that ties conversation history to file state:

  • Automatically create a checkpoint whenever the agent modifies files (e.g., via apply_patch or approved shell writes).
  • When jumping to a past message from history/backtrack, restore the workspace to the file state at that message. Make this restore behavior configurable: automatic or prompt/manual.

Implementation note

  • Backend is implementation‑agnostic. A Git‑based approach is one practical option, but any local snapshot store that can recreate exact file states is acceptable.

Slash commands (especially for manual mode)

  • /checkpoint restore <message-id|checkpoint-id> → Restore files to the state associated with a specific history message or checkpoint (confirmation shown).
  • /checkpoint save [message] → Optional manual checkpoint at the current workspace state.
  • /checkpoint mode auto|manual → Toggle restore behavior when navigating history/backtrack.

Are you interested in implementing this feature?

Potentially—happy to help refine the design and contribute an implementation once maintainers confirm the scope and preferred storage backend.

Additional information

Inspiration: Gemini CLI checkpointing (conceptual prior art): https://github.com/google-gemini/gemini-cli/blob/main/docs/checkpointing.md

View original on GitHub ↗

5 Comments

ssanumand · 10 months ago

I'm too waiting for this feature. Thanks for brining it out. Any idea on when it'll release?

Jiabinone · 9 months ago

I'm also looking forward to this useful feature.

hmottestad · 7 months ago

This would be awesome!

anywaypridyrok · 2 months ago

Disclosure: I’m building DiffReceipt, a receipt layer for AI-agent code changes.

History-linked checkpoints are the right direction. The thing I’d want as a user is a visible connection between conversation history, file state, and review evidence.

For each checkpoint, a receipt could include:

  • conversation turn / task
  • snapshot id
  • files touched
  • diff summary
  • checks run
  • what restore will and will not affect

This makes checkpoints useful for human review too, not only for emergency rollback.