openhermes 2.8.0 → 4.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CONTEXT.md +18 -0
- package/ETHOS.md +15 -0
- package/README.md +135 -292
- package/bootstrap.mjs +174 -512
- package/harness/agents/openhermes.md +87 -0
- package/harness/codex/CONSTITUTION.md +70 -148
- package/harness/codex/ROUTING.md +126 -0
- package/harness/commands/oh-doctor.md +26 -0
- package/harness/instructions/CONVENTIONS.md +206 -206
- package/harness/instructions/RUNTIME.md +54 -31
- package/harness/skills/oh-builder/SKILL.md +98 -0
- package/harness/skills/oh-caveman/SKILL.md +33 -0
- package/harness/skills/oh-expert/SKILL.md +121 -0
- package/harness/skills/oh-freeze/SKILL.md +28 -0
- package/harness/skills/oh-gauntlet/SKILL.md +119 -0
- package/harness/skills/oh-grill/SKILL.md +77 -0
- package/harness/skills/oh-guard/SKILL.md +33 -0
- package/harness/skills/oh-handoff/SKILL.md +33 -0
- package/harness/skills/oh-health/SKILL.md +90 -0
- package/harness/skills/oh-init/SKILL.md +78 -0
- package/harness/skills/oh-investigate/SKILL.md +35 -0
- package/harness/skills/oh-issue/SKILL.md +36 -0
- package/harness/skills/oh-learn/SKILL.md +28 -0
- package/harness/skills/oh-manifest/SKILL.md +84 -0
- package/harness/skills/oh-plan-review/SKILL.md +128 -0
- package/harness/skills/oh-planner/SKILL.md +159 -0
- package/harness/skills/oh-prd/SKILL.md +35 -0
- package/harness/skills/oh-retro/SKILL.md +33 -0
- package/harness/skills/oh-review/SKILL.md +110 -0
- package/harness/skills/oh-security/SKILL.md +110 -0
- package/harness/skills/oh-ship/SKILL.md +39 -0
- package/harness/skills/oh-skill-craft/SKILL.md +107 -0
- package/harness/skills/oh-skills-link/SKILL.md +29 -0
- package/harness/skills/oh-skills-list/SKILL.md +31 -0
- package/harness/skills/oh-triage/SKILL.md +36 -0
- package/index.mjs +3 -60
- package/lib/harness-resolver.mjs +77 -0
- package/lib/logger.mjs +62 -0
- package/package.json +49 -53
- package/test/plugins-behavioral.test.mjs +64 -0
- package/test/plugins.test.mjs +62 -0
- package/autorecall.mjs +0 -237
- package/curator.mjs +0 -482
- package/harness/commands/build-fix.md +0 -60
- package/harness/commands/checkpoint.md +0 -68
- package/harness/commands/code-review.md +0 -71
- package/harness/commands/doctor.md +0 -42
- package/harness/commands/eval.md +0 -89
- package/harness/commands/go-build.md +0 -87
- package/harness/commands/go-review.md +0 -71
- package/harness/commands/harness-audit.md +0 -90
- package/harness/commands/learn.md +0 -37
- package/harness/commands/loop-start.md +0 -38
- package/harness/commands/loop-status.md +0 -30
- package/harness/commands/memory-search.md +0 -37
- package/harness/commands/model-route.md +0 -32
- package/harness/commands/ohc.md +0 -13
- package/harness/commands/orchestrate.md +0 -88
- package/harness/commands/plan.md +0 -53
- package/harness/commands/quality-gate.md +0 -35
- package/harness/commands/refactor-clean.md +0 -102
- package/harness/commands/rust-build.md +0 -78
- package/harness/commands/rust-review.md +0 -65
- package/harness/commands/security.md +0 -93
- package/harness/commands/setup-pm.md +0 -65
- package/harness/commands/skill-create.md +0 -99
- package/harness/commands/test-coverage.md +0 -80
- package/harness/commands/update-codemaps.md +0 -81
- package/harness/commands/update-docs.md +0 -67
- package/harness/commands/verify.md +0 -68
- package/harness/prompts/architect.txt +0 -189
- package/harness/prompts/build-cpp.md +0 -98
- package/harness/prompts/build-error-resolver.md +0 -44
- package/harness/prompts/build-go.md +0 -340
- package/harness/prompts/build-java.md +0 -140
- package/harness/prompts/build-kotlin.md +0 -137
- package/harness/prompts/build-rust.md +0 -108
- package/harness/prompts/code-reviewer.md +0 -40
- package/harness/prompts/doc-updater.md +0 -206
- package/harness/prompts/docs-lookup.md +0 -71
- package/harness/prompts/e2e-runner.txt +0 -317
- package/harness/prompts/explore.md +0 -42
- package/harness/prompts/harness-optimizer.md +0 -42
- package/harness/prompts/loop-operator.md +0 -53
- package/harness/prompts/planner.md +0 -37
- package/harness/prompts/refactor-cleaner.md +0 -256
- package/harness/prompts/review-cpp.md +0 -81
- package/harness/prompts/review-database.md +0 -261
- package/harness/prompts/review-go.md +0 -257
- package/harness/prompts/review-java.md +0 -113
- package/harness/prompts/review-kotlin.md +0 -143
- package/harness/prompts/review-python.md +0 -101
- package/harness/prompts/review-rust.md +0 -77
- package/harness/prompts/security-reviewer.md +0 -42
- package/harness/prompts/tdd-guide.md +0 -228
- package/harness/rules/audit.md +0 -84
- package/harness/rules/checkpointing.md +0 -75
- package/harness/rules/context-loading.md +0 -33
- package/harness/rules/credential-exposure.md +0 -0
- package/harness/rules/delegation.md +0 -80
- package/harness/rules/handoff.md +0 -267
- package/harness/rules/memory-management.md +0 -28
- package/harness/rules/precedence.md +0 -52
- package/harness/rules/promotion.md +0 -46
- package/harness/rules/ranking.md +0 -64
- package/harness/rules/retrieval.md +0 -94
- package/harness/rules/runtime-guards.md +0 -196
- package/harness/rules/self-heal.md +0 -79
- package/harness/rules/session-start.md +0 -34
- package/harness/rules/skills-management.md +0 -165
- package/harness/rules/state-drift.md +0 -192
- package/harness/rules/verification.md +0 -88
- package/harness/scripts/sync-commands.mjs +0 -259
- package/harness/skills/.bundled_manifest +0 -17
- package/harness/skills/.usage.json +0 -6
- package/harness/skills/api-design/SKILL.md +0 -523
- package/harness/skills/backend-patterns/SKILL.md +0 -598
- package/harness/skills/coding-standards/SKILL.md +0 -549
- package/harness/skills/e2e-testing/SKILL.md +0 -326
- package/harness/skills/frontend-patterns/SKILL.md +0 -642
- package/harness/skills/frontend-slides/SKILL.md +0 -184
- package/harness/skills/security-review/SKILL.md +0 -495
- package/harness/skills/strategic-compact/SKILL.md +0 -131
- package/harness/skills/tdd-workflow/SKILL.md +0 -463
- package/harness/skills/verification-loop/SKILL.md +0 -126
- package/lib/ambient-memory.mjs +0 -167
- package/lib/handoff.mjs +0 -171
- package/lib/hardening.mjs +0 -146
- package/lib/memory-tools-plugin.mjs +0 -368
- package/lib/ohc/block-sync.mjs +0 -69
- package/lib/ohc/compress/search.mjs +0 -152
- package/lib/ohc/compress/state.mjs +0 -76
- package/lib/ohc/config.mjs +0 -185
- package/lib/ohc/message-ids.mjs +0 -178
- package/lib/ohc/notify.mjs +0 -135
- package/lib/ohc/protected-patterns.mjs +0 -55
- package/lib/ohc/prune-apply.mjs +0 -134
- package/lib/ohc/pruner.mjs +0 -608
- package/lib/ohc/reaper.mjs +0 -70
- package/lib/ohc/state.mjs +0 -265
- package/lib/ohc/strategies/deduplication.mjs +0 -72
- package/lib/ohc/strategies/index.mjs +0 -2
- package/lib/ohc/strategies/purge-errors.mjs +0 -43
- package/lib/ohc/token-utils.mjs +0 -26
- package/lib/ohc/updater.mjs +0 -132
- package/lib/paths.mjs +0 -49
- package/lib/schema-validator.mjs +0 -79
- package/lib/search.mjs +0 -48
- package/schemas/audit.schema.json +0 -82
- package/schemas/backlog.schema.json +0 -63
- package/schemas/checkpoint.schema.json +0 -65
- package/schemas/constraint.schema.json +0 -62
- package/schemas/decision.schema.json +0 -63
- package/schemas/instinct.schema.json +0 -63
- package/schemas/loop-state.schema.json +0 -33
- package/schemas/mistake.schema.json +0 -64
- package/schemas/verification_receipt.schema.json +0 -88
- package/skill-builder.mjs +0 -88
package/CONTEXT.md
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# OpenHermes — Shared Language
|
|
2
|
+
|
|
3
|
+
## Terms
|
|
4
|
+
**OpenHermes** — OpenCode-native orchestration layer for this package.
|
|
5
|
+
**Skill** — A `SKILL.md` loaded on demand through OpenCode's skill tool.
|
|
6
|
+
**Command** — A slash command backed by package-local markdown in `harness/commands/`.
|
|
7
|
+
**Agent** — A primary or subagent definition loaded through OpenCode config.
|
|
8
|
+
**Instruction** — Markdown loaded through `AGENTS.md` or `opencode.json` instructions.
|
|
9
|
+
**Bootstrap** — The first-message context injected by the OpenHermes plugin.
|
|
10
|
+
|
|
11
|
+
## Relationships
|
|
12
|
+
- OpenHermes contains many Skills, Commands, Agents, and Instructions.
|
|
13
|
+
- Skills are invoked on demand.
|
|
14
|
+
- Commands are entry points.
|
|
15
|
+
- OpenHermes is the default primary Agent.
|
|
16
|
+
|
|
17
|
+
## Flagged Ambiguities
|
|
18
|
+
- Durable state is deferred for now and not a domain term for this pass.
|
package/ETHOS.md
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# OpenHermes Ethos
|
|
2
|
+
|
|
3
|
+
Four immutable principles. Every skill, every command, every session.
|
|
4
|
+
|
|
5
|
+
## Native First
|
|
6
|
+
OpenCode-native loading over manual copying or hidden state.
|
|
7
|
+
|
|
8
|
+
## Small Surface
|
|
9
|
+
Every file earns its keep. Prefer markdown when behavior is declarative.
|
|
10
|
+
|
|
11
|
+
## Skills Over Glue
|
|
12
|
+
Behavior lives in `SKILL.md`, `commands/*.md`, and `agents/*.md`.
|
|
13
|
+
|
|
14
|
+
## Delegate Hard Work
|
|
15
|
+
Subagents for substantive work. Main context orchestrates and verifies.
|
package/README.md
CHANGED
|
@@ -1,292 +1,135 @@
|
|
|
1
|
-
<p align="center">
|
|
2
|
-
<h1 align="center">☤ OpenHermes</h1>
|
|
3
|
-
<p align="center"><i>
|
|
4
|
-
</p>
|
|
5
|
-
|
|
6
|
-
<p align="center">
|
|
7
|
-
<a href="https://www.npmjs.com/package/openhermes"><img src="https://img.shields.io/npm/v/openhermes?style=for-the-badge&label=version&color=FFD700" alt="npm version"></a>
|
|
8
|
-
<a href="https://github.com/nathwn12/openhermes/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-green?style=for-the-badge" alt="License: MIT"></a>
|
|
9
|
-
<a href="https://opencode.ai"><img src="https://img.shields.io/badge/runs%20on-OpenCode-6366f1?style=for-the-badge" alt="Runs on OpenCode"></a>
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
|
48
|
-
|
|
49
|
-
|
|
|
50
|
-
|
|
|
51
|
-
|
|
|
52
|
-
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
|
57
|
-
|
|
58
|
-
|
|
|
59
|
-
|
|
|
60
|
-
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
No
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
```
|
|
137
|
-
T0 ── Any mistake
|
|
138
|
-
Observe → log mistake record → smallest safe correction → verify
|
|
139
|
-
|
|
140
|
-
T1 ── Same mistake repeats within 7 days
|
|
141
|
-
Add prevention rule → targeted verification
|
|
142
|
-
|
|
143
|
-
T2 ── Prevention failed / systemic issue
|
|
144
|
-
Delegate to specialist → deep audit → backlog item → structural fix
|
|
145
|
-
|
|
146
|
-
T3 ── Cascading failures
|
|
147
|
-
Constrained safe mode: narrow claims, preserve receipts, produce handoff
|
|
148
|
-
```
|
|
149
|
-
|
|
150
|
-
No self-termination. No grandstanding. The agent gets better — you don't teach it twice.
|
|
151
|
-
|
|
152
|
-
---
|
|
153
|
-
|
|
154
|
-
## Session Lifecycle
|
|
155
|
-
|
|
156
|
-
Three phases. Six plugins coordinate across 20+ OpenCode hooks.
|
|
157
|
-
|
|
158
|
-
```
|
|
159
|
-
▶️ Warmup
|
|
160
|
-
config hook BootstrapPlugin registers harness/skills/, skills auto-discover
|
|
161
|
-
session.created BootstrapPlugin injects constitution → router → runtime
|
|
162
|
-
AutorecallPlugin loads disk memory → writes recall cache
|
|
163
|
-
SkillBuilderPlugin resets counters
|
|
164
|
-
|
|
165
|
-
⚙️ Execution
|
|
166
|
-
tool.execute.* SkillBuilderPlugin counts calls + spawns
|
|
167
|
-
|
|
168
|
-
⏹️ Cooldown
|
|
169
|
-
session.idle CuratorPlugin: checkpoint snapshot + verification receipt
|
|
170
|
-
SkillBuilderPlugin: complexity check → backlog candidate
|
|
171
|
-
session.compacting CuratorPlugin: force-writes pre-compaction checkpoint
|
|
172
|
-
Injects harness state + recall context → compaction buffer
|
|
173
|
-
session.compacted CuratorPlugin: updates loop-state to "compacted"
|
|
174
|
-
session.error CuratorPlugin: logs mistake (type, root cause, fix, prevention)
|
|
175
|
-
permission.replied CuratorPlugin: writes audit record for every permission decision
|
|
176
|
-
```
|
|
177
|
-
|
|
178
|
-
---
|
|
179
|
-
|
|
180
|
-
## Verification Discipline
|
|
181
|
-
|
|
182
|
-
One core habit — **verify before claiming success.**
|
|
183
|
-
|
|
184
|
-
| Rule | Why |
|
|
185
|
-
|------|-----|
|
|
186
|
-
| 🕵️ Read before editing | Don't fix what you haven't seen |
|
|
187
|
-
| 🧪 Run before announcing | Don't claim what you haven't tested |
|
|
188
|
-
| 🧬 Cache by fingerprint | Same file, same receipt — skip re-verify |
|
|
189
|
-
| 🔄 Re-verify on change | Stale receipt is worse than no receipt |
|
|
190
|
-
| 🚩 Flag contradictions | Silence is consent to bugs |
|
|
191
|
-
|
|
192
|
-
Verification receipts are a first-class memory type — keyed by artifact identity + fingerprint (path, mtime, hash). This is not an afterthought. It's the difference between "I think it works" and "I know it works."
|
|
193
|
-
|
|
194
|
-
---
|
|
195
|
-
|
|
196
|
-
## Bundled Harness
|
|
197
|
-
|
|
198
|
-
The full operational doctrine ships inside the package. Six directories, zero dependencies outside Node.js.
|
|
199
|
-
|
|
200
|
-
| Directory | Contents | Purpose |
|
|
201
|
-
|-----------|----------|---------|
|
|
202
|
-
| `codex/` | `CONSTITUTION.md` — 14 immutable principles | Your agent's behavior, frozen per session |
|
|
203
|
-
| `instructions/` | Runtime workflow + coding conventions | The playbook every session runs on |
|
|
204
|
-
| `rules/` | 17 files: retrieval, verification, audit, self-heal, delegation, handoff | The legal framework — no ambiguity |
|
|
205
|
-
| `skills/` | 10 procedural SKILL.md files | Domain expertise discovered automatically |
|
|
206
|
-
| `prompts/` | 25 subagent prompt templates | Language specialists, docs lookup, loop drivers — all on tap |
|
|
207
|
-
| `commands/` | 26 slash command templates | From `/verify` to `/review-go` — full toolbelt |
|
|
208
|
-
|
|
209
|
-
OpenHermes is not a runtime shim. The doctrine ships with the package — every subagent and every command follows the same constitution, rules, and conventions.
|
|
210
|
-
|
|
211
|
-
---
|
|
212
|
-
|
|
213
|
-
## The Six Plugins
|
|
214
|
-
|
|
215
|
-
| Plugin | Hook Points | Job |
|
|
216
|
-
|--------|-------------|-----|
|
|
217
|
-
| **Bootstrap** | `config`, `chat.transform` | Registers agents/commands/skills; injects constitution + router + runtime |
|
|
218
|
-
| **MemoryTools** | (tool registration) | Provides 6 `ohc_*` tools — no MCP server, no network |
|
|
219
|
-
| **Curator** | `session.idle`, `.error`, `.compacted`, `.compacting`, `permission.replied` | Snapshots state, logs mistakes, records decisions, injects into compaction |
|
|
220
|
-
| **Autorecall** | `session.created` | Loads prior session memory into recall cache at startup |
|
|
221
|
-
| **SkillBuilder** | `session.created`, `.idle`, `tool.execute.after` | Auto-detects complex sessions (8+ calls or 2+ spawns) → backlog candidates |
|
|
222
|
-
| **OhcPlugin** | `config`, all transform/command hooks | Silent context pruner; injects budget; progressive nudges; `/ohc` command + `compress` tool |
|
|
223
|
-
|
|
224
|
-
---
|
|
225
|
-
|
|
226
|
-
## Architecture — Three Layers, One Dependency
|
|
227
|
-
|
|
228
|
-
```
|
|
229
|
-
openhermes/
|
|
230
|
-
│
|
|
231
|
-
├── ⚡ index.mjs # Plugin exports (all 5)
|
|
232
|
-
├── ⚡ bootstrap.mjs # Config hook + chat.transform
|
|
233
|
-
├── ⚡ autorecall.mjs # Memory → recall cache
|
|
234
|
-
├── ⚡ curator.mjs # Lifecycle hooks engine
|
|
235
|
-
├── ⚡ skill-builder.mjs # Complexity detection
|
|
236
|
-
│
|
|
237
|
-
├── ⚡ lib/
|
|
238
|
-
│ ├── memory-tools-plugin.mjs # 5 hm_* tools
|
|
239
|
-
│ ├── handoff.mjs # Structured delegation protocol
|
|
240
|
-
│ ├── hardening.mjs # sanitize, redact, atomic write
|
|
241
|
-
│ ├── paths.mjs # storage root resolver
|
|
242
|
-
│ ├── schema-validator.mjs # Draft-07 validation
|
|
243
|
-
│ └── ohc/ # context pruner
|
|
244
|
-
│
|
|
245
|
-
├── ⚡ schemas/ # 9 Draft-07 memory schemas
|
|
246
|
-
│
|
|
247
|
-
├── 📦 harness/
|
|
248
|
-
│ ├── codex/ # CONSTITUTION.md — 14 principles
|
|
249
|
-
│ ├── instructions/ # runtime + conventions
|
|
250
|
-
│ ├── rules/ # 17 files (handoff.md + 16 existing)
|
|
251
|
-
│ ├── skills/ # 10 procedural skills
|
|
252
|
-
│ ├── prompts/ # 25 subagent templates
|
|
253
|
-
│ └── commands/ # 26 slash command templates
|
|
254
|
-
│
|
|
255
|
-
└── 📦 package.json # one dependency: @opencode-ai/plugin
|
|
256
|
-
```
|
|
257
|
-
|
|
258
|
-
**Dependency footprint:** `@opencode-ai/plugin` only. No postinstall scripts. No native compilation. No Docker. No Python. Your entire agent OS in a single `npm install`.
|
|
259
|
-
|
|
260
|
-
---
|
|
261
|
-
|
|
262
|
-
## Why OpenHermes ≠ Hermes Agent
|
|
263
|
-
|
|
264
|
-
Same messenger emoji. Entirely different mediums.
|
|
265
|
-
|
|
266
|
-
| | Hermes Agent | OpenHermes |
|
|
267
|
-
|-|------------|------------|
|
|
268
|
-
| Platform | Standalone agent — TUI + gateway + cron | OpenCode-native plugin — lives *inside* your editor |
|
|
269
|
-
| Installation | Python 3.11 + uv + 30+ deps — 5-15 min | `npm i` — 3 seconds |
|
|
270
|
-
| Infrastructure | Long-running gateway, cron daemon, 20 platform adapters, 7 terminal backends, SQLite+FTS5 | Zero sidecars — everything is a plugin hook |
|
|
271
|
-
| Memory | MEMORY.md + USER.md files + optional Honcho | 9-class schema-validated, fingerprint-aware, in-process tools |
|
|
272
|
-
| Skills | agentskills.io standard, auto-creation + self-improvement | SKILL.md progressive disclosure, auto-detected |
|
|
273
|
-
| Subagents | N/A | 25 specialists with handoff protocol, permission tiers, phase management |
|
|
274
|
-
| Philosophy | "The self-improving agent" — feature-rich, platform-expansive | **"The constitutional router"** — discipline-first, precision-only |
|
|
275
|
-
|
|
276
|
-
Both are ☤ messengers. Different mediums.
|
|
277
|
-
|
|
278
|
-
---
|
|
279
|
-
|
|
280
|
-
## Contributing
|
|
281
|
-
|
|
282
|
-
Problems, ideas, improvements? [Open an issue](https://github.com/nathwn12/openhermes/issues). PRs welcome.
|
|
283
|
-
|
|
284
|
-
---
|
|
285
|
-
|
|
286
|
-
## License
|
|
287
|
-
|
|
288
|
-
MIT — see [LICENSE](LICENSE). All credited inspirations are independent implementations — no code copied. ECC and Hermes Agent are MIT. DCP is AGPL-3.0 but shared concepts (compress, dedup, purge) are uncopyrightable ideas (17 U.S.C. § 102(b); *Computer Assocs. v. Altai*, 982 F.2d 693). AGPL copyleft requires copying or adapting the work (§ 0) — independent implementation does not trigger it.
|
|
289
|
-
|
|
290
|
-
<p align="center">
|
|
291
|
-
<sub><b>☤</b> Built with discipline. Inspired by <a href="https://github.com/NousResearch/hermes-agent">Hermes Agent</a> (MIT), <a href="https://github.com/affaan-m/everything-claude-code">ECC</a> (MIT), and <a href="https://github.com/Opencode-DCP/opencode-dynamic-context-pruning">DCP</a> (AGPL-3.0). Built for <a href="https://opencode.ai">OpenCode</a>.</sub>
|
|
292
|
-
</p>
|
|
1
|
+
<p align="center">
|
|
2
|
+
<h1 align="center">☤ OpenHermes</h1>
|
|
3
|
+
<p align="center"><i>Plan. Build. Ship. One plugin.</i></p>
|
|
4
|
+
</p>
|
|
5
|
+
|
|
6
|
+
<p align="center">
|
|
7
|
+
<a href="https://www.npmjs.com/package/openhermes"><img src="https://img.shields.io/npm/v/openhermes?style=for-the-badge&label=version&color=FFD700" alt="npm version"></a>
|
|
8
|
+
<a href="https://github.com/nathwn12/openhermes/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-green?style=for-the-badge" alt="License: MIT"></a>
|
|
9
|
+
<a href="https://opencode.ai"><img src="https://img.shields.io/badge/runs%20on-OpenCode-6366f1?style=for-the-badge" alt="Runs on OpenCode"></a>
|
|
10
|
+
</p>
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
OpenHermes is an OpenCode plugin that gives your agent a complete skill system out of the box. Add one line to `opencode.json`, get 25 skills, a primary orchestrator, and a shared operating model.
|
|
15
|
+
|
|
16
|
+
```json
|
|
17
|
+
{ "plugin": ["openhermes@git+https://github.com/nathwn12/openhermes.git"] }
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
No setup. No file copying. No extra dependencies.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## What you get
|
|
25
|
+
|
|
26
|
+
### Seven core skills
|
|
27
|
+
|
|
28
|
+
| Skill | What it does |
|
|
29
|
+
|---|---|
|
|
30
|
+
| **oh-planner** | Brainstorm, analyze architecture, run strategy reviews, auto-decide 90% of questions with gstack decision principles. Produces a consumable plan artifact. |
|
|
31
|
+
| **oh-builder** | Prototype, TDD red-green-refactor, design interfaces in parallel sub-agents, implement from plan. Vertical tracer bullets, one test at a time. |
|
|
32
|
+
| **oh-manifest** | Full build loop: planner → builder → verify → loop until done or a real blocker is surfaced. Auto-resolves intermediate questions; only interrupts you for genuine blockers. |
|
|
33
|
+
| **oh-gauntlet** | Multi-axis testing gauntlet: unit tests, dual-axis review (Standards + Spec in parallel sub-agents), edge case sweep, QA tier, canary post-deploy. |
|
|
34
|
+
|
|
35
|
+
These seven form a pipeline: **think → plan → build → test → ship → secure → monitor**. Each produces artifacts the next consumes.
|
|
36
|
+
|
|
37
|
+
### Twenty-five skills total
|
|
38
|
+
|
|
39
|
+
| Skill | Purpose |
|
|
40
|
+
|---|---|
|
|
41
|
+
| oh-planner, oh-builder, oh-manifest, oh-gauntlet | Core pipeline (above) |
|
|
42
|
+
| oh-expert | AI self-diagnosis vocabulary — sycophancy, hallucination type, attention degradation |
|
|
43
|
+
| oh-grill | Stress-test plans through Socratic questioning; optionally updates CONTEXT.md, ADRs, and extracts ubiquitous language |
|
|
44
|
+
| oh-plan-review | Multi-lens plan review: Engineering, Design, DX, Strategy |
|
|
45
|
+
| oh-security | Security audit: secrets archaeology, supply chain, CI/CD, OWASP, STRIDE, LLM security |
|
|
46
|
+
| oh-health | Code quality dashboard: wraps tools, composite score, trend tracking |
|
|
47
|
+
| oh-investigate | Systematic bug diagnosis |
|
|
48
|
+
| oh-handoff | Compact session into structured handoff artifact for another agent |
|
|
49
|
+
| oh-skill-craft | Create new skills for the harness (meta-skill) |
|
|
50
|
+
| oh-init | Initialize project: scaffold CONTEXT.md, AGENTS.md, ADRs, issue tracker config, triage labels |
|
|
51
|
+
| oh-retro | Retrospective after shipping |
|
|
52
|
+
| oh-review | Two-axis review (Standards + Spec) in parallel sub-agents + architecture deepening |
|
|
53
|
+
| oh-ship | PR, version bump, changelog, post-ship docs sync |
|
|
54
|
+
| oh-triage | Issue triage state machine |
|
|
55
|
+
| oh-issue | Break plans into vertical-slice issues |
|
|
56
|
+
| oh-prd | Write structured PRDs |
|
|
57
|
+
| oh-caveman | Ultra-compressed response mode |
|
|
58
|
+
| oh-freeze | Freeze dependencies |
|
|
59
|
+
| oh-learn | Learn patterns from the codebase |
|
|
60
|
+
| oh-guard | Safety confirmations for destructive operations |
|
|
61
|
+
| oh-skills-link | Verify skills discovery |
|
|
62
|
+
| oh-skills-list | List available skills |
|
|
63
|
+
|
|
64
|
+
### One orchestrator agent
|
|
65
|
+
|
|
66
|
+
OpenHermes is the default primary agent — a hub-and-spoke commander that delegates to skills, spawns sub-agents for isolated context, and surfaces blockers instead of silently retrying.
|
|
67
|
+
|
|
68
|
+
### One diagnostic command
|
|
69
|
+
|
|
70
|
+
`/oh-doctor` — inspect plugin load, skills discovery, command/agent registration, and config safety.
|
|
71
|
+
|
|
72
|
+
---
|
|
73
|
+
|
|
74
|
+
## How it works
|
|
75
|
+
|
|
76
|
+
OpenHermes loads through OpenCode's native plugin system. On install:
|
|
77
|
+
|
|
78
|
+
1. `config.skills.paths` is pointed at the package-local `harness/skills/` — skills load on demand through the `skill` tool, no preloading
|
|
79
|
+
2. Commands from `harness/commands/` register as slash commands
|
|
80
|
+
3. The agent manifest in `harness/agents/` sets OpenHermes as the primary orchestrator
|
|
81
|
+
4. Instructions from `CONSTITUTION.md`, `RUNTIME.md`, `CONTEXT.md`, and `ETHOS.md` are injected into every session
|
|
82
|
+
|
|
83
|
+
Everything is package-local. Nothing is copied into your global config.
|
|
84
|
+
|
|
85
|
+
---
|
|
86
|
+
|
|
87
|
+
## OptiRoute: Smart Auto-Routing Protocol
|
|
88
|
+
|
|
89
|
+
Every skill routes to the next based on outcome — pass, fail, or blocker. OptiRoute is a guard layer on top of that graph. Three rules:
|
|
90
|
+
|
|
91
|
+
**Loop guard.** Tracks routing depth. If the same skill is visited 3+ times in one chain, or 5+ hops pass without measurable progress (new artifact, changed target), routing stops. No infinite loops.
|
|
92
|
+
|
|
93
|
+
**Question gate.** Before each routing hop, the protocol checks whether the next skill's inputs are satisfied. If the task is underspecified or information is missing, it asks the user instead of routing into uncertainty.
|
|
94
|
+
|
|
95
|
+
**Auto-handoff.** When the loop guard triggers, it writes an OptiRoute report into `plan.md` — the routing chain, the trigger threshold, current state, and the blocker. Then it surfaces the blocker and awaits direction.
|
|
96
|
+
|
|
97
|
+
```md
|
|
98
|
+
OPTIROUTE STOP: 5-hop ceiling reached, no progress
|
|
99
|
+
Chain: planner → grill → planner → builder → gauntlet → planner
|
|
100
|
+
See .opencode/plan.md for full report
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
No loops. No guessing. No silent death.
|
|
104
|
+
|
|
105
|
+
---
|
|
106
|
+
|
|
107
|
+
## Layout
|
|
108
|
+
|
|
109
|
+
```
|
|
110
|
+
openhermes-pkg/
|
|
111
|
+
├── AGENTS.md # Skill/command/agent inventory
|
|
112
|
+
├── CONTEXT.md # Shared language
|
|
113
|
+
├── ETHOS.md # Operating principles
|
|
114
|
+
├── bootstrap.mjs # Plugin loader — registers everything
|
|
115
|
+
├── index.mjs # Package entrypoint
|
|
116
|
+
├── harness/
|
|
117
|
+
│ ├── agents/ # Agent manifests (OpenHermes)
|
|
118
|
+
│ ├── codex/ # CONSTITUTION.md
|
|
119
|
+
│ ├── commands/ # Slash command manifests (/oh-doctor)
|
|
120
|
+
│ ├── instructions/ # RUNTIME.md, CONVENTIONS.md
|
|
121
|
+
│ └── skills/ # 25 skill SKILL.md files
|
|
122
|
+
└── test/
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
---
|
|
126
|
+
|
|
127
|
+
## Inspiration
|
|
128
|
+
|
|
129
|
+
OpenHermes merges high-signal patterns from:
|
|
130
|
+
|
|
131
|
+
- **superpowers** — skill loading model (config.skills.paths + bootstrap injection)
|
|
132
|
+
- **dictionary-of-ai-coding** — shared vocabulary for agent self-diagnosis
|
|
133
|
+
- **skills (mattpocock)** — TDD discipline, write-a-skill meta, design-an-interface parallel sub-agents, dual-axis review
|
|
134
|
+
- **gstack** — preamble-tier seniority, artifact-chain pipeline, decision principles
|
|
135
|
+
- **opencode-orchestrator** — hub-and-spoke delegation, session pool discipline, pipelined verification
|