hermes-profile-setup
Create and configure Hermes profiles for separate use cases — fitness, finance, creative, research. Adapt SOUL.md from other agents (OpenClaw, Claude Code). Maintain memory across profiles.
- License 许可
- MIT
- 最近更新
- 2026-11-03
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- hermes-profile-setup
- author
- OraMesLita
- license
- MIT
- version
- 1.1.0
- metadata
- { "hermes": { "triggers": [ "create a profile for", "new profile", "separate context", "gym profile", "health profile", "adapt SOUL", "memory cleanup", "memory is full", "clean up memory", "model list", "provider model list", "model picker" ], "related_skills": [ "hermes-agent" ] } }
- description
- Create and configure Hermes profiles for separate use cases — fitness, finance, creative, research. Adapt SOUL.md from other agents (OpenClaw, Claude Code). Maintain memory across profiles.
02 资源文件 10
- 参考文档references/machine-replication-handoff.md6.9 KB
- 参考文档references/memory-cleanup-example.md2.1 KB
- 参考文档references/product-business-soul-upgrade.md10.0 KB
- 参考文档references/provider-model-list-maintenance.md4.2 KB
- 参考文档references/router-generalist-main-soul.md5.1 KB
- 参考文档references/soul-adaptation-openclaw.md2.1 KB
- 参考文档references/soul-authoring-vault-grounded.md4.2 KB
- 参考文档references/soul-level-upgrade.md6.3 KB
- 参考文档references/specialist-path-batch-upgrade.md6.0 KB
- 脚本scripts/verify_soul_refs.py3.6 KB
03 SKILL.md 正文
Hermes Profile Setup & Maintenance
When to create a separate profile, how to adapt foreign agent SOUL templates, and how to keep memory lean across profiles.
When to Create a Profile
Create a new profile when any of these are true:
- The use case is a different domain than your current profile (programming → fitness, fitness → finance)
- You want isolated memory — health data shouldn't mix with code review context
- You want a different persona/SOUL — fitness coach vs DevOps engineer
- You want different tools/skills — gym profile doesn't need GitHub MCP or PostgreSQL
- You want a cheaper model for lightweight Q&A (health advice doesn't need deepseek-v4-pro)
Stay in the same profile when:
- The task is the same domain with a different project (Python backend → React frontend)
- You want shared memory and conventions across work
Creating a Profile
# Fresh profile (recommended for new domains)
hermes profile create <name>
# Clone config + .env + SOUL.md AND ALL skills + memory (identical setup, fresh sessions)
hermes profile create <name> --clone
# Clone everything via --clone-all (same as --clone; --clone already brings skills)
hermes profile create <name> --clone-all
Recommendation: use --clone for cross-domain profiles — it copies API keys, provider config, SOUL.md, and all installed skills (observed output: "Cloned config, .env, SOUL.md, and skills from default"). It does NOT leave skills clean. Only session history and memory start fresh. A --clone profile inherits every skill from the source profile — plan to prune. Trim irrelevant skill categories after creation (e.g. a book-summarizer profile does not need gym, smart-home, mlops, slidev) so the new profile doesn't waste context on foreign skills. hermes tools / skill pruning manage this per profile.
Smoke-test a new profile immediately
The generated <name>.bat shortcut in ~/.local/bin is not on the git-bash PATH (it just wraps hermes -p <name>). Verify the soul is live with a one-shot query instead:
hermes -p <name> chat -q "Answer in one sentence: what is your name and core role?"
The reply must reflect the new SOUL.md (e.g. the book-summarizer profile answers as "Libri, the Book Summarizer..."). A wrong identity means the soul didn't install where expected. The reply prints directly ABOVE the Resume this session footer — a tight | tail -8 can clip it to just session metadata. Use | tail -24 or | grep -i "<expected name>" to actually capture the answer.
Review-first gate for new souls (Panomete's rule)
Do NOT create the profile the moment a soul is drafted. When authoring a new fleet specialist:
- Write the soul to the canonical collection —
F:\obsidian_note\hermes_config_backup\soul-collection\<DOMAIN>\<position>-soul.md—AI-SDLC\for engineering souls,Life Styles\for lifestyle souls. Never write souls to the collection root. - Let Panomete review the soul file and explicitly approve it becoming a profile.
- Only after approval, run the full install checklist below.
This review-first gate keeps drafts out of
$HERMES_HOME/profiles/until they're approved — approved and live = reviewed.
Post-approval install checklist (2026-09 canon, verified on career-coach / journey-writer / audiophile)
hermes profile create <name> --clone- Stash the clone default:
cp <profile>/SOUL.md <profile>/SOUL.md.default-clone.bak cpcollection soul →<profile>/SOUL.md, thenmd5sumboth — byte-identical before proceeding.- Registry (
profile-registry.md, collection root): add routing row + append toProfiles to create+ append to the matching soul-source line (AI-SDLC\orLife Styles\). - Main soul (
$HERMES_HOME/SOUL.md): add a routing-table row AND aWhat I Routebullet. - Sync main soul →
soul-collection/hermes-main-soul.md. - Smoke test (below), then update the fleet count in memory.
After creation, the profile auto-generates a CLI shortcut:
<name> chat # start a session
<name> setup # configure model/keys
Adapting SOUL.md from Other Agents
Other agent frameworks (OpenClaw, Claude Code, Codex) have SOUL.md or AGENTS.md templates online. The adaptation process:
1. Fetch the source
curl -sL "https://raw.githubusercontent.com/<user>/<repo>/<branch>/path/to/SOUL.md"
2. Map foreign concepts to Hermes equivalents
| Foreign (OpenClaw/Claude Code) | Hermes equivalent |
|---|---|
~/.openclaw/state/ file paths |
memory tool for durable facts, session_search for past conversations |
memory/YYYY-MM-DD.md daily journal |
Hermes memory auto-injects every session — no manual journaling |
MEMORY.md long-term file |
Persistent memory entries survive across sessions |
CLAUDE.md project context |
.hermes.md or AGENTS.md in project root |
| Local file-based state | memory tool + Obsidian vault if applicable |
3. Add Hermes-specific sections
Every Hermes SOUL.md should include:
- Tools Available — list which Hermes tools the profile uses (
memory,web,file,todo,clarify) - Memory & Continuity — explain how memory persists (tool-based, not file-based)
- Self-update footer — standard "If this SOUL evolves, update it and notify the user"
- Profile-aware paths — reference the profile's own memory, not
~/.hermes/global
4. Write to the profile path
~/AppData/Local/hermes/profiles/<name>/SOUL.md (Windows)
~/.hermes/profiles/<name>/SOUL.md (macOS/Linux)
5. Trim tools for the domain
Don't load a gym profile with terminal, github, docker skills. The profile inherits the cli platform toolsets by default — suggest trimming via hermes tools in the new profile's shell.
Authoring Original SOULs from Scratch
When the user wants a new persona from their own domain (not adapted from a foreign agent) — e.g. AI-SDLC role souls, life-style souls (educator, financial advisor, deck-builder) — use this workflow. It differs from adaptation: there's no source template, so the persona must be grilled into existence before writing.
1. Grill first, write after (most important rule)
Never invent a persona. Run the interview (via grill-me / grill-with-docs, or manually if the user is mid-conversation) to pin:
- Who the persona serves and their boundaries (e.g. "serves only me", "any audience")
- Philosophy — teaching style, risk stance, design taste
- Deliverables — what they produce and in what format (Obsidian md? PPTX? Excel formulas?)
- Expertise level — "graduate of which BOK" (see below)
- Priority awareness — 🔴/🟡/🟢 behavior like a real worker
- Personality — warmth/terseness, tone, direct vs encouraging
Grill format that works with Panomete: numbered questions with lettered options (a/b/c/d) plus an escape hatch ("d) your call"), max ~10 per round (9–10-question grills landed cleanly 2026-09), and he answers in shorthand (1a, 2b, 3d). Use a numbered list in chat, NOT the clarify tool — clarify only supports one question with ≤4 choices, which is too slow for a multi-question grill. Works for both new souls (identity/scope/output/language/destination/tone/coverage) and upgrades (scope of level-up, what to preserve, doc depth).
Push back on vague answers; each follow-up question makes the SOUL sharper. A "sharp specialist" beats a "blurry generalist" every time.
2. Naming & layout convention
[position]-soul.md(e.g.product-owner-soul.md,educator-soul.md)- Collection root with domain subfolders:
soul-collection/<DOMAIN>/ e.g. soul-collection/AI-SDLC/ <position>-soul.md - One person wearing several hats = one soul per role, not one per person.
3. Anatomy (borrows the AI-SDLC template)
Core Principles → Identity (name/role/emoji/vibe/mission) → Role Boundary (for specialist/product souls: who owns what across the fleet) → Knowledge Base (vault-grounded) → Core Techniques (applied, not named) → Owned Documents (🔴/🟡/🟢 with template paths + depth) → Handoff Protocol (outgoing/incoming) → Priority Protocol → Execution Style → Collaboration Rules → Quality Gates.
This anatomy is a template, not a straitjacket — lifestyle souls reorder/omit sections to match the domain (deck/educator souls have no Priority Protocol section, and that's fine). Souls that produce visual output (UI, decks, dashboards, diagrams) also carry a Brand Compliance (Panomete CI) section: brand root F:\obsidian_note\oralita_md\personal\brand\ (locked 2026-08-25: primary #1FB854, secondary #1EB88E, accent #1FB8AB, Sarabun + JetBrains Mono) with Apply-when / Skip-when / ask-if-unsure rules. Text-only souls (audiophile, career-coach, journey-writer) skip it.
Role Boundary section (added 2026-08-06 after 4 specialist upgrades): when a soul shares a fleet with other specialist profiles, include a dedicated section that states explicitly what this role owns vs. what DevOps/Full-Stack/QA/PO own. This prevents cross-profile turf confusion — without it, specialist souls tend to absorb responsibilities that belong to other profiles. Every specialist soul upgraded in batch (devops, qa, product-owner, data-engineer) needed one.
4. Ground each soul in the user's BOK vault
Each soul is a "graduate" of the BOK(s) that own its documents. The knowledge is live, so point at real vault paths, not titles:
body-of-knowledge/<BOK>/<chapter>.md— the curriculum the soul readsdocument_template/<category>/<doc>.md— the templates the soul owns (with Heavy/Med/Light depth)career-path/<NN>_<Role>/00_overview.md— competence anchorsoftware-engineering-note/<KA>/— deep domain notes
Verify every referenced path resolves after writing — stale template names are the #1 error. See references/soul-authoring-vault-grounded.md and run scripts/verify_soul_refs.py.
Upgrading an Existing SOUL to a New Career Level
When the user has a career-path vault (swe-knowledge/career-path/<NN>_<Role>/) and asks to level up an existing specialist soul (e.g. full-stack → senior), run the upgrade workflow in references/soul-level-upgrade.md:
- Inventory the career path first — read the target
00_overview.md+ every capability-area00_overview.md(the mid-vs-senior tables state the exact behavior shift). - Gap-analyze the current soul — capability × coverage (✅/🟡/❌) table. Expect 5–7 missing areas on a level-up; that's the point.
- Keep what survives — carry forward still-valid principles (Dependency Rule, ADR discipline, API-contract-first) and preserve identity; elevate role line + philosophy ("code is the product" → "outcomes are the product").
- Flip the career anchor to the new level; add BOKs the new capability areas cite (BABOK/PMBOK/CyBOK for senior).
- Same review-first gate + sync flow as new souls: collection file → user review → approve → backup → copy → md5sum → smoke test. Registry/main-soul routing rows change only for NEW profiles, not level upgrades.
Product/business path variant
Not every career path entered from Senior Software Engineer is a senior-specialist engineering path. For paths whose overview declares career_family: product-and-business or level: manager (for example, Product Manager), use a layered product upgrade rather than copying the Senior SWE soul:
- Make the product path primary. Map every product capability area (for example, discovery, strategy, prioritization, roadmapping, analytics, requirements, and technical partnership) to an operating charter.
- Use Senior SWE as a foundation. When
entry_fromincludes Senior Software Engineer, include all nine senior capabilities in a compact mapping table, but translate them into product behavior instead of duplicating engineering techniques. - Elevate from backlog ownership to outcome ownership. Add customer evidence, market context, strategic choices, measurable outcomes, living roadmaps, learning loops, and post-launch outcome review.
- Declare role boundaries. Product owns the problem, why, outcomes, and priority; engineering owns how; QA and DevOps provide quality and operational evidence. Do not silently turn the soul into a project manager, engineering manager, or architect.
- Ground product documents in verified templates. If a canonical backlog, roadmap, or experiment template does not exist, label it project-specific or external instead of inventing a vault path.
- Treat career-path wikilinks as leads, not proof. Career notes may contain illustrative or stale links. Verify every referenced path against the live filesystem before copying it into a soul.
See references/product-business-soul-upgrade.md for the reusable capability map, document map, boundary rules, and review checklist.
For a batch worked example showing the specialist-path upgrade pattern applied to 4 souls (devops, qa, product-owner, data-engineer) in one session — including the Role Boundary section, principle-count growth, BOK expansion, and sync flow — see references/specialist-path-batch-upgrade.md.
Syncing Profiles to the Soul Collection
When the collection is updated (soul upgraded, persona changed) and the user wants existing profiles updated, sync each $HERMES_HOME/profiles/<name>/SOUL.md to its collection counterpart. Do NOT assume a profile is stale — verify first.
1. Find stale profiles with a hash diff
cd "$HERMES_HOME/profiles" && md5sum */SOUL.md
md5sum ~/soul-collection/<DOMAIN>/*.md
A profile is stale when its SOUL.md hash ≠ the matching collection file's hash. Matching by content hash, not size or date — that's how you catch "same-ish but different" souls. Life-style souls that weren't touched stay in sync automatically; only the re-authored ones go stale.
2. Name-mapping pitfall
Profile dir name ≠ collection filename (and ≠ subfolder). Map manually — and update the map every time the fleet grows:
product-owner ↔ AI-SDLC/product-owner-soul.md
full-stack ↔ AI-SDLC/full-stack-developer-soul.md (NOT full-stack-soul.md)
devops ↔ AI-SDLC/devops-engineer-soul.md
qa ↔ AI-SDLC/qa-engineer-soul.md
ui-ux ↔ AI-SDLC/ui-ux-designer-soul.md
career-coach ↔ Life Styles/career-coach-soul.md
journey-writer ↔ Life Styles/journey-writer-soul.md
audiophile ↔ Life Styles/audiophile-soul.md
Writing a verification loop that guesses <profile>-soul.md will report false "MISMATCH" on every profile whose collection name has a middle token. Use an explicit declare -A map instead, and have the loop search BOTH AI-SDLC/ and Life Styles/.
3. Back up before overwriting
Old souls are not recoverable once overwritten (the collection file was already replaced). Canonical backup root (Panomete, 2026-09 — replaces the retired profiles/_soul_backup_* dated-dir pattern): F:\obsidian_note\hermes_config_backup\soul-collection\, with live souls under AI-SDLC\ / Life Styles\ subfolders. For pre-overwrite stashes use a dated archive subfolder:
BK="F:/obsidian_note/hermes_config_backup/soul-collection/_archive/$(date +%Y%m%d)" && mkdir -p "$BK"
for d in <stale-profiles>; do cp "$d/SOUL.md" "$BK/${d}-SOUL.md.bak"; done
4. Copy, then re-verify
cp <collection>/<file>-soul.md <profile>/SOUL.md
# re-run md5sum: profile hash must now equal collection hash (byte-identical)
5. Tell the user the running-session caveat
Already-running sessions keep the old soul (Hermes never mutates a live system prompt). New sessions pick up the new SOUL.md. Recommend opening a fresh session per profile to see the change.
6. Remember the main soul
The default/main profile's SOUL lives at $HERMES_HOME/SOUL.md (not in profiles/). Back it up to the collection root (e.g. soul-collection/hermes-main-soul.md) when iterating on it — it's the file that governs the base agent.
Replicating the Setup to a New Machine
When the user wants the whole Hermes setup on another computer (new PC, friend's PC, disaster recovery) — full verified detail in references/machine-replication-handoff.md.
- Grill the scope first (same numbered-options format as souls): base-only vs fleet, searxng local vs homelab, OpenRouter model tier, target OS, who owns the API keys. The answers define the runbook.
- The GitHub repo is the handoff source (
oat431/hermes_config_backup):workflow/= skills (hermes-main-profile/+shared-skills/+ per-profile folders),soul-collection/= souls + registry, runbookHermes-Setup-Install.mdat repo root. (oat431/oralita_mdis STALE legacy — never point a new machine there.)git pushbefore going. - Skill install:
hermes skills tap add oat431/oralita_md+hermes skills install <name>— but taps resolve theskills/folder ONLY; skills under a different path (e.g.workflow/) are invisible to taps → fallback is direct raw-URL install of the SKILL.md. - Profile handoff:
hermes profile exportworks but ships caches (~105 MB). Lean copy =SOUL.md+memories/+config.yamlonly; skipstate.db,sessions/, caches. - Profile skills are NOT in the main skills dir. Each profile's
skills/folder holds its own custom skills (created inside that profile's sessions) that do NOT appear in$HERMES_HOME/skills/. A backup that only walks the main skills dir silently misses them. Backup layout is SHALLOW skill dirs only —workflow/hermes-main-profile/<skill>/+workflow/<profile>/<skill>/, never a deepskills/tree copy (that is clone bloat; see "Syncing Created Skills to the Backup Repo") — plus a shared-skills dedup layer:- Hash-verify (md5sum) every copy of a multi-profile skill BEFORE consolidating. All copies identical → move one copy to
workflow/shared-skills/, delete the per-profile copies, and write ashared-skills/README.mdlisting what's shared and what stays local. - A profile with a divergent variant keeps its local copy (e.g. ui-ux's
grill-me/grill-with-docs, career-coach'sobsidian-vault-builder). - A skill with many variants never gets shared (e.g.
hermes-profile-setuphad 4 — stays per-profile). - Net effect 2026-09: 8 skills shared, 59 duplicate copies removed.
Restore by copying back into
%LOCALAPPDATA%\hermes\profiles\<name>\skills\.
- Hash-verify (md5sum) every copy of a multi-profile skill BEFORE consolidating. All copies identical → move one copy to
- 🔴 SECRET HYGIENE (hard rule): never copy
config.yamlinto a public repo as-is —mcp_servers.<name>.envcarries live tokens (GitHub PATs, DB URLs with passwords). Sanitize to the model block only. GitHub push protection (GH013) blocks the push — treat the rejection as a gift: nothing landed, but the secret transited GitHub's servers, so amend the local commit (git commit --amend) AND recommend token rotation. - Skill publishing:
hermes skills publish --to github --repo <owner/repo> <skill_path>scans the skill, then creates a PR (it does NOT push directly). The merge API 404s on bot-created PRs → squash-merge locally (git fetch origin pull/N/head:branch,git merge --squash, push), then close the PR and delete the branch via API. Strip__pycache__/.pycfrom the merged set. - User-facing runbook format (Panomete): numbered steps, every command explained, tables for ladders/checklists, Mermaid flow at top, verification checklist at the end, written into the vault and pushed to the repo.
Syncing Created Skills to the Backup Repo (workflow/)
Run whenever the user asks to back up "skills created along the way" — it recurs every few weeks as the fleet grows.
- Inventory: walk
$HERMES_HOME/skills/(main) AND every$HERMES_HOME/profiles/<name>/skills/(profile skills do NOT appear in the main dir). Content-hash each SKILL.md against the backup copy — new or changed are the sync candidates. - Author gate: back up only user-created skills — check the
author:frontmatter (this fleet: Panomete / OraMesLita / Hermes-authored). Cross-check community packs by hashing against the bundled tree at$HERMES_HOME/hermes-agent/skills/; name-matching alone misses renamed or re-grouped copies, so hash is the tiebreaker. The bundle hash alone under-reports: packs installed from a skills registry are not in the bundled tree, so they pass the hash test and pollute the candidate list. The reliable third signal is recurrence across homes — a skill present in nearly every profile (30–40 per home, same names) is a distributed pack, while genuine profile work appears in one or two homes. Rank candidates bylen(homes)ascending and only the 1–3-home tail is real. - Shallow dirs only: entries live at
workflow/hermes-main-profile/<skill>/,workflow/<profile>/<skill>/,workflow/shared-skills/<skill>/. Aworkflow/<profile>/skills/...deep tree means a copy swallowed the entire live skills dir (~90–118 preloaded skills per profile, tens of MB) — that is bloat to purge, since Hermes ships those anyway. - Rescue before purge: real user skills can hide inside those deep junk trees, never promoted to the shallow level. Classify EVERY orphan directory by author + bundle hash and copy the user-created ones to their shallow spot before deleting the tree — a purge without this step silently destroys unique work.
- Soul check with CRLF awareness: hash-compare every live
profiles/<name>/SOUL.mdagainst its collection counterpart using the explicit name map (see name-mapping pitfall). A plaindiffcan report the whole file changed from pure CRLF-vs-LF line-ending noise — before concluding a soul differs, compare normalized content (replace('\r\n','\n').strip()), and only then weigh mtimes; a "newer" backup file with identical normalized content needs no update. - Secret-scan the staged diff before committing:
git diff --cached | grep -oE "ghp_|sk-[A-Za-z0-9]{20,}|AIza"(or your provider's key prefixes) and review hits by direction — a match insidedeleted filehunks of purged preloaded helper scripts is removal, not a leak; a match in+lines blocks the commit. - Close out: update
workflow/Overview.mdcounts and the per-profile table to the verified post-sync numbers, commit, push, and correct the fleet entry in memory only if the profile roster changed.
Routing-Generalist Main Soul (multi-profile fleets)
Once the user has specialist profiles, the main soul's job changes: it stops being another specialist and becomes the router/operator — the one who "knows lots of things AND knows lots of people." This pattern (full detail + worked example: references/router-generalist-main-soul.md):
- Hard handoff protocol — when a question matches a specialist domain: (1) 2-3 sentence summary, (2) direct routing line ("This is a
full-stacktask."), (3) context to bring. Be straight, not wishy-washy. - "What I Do / What I Route" split — light work (chat, research, quick scripts, Hermes config, soul creation) done directly; deep work (code→full-stack, bugs→qa, design→ui-ux, homelab→devops, money→financial-advisor, lessons→educator, decks→deck) routed, never half-done.
- New-specialist triggers — depth signal (question needs real depth in a domain with no profile) or repeated signal (same kind of question 2-3×) → recommend creating a soul, never create unilaterally.
profile-registry.md— a routing table (profile → domain → owns → trigger phrases → emoji) living in the soul-collection root. Single source of truth for routing AND the re-install manifest for a new device (profile list, soul sources, MCP servers).- Keep the old persona when re-purposing: same name/emoji/vibe, changed role description + routing table. The user keeps their identity; the job changes.
SOUL.md load semantics (verified in source)
SOUL.md is auto-injected at conversation start (the --ignore-rules flag: "Skip auto-injection of AGENTS.md, SOUL.md, .cursorrules, memory"). The system prompt is byte-stable for the life of a conversation — a live session keeps its old soul no matter what you edit. A new conversation picks up the new soul; restarting the app only helps if it starts a fresh chat (resuming an old session does nothing). Tell the user: open a new chat, don't just restart.
Memory Maintenance
Memory fills up from procedural entries, stale stats, and duplication. Clean it periodically.
Audit pattern
- Read current state: check the memory and user profile percentages in the system prompt header
- Categorize entries:
- ✅ Keep: identity facts, preferences, paths, security rules
- ❌ Remove: procedural rules (belong in SOUL.md or skills), stale completion stats, task logs
- ⚠️ Consolidate: entries duplicated across memory + user profile
- Batch operations: use
memory(operations=[...])for atomic changes — never multiple single-operation calls - Verify: check new percentages after the batch completes
What never belongs in memory
- Procedural rules ("always do X, never do Y") → SOUL.md or skill
- Task progress ("completed phase 3", "merged PR #42") → session_search
- Stale counts ("12 files done, 5 remaining") → they rot within days
- Environment-specific failures ("pip install failed") → fix the environment, don't memorialize the error
What belongs in memory
- User identity, preferences, and style
- Persistent paths (Obsidian vaults, project roots)
- Security rules and boundaries
- Domain-specific context (homelab URL, tech stack)
Cleaning stale entries
When Obsidian or another external system is the source of truth, memory should only hold the path and the pattern — not the current completion state. "Vault at F:\projects\orlita_md, numbered folders" is durable. "Math (12 files), English (27 files)" is stale in a week.
Configuration Audit for Specific Use Cases
When auditing a profile for a specific use case (e.g., programming):
Priority order
- Safety nets: fallback model (uncommented), checkpoints enabled, approval mode
- Cost: model choice matches the domain (coding needs reasoning, health Q&A doesn't)
- Memory headroom: under 60% is healthy, over 80% needs pruning
- Tools: MCP servers and skills relevant to the domain
- UX: streaming, cost display, reasoning effort tuned to the task
Common misses
- Fallback model commented out → no automatic failover on 429/503
checkpoints.enabled: false→ no/rollbacksafety net during refactorsapprovals.mode: manual→ excessive friction;smartuses LLM to auto-approve low-risk commandsreasoning_effort: mediumon coding profiles → bump tohighfor architecture decisionsterminal.timeout: 180→ too tight for docker builds or large test suites
Bulk Provider/Model Migration Across All Profiles
When the user switches the whole fleet to a new provider/model (e.g. "unsubscribed z.ai, everything on QwenCloud token plan now"), do it as one systematic sweep, not profile-by-profile ad-hoc:
- Survey first — read every
config.yamlmodel block at once (hermes config get modelfor main;hermes --profile <name> config get modelper profile). Build a table: current provider / default / base_url. Note profiles on the old provider AND profiles with a stalebase_urlfrom the previous provider — both need fixing. - Standardize provider + default via the CLI (never hand-edit
config.yaml— the patch tool refuses and a stray indent corrupts it):hermes config set model.provider <p>+hermes config set model.default <m>(prefix--profile <name>for each profile). - Strip stale base_urls —
hermes config unset model.base_url(main) /--profile <name>. Let the provider resolve its endpoint from the env var; a leftover DeepSeek/z.ai URL is the classic breakage. - 🔴 Per-profile
.envis NOT inherited from main. Each profile's$HERMES_HOME/profiles/<name>/.envis a separate file. When you migrate profiles to a provider whose key lives in the main.env, you MUST copy the key (and any base_url override) into every profile's.env. This session:financial-advisorandproduct-ownerhad noDASHSCOPE_API_KEY;book-summarizer,data-engineer,security-engineerhad noDASHSCOPE_BASE_URL— all would have silently failed auth. Audit with a grep loop overprofiles/*/.envfor the provider's env var and fill the gaps. - Create missing configs — some profiles may lack
config.yamlentirely (e.g.product-ownerhad onlyprofile.yamlwith aui_metablock, no model config). Copy a known-good sibling's config, set the model block, and inject real secrets in-shell (see secret hygiene below). - Verify the whole sweep — re-run
hermes config get model+--profile <name>for every profile; confirm provider/default/base_url are uniform and no stale provider (zai/deepseek/openrouter) remains. Watch for false positives fromfallback_providers:blocks and commented# provider:templates.
Faster alternative — Python script for 10+ profiles: when the fleet is large,
running hermes config set per profile is slow. Use a Python script with
re.sub to patch all config.yaml files at once, then verify with the CLI.
The script replaces the default: value inside each model block. Template:
import os, re
HOME = os.environ["HERMES_HOME"]
NEW_MODEL = "qwen3.8-flash"
for p in os.listdir(os.path.join(HOME, "profiles")):
if p.startswith("_"): continue
cfg = os.path.join(HOME, "profiles", p, "config.yaml")
if not os.path.exists(cfg): continue
with open(cfg, encoding="utf-8") as f:
text = f.read()
text = re.sub(r"^ default: .*$", f" default: {NEW_MODEL}", text, flags=re.M) # whole-line replace, see pitfalls
with open(cfg, "w", encoding="utf-8") as f:
f.write(text)
Then set the main config: hermes config set model.default <model>. Verify
every profile after with a grep loop over hermes config get.
Regex-sweep pitfalls (each broke a real sweep):
- Replace the WHOLE
key: valueline (anchored^ default: .*$+re.M), never\s*-after-colon with an insert —\s*swallows the newline when the old value is empty and glues the new value onto the next one (default: mimo-v2.6-promimo-v2.6-pro). A\S+-value pattern silently skips an emptydefault:, leaving the profile on no model. base_urlcleanup must match 2-space lines undermodel:only.fallback_providers:entries carry their own 4-spacebase_url(often'') — those are per-fallback settings, not stale endpoints; leave them alone.- Re-read and assert on every file in the same run (
default:/provider:parse to the expected values) before reporting done — a "N files updated" log cannot see a doubled value or an untouched empty one.
^ default: (2-space, anchored) is safe on single-model-block configs; if a config carries extra model blocks (fallback, TTS), scope the sub to the ^model: block first.
Secret hygiene while bulk-editing: never echo a live token into chat output. Use grep '<KEY>=' main/.env >> profile/.env (redirection, no display) or, when a file must be written fresh, write a __PLACEHOLDER__ then REAL=$(grep ...); sed -i "s|__PLACEHOLDER__|$REAL|" so the value never appears in the transcript.
Provider keys can live in auth.json, not just .env. Credentials added via hermes setup or by hand land in auth.json → credential_pool.<provider>[]. Two traps: (1) the secret field name varies by entry — access_token, api_key, key — so entry.get("api_key") or entry.get("key") reports "no key" for a perfectly valid manual entry; probe secret_fingerprint presence instead. (2) 🔴 A named profile reads ONLY its own auth.json/.env — the root store is never a fallback — so a root-added credential must be backfilled per profile (copy the credential_pool entry or re-run provider setup per profile) and smoke-tested with hermes -p <name> chat -q. A fleet whose configs already point at the new provider can still be unauthenticated in every profile.
Token-plan key specifics (QwenCloud / Alibaba Token Plan): the key authenticates against the Anthropic-format gateway, so DASHSCOPE_BASE_URL=https://token-plan.ap-southeast-1.maas.aliyuncs.com/apps/anthropic is required in every profile .env. Unset it and the alibaba provider falls back to the OpenAI-compatible dashscope-intl endpoint, which rejects the token-plan key.
A model listed anywhere is NOT proof the key can call it. provider_models_cache.json aggregates listings across providers, so a model seen next to your provider's block may belong to another (kimi-k3 under openrouter), and even models inside your provider's list can be plan-ineligible ("Access to model denied — check eligibility") or absent ("Model not exist"); the token-plan gateway may not even expose /models. Before bulk-switching any fleet to a named model, live-test it with the real key — POST one tiny chat message to $DASHSCOPE_BASE_URL/v1/messages (header x-api-key, anthropic-version: 2023-06-01) and require a 200 with content in the reply. An unverified model never goes into N configs; if it fails, report that and leave profiles untouched.
Provider Model List (picker) Maintenance
The picker's rows do not come from config.yaml — a home stores no model list. They resolve from a
per-home provider_models_cache.json (keyed by credential fingerprint), then a curated static
fallback, then models.dev metadata. So "the provider's model list is stale/missing" is a per-home
cache fix, not a config edit. Three rules that do not bend:
- Never hand-edit
provider_models_cache.json— a row with a wrong fingerprint is invalid and the next picker open silently replaces it with the curated fallback. - Write through
hermes_cli.models.update_provider_cache_entry(slug, models)(Hermes venv interpreter), settingHERMES_HOMEand loading that home's.envbefore each call — the fingerprint hashes the provider env vars, and env keys must be cleared between homes. - Verify with
cached_provider_model_ids(slug, non_blocking=True), the function the UI uses; the raw JSON can look right while the read path filters rows away.
A served list that exactly equals the curated static list means the live probe failed — that is not
proof about the account's entitlement. Full procedure, probe-result decoding, and the durable
slug-based alternative: references/provider-model-list-maintenance.md.
Troubleshooting a Broken Profile (gateway setup / no provider / no MCP)
Symptom: a profile loads but (a) shows a "gateway needs setup" prompt, (b) has no provider/model available, (c) reports no MCP servers. All three hit the deck profile in one session (2026-08) — root causes, in order of likelihood:
-
Missing
_config_version→hermes config check --profile <name>reportsConfig version: 0 → N (update available). Hermes treats the profile as unconfigured and asks for gateway setup. Fix: add_config_version: <N>(copy the current value from the main$HERMES_HOME/config.yaml) as the first line ofprofiles/<name>/config.yaml. -
Empty
gateway: {}block in the profile config confuses startup. Working profiles have nogatewaykey at all. Fix: delete the empty block. -
Stale
base_urlmismatched withproviderprotocol → e.g.provider: alibaba+ a leftover DeepSeek/z.ai/OpenRouter URL breaks model loading. This exact bug was found incareer-coach,gym,full-stack(stale DeepSeek URLs after switching provider) anddeck. Fix: remove the stalebase_urlso the provider resolves its own endpoint (hermes config unset model.base_url --profile <name>), or set one matching the provider protocol.⚠️ Token-plan nuance (do NOT over-generalize "Anthropic URL = broken"). The
alibabaprovider's default endpoint is OpenAI-compatible (dashscope-intl.aliyuncs.com/compatible-mode/v1). BUT the QwenCloud Token Plan key only authenticates against the Anthropic-format gatewayhttps://token-plan.ap-southeast-1.maas.aliyuncs.com/apps/anthropic. So for a token-plan key, an Anthropic-formatbase_urlis correct, not a bug — it must be set via theDASHSCOPE_BASE_URLenv var (see the bulk-migration section below). The rule is: the protocol must match whatever endpoint the key is actually provisioned for, not a fixed "alibaba = OpenAI-compat" assumption. -
mcp_serversblock missing → MCP servers are NOT inherited from main config; each profile'sconfig.yamlneeds its own block. A baremcp: {}is not a config. Fix: copy the 5 standard servers (github, postgres, drawio, filesystem, searxng) from the main config into the profile file. -
Model not served by the configured provider → check
hermes config check --profile <name>output for which env vars the provider expects (e.g.DASHSCOPE_API_KEYfor alibaba,GLM_API_KEY/ZAI_API_KEYfor zai) and confirm the model name exists on that plan.
Fix flow: hermes config check --profile <name> → patch config.yaml (version + remove gateway + fix base_url + add mcp_servers) → hermes gateway restart --profile <name> to pick up the changes.
Pitfalls
- Don't clone-all for cross-domain profiles. GitHub MCP, PostgreSQL, and Docker skills in a fitness profile waste memory and confuse context.
- Don't keep procedural rules in memory. They get re-read as directives each session, creating self-imposed constraints. SOUL.md or skills are the right home.
- Don't store completion stats in memory. "Phase 3 done, 12 of 20 files" rots within days. Obsidian or session_search are better.
- OpenClaw SOULs reference file paths that don't exist in Hermes. Always map
~/.openclaw/state/→memorytool, not literal file paths. - Profile
.envfiles are NOT inherited from the main.env. A key that lives in$HERMES_HOME/.env(e.g.DASHSCOPE_API_KEY) is not automatically available to a profile — each$HERMES_HOME/profiles/<name>/.envis its own file. The exception ishermes profile create --clone, which copies the.envat creation time, but a key added to main later will still be missing from existing profiles. After any provider change, grep each profile's.envfor the new provider's key and backfill gaps (see Bulk Provider/Model Migration). - Never commit
config.yamlto a public repo. MCP server env sections hold live secrets — a profile's config is machine-local, not handoff material. Sanitize to the model block or omit it entirely (see Replicating section). - Write souls into the collection subfolder, never the root. Root-level
<profile>-soul.mdfiles sitting next toAI-SDLC//Life Styles/are exactly how the 2026-09 duplicate pile-up happened (7 root dupes). Cleanup order when they exist anyway: hash-compare root vs subfolder → copy the NEWER content (e.g. brand-section updates) INTO the subfolder copy → only then delete the root file. Never delete first. - Patch souls by anchoring on a header every target soul has. Fleet souls are structurally heterogeneous (some lack
## Priority Protocol; all have## Quality Gates). Read the actual section first — a file previously read with offset/limit counts as a partial view and later writes get refused/warned — then insert new sections before## Quality Gatesor after the Document Handoff tables. Writes to profileSOUL.mdfiles may trigger a write-approval prompt; if it times out with the user away, that is not a content refusal — re-issue the identical patch in a fresh turn (it succeeded on retry) instead of forcing it through another path.
04 同仓库更多 Skills
project-spec-docs
Fill/update project_spec docs (templates, MM handoffs).
penpot-mcp
Penpot MCP: connect, verify, and fix streaming via nginx.
nginx-streaming-proxy
Configure nginx for streaming endpoints (SSE, MCP, WS).
branding-ci
Use for brand/CI identity, style guides, and brand docs.
yuanbao
Yuanbao (元宝) groups: @mention users, query info/members.
slidev
Create and present web-based slidedecks for developers using Slidev with Markdown, Vue components, code highlighting, animations, and interactive features. Use when building technical presentations, conference talks, code walkthroughs, teaching materials, or developer decks.