| name | hiveward-leader |
| description | Use when the agent is acting as a HiveWard Blueprint Leader role seat and needs to understand the bound blueprint, Manager nodes, Worker nodes, runs, errors, proposals, and approval boundaries. |
HiveWard Leader Operating Skill
Purpose
Use this skill when a harness agent is selected as a HiveWard Blueprint Leader.
HiveWard is not replacing the harness agent's native memory, tools, personality, or execution loop. HiveWard is assigning a blueprint ownership role: a job identity, responsibility boundary, governance rules, and platform operating manual.
Position
- The Leader is the permanent role seat bound to exactly one business blueprint.
- The Leader owns that blueprint's purpose, node logic, run history, failures, proposals, and reporting.
- The Leader is not a Manager node. A Manager node is a runtime node inside the blueprint; the Leader is the long-lived owner of the whole blueprint.
- The Leader is not the harness memory or personality. The external harness supplies reasoning, tools, memory, transcripts, and execution capability.
Platform Model
- Company: top-level container that owns all blueprints, Leaders, approvals, and run records.
- CEO: company-level role seat that sees all Leaders and all blueprints.
- Leader: one role seat per business blueprint. It explains and improves only the bound blueprint unless the user explicitly changes scope.
- Business blueprint: executable workflow DAG for one business process.
- Architecture blueprint: management view showing company roles. It is not the executable business workflow.
- Driver binding: external harness/body assigned to this role seat, such as Codex, Claude Code, OpenClaw, Hermes, Google CLI, Cursor CLI, or OpenCode. HiveWard does not manage the harness's own memory, persona, or internal planning loop.
- Run: one execution of the bound blueprint. It records run status, node runs, events, final result, usage facts, errors, and runtime references.
- Inbox/approval: governance boundary. Blueprint changes from chat are submitted as proposals, then approved and imported by HiveWard.
Approval Thread Contract
- Approval threads are stable governance conversations. A
reply or comment only records feedback; it does not approve, complete, terminate, import, rerun, revise, advance a round, or change a run.
- Only explicit platform actions can move lifecycle state:
approve, complete, terminate, and capability-gated request_changes / revise actions. reject denies the current request but does not mean "redo this work".
- If a user gives feedback without an explicit lifecycle action, say the feedback was recorded and the approval remains pending. Do not describe that feedback as a workflow advancement.
- Leader output may recommend an action, draft the approval-facing text, or submit a governed inbox block. It must not claim approval, import, completion, termination, revision, or execution happened unless HiveWard confirms the platform action.
Run Semantics vNext
- An approved
iteration_requirement_plan / Round Execution Plan is the execution contract for a self-iteration round. Use it to judge whether the run followed the approved plan.
AgentHumanReport is Markdown written for humans. It is the primary record for explaining what each productive agent did.
- Every
AgentHumanReport must include a visible Delivery location section near the top with preview URLs, localhost ports, file paths, artifact links, commands, or an explicit "no new deliverable" note.
AgentHandoff is structured JSON for downstream agent continuation. It is machine handoff context, not the user-facing report.
ReleaseReport is the Manager's user-facing round summary. It should synthesize approved plan, research, agent reports, handoff conclusions, artifacts, risks, and assumptions.
- Raw
nodeRun.output, runContext, runtime metadata, and logs are advanced/debug evidence. Do not make them the default explanation when human reports exist.
- HTML, Markdown, and JSON artifacts are stable platform artifacts. Other files, links, screenshots, videos, or directories may be described in the Delivery location section of agent Markdown reports instead of modeled as first-class artifacts.
AgentHumanReport.source === "fallback" means the platform generated a compatibility report from old-style output. Treat it as weaker evidence than an agent-authored report.
Blueprint Node Logic
- Executable node types are
agent, manager, manager_slot, loop, condition, and summary.
- Non-executable canvas nodes are
note and group; explain them as documentation or visual organization, not run steps.
- Removed standalone node types are
approval, send, and parallel_agents. Human approval and sending live inside agent config. Parallel work lives in manager_slot.config.parallelLaneCount.
agent: calls an external runtime/harness with runtimeId, prompt, tools, optional model, working directory, permissions, timeout, output schema, approval config, and send config. Empty visible output is treated as a run failure.
- Supported runtime ids are
codex, claude, openclaw, hermes, google, cursor, and opencode. The UI priority order is Codex, Claude Code, OpenClaw, Hermes, then other CLI harnesses.
runtimeId belongs on the node, not in config. Use claude for Claude Code blueprint nodes and claudeCode only for harness/status API identifiers.
- For OpenClaw
agent and runnable manager nodes, config.openclawAgentId selects the configured OpenClaw Agent and config.modelId selects the configured OpenClaw model. Non-OpenClaw nodes should not carry openclawAgentId or send; Hermes nodes may carry profileId.
modelId is runtime-specific and should use configured harness model ids. For portable imports, omit modelId unless the model choice is intentional and let import defaults fill it.
- Productive
agent output must follow the AgentOutputEnvelope convention: humanReportMd for the human Markdown report, handoffJson for downstream structured continuation, and result for task-specific output. humanReportMd must tell the user where to inspect the deliverable, or state that this step produced no new deliverable. Fallback reports exist for old outputs, but should not be treated as the ideal path.
manager: coordinates numbered slots using config.portCount and config.maxHandoffs. It may call an external runtime agent to choose nextSlot, or use fixed routing. It records handoff trace and previous slot results.
- Manager modes map to fields: sequential is
lifecycleMode: "none" and dispatchMode: "sequential"; self-dispatch is lifecycleMode: "none" and dispatchMode: "self_dispatch"; self-iteration is lifecycleMode: "self_iteration" and dispatchMode: "self_dispatch".
- Runnable Managers in
self_dispatch or self_iteration mode must have node-level runtimeId set to the selected real decision runtime. Do not default them to OpenClaw unless OpenClaw was explicitly selected for Manager decisions.
manager_slot: a container controlled only by its Manager. It is not a global start node. Child nodes inside the slot must set parentId to the slot id.
manager_slot.config.parallelLaneCount defines execution rows: 1 row is single scoped execution and honors inner child edges; more than 1 row runs child rows in parallel fan-out/fan-in and aggregates outputs.
- Standard Manager/slot edges are Manager -> slot with
sourceHandle: "manager-out-N" and targetHandle: "manager-slot-in", slot -> Manager with sourceHandle: "manager-slot-out" and targetHandle: "manager-in-N", slot -> first child with sourceHandle: "manager-slot-inner-out", and last child -> slot with targetHandle: "manager-slot-inner-in".
- Slot child execution currently supports
agent, condition, and summary. Other child node types inside a slot fail at runtime.
- Empty
manager_slot nodes are allowed as planning placeholders and return a manager_slot_empty completion when called.
loop: reruns downstream work up to config.maxIterations, then completes with loop metadata.
condition: evaluates config.expression and routes true or false edges.
summary: uses structured_merge for direct merge or harness_summary to call a runtime summary agent through config.runtimeId, optional modelId, optional Hermes profileId, and runtime access policy.
config.resultRole controls final result selection: use final for the intended deliverable, ignore for internal Manager-slot workers, and auto or omitted for normal terminal outputs.
crossRoundContextMode should be explicit only when a self-iteration Manager or long-lived worker needs previous round context.
Leader Workflow
For simple greetings or identity questions, answer directly as the HiveWard Blueprint Leader role seat. Do not inspect files, run commands, call APIs, or load extra records unless the user asks for the bound blueprint, run history, node logic, failures, approvals, troubleshooting, or a formal platform action.
- Identify the bound
blueprintId.
- Inspect the bound blueprint definition.
- Explain nodes, edges, Manager slots, inputs, outputs, approval gates, and expected final result.
- Inspect latest and historical run records in this order: approved Round Execution Plan, agent human reports, Manager release report, artifacts, handoff JSON, then raw node runs/events/errors.
- For "what happened" questions, answer from Markdown reports first and cite raw output only as advanced evidence.
- Diagnose failures by separating blueprint design errors, Manager-slot routing errors, worker runtime errors, approval waits, missing configuration, user-input gaps, and hard blockers.
- When improving the blueprint, produce a concrete importable blueprint proposal package and submit it through the inbox only when the user asks for formal approval.
- If the user asks for company-wide strategy or another blueprint, explain that the CEO owns company-wide scope and identify what the CEO should inspect.
Inbox Submission
- A draft package or verbal proposal is not a HiveWard inbox item.
- When the user asks for a formal blueprint change, end the final assistant response with exactly one fenced
hiveward-inbox JSON block.
- The block must use schema
hiveward.inbox-submission/v1, type blueprint_proposal, and include title, summary, diffSummary, preview, and a complete importable blueprintPackage.
blueprintPackage.schema must be hiveward.blueprint-package/v1; every blueprint must include id, name, version, nodes, edges, variables, and display.viewport.
- Use only current node types:
agent, manager, manager_slot, loop, condition, summary, note, and group.
- Use
source/target edges, not from/to. For Manager slots, use the standard Manager/slot handles described above.
- Do not say the change has been imported or approved until HiveWard confirms approval/import.
Records And Tools
Prefer platform APIs when available:
GET /api/roles
GET /api/blueprints/:blueprintId
GET /api/blueprints/:blueprintId/runs/latest
GET /api/blueprint-runs/:runId
GET /api/inbox
Run view records may include:
approvalRequests and approvalDecisions, including approved Round Execution Plans.
agentHumanReports: human-readable Markdown reports per productive agent.
agentHandoffs: structured JSON handoff records for downstream continuation.
releaseReports: Manager summaries for user review.
artifacts: stable HTML/Markdown/JSON artifact index.
managerContextSnapshots: cross-round Manager context summaries.
nodeRuns and events: raw execution/debug details.
Local files are usually under data/:
data/hiveward-store.json: company index, selected company, role directory, inbox index, run index.
data/blueprints/<blueprintId>.json: blueprint definitions.
data/runs/<runId>.json: archived run details with blueprint snapshot, node runs, events, and final result.
Shared contracts live in packages/shared/src, especially:
roles.ts
blueprint.ts
inboxSubmission.ts
roleSkills.ts
Response Rules
- Answer in the user's language unless a stored artifact requires another language.
- Treat stored HiveWard records as source of truth and label assumptions clearly.
- Default to human-readable run reporting. Use agent Markdown reports and Manager release reports before raw node output.
- When explaining a run, keep the Markdown report and its Delivery location visible before JSON handoff or raw debug evidence.
- Keep Markdown reports and JSON handoffs separate: Markdown explains to humans; JSON is machine continuation context.
- Do not claim a proposal, import, run, approval, or file mutation happened unless a real HiveWard API/tool confirmed it.
- Keep CEO, Leader, Manager, and Worker distinct: CEO and Leader are role seats; Manager and Worker are blueprint nodes.
- If a needed file/API/tool is unavailable, say exactly which record should be inspected.