Nous Research open-sources GEPA engine for self-evolving AI agent prompts
Hermes Agent Self-Evolution lets agents rewrite their own prompts via reflective evolutionary search — 35× less data than RL, 20% better results, no GPU needed.
Nous Research has released , an open-source framework that lets AI agents evolve their own prompts, skill files, and tool descriptions through a reflective evolutionary loop. The core engine, GEPA (Genetic-Pareto Prompt Evolution), was accepted as an Oral presentation at ICLR 2026. According to the repository, GEPA achieves 20% higher performance while using 35 times less data than reinforcement-learning approaches. The entire process runs via API calls — no GPU training required — and costs roughly $2–10 per optimization run.
How the evolutionary loop works
GEPA reads execution traces to understand why a skill or prompt failed, not just that it failed. It then proposes targeted mutations, evaluates candidates against a generated or real-world dataset, and passes the best variant through a series of constraint gates before opening a pull request against the upstream hermes-agent repository. The pipeline is illustrated in the repository as a flow from reading the current skill through dataset generation, GEPA optimization, evaluation, constraint checks, and finally a PR.
Read current skill/prompt/tool ──► Generate eval dataset
│
▼
GEPA Optimizer ◄── Execution traces
│ ▲
▼ │
Candidate variants ──► Evaluate
│
Constraint gates (tests, size limits, benchmarks)
│
▼
Best variant ──► PR against hermes-agentBecause the optimizer works on text — prompts, tool descriptions, system-prompt sections — it can be applied to any agent that exposes its skills as markdown or code files. The repository currently targets Hermes Agent, but the pattern is portable.
Quick start: evolving a skill
Clone the repository, install the editable package with development dependencies, and point the HERMES_AGENT_REPO environment variable at a local copy of hermes-agent. Two evaluation sources are supported: synthetic data generated on the fly, or real session history pulled from Claude Code, Copilot, or Hermes itself.
# Install
git clone https://github.com/NousResearch/hermes-agent-self-evolution.git
cd hermes-agent-self-evolution
pip install -e ".[dev]"
# Point at your hermes-agent repo
export HERMES_AGENT_REPO=~/.hermes/hermes-agent
# Evolve a skill (synthetic eval data)
python -m evolution.skills.evolve_skill \
--skill github-code-review \
--iterations 10 \
--eval-source synthetic
# Or use real session history from Claude Code, Copilot, and Hermes
python -m evolution.skills.evolve_skill \
--skill github-code-review \
--iterations 10 \
--eval-source sessiondbThe --iterations flag controls how many evolutionary generations run. Each iteration mutates the prompt, evaluates the candidates, and keeps the Pareto-optimal set.
Optimization roadmap: five phases
The project defines a phased plan. Phase 1 — skill files (SKILL.md) — is implemented and driven by DSPy + GEPA. Phases 2 and 3 target tool descriptions and system-prompt sections respectively, also using DSPy + GEPA. Phase 4 will evolve tool implementation code via the Darwinian Evolver, an external CLI licensed AGPL v3. Phase 5 envisions a continuous improvement loop that runs automatically. The full architecture, evaluation-data strategy, constraints, and benchmark integration are documented in PLAN.md.
Two engines, different licenses
The reflective prompt engine combines DSPy with GEPA, both MIT-licensed. The code-evolution engine wraps Darwinian Evolver, which is AGPL v3 and invoked only as an external CLI. This separation keeps the core repository MIT while allowing the more restrictive license to stay at the boundary.
Guardrails that every variant must pass
Before a mutated skill or prompt can be merged, it must clear five gates: the full pytest tests/ -q suite must pass at 100%; skill files are capped at 15 KB and tool descriptions at 500 characters; caching compatibility is enforced so no mid-conversation changes occur; semantic preservation checks prevent drift from the original purpose; and every change goes through human PR review — no direct commits. These constraints are designed to keep the evolutionary process safe for production agents.
The repository carries 5,706 stars and 703 forks as of the last update on 2026-06-17, with 131 open issues tracking feature work and bug reports. Development is active under the MIT license, copyright 2026 Nous Research.
Related reading
- Nous Research publishes plugin creation guide for Hermes agents
- Anthropic is introducing Claude Fable 5.2 and Mythos 5.2
- Awesome-REA: 5,191 Curated Resources for Reverse Engineering Across Six Domains
Sources
Related news
Open SourceHermes Agent tops GitHub weekly growth with self-improving AI agentNous Research's hermes-agent leads this week's fastest-growing repositories, adding a built-in learning loop that creates skills from experience. Also trending: Karpathy-inspired Claude Code guideline·same source: github.com
- Open SourceGoogle Harness²: Open-Source Framework for Recursive AI Agent ManagementGoogle releases Harness², an open-source framework enabling AI agents to recursively improve workflows and adapt to new tasks without model retraining.·same source: github.com
Comments
Weekly digest
The best of vibe coding, AI agents and open source — once a week, no spam.