All plugins

checkpoint-resume

Re-arms a working-status digest after a context compaction or when a session opens: at post_compaction, on_session_open and on_session_start it runs the local commands you list in inject_commands, stores their live output as pending per-session state, and the next pre_llm_call returns it as {context: ...} so Hermes appends it to that turn's user message exactly once, letting an agent resume from real status output instead of a paraphrased summary. Config-driven and inert until configured: empty inject_commands (the default) runs nothing and injects nothing, so it costs zero tokens. Not a memory provider, not a compressor, not a conversation checkpoint: the payload is command output. Disclosure — runs shell subprocesses, only the commands the user puts in plugins.entries.checkpoint-resume.settings.inject_commands, each under command_timeout_seconds (default 25 s); those commands inherit the full Hermes process environment (provider API keys included) and can read whatever the user's own scripts can read, and their output is injected into the next turn and sent to the model provider; writes only its own plugin-data state.json through PluginState (host quota 10 MiB); injected text is capped by max_chars (default 2600) and max_commands (default 6); every callback is fail-open; no network calls of its own, no LLM calls, no credentials, no telemetry, no self-updating code.

lilaoGeneralv0.2.2Updated 2 hours ago

About

Re-arms a working-status digest after a context compaction or when a session opens: at post_compaction, on_session_open and on_session_start it runs the local commands you list in inject_commands, stores their live output as pending per-session state, and the next pre_llm_call returns it as {context: ...} so Hermes appends it to that turn's user message exactly once, letting an agent resume from real status output instead of a paraphrased summary. Config-driven and inert until configured: empty inject_commands (the default) runs nothing and injects nothing, so it costs zero tokens. Not a memory provider, not a compressor, not a conversation checkpoint: the payload is command output. Disclosure — runs shell subprocesses, only the commands the user puts in plugins.entries.checkpoint-resume.settings.inject_commands, each under command_timeout_seconds (default 25 s); those commands inherit the full Hermes process environment (provider API keys included) and can read whatever the user's own scripts can read, and their output is injected into the next turn and sent to the model provider; writes only its own plugin-data state.json through PluginState (host quota 10 MiB); injected text is capped by max_chars (default 2600) and max_commands (default 6); every callback is fail-open; no network calls of its own, no LLM calls, no credentials, no telemetry, no self-updating code.

checkpoint-resume

A Hermes plugin that re-arms your working status after a context compaction or a new session — without
waiting for the user to ask for it.

On post_compaction, on_session_open and on_session_start it runs the local commands you
configure, stores their real output as pending per-session state, and on the next pre_llm_call returns
that output as {"context": ...} so Hermes appends it verbatim to that turn's user message, once.

Unconfigured it runs nothing and injects nothing: zero token cost until you point it at something.

It is not a memory system, not a compressor, and not a task tracker. It is the small seam between
"something just got summarised away" and "here is the live output of my own status commands".

Why this shape (read from hermes-agent source, 2026-12-01)

  • post_compaction fires on every committed compaction (agent/compaction_events.py,
    fire_post_compaction) — auto, manual, gateway, Codex, micro, prune — but it is an observer: its
    return value is ignored, so it cannot put text into the model's context.
  • pre_llm_call is the hook that can: returning {"context": "..."} appends the text to the current
    turn's user message (agent/turn_context.py, _collect_pre_llm_call_context).
  • So a boundary event cannot inject by itself. This plugin splits it in two: the boundary arms a
    digest, the next pre_llm_call delivers it.
  • Turn order matters: in a turn that starts above the compression threshold, _collect_pre_llm_call_context
    runs before run_turn_start_compaction (same file, comment "Before turn-start compaction"). A digest
    armed by that compaction therefore lands on the next turn, not on the turn that compacted. Verified
    live: armed digest … 00:34:40 → injected 702 chars … 00:47:28, same session.

Install

hermes plugins install <owner>/checkpoint-resume      # or a git URL
hermes plugins enable checkpoint-resume

Configure — this is the part you must do

Status text is injected only for the commands you list. Add to ~/.hermes/config.yaml:

plugins:
  entries:
    checkpoint-resume:
      enabled: true
      settings:                     # where Hermes stores a plugin's own settings (`config:` is still read, legacy)
        inject_commands:
          - label: "open work items"
            argv: ["/usr/bin/python3", "/path/to/your/open_items.py"]
            cwd: "/path/to/your/vault"
          - label: "checkpoint self-check"
            command: "/usr/bin/python3 /path/to/your/checkpoint_check.py"
        note: "Resume from the declared next step; do not re-run finished steps."
KeyDefaultMeaning
inject_commands[]Commands to run at each boundary. argv list, command string, or {label, argv|command, cwd}. Empty means the plugin never injects.
max_commands6Cap per digest, bounds the cost of one injection
max_chars2600Cap of the injected text
command_timeout_seconds25Per-command timeout; keep it below plugins.hook_callback_timeout (core default 30 s) because these hooks run on bounded worker threads
max_age_seconds21600An unconsumed digest older than this is dropped instead of injected late
skip_subagentstrueDelegated child sessions do not get their own injection
require_nonemptytrueArm only when at least one command produced output
note""Optional fixed line injected above the command output

Check it is working

hermes plugins validate .            # manifest, hooks, capabilities, security scan, no core override
hermes plugins show checkpoint-resume
python3 tests/test_hooks.py          # hook-level tests (add --real to use Hermes' PluginState)
grep -a checkpoint-resume ~/.hermes/logs/agent.log | tail

Expected log pair once a boundary happens:

INFO hermes.plugins.checkpoint_resume: checkpoint-resume: armed digest for session local-… (702 chars, store=PluginState, compaction kind=summarize reason=turn_start_threshold tokens 172390->31372)
INFO hermes.plugins.checkpoint_resume: checkpoint-resume: injected 702 chars into session local-…

Known boundaries (measured, not theoretical)

  • Injection lands on the next turn, not the turn that compacted (turn-order note above).
  • Persistence is per plugin process. If the armed digest could not reach PluginState, it lives only in
    process memory and a killed process loses it. The armed log line reports which store was used
    (store=PluginState vs store=in-process); the state file lives in ~/.hermes/plugin-data/.
  • The injected text is a snapshot taken when the boundary fired. If your own status files change between
    the compaction and the injection, the injected copy is stale. Recomputing inside pre_llm_call would
    fix that at the cost of 1–2 s on the injecting turn — deliberately not done here.
  • Callbacks are fail-open: a broken command or a failed state write logs at INFO and the turn proceeds
    normally. So injection is not a guarantee; anything that must survive a compaction should also live
    in files.
  • A new session often arms twice (on_session_open and on_session_start fire on worker threads and
    overlap). A claim is written before the command work so the second arm skips it, and injection still
    happens once.
  • requires_hermes: ">=0.23.1" — floor taken from the earliest Hermes release whose tag contains
    on_session_open (commit e412d4c6a4, in v0.23.1, released 2026-11-10). Older releases lack that
    hook; post_compaction and pre_llm_call are older and PluginState landed in v0.21.6, so the
    hook is what binds.

Disclosure

  • No network calls. No LLM calls. No credentials. No telemetry. No self-updating code.
  • It runs subprocesses — only the commands you put in inject_commands — each with a timeout.
  • Read reach equals your scripts' reach: the plugin itself reads nothing outside its own
    plugin-data/ state file, but the commands you configure can read whatever they are able to read.
  • Writes only its own state file under ~/.hermes/plugin-data/ (host quota 10 MiB, per-key size checked).
  • Extends Hermes only through the four hooks; it does not patch, wrap or rebind Hermes internals.

Not this plugin

agent-checkpoint and ctx_checkpoint in the Hermes catalog are different tools (budget / context
checkpointing), and constraint-vault re-injects pinned verbatim text on every turn. This one re-injects
live command output, only at a compaction or new-session boundary, and only when configured.

MIT licensed.

README from the reviewed commit 56d5d7d; it updates when the author re-pins.

Developer Mode

Explore built-in Hermes toolsets and actions.

HermesAgent

Developer?

Create a Hermes extension for Desktop or agent workflows.

Developer Section