Measure Hermes System Prompt and Tool Schema Size
Every Hermes turn includes a system prompt and tool schemas before the conversation itself. Profiles with many tools, long memories, or large skill indexes can spend a meaningful portion of the context window before the user’s task begins.
Official documentation: https://hermes-agent.nousresearch.com/docs/reference/cli-commands
Measure before trimming
Run hermes prompt-size for an offline byte breakdown of the assembled prompt surfaces. Compare profiles rather than guessing. Large MCP and plugin catalogs may benefit from Tool Search, while long project rules, stale memory, or redundant skills need editorial cleanup rather than a larger model.
Prompt bytes are not identical to provider tokens, but the breakdown is a practical way to find disproportionate contributors and track regressions over time.
Context-budget checklist
- Measure the intended profile, not only the default profile.
- Record the total and the largest sections.
- Keep project context concise and scoped.
- Remove stale or duplicate memory entries.
- Consolidate overlapping skills instead of deleting useful procedures blindly.
- Enable only the tools required by each platform and role.
- Use progressive tool discovery for genuinely large catalogs.
- Repeat the measurement after changes.
Pitfalls
- Treating byte count as an exact token bill.
- Deleting safety guidance because it is large without considering its value.
- Measuring one profile while another runs the production gateway.
- Loading every tool into a public or narrow worker profile.
- Assuming automatic compression can shrink the fixed system prompt.
Verification steps
- Run
hermes prompt-sizefor the target profile. - Save the high-level section totals without copying private prompt content.
- Remove or consolidate one clearly redundant source.
- Run the command again and compare totals.
- Start a fresh session and inspect its reported context limit and usage.
- Execute a representative task and verify tool discovery still works.
- Keep a threshold that triggers review when future configuration grows materially.
