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 skills/borda/ai-rig/sessionnpx skills add Borda/AI-Rig --skill sessiongit clone --depth 1 https://github.com/Borda/AI-RigWhat 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.00209 | $0.05029 |
| Opus 5 | $0.00105 | $0.02514 |
| Sonnet 5 | $0.00042 | $0.01006 |
| Haiku 4.5 | $0.00021 | $0.00503 |
Grade B, and why
session scanned grade B with 1 finding 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 3d 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.
Reads agent configuration directoriesmediumAgent snooping
.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.
find .claude/state/session -maxdepth 1 -name '*.md' ! -name 'PARKED.md' -mtime +30 -delete 2>/dev/null; echo "sweep done" # timeout: 5000 How it starts
The opening of the file, as written. The whole thing — 337 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Carry the durable part of a session across /clear, and hold open loops until they land. dump composes a small handover doc from the live conversation, writes it to .claude/state/session/<slug>.md, and ends by printing /clear. The session-restore.js hook (SessionStart, matcher clear) injects that doc into the fresh session, so restore is free. Implementation detail — diffs, tool output, exploration transcript, abandoned approaches — is dropped on purpose; only the decision that settled an approach survives.
Runs inline, never context: fork. The conversation history is the authoritative source for what changed, what was decided, and what never landed; a forked run would see none of it.
NOT for: auto-compact survival (compaction.md skill contract); reviving a finished conversation (native /resume). Boundary table in the notes section below.
- $ARGUMENTS: required. Six modes:
dump [name]— sweep, compose and write the handover doc, set theLATESTpointer, print the/clearnext step.nameoptional; unnamed dumps derive a slug from branch + UTC timestamp.recall [name]— print a stored handover into context and mark it consumed. Named, orLATESTwhen omitted. Manual path for the dumps the hook skips.list— table of stored handovers (slug, age, consumed) plus the open parked items.park <idea>— append one open-loop item to.claude/state/session/PARKED.md. No dump needed; works any time.sweep— read the conversation for unlanded ideas, unanswered questions and pending tasks; report them and offer to park.drop <item>— fuzzy-match a parked item and remove it, logging the closure.
- Store dir:
.claude/state/session/(project-local;.claude/state/is gitignored, same assession-context.md) - Item store:
.claude/state/session/PARKED.md— one bullet per open item; survives every dump, never auto-deleted - Pointer file:
.claude/state/session/LATEST— plain text, the slug of the most recent unconsumed dump. Blank or missing = nothing pending. - Closure log:
.claude/state/session/dropped.jsonl— one JSON line perdrop - Doc size cap: ~1.5K tokens (~75 lines). Compress prose, never drop a decision.
- Hook auto-restore window: unconsumed and
createdwithin 30 min. Outside it,recallis the manual path. - Hook truncation threshold: ~8000 chars — above it the hook injects
## Goal+ files table +## Next step+ a→ /foundry:session recall <slug>pointer instead of the whole doc. - Stale threshold: 14 days (
⚠ staleprefix when listing) — applies to handover docs and parked items - Delete threshold: 30 days — handover docs only, swept during
list. Parked items are never auto-deleted; onlydropremoves one. - Files-table row cap: 25 (over that, group by directory and state the elided count)
Task hygiene: load and follow the protocol below.
# audit-skip: resilience-replication
python "${CLAUDE_PLUGIN_ROOT:-plugins/cc_foundry}/bin/load_shared_doc.py" foundry skills/_shared task-hygiene.md # timeout: 5000
Step 0: Validate and dispatch mode
Extract first word of $ARGUMENTS as MODE.
If MODE matches:
dump(alias:save) → Mode: dumprecall(aliases:restore,load) → Mode: recalllist→ Mode: listpark→ Mode: parksweep→ Mode: sweepdrop(alias:archive) → Mode: drop
Unsupported flag check — after extracting the mode token, scan $ARGUMENTS for remaining --<token> patterns. If found: print ! Unknown flag(s): `--<token>`. Supported modes: dump, recall, list, park, sweep, drop. then invoke AskUserQuestion — (a) Abort (stop, re-invoke correctly) · (b) Continue ignoring (skip unknown flags, proceed with recognized mode).
Otherwise (empty, unrecognized, misspelled): use AskUserQuestion:
"Which session mode did you want?"
Options: (a)
dump [name]— write the handover doc now, (b)park <idea>— stash one open loop without derailing, (c)sweep— audit the conversation for unlanded work, (d)list— stored handovers and open items
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.
- 3d ago First seen · 337 lines · 209 tokens per session scan B ef11cbb9599e
session is a skill published in the GitHub repository Borda/AI-Rig (25 stars, last pushed 9d ago), licensed Apache-2.0. It adds 209 tokens to every session and 5,029 once invoked, about $0.0010 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
apm-usage
Activate when the user asks about APM (Agent Package Manager): installing, configuring, authoring, or troubleshooting AI-agent packages, dependencies, compilation, MCP servers, policy, or any apm CLI command.
clean-user-facing-text
Audit and finalize authorized natural-language text meant for readers: strip suspicious invisible Unicode, then rewrite prose while keeping facts, meaning, and the writer's voice. Use when the user asks to clean, humanize, polish, or finalize articles, manuscripts, reports, documentation, emails, product copy, UI…
sessions
Search and ask questions about coding agent session history across Claude Code, Codex, and Cursor. Use when asking what was worked on, what was tried before, how a problem was investigated across sessions, what happened recently, or any question about past agent sessions. Also use when the user references prior…
codex-autoresearch
Run autonomous, measurable experiments in a Git repository: change one hypothesis, verify a numeric metric, keep improvements, and revert failures. Use when the user wants Codex to keep iterating toward a numeric target in the foreground or as a detached background run. Do not use for ordinary one-shot coding…
daily-budget-check
Run a daily spend check-in against a daily budget on the Agent Monitor dashboard — today's spend vs the daily target, pace through the day, and the projected overage if the current pace holds. Uses /api/pricing/cost and /api/sessions (grouped by startedat = today). Use for a quick daily spend check-in or a…
ship-feature
Implement a feature safely end-to-end in this repository. Use when adding or changing functionality across backend, frontend, or MCP with required verification and documentation updates.