gormes-references
Find Go donor/reference implementations for Gormes. Use when stuck on implementation shape, checking donor provenance, or comparing Go agent donors.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Find Go donor/reference implementations for Gormes. Use when stuck on implementation shape, checking donor provenance, or comparing Go agent donors.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Implement one selected repo-scoped Gormes row with tests. Use when next-work says decision=build. Do not use for decision=plan, broad parity audits, or untracked feature ideas.
Shape source-backed Gormes progress rows. Use for decision=plan builder handoffs, row splitting, feature maps, or parity planning. Do not use when decision=build or for runtime code.
Route Gormes work to the smallest repo-local skill chain. Use before substantial planning/building/refactor work, when unsure which Gormes skill applies, or when creating/improving repo-local skills.
Build one selected Gormes behavior with red-green-refactor. Use when the row or reproduced bug defines a test target. Do not use after decision=plan or for broad planning.
Move one bounded cmd/gormes command domain out of root files toward root main.go only. Use when thinning cmd/gormes, burning down loose root files, preserving CLI behavior, or catching refactor regressions during cmd moves.
Use when an agent is unfamiliar with a Gormes code area, a change crosses package boundaries, or a refactor needs a source-backed module map before edits.
| name | gormes-references |
| description | Find Go donor/reference implementations for Gormes. Use when stuck on implementation shape, checking donor provenance, or comparing Go agent donors. |
For Gormes work, stay on the existing development branch. Do not create or
use feature branches, short-lived branches, or git worktrees. If the checkout
is not on development, stop before editing and switch safely or report the
blocker.
Use this skill whenever you are about to write Gormes Go code and you are not sure which shape to use, which library to consult, or how a similar agent system solved the same problem. It is a research/lookup skill — not a planner, builder, or TDD skill. After consulting references, hand off to gormes-builder / gormes-tdd-slice for implementation.
Trigger this skill when:
GORMES-PROVIDER-PATTERN-REFERENCES.md donor note.Skip this skill when:
gormes-parity-auditor first);gormes-provider-parity — it is the focused superset);gormes-tdd-slice);Reduce token waste, copy-paste errors, and re-invented abstractions by routing every Gormes implementation question to the smallest set of donor files that answer it.
Hermes Python remains the parity contract. Go donors are how Gormes shapes Hermes parity in idiomatic Go.
The local Hermes source is normally ./hermes-agent inside this repository;
fall back to ../hermes-agent only when absent. Resolve it as $HERMES_SRC
before reading upstream behavior.
| Donor | Permission for Gormes |
|---|---|
goclaw (CC BY-NC 4.0 in upstream) | Code permitted — Juan granted explicit permission. Port with provenance comment. |
nanobot (Apache 2.0) | Patterns + adapted code with attribution |
plandex (MIT/AGPL — verify per file) | Patterns; copy code only after per-file license check |
engram (MIT) | Patterns + adapted code with attribution |
trpc-agent-go (Apache 2.0) | Patterns + adapted code with attribution |
adk-go (Apache 2.0) | Patterns + adapted code with attribution |
axe (MIT) | Patterns + adapted code with attribution |
agentcontrolplane, uzi | Patterns only; no code copy without review |
When porting code (any donor), add a provenance comment on the receiving Gormes file:
// Adapted from <donor>/path/to/file.go::SymbolName
// Reason: <why we needed this shape>
Convert types and imports to Gormes-native names; never let donor symbol names leak into Gormes' public API.
Pick exactly one and continue:
gormes-provider-parity (focused superset). If an available donor note maps provider files, use it after resolving the donor root.Even when Gormes ships its own Go implementation, the user-facing behavior must match Hermes. Anchor the parity target before reading donors:
$HERMES_SRC/AGENTS.md$HERMES_SRC/If Hermes has no analog (e.g. a brand-new Gormes-only seam), record this explicitly in the receiving row's provenance.origin_type: gormes.
Open the donor file once and skim it whole before extracting any pattern. Donor files often hide invariants in helpers (e.g. path sanitization, header construction, jittered backoff) that are easy to miss when grepping.
Translate the donor pattern into Gormes-native names, types, and tests. Never:
Always:
go test ./... + go run ./cmd/progress validate.After lookup, hand off to:
gormes-tdd-slice for the red-green-refactor loop;gormes-builder to land the row;gormes-interface-designer if the package boundary is now clearer but not finalized.When present, a provider/auth/streaming donor note named GORMES-PROVIDER-PATTERN-REFERENCES.md is the focused lookup surface. Resolve the donor root first; the maps below cover everything else.
| Gormes problem | Donor file | Pattern |
|---|---|---|
| Wire a runtime with explicit dependency layering | nanobot/pkg/runtime/runtime.go | Options.Merge + Complete defaults + explicit wiring of LLM client, tool registry, sampler |
| Build a tool service with before/after hooks | nanobot/pkg/tools/service.go, nanobot/pkg/tools/flows.go | Tool registry + filter gates + hook ordering |
| Truncate large tool outputs while persisting full bytes | nanobot/pkg/agents/truncate.go | maxToolResultSize, sanitized session-local artifact path, short text pointer |
| Estimate image tokens by decoded dimensions | nanobot/pkg/agents/tokencount.go | WebP decode, per-provider estimate, conservative fallback |
| Loop / sequential / parallel workflow agents | adk-go/agent/workflowagents/..., examples under adk-go/examples/workflowagents/... | Workflow primitives without rewriting kernel |
| Tool filtering (include/exclude by channel/trust/toolset) | axe/internal/... (filter helpers), nanobot/pkg/tools/flows.go | Pre-call gate, declarative filter |
| Gormes problem | Donor file | Pattern |
|---|---|---|
| SQLite + FTS5 memory store | engram/internal/persistence/store/store.go | DDL, indexes, migration helpers |
| Memory relation/conflict vocabulary | engram/internal/persistence/store/relations.go | related, conflicts_with, supersedes, compatible, scoped, not_conflict |
| Deterministic serialized MCP write queue | engram/internal/mcp/write_queue.go | Mutex-serialized queue, cancel-before-start, evidence vocabulary |
| MCP activity/audit logging | engram/internal/mcp/activity.go | Audit shape, redaction, append-only file |
| Gormes problem | Donor file | Pattern |
|---|---|---|
| Await-user-reply / pause-and-resume | trpc-agent-go/agent/await_user_reply.go | Resume-token contract, callback-context shape, no-leak design |
| Provider/agent callback pipeline | trpc-agent-go/model/callbacks.go, trpc-agent-go/agent/callbacks.go | Before/after split from core turn |
| Per-session worker fan-out | uzi (patterns only) | Tmux fanout, isolated session state; do not use git worktrees for Gormes work |
| Gormes problem | Donor file | Pattern |
|---|---|---|
| Bounded token-budget tracker | axe/internal/budget/budget.go | Per-turn counter, reset, overflow signal |
| Artifact tracker with sanitized paths | axe/internal/artifact/tracker.go | Path-traversal guard, append-only registry |
| Test-budget / agent-step counter | axe/internal/budget/budget_test.go | Test shape Gormes can mirror |
If a resolved donor root includes GORMES-PROVIDER-PATTERN-REFERENCES.md ("Quick Lookup: Problem → Donor File"), consult it for OAuth, token refresh, error classification, retry/backoff, drift, and stream-error mapping.
When the table doesn't list the problem:
# Resolve an available donor root before searching. Adjust the pattern to match
# your problem (function name, header, error code, struct field).
DONOR_ROOT="$(for p in ./references/go-agent-os ../references/go-agent-os "$GORMES_GO_AGENT_OS_REFS"; do [ -n "$p" ] && [ -d "$p" ] && { printf '%s\n' "$p"; break; }; done)"
if [ -z "$DONOR_ROOT" ]; then
echo "no go-agent-os donor root found; route to gormes-skill-manager or gormes-context-sourcing"
else
grep -rn "<symbol-or-concept>" "$DONOR_ROOT"/{goclaw,nanobot,plandex,engram,trpc-agent-go,adk-go,axe} 2>/dev/null | head -20
fi
If the grep returns nothing useful, escalate to gormes-skill-manager to decide whether the missing donor is a real gap (file a new reference clone request) or whether Gormes needs a from-scratch interface (route to gormes-interface-designer).
This is a research skill, so validation focuses on the implementation that follows:
// Adapted from … provenance comment.go test ./<receiving-package> -count=1 is green.go test ./... -count=1 and go run ./cmd/progress validate pass before commit.go doc ./<package> | grep -iE "(goclaw|nanobot|plandex|engram|trpc|adk|axe)" returns nothing).problem_class:
hermes_parity_target:
donor_files_consulted:
adaptation_applied:
provenance_comment:
gormes_tests_added:
hand_off_skill: gormes-tdd-slice | gormes-builder | gormes-interface-designer