feat: add Hermes Agent as a first-class backend and transcript source#114
Open
fgscaglioni wants to merge 3 commits into
Open
feat: add Hermes Agent as a first-class backend and transcript source#114fgscaglioni wants to merge 3 commits into
fgscaglioni wants to merge 3 commits into
Conversation
This adds full support for Nous Research's Hermes Agent across all three
SkillOpt layers — core model backend, sleep-cycle backend, and transcript
harvesting.
Core model layer (skillopt/model/):
- Register the Hermes CLI as a chat backend (hermes_chat) alongside the
existing Claude, Codex, Qwen, and MiniMax backends.
- All chat entry points (optimizer, target, messages, deployment) route
through the Hermes adapter.
Sleep-cycle backend (skillopt_sleep/backend.py):
- Add HermesBackend extending CliBackend, driving hermes --profile
<name> chat -Q -q for attempt / judge / reflect calls.
- CLI output is filtered to strip notices, warnings, and traceback
debris so the pipeline sees only the model response.
- Registered under get_backend("hermes") with aliases hermes_chat and
hermes_cli.
Transcript harvesting (skillopt_sleep/harvest_hermes.py):
- New harvest source reads Hermes session data from ~/.hermes/state.db
(SQLite), building SessionDigest objects from sessions + messages.
- Skips engine-internal sessions (temp dirs matching skillopt_sleep_*)
so the mine step only sees real user sessions.
- Supports the standard harvest contract: scope, since, limit, project.
Config additions (skillopt_sleep/config.py):
- memory_filename — controls the project memory file name.
Defaults to "CLAUDE.md" for backward compatibility.
Set to "AGENTS.md" for Codex and Hermes.
- hermes_home — path to Hermes state directory, defaults to
~/.hermes, overridable via $HERMES_HOME.
Tests:
- 7 new tests in TestHermesBackendCli covering backend registration,
command construction, error capture, output filtering, and env vars.
Backward compatible — defaults unchanged, all existing backends intact.
Author
|
@microsoft-github-policy-service agree |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds full support for Nous Research's Hermes Agent across all three SkillOpt layers — core model backend, sleep-cycle backend, and transcript harvesting.
Core model layer (skillopt/model/):
Sleep-cycle backend (skillopt_sleep/backend.py):
Transcript harvesting (skillopt_sleep/harvest_hermes.py):
Config additions (skillopt_sleep/config.py):
Tests:
Backward compatible — defaults unchanged, all existing backends intact.