Skip to content
AI Primer
workflow

Hermes Agent removes 375,000 lines in a 15-hour recursive cleanup run

Nous Research says a 15-hour Hermes Agent run used waves of roughly 120 subagents on one desktop machine to simplify its repository. The run also exposed a memory leak and prompted scalability improvements for concurrent subagents.

3 min read
Hermes Agent removes 375,000 lines in a 15-hour recursive cleanup run
Hermes Agent removes 375,000 lines in a 15-hour recursive cleanup run

TL;DR

  • Hermes Agent reportedly simplified or removed 375,000 lines during a 15-hour repository cleanup, according to Teknium's run report.
  • One standing goal produced waves of roughly 120 live workers, including recursive child spawning, and 1,320 total subagent lifecycles, Teknium reported in his thread.
  • The run used Fable 5.1, while most host load came from Hermes running its own test suite in parallel, as Teknium said in a follow-up and another reply.
  • A memory leak surfaced without interrupting the machine, and Teknium said in a scale-up update that the exercise was already yielding concurrency improvements.
  • The resulting change is still unmerged and under regression review, according to Teknium and his follow-up.

The v0.21.0 release lists live subagent steering, bot-to-bot DMs, and persistent multi-gateway connections. Hermes's persistent-goals documentation says a lightweight judge decides whether work continues after each turn; the delegation documentation says each child starts with a fresh context and only returns a final summary to its parent.

The 15-hour `/goal` run

Teknium said the cleanup began with a standard, simple /goal <prompt> in a reply, rather than a published multistage runbook.

At one checkpoint, the goal had a 50-loop ceiling and was at 41 after 15 hours, 7 minutes, and 57 seconds.

The line-count figure was moving during the run. Teknium's original estimate was 375,000 lines; he later gave a raw 1.04M to 650K count in a later reply, which implies 390,000.

Isolated workers and shared state

Teknium described waves of about 120 concurrent subagents, three sets of 15 subagents whose children could spawn more children, and 1,320 agents that “lived and died” across the session in his thread.

The docs put the default at three concurrent subagents, configurable with no hard ceiling. Each delegate_task receives a fresh conversation, inherited tools, and its own terminal session; Teknium said in a reply that these workers also had a shared notepad.

The v0.21 desktop feature connects local and remote agent instances, but Teknium characterized this particular setup as one CLI profile with many Hermes instances accessed through VS Code SSH in a reply. He said the host was a consumer Linux desktop with 64 GB of RAM and an i9-4700K in another reply; inference came from Fable 5.1 rather than a local model, he added in a follow-up.

Test-suite load and memory leak

Most of the machine load came from Hermes running Hermes's own test suite in parallel, Teknium said in a reply. The refactor therefore doubled as an internal concurrency stress test.

Teknium reported finding a memory leak in a follow-up, but said it did not interrupt or degrade the machine. His scale-up update says the same run was already driving optimizations to concurrent-subagent scalability.

Four thousand commits, still unmerged

The cleanup has not landed in the repository's main branch.

Teknium said the refactor PR contains more than 4,000 commits in a reply. He said in a follow-up that the work was complete and the team was reviewing it for regressions, and that he now runs /review at the end in another reply.

Teknium said he intends to publish a blog postmortem in a follow-up.

Further reading

Discussion across the web

Where this story is being discussed, in original context.

On X· 5 threads
TL;DR4 posts
The 15-hour `/goal` run3 posts
Isolated workers and shared state4 posts
Test-suite load and memory leak2 posts
Four thousand commits, still unmerged4 posts
Share on X