Borrowing it
Nothing to install: this file belongs to betmoar/cc-reload-plugin. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/betmoar/cc-reload-plugin/main/CLAUDE.mdgit clone --depth 1 https://github.com/betmoar/cc-reload-pluginWrote 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/instructions/betmoar/cc-reload-plugin/claude-md)<a href="https://agentmods.dev/instructions/betmoar/cc-reload-plugin/claude-md"><img src="https://agentmods.dev/badge/instructions/betmoar/cc-reload-plugin/claude-md/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/instructions/betmoar/cc-reload-plugin/claude-md"><img src="https://agentmods.dev/badge/instructions/betmoar/cc-reload-plugin/claude-md.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.18152 | $0.18152 |
| Opus 5.5 | $0.07261 | $0.07261 |
| Sonnet 5.5 | $0.03630 | $0.03630 |
| Haiku 4.5 | $0.01815 | $0.01815 |
Grade A, and why
cc-reload-plugin CLAUDE.md scanned grade A 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 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.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
fail-open-silent on literally anything going wrong (down, no `curl`, timeout, bad JSON, missing or How it starts
The opening of the file, as written. The whole thing — 734 lines — stays where its author put it; the contents beside it link to each section on GitHub.
cc-reload — maintainer handoff
This file is the mental model for anyone (human or agent) changing this plugin. Read it before
touching hooks/. The README explains what the plugin does for users; this explains why the
code is shaped the way it is, which invariants are load-bearing, and how to change each piece
without breaking the others.
What this is, in one paragraph
Four bash hooks + three slash commands + one skill that keep a Claude Code session's working
thread alive across context resets. State machine on disk under the user's project at .reload/:
a digest (session.md), a one-shot arm marker (pending, now stamped with its arming session
id when known), a two-pass handshake marker (summarizing), a notify ladder (notified), a
model/window stamp (model, one session: line per session since 0.5.0), per-project config
(config), side-filed digests from a detected cross-session collision (session.<id>.md, since
0.3), and — since 0.5.0 — per-lineage arms (pending.<pid>, keyed on the Claude Code PROCESS id,
which /clear keeps) and an append-only journal of every snapshot/arm/side-file/rehydrate. The
fourth hook, PreToolUse, is a same-session enforcement point for the collision guard (and the
journal's snapshot writer), not a new continuity mechanism. There is no daemon, no state anywhere
else, and no network on the per-turn hot path — SessionStart makes one optional loopback-only
lookup against a local cc-proxy (see the proxy_window() decision below), fail-open, never
repeated per-turn. User-facing docs: README (short) + docs/how-it-works.md,
docs/concurrent-sessions.md, docs/statusline.md.
Control flow (the whole system)
Stop hook (every turn end)
├─ summarizing marker present AND not another LIVE process's (invariant 22)?
│ → PASS 2: consume marker; if digest exists, arm THIS lineage's slot (lib.sh arm_reload:
│ `pending.<CLAUDE_PID>`, else bare `pending`) and VERIFY it with -f
│ (not a regular file → "reload NOT armed", never "saved")
│ (fresh digest → success msg; digest not rewritten this turn → arm anyway, warn honestly;
│ no digest → do NOT arm, warn)
│ (occupancy below = the last MAIN-THREAD assistant row of a tail window of the transcript,
│ per-line parsed; full-file stream only if the window holds none — invariant 14)
├─ stop_hook_active && no marker? → stand down (broken handshake must never re-block = loop)
├─ occupancy < budget? → clear the `notified` ladder, exit silently
└─ occupancy ≥ budget → branch on context_budget_mode (default notify):
├─ snapshot mode AND not armed_here (no consumable arm entry; a foreign LIVE arm does
│ NOT count — F12; a stray directory DOES: -e, invariant 15) [legacy `checkpoint` aliases here]
│ → PASS 1: unless another LIVE process's `summarizing` sits there (then notify instead),
│ write `summarizing` (sid + pid) and VERIFY it with -f (or refuse to block),
│ emit {decision:"block"} re-injecting "write .reload/session.md, then STOP"
└─ notify mode, OR snapshot mode already armed_here
→ laddered nudge: {systemMessage} only — never blocks, zero model tokens.
Fires on first crossing, then only at last-notified +10 points (`notified`
stores the %). Ladder unwritable → silent (else it would nag every turn).
PreCompact hook (manual /compact or auto-compaction)
└─ arm this lineage's slot (arm_reload); on failure journal `arm-failed` (CC DISCARDS PreCompact's
systemMessage — the SessionStart(compact) that follows surfaces it); if no digest exists,
write a mechanical fallback stub (honest about being thin)
SessionStart hook (startup|resume|clear|compact|fork)
├─ stamp model id + resolved window to .reload/model, PER SESSION (`session:` line; Stop gets no
│ model field — this bridges it; another session's startup never moves this one's window)
├─ startup|clear|compact (NOT resume|fork) → purge `notified`, and `summarizing` unless it is
│ another LIVE process's (invariant 22); a handshake must not outlive its context (invariant 10)
├─ arms_here (own `pending.<pid>` first, then bare `pending` + ORPHANS whose pid is dead, newest
│ first; a foreign LIVE arm is NEVER listed) empty?
│ ├─ foreign live arm(s) exist → 🔒 notice "left in place, this session starts fresh", journal
│ │ `defer`, exit — invariant 21
│ ├─ source=compact and the journal's last event is `arm-failed` → surface it once (F06)
│ └─ else do nothing (a deliberate /clear is respected)
└─ else → resolve the digest: session.md, or, when its owner ≠ the arm's sid and a side-file
`session.<armsid>*.md` exists, that side-file (this lineage's OWN thread — no warning);
no side-file → session.md + the incoherence WARNING (never gates — invariant 3);
consume every listed arm (one-shot); claim session.md (only when it is the source);
inject as additionalContext + visible banner; warn above the 10,000-char hook-output cap
(F05); journal `rehydrate`
PreToolUse hook (model Write/Edit)
└─ path == $DIGEST && tool is Write|Edit?
→ journal `snapshot`; with a session_id → claim-digest.sh: foreign + fresh incumbent ->
side-file (journal `sidefile`) + warn; ALWAYS exit 0 (permit)
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 Changed · +166 lines · +4,441 tokens per session 23d8e40fa71c
- 1mo ago Changed · +133 lines · +3,415 tokens per session b0b4868bed30
- 1mo ago Changed · +33 lines · +874 tokens per session de4e8bf54446
- 1mo ago Changed · +157 lines · +4,209 tokens per session 7beca7b18acf
- 1mo ago First seen · 245 lines · 5,213 tokens per session scan A 05e202842025
cc-reload-plugin CLAUDE.md is an instructions file published in the GitHub repository betmoar/cc-reload-plugin (1 stars, last pushed 1mo ago), licensed MIT. It adds 18,152 tokens to every session, about $0.0726 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode copilot-instructions.md
Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).
vscode model-prompts.instructions.md
Model-specific prompt authoring and registry guidelines.