Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/sliamh11/deus/compressgit clone --depth 1 https://github.com/sliamh11/DeusWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.01144 |
| Opus 5 | $0.00000 | $0.00572 |
| Sonnet 5 | $0.00000 | $0.00229 |
| Haiku 4.5 | $0.00000 | $0.00114 |
Grade A, and why
compress scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 89 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Save this Claude Code session to the vault and update the semantic memory index.
First, resolve the vault path using this per-instance order (highest priority first). $VAULT means the resolved path:
DEUS_VAULT_PATHenv var, if set.vault_pathin./.deus/config.json(the current working directory's instance-local config), if that file exists. If the file exists but has no usablevault_path, STOP and tell the user it is present but missingvault_path— do not fall through to the global config (that fall-through is what corrupts another instance's vault).vault_pathin~/.config/deus/config.json(global fallback).
Tiers 1 and 2 are the per-instance mechanisms: when several Deus instances run on one machine they share the global config (tier 3), so resolving from it alone can silently point this instance's /compress at a different instance's vault and corrupt its memory. The instance-local ./.deus/config.json keeps each instance self-contained. The memory_indexer.py calls below resolve the vault by the same order, so their writes land in this instance's vault too.
Review the conversation and create a session log at: $VAULT/Session-Logs/YYYY-MM-DD/{topic}.md
Create the YYYY-MM-DD folder if it doesn't exist. The filename should be the topic only (no date prefix), since the date is already in the folder name.
Use this format — tldr frontmatter is mandatory, decisions is mandatory when applicable, full sections are optional:
---
type: session
date: YYYY-MM-DD
topics: [topic1, topic2]
tldr: |
What happened (1 sentence). Key decision or outcome. Pending: X, Y.
decisions:
- "chose X over Y: brief reason"
- "rejected approach A: brief reason"
---
<!-- Full details — only loaded on demand -->
## Decisions Made
- ...
## Key Learnings
- ...
## Files Modified
- ...
## Pending Tasks
- [ ] ...
Rules for decisions: array:
- Maximum 3 items. Only include decisions that affect future sessions (tool choices, format preferences, architectural calls, explicit rejections).
- Each item: quoted string, verb-first, ≤12 words.
- Omit the
decisions:key entirely if the session had no future-relevant stable decisions (e.g. purely exploratory sessions).
Keep tldr to 2–3 lines. Skip sections with no content.
After saving the session log, do three things:
-
Update vault CLAUDE.md (
$VAULT/CLAUDE.md):previous:block — rolling list of the last 3 sessions. Do NOT hand-edit it (concurrent/compressruns race on a manual read-modify-write and have corrupted the file). Use the atomic, lock-serialized splice:- Run:
python3 ~/deus/scripts/sync_linear_pending.py --write-previous "YYYY-MM-DD: <tldr one-liner>"(≤120 chars). - It prepends, trims to 3, converts a single-line
previous: "..."to list form, inserts beforepending:if absent, and writes atomically under a lock — refusing (file unchanged, nonzero) rather than dropping a body key. If it exits non-zero, leaveprevious:as-is; never hand-splice.
pending:block — merge, never replace:- Read the current
pending:block from CLAUDE.md. If missing, treat as empty list. - Remove any items that match
[x]completed tasks from the session log (fuzzy match on description). - Add any new
[ ]items from the session log that don't already exist (avoid duplicates). - Cap at 10 items. If over 10, archive the oldest to
$VAULT/CLAUDE-Archive.md. - Write the merged list back to
pending:.
- Run:
-
Index the new log into the semantic memory index by running: python3 scripts/memory_indexer.py --add "" (If the script fails, skip silently — the log is still saved.)
-
Extract atomic facts from the session log: python3 scripts/memory_indexer.py --extract "" (If the script fails or prints "No decisions content — skipping extraction", skip silently.)
-
Delete today's checkpoint now that the session log supersedes it: find "$VAULT/Checkpoints" -name "$(date +%Y-%m-%d)-*.md" -delete 2>/dev/null (Silent — no output expected.)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 89 lines · 0 tokens per session scan A 5e3b08a67f7f
compress is a command published in the GitHub repository sliamh11/Deus (51 stars, last pushed 8d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,144 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
toon-decode
Convert TOON v2.0 format back to JSON using the Zig decoder.
toon-encode
Convert JSON to TOON v2.0 format using the Zig encoder.
toon-validate
Validate TOON v2.0 files for correctness.
memcord-save-progress
Auto-summarize and save conversation progress.
memcord-save
Save current conversation to memory.
memcord-close
Deactivate memory slot and end session.