bug(workflow-utils): createHermesRole passes prompt as Hermes profile name #216

Closed
opened 2026-04-28 05:10:52 +00:00 by xiaoju · 1 comment
Owner

What

When a workflow uses createHermesRole, the prompt string is passed as a positional argument to the Hermes CLI, which interprets it as a profile name instead of a prompt.

Reproduce

Trigger any workflow with a tester role using createHermesRole. The tester fails with:

hermes: exitCode=1 stderr=Error: Invalid profile name "You are testing a newly created Nerve sense..."

Expected

The prompt should be passed via --prompt flag or stdin, not as a positional argument.

Found in

Running sense-generator workflow — planner and coder succeeded, tester failed at Hermes invocation.

Fix

Update createHermesRole in packages/workflow-utils/src/role-factories.ts to pass the prompt correctly to Hermes CLI.

## What When a workflow uses `createHermesRole`, the prompt string is passed as a positional argument to the Hermes CLI, which interprets it as a profile name instead of a prompt. ## Reproduce Trigger any workflow with a tester role using `createHermesRole`. The tester fails with: ``` hermes: exitCode=1 stderr=Error: Invalid profile name "You are testing a newly created Nerve sense..." ``` ## Expected The prompt should be passed via `--prompt` flag or stdin, not as a positional argument. ## Found in Running `sense-generator` workflow — planner and coder succeeded, tester failed at Hermes invocation. ## Fix Update `createHermesRole` in `packages/workflow-utils/src/role-factories.ts` to pass the prompt correctly to Hermes CLI.
Owner

补充诊断

Issue 描述的问题是对的,但修复位置不准确。问题不在 role-factories.ts,而在 packages/workflow-utils/src/hermes-agent.ts

要改的点(第 36-49 行)

  1. "run""chat" — hermes 没有 run 子命令
  2. "-p""-q" — 单次查询用 -q/--query
  3. "--skill""-s" — 正确的 flag 是 -s/--skills

— 小墨

## 补充诊断 Issue 描述的问题是对的,但修复位置不准确。问题不在 `role-factories.ts`,而在 `packages/workflow-utils/src/hermes-agent.ts`。 ### 要改的点(第 36-49 行) 1. `"run"` → `"chat"` — hermes 没有 run 子命令 2. `"-p"` → `"-q"` — 单次查询用 -q/--query 3. `"--skill"` → `"-s"` — 正确的 flag 是 -s/--skills — 小墨
This repo is archived. You cannot comment on issues.
No Label
2 Participants
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/nerve#216