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/atlasomnia/donna-starter/hermes-context-optimizationnpx skills add AtlasOmnia/donna-starter --skill hermes-context-optimizationgit clone --depth 1 https://github.com/AtlasOmnia/donna-starterWrote 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/skills/atlasomnia/donna-starter/hermes-context-optimization)<a href="https://agentmods.dev/skills/atlasomnia/donna-starter/hermes-context-optimization"><img src="https://agentmods.dev/badge/skills/atlasomnia/donna-starter/hermes-context-optimization.svg" alt="Measured on agentmods" 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.00035 | $0.07307 |
| Opus 5 | $0.00017 | $0.03653 |
| Sonnet 5 | $0.00007 | $0.01461 |
| Haiku 4.5 | $0.00003 | $0.00731 |
Grade A, and why
hermes-context-optimization 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 5d 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.
Copies of this mod
1 near-identical copy found in the catalogue:
- hermes-context-optimization — 100% identical, 0 lines differ
How it starts
The opening of the file, as written. The whole thing — 438 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Hermes Context Optimization
Use this when the user asks about Hermes prompt/context size, “hello” startup cost, compression behavior, memory/profile bloat, tool-schema overhead, skill loading, session-store/search-index storage, or multimodal/visual-context approaches such as Snapcompact.
For large state.db search-index maintenance, resumable optimize-storage --no-vacuum runs, foreground timeout handling, and post-run verification, follow references/session-store-optimization.md.
When bounded workers repeatedly fail with session_persistence_failed because a live profile DB is lock-contended, preserve the worktree handoff and use the non-disruptive isolated-HERMES_HOME workflow in references/isolated-worker-state-store.md. Diagnose the profile-specific DB and lock owners first; never terminate a user's live TUI or optimize its store merely to unblock a coding worker.
Operating style for the user
- Be concise first. If he asks for the savings, give the numbers, not a lecture.
- Separate hard blockers from engineering choices.
- Prefer token/accounting estimates grounded in actual provider/runtime data when available; use ratios only when clearly labeled.
- Do not imply that all startup prompt text is interchangeable. Bucket it by runtime role.
Long standing-goal payloads
When a long /goal prompt is displayed as a compact token such as [[ … [77 lines] … ]], treat that representation as potentially lossy rendered text, not as the authoritative goal body. Hermes' goal state stores the string it receives and does not dereference wiki-style links or recover omitted lines. Before allowing a goal worker to edit anything, require it to read the complete authoritative specification from a file and verify that the first turn contains the expected task scope. Use a short file-backed goal such as: Read and execute the complete goal specification at /absolute/path/goal.md; treat that file as authoritative; do not act on truncated display text. If the worker loads Obsidian or searches for a note matching the compact label, pause/clear the goal: it received the display placeholder, not the task. Do not accept a “goal achieved” result caused only by missing input; require artifact or test evidence.
What ships with it
13 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/compression-runtime-fallback-notes.md 1.9 KB
- references/context-overflow-recovery.md 3.4 KB
- references/gateway-voice-latency-attribution.md 2.8 KB
- references/goal-long-prompt-preservation.md 2.0 KB
- references/isolated-worker-state-store.md 4.2 KB
- references/jinja-chat-template-audit.md 2.4 KB
- references/native-context-inspection.md 2.4 KB
- references/profile-data-accuracy.md 1.7 KB
- references/prompt-composition-baseline.md 1.3 KB
- references/session-store-optimization.md 2.3 KB
- references/skill-pruning-workflow.md 1.6 KB
- references/snapcompact-hermes-boot-analysis.md 2.7 KB
- references/tool-router-architecture.md 3.6 KB
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.
- 5d ago First seen · 438 lines · 35 tokens per session scan A 19b5531fa0d0
hermes-context-optimization is a skill published in the GitHub repository AtlasOmnia/donna-starter (103 stars, last pushed 6d ago), licensed MIT. It adds 35 tokens to every session and 7,307 once invoked, about $0.0002 per session on Opus 5. 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 skills, from other repositories
obsidian-memory-architecture
Use when designing, setting up, or maintaining an Obsidian vault as Hermes Agent's durable knowledge layer. Routes facts, conversation history, documents, procedures, and daily logs to the correct Hermes or vault system without duplicating everything into the prompt.
paleo-auto
Use when you want automatic token-saving without manual skill selection. Auto-detects long sessions (>15 turns), high token usage, or bulky context — then auto-enables paleo + paleo-trim-context + paleo-converse + paleo-budget at safe defaults. User does not need to think about which skill is active. Off: "disable…
paleo-converse
Use when user says "compress conversation", "condense chat", "summarize history", "too long context", or a session has many old turns. Condense prior conversation turns into a tight summary, merge near-duplicate messages, keep the last N turns verbatim. Saves context tokens without losing task state. Off: "stop…
paleo-trim-context
Use when context window is large / token cost high / long session. Proactively trim, summarize, or drop stale content to save context tokens without losing the task state.
hermes-context-optimization
Use this when the user asks about Hermes prompt/context size, “hello” startup cost, compression behavior, memory/profile bloat, tool-schema overhead, skill loading, session-store/search-index storage, or multimodal/visual-context approaches such as Snapcompact.
hermes-mnemosyne
Mnemosyne is Hermes' primary local-first memory engine — SQLite with vector + FTS5 hybrid search, 19+ tools, auto-consolidation, and a standalone CLI. It's a pip-installed plugin (not a built-in toolset) discovered via $HERMESHOME/plugins/mnemosyne/.