Every artifact change creates a new version automatically. Browse history, preview rendered or raw, and restore any version non-destructively.
Every artifact in CRHQ is automatically versioned. Each time the content changes — whether the agent updates it, you save an edit in the panel, or anything in between — a new immutable version is recorded. Older versions are never overwritten.
When an artifact is created, it's v1. Every subsequent change adds a new version row:
Detection uses a composite hash of title + language + filePath + content. So renames count, not just content changes.
The current version number appears as a small v<n> badge in the artifact header (only shown when versionNum > 1 — fresh artifacts don't carry the noise).
Once an artifact has been edited at least once, the History button (clock-rewind icon) appears in the artifact toolbar. Tap it to open the Version History modal.
The modal has two zones:
Restored from v<n> label.Tap any row to preview that version. The currently-active version has a small current pill on the right.
In the preview pane, tap Restore as new version. A confirm sheet slides up with the reassurance text:
Restore creates a new version with v<n>'s content. Historical versions are always preserved — nothing is overwritten.
Tap Yes, restore as new version and:
Restored from v<n> so the lineage is visibleRestored from v2 (now v5)Restore is always non-destructive. v2 still exists in the list. v4 still exists in the list. Restoring v2 creates v5.
On mobile (≤600px) the modal becomes fullscreen with the same 2-zone layout. Tap targets are 44px minimum. The slide-up confirm sheet is anchored to the bottom of the preview pane (max 75% height) so the reassurance text and CTAs are always visible.
For artifacts backed by a file on disk (file_content type), restore updates the artifact snapshot only — the file on disk is not touched. The next manual file Refresh may overwrite the restored content with what's currently on disk. The History modal shows an inline tip when the selected artifact is file_content so you're not surprised.
When the agent updates an artifact:
version.create event is logged on the serverartifact:update broadcast goes out with the new versionNumClosing the artifact panel tab (the × on the tab) does not affect versions — the artifact and all its history stay in the database. To permanently delete an artifact and all its versions (and revoke any active share), use Session Details → Artifacts tab → ⋯ → Remove forever, with confirm.
v1 row with the change summary Initial version