CCompactor
Extract any coding agent's session into a compact, verified, provenance-linked handoff that any other agent can continue from.
📖 ccompactor.github.io · 📦 npm
ccompactor list # what sessions exist
ccompactor find "auth migration" # find one by topic
ccompactor extract claude:last # the handoff artifact
ccompactor handoff claude:last --to codex --runSame idea as sctxx, in TypeScript.
Install and run
npm i -g ccompactor # the tool
ccompactor doctorOr from source, to work on it:
npm install # workspaces; installs commander, ink and react
npm run link # builds, then points `ccompactor` at this checkout
npm run dev -- doctor # build and run in one stepSee DEVELOPING.md for the loop, the checks and how to try it on real sessions.
Standalone binaries (no Node needed) for macOS arm64/x64, Linux x64/arm64 with a .deb, and Windows x64/arm64 are attached to each release.
Either way, ccompactor update moves you to the newest release: it re-runs the npm install for a global npm install, and downloads and replaces the binary in place for a standalone one. It reports what it would do without --check changing anything, and it refuses to touch a source checkout.
Or without linking:
npm run ccompactor -- doctor
node packages/ccompactor/dist/cli.js list --any-projectReleasing is automated — see RELEASING.md. The one manual step is an npm Automation token stored as the NPMTOKEN secret, because a normal Publish token is gated behind an OTP prompt that CI cannot answer.
Status
All phases of SPEC.md are implemented: CLI, discovery, three adapters, ledgers, artifact, verify, expand, handoff, skill and TUI. No Anthropic-derived code is present — an earlier vendored copy was never imported and has been deleted; see NOTICE.
ccompactor bench also exists, as a research instrument rather than a feature: it measures whether a handoff hands anything off, and it is how the recency-tail arm was measured and then deleted. A previously published comparison against sctxx has been withdrawn — the two runs were scored on question sets sharing 3 of 21 questions, so the per-arm percentages were not comparable. On the 22 questions they do share, sctxx answers 14 and ccompactor