session-compaction-and-restore skillA
session-compaction-and-restore is agent-read markdown (skill) from mvschwarz/openrig: Use when reasoning about what survives compaction/context-loss/restart/seat-refresh, designing a high-fidelity restore packet, or distinguishing native runtime resume vs fork vs artifact-backed mental-model rebuild. Covers the 4 failure modes that prevent honest restore (compacted seat drops hot potato; restore packet preserves details but loses product intent; runtime resume mistaken for handover or fork; rebuilt seat starts with stale instructions)..
Indexed from public GitHub and served as immutable, content-addressed versions. Install it pinned to an exact SHA-256 with the mdr CLI, and every file is verified against the hash recorded here before it reaches your agent. The deterministic audit below grades the latest version, and the same file always earns the same grade.
What the file says
# Session Compaction and Restore Preserving useful working state across **compaction, context loss, restart, or seat refresh.** Includes Claude compaction restore, Codex resume/fork mechanics, transcript-based mental-model rebuilds, and durable handoff packets. **Long-lived seats are valuable only if they can survive context pressure.** If compaction turns a senior seat into a cold-started agent, users will avoid persistent topologies and fall back to throwaway agents. ## Use this when - A seat is approaching compaction or just compacted - Designing a high-fidelity restore packet for an active workflow - Distinguishing native runtime resume vs fork vs artifact-backed mental-model rebuild - Reasoning about what should be preserved vs reconstructable - Auditing a restore for product-intent preservation (not just detail preservation) ## Don't use this when - The session is fresh and has no working state to preserve - The intent is to *create* a new seat from a primed source — that's `session-source-fork` or `agent-starters` - The packet is a one-off snapshot for human review — restore packets are for re-entering active work ## The 5 distinctions (do not collapse) …
Read the whole file at its exact version.
How to install
mdr add mvschwarz/openrig/session-compaction-and-restore@git:20260907.9006fc5mdr add mvschwarz/openrig/session-compaction-and-restore@sha256:cdf4e40625e88bcePin to a label to follow the author's releases, or to a sha256 to freeze the exact bytes forever. Either way the resolved hash is written to mdr.lock, and mdr install reproduces it on any machine.
[](https://markdownregistry.com/a/art_rjlo4vbjedxovzdm)
0 badge views in 30 days
Versions
| version | committed | commit | size | audit | |
|---|---|---|---|---|---|
| git:20260907.9006fc5 latest | 2026-09-07 | 9006fc5 | 8,452 B | A | view · diff |
| git:20260805.cabd2b2 | 2026-08-05 | cabd2b2 | 8,154 B | A | view · diff |
| git:20260802.4c6d888 | 2026-08-02 | 4c6d888 | 8,115 B | A | view · diff |
| git:20260510.b98294b | 2026-05-10 | b98294b | 6,285 B | A | view |
Audit of the latest version
- pass: Frontmatter block present
- pass: Frontmatter declares a name
- pass: Frontmatter declares a description
- pass: Size between 200 bytes and 200 KB (8452 bytes)
- pass: No zero-width or bidi control characters
- pass: No instruction hidden inside an HTML comment
- pass: No link to an exfiltration or paste host
- pass: No credential-shaped string
- pass: No instruction to send local credentials anywhere
- pass: No text hidden with inline styles
- pass: No prompt-injection phrasing
- pass: No curl or wget piped into a shell
- pass: No recursive delete of root, home or parent
- pass: No instruction to read or print local credentials
- pass: No base64 blob over 200 characters
- pass: No link to a raw IP address
- pass: No script tag
Source
mvschwarz/openrig · 362 stars · license Apache-2.0 · pushed 2026-09-25 · branch main
API
GET https://markdownregistry.com/api/v1/artifacts/art_rjlo4vbjedxovzdm GET https://markdownregistry.com/api/v1/resolve?ref=mvschwarz/openrig/session-compaction-and-restore GET https://markdownregistry.com/api/v1/blob/cdf4e40625e88bce982fbf0a7988fd1aff34896e26fa3beae2c683323eef2446
Your agent does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.