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.
git clone --depth 1 https://github.com/andrew-shwetzer/claude-code-saveWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/andrew-shwetzer/claude-code-save/saves)<a href="https://agentmods.dev/commands/andrew-shwetzer/claude-code-save/saves"><img src="https://agentmods.dev/badge/commands/andrew-shwetzer/claude-code-save/saves/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/andrew-shwetzer/claude-code-save/saves"><img src="https://agentmods.dev/badge/commands/andrew-shwetzer/claude-code-save/saves.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What 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.1 | $0.00000 | $0.01090 |
| Opus 5.5 | $0.00000 | $0.00436 |
| Sonnet 5.5 | $0.00000 | $0.00218 |
| Haiku 4.5 | $0.00000 | $0.00109 |
Grade A, and why
saves 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 1mo 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 — 122 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Browse and search past session saves across all projects.
Arguments
The user's message after /saves determines the view:
- Nothing (
/saves): Show the 10 most recent saves across all projects - Project slug (
/saves my-app): Show recent saves for that project with summary - Search (
/saves search "auth bug"): Search saves by content
How to execute
Step 1: Read the index
Read ~/.claude/saves/index.jsonl. Each line is a JSON object:
{"id":"save_xxx","ts":"ISO-8601","project":"slug","type":"manual|auto","intent":"...","tags":["..."]}
If the file doesn't exist or is empty:
No saves found. Use /save to create your first checkpoint.
Parse all lines into an array. Skip any malformed lines silently.
Step 2: Filter entries
No argument: Take all entries, sort by ts descending, take the first 10.
Project slug: Filter to entries where project matches the given slug (case-insensitive). Sort by ts descending, take the first 10.
Search query (search "..."):
- Extract the search query (strip quotes if present)
- For each index entry, check if the query appears (case-insensitive) in:
intenttags(joined with spaces)
- If a match is found in the index, include it
- If fewer than 3 matches from index alone, read the full JSON files for remaining entries and search
decisionsandnext_stepsarrays too - Sort matches by
tsdescending, take the first 10
Step 3: Calculate relative times
For each entry, convert ts to human-readable:
- Under 60 minutes: "Xm ago"
- Under 24 hours: "Xh ago"
- Yesterday: "yesterday"
- Under 7 days: "X days ago"
- Under 30 days: "X weeks ago"
- Older: "YYYY-MM-DD"
Step 4: Format output
Default view (all projects):
=== Session Saves ===
ID Project When Type Intent
save_1711152000000 my-app 2h ago manual Implementing JWT auth
save_1711148400000 my-app 3h ago auto (session exit)
save_1711134000000 api-server yesterday manual Fixing rate limiter bug
save_1711120000000 my-app 2 days ago manual Database migration setup
...
Showing [N] of [total] saves across [project count] projects.
/saves <project> -- filter by project | /saves search "query" -- search
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.
- 1mo ago First seen · 122 lines · 0 tokens per session scan A 97b0d604c048
saves is a command published in the GitHub repository andrew-shwetzer/claude-code-save (2 stars, last pushed 5mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,090 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-31.
Other commands, from other repositories
recall-save
Generate / overwrite .recall/context.md with Recall's local offline summarizer.
show
Show this project's saved Recall context (.recall/context.md).
learn
Codify implicit codebase knowledge as agent rules.
ccc-context-budget
Show how full the context window is, which components use the most of it, and when to save the session and compact. Use when the session feels slow, long or near its context limit.
pin
Break checkpoint — status display, session log, optional MEMORY.md update.
atlas
Cross-project atlas with an adaptive render — ≤4 projects in scope get detail cards, more get one aligned digest line each, grouped by domain. Facets projects · sessions · memory · plans · specs · plugins · claude.md; a bare run renders all of them except plugins (opt-in, machine-global). --dir NAME|PATH anchors the…