Hit Claude Code's 5-hour quota mid-feature? Or watching Cursor / Codex slow to a crawl after 150k tokens of context rot?
Vicem compacts your active coding session by 80–90% (via deterministic code skeletonization + lossless MCP on-demand rehydration) and hands off a clean across in 3 seconds — with and .
Zero-dependency AI agent context baton & diet suite. Hand off sessions between Claude Code, Codex, Gemini, and Cursor with 80% fewer tokens.
星數
7
工具
—
可用率
—
.vicem/BATON.md
Claude Code, Cursor, Codex CLI, Gemini CLI, Windsurf, Antigravity IDE, and Web AI
0 npm dependencies
0 network calls
⭐ Tip: Click Star (top-right) to bookmark this repo for the next time your coding agent hits a 5-hour quota limit or context rot.
⚡ 10-Second Quick Start (npx — Zero Install)
1. Run the Local Web Studio GUI or Pass a Baton Immediately
# Launch the local 3-column Desktop Utility GUI (12 agents, live token/quota telemetry)
npx -y @rakkunn/vicem gui
# Or pack a compressed baton from your current repo & hand off in 1 command
npx -y @rakkunn/vicem codex
npx -y @rakkunn/vicem claude
npx -y @rakkunn/vicem cursor
# Or auto-configure global `vicem` CLI + MCP servers across all installed agents
npx -y @rakkunn/vicem setup
2. Add as an MCP Server in 1 Line (Claude Code / Codex / Cursor)
How Lossless Code Skeletonization + MCP Rehydration Works
Instead of lossy LLM summarization that forgets exact type contracts, Vicem keeps all imports, types, and signatures 100% intact inside .vicem/BATON.md while collapsing unchanged function bodies >= 12 lines into .vicem/ledger.json:
// What the receiving agent sees in .vicem/BATON.md (-85% tokens, disk file untouched):
export interface JwtPayload { sub: string; exp: number; role: 'admin' | 'user'; }
export async function verifySessionToken(rawToken: string, secret: string): Promise<JwtPayload> { /* ... */ }
When the receiving agent actually needs to edit verifySessionToken, it calls the MCP tool vicem_rehydrate("src/auth.ts", "verifySessionToken") to pull back the exact raw lines on demand (with automatic git HEAD and live-file SHA-256 staleness detection).
Pipeline Stage
Before Vicem (Raw Session)
After Vicem Baton & Diet
Token Savings
1. Session Handoff
40+ turns of raw JSONL / SQLite history locked in one tool
Extracts Goal, Done, Immediate NEXT & git diff into .vicem/BATON.md
< 3s handoff across 12+ CLI, IDE & Web AI agents
2. Code Skeletonizer
Full source files with unchanged function bodies (~120,000 tok)
Signatures & types 100% intact; bodies indexed in .vicem/ledger.json
-80% to -90% code tokens (lossless via vicem_rehydrate)
Lockfiles dropped; data files reduced to inferred schema + 2 sample rows
-98% data bloat
5. Safety & Secret Guard
Plaintext .env keys in logs & risk of placeholder overwrites
Local secret redaction + SkeletonWriteGuard pre-commit protection
0 leaked secrets & 0 npm dependencies
Direct CLI Commands & Offline Source Setup
# 1. Launch the interactive Desktop Utility GUI
vicem gui
# 2. Compact current bloated session in-place (Context Rot Rescue)
vicem self
# 3. Pass baton to any CLI, IDE, or Web AI target
vicem codex | vicem claude | vicem gemini | vicem cursor | vicem windsurf | vicem vscode | vicem web
# 4. Return baton to previous agent & auto-unmount temporary rules
vicem back
# 5. Extract & smart-patch code blocks from a Web AI clipboard reply
vicem land
# 6. Run <50ms environment & agent storage diagnostics
vicem doctor
git clone https://github.com/RAKKUNN/vicem.git && cd vicem
./vicem.mjs setup # or double-click setup.command (macOS/Linux) / setup.bat (Windows)
For browser-only air-gapped environments without Node.js, open index.html directly in Chrome, Edge, Brave, or Safari (enforced by connect-src 'none' CSP).
Supply-Chain Verification & Minimal TCB
Verify zero third-party dependencies and cryptographic artifact integrity in one command:
# 1. Confirm zero npm dependencies
node -e "console.log(JSON.parse(fs.readFileSync('package.json')).dependencies ?? '0 dependencies')"
# 2. Verify SHA-256 checksums of all core artifacts
shasum -a 256 -c SHA256SUMS
# 3. Run the 52-test automated suite
node --test test/*.test.mjs
V
Vicem
RAKKUNN·7 顆星·
Zero-dependency AI agent context baton & diet suite. Hand off sessions between Claude Code, Codex, Gemini, and Cursor with 80% fewer tokens.
上次檢查時間:2026-11-13。 Zero-dependency AI agent context baton & diet suite. Hand off sessions between Claude Code, Codex, Gemini, and Cursor with 80% fewer tokens.