Snapshot before every overwrite
Whenever the agent is about to mutate a file through fs_write or fs_edit_hashline, PasClaw captures the prior contents first. Multi-edit turns dedupe so a single file is only snapshotted once per turn.
// Checkpoints
Checkpoints capture the workspace before each fs_write or fs_edit_hashline overwrite so an operator can /undo a regretted change, /redo to replay it, and explore agent edits without fear of losing work.
Whenever the agent is about to mutate a file through fs_write or fs_edit_hashline, PasClaw captures the prior contents first. Multi-edit turns dedupe so a single file is only snapshotted once per turn.
From the TUI or interactive agent, /undo restores the most recent snapshot in place. The same command works inside pasclaw agent and the sample dprojs, not just the TUI.
The checkpoint backend uses zpaq for content-addressable, dedupe-by-default storage. That history makes /redo possible on top of /undo so an operator can step forward through changes they previously reverted.
Each session keeps its own archive under workspace/checkpoints/<session>/archive.zpaq, so multi-edit sessions stay compact and undo history never leaks across unrelated work.
From the documentation
Implementation notes drawn from the PasClaw repository documentation.
Checkpoints run immediately before fs_write or fs_edit_hashline overwrites a file, so the recorded state is the pre-edit content rather than a later mutation.
The backend was switched to zpaq for content-addressable, dedupe-by-default storage. That makes /redo viable on top of /undo because forward history survives a previous revert.
Common questions
Keep exploring
See how the rest of PasClaw fits together.