warded ignores selected bundle agents.kdl default harness, so aos config appears active but does nothing #1227

Closed
opened 2026-07-14 05:56:53 +00:00 by coilyco-ops · 6 comments
Member

Problem

warded director defaults to Claude even when the selected aos bundle declares Codex as the fleet default.

Observed on 2026-07-13 from coilyco-flight-deck/agentic-os:

  • shell bootstrap exports WARD_CONFIG_REF=file:///Users/kai/projects/coilyco-flight-deck/agentic-os/.ward.
  • ward doctor reports that same config source and passes.
  • aos .ward/agents.kdl contains defaults { agent codex }.
  • warded director --repo coilyco-flight-deck/agentic-os --print still resolves director harness: claude, engineer-harness: claude, and dispatch: ward agent engineer ... --harness claude.
  • ward agents list --json also reports baked defaults with agent: claude, even with WARD_CONFIG_REF set to the aos bundle.

This makes the aos bundle misleading: it carries and validates agents.kdl, but the core warded launch path does not use that default for the actual harness selection.

Why this is confusing

The operator sees a selected bundle in ward doctor and in warded --print, so it is reasonable to expect the bundle fleet default to drive the run. Instead, ward splits behavior:

  • edge/operator surfaces use the selected WARD_CONFIG_REF bundle
  • core agent/container paths use ward baked fleet defaults

That split may be intentional today, but it makes aos config look like it controls launch behavior when it does not.

Evidence in code

  • cmd/ward/fleet.go loads fleet config from coreRuntimeConfigSource().
  • cmd/ward/configsource.go says core agent/container paths do not depend on WARD_CONFIG_REF parsing.
  • cmd/ward/agent.go builds the --harness flag default from defaultAgentMode().
  • cmd/ward/agent_adapter.go resolves defaultAgentMode() from the core fleet default.

Ask

Pick and enforce one contract:

  1. Make selected bundle agents.kdl and roles.kdl drive ward agent defaults, including warded director default harness and inherited engineer harness.
  2. Or explicitly reject or ignore those fields for warded, and remove or rename the aos-side shape so it cannot look like launch config.

Acceptance

  • If the selected bundle says defaults { agent codex }, warded director --print resolves director harness: codex unless the user passes --harness or --agent.
  • If ward intentionally keeps core defaults baked, ward doctor or warded --print makes the ignored bundle fields visible so the operator does not debug shell env that is already correct.
  • Docs explain which config source owns harness defaults.

Filed from the agentic-os investigation after Kai noticed warded director defaulting to Claude despite aos declaring Codex.


Decision for headless carry

Chosen contract: the selected bundle should drive warded defaults when it defines them. If the selected bundle says defaults { agent codex }, warded director --print should resolve director harness codex unless the user passes --harness or --agent.

Required shape:

  • Make selected bundle agents.kdl and roles.kdl defaults visible to warded launch resolution.
  • Preserve explicit CLI flag precedence over bundle defaults.
  • If any field remains intentionally ignored, print that ignored status in warded --print and document why.
  • Add regression coverage for selected-bundle default harness and inherited engineer harness.
  • Keep baked defaults only as fallback when no selected bundle value exists.
## Problem `warded director` defaults to Claude even when the selected aos bundle declares Codex as the fleet default. Observed on 2026-07-13 from `coilyco-flight-deck/agentic-os`: * shell bootstrap exports `WARD_CONFIG_REF=file:///Users/kai/projects/coilyco-flight-deck/agentic-os/.ward`. * `ward doctor` reports that same config source and passes. * aos `.ward/agents.kdl` contains `defaults { agent codex }`. * `warded director --repo coilyco-flight-deck/agentic-os --print` still resolves `director harness: claude`, `engineer-harness: claude`, and `dispatch: ward agent engineer ... --harness claude`. * `ward agents list --json` also reports baked defaults with `agent: claude`, even with `WARD_CONFIG_REF` set to the aos bundle. This makes the aos bundle misleading: it carries and validates `agents.kdl`, but the core `warded` launch path does not use that default for the actual harness selection. ## Why this is confusing The operator sees a selected bundle in `ward doctor` and in `warded --print`, so it is reasonable to expect the bundle fleet default to drive the run. Instead, ward splits behavior: * edge/operator surfaces use the selected `WARD_CONFIG_REF` bundle * core agent/container paths use ward baked fleet defaults That split may be intentional today, but it makes aos config look like it controls launch behavior when it does not. ## Evidence in code * `cmd/ward/fleet.go` loads fleet config from `coreRuntimeConfigSource()`. * `cmd/ward/configsource.go` says core agent/container paths do not depend on `WARD_CONFIG_REF` parsing. * `cmd/ward/agent.go` builds the `--harness` flag default from `defaultAgentMode()`. * `cmd/ward/agent_adapter.go` resolves `defaultAgentMode()` from the core fleet default. ## Ask Pick and enforce one contract: 1. Make selected bundle `agents.kdl` and `roles.kdl` drive `ward agent` defaults, including `warded director` default harness and inherited engineer harness. 2. Or explicitly reject or ignore those fields for `warded`, and remove or rename the aos-side shape so it cannot look like launch config. ## Acceptance * If the selected bundle says `defaults { agent codex }`, `warded director --print` resolves `director harness: codex` unless the user passes `--harness` or `--agent`. * If ward intentionally keeps core defaults baked, `ward doctor` or `warded --print` makes the ignored bundle fields visible so the operator does not debug shell env that is already correct. * Docs explain which config source owns harness defaults. Filed from the agentic-os investigation after Kai noticed `warded director` defaulting to Claude despite aos declaring Codex. --- ## Decision for headless carry Chosen contract: the selected bundle should drive `warded` defaults when it defines them. If the selected bundle says `defaults { agent codex }`, `warded director --print` should resolve director harness `codex` unless the user passes `--harness` or `--agent`. Required shape: * Make selected bundle `agents.kdl` and `roles.kdl` defaults visible to warded launch resolution. * Preserve explicit CLI flag precedence over bundle defaults. * If any field remains intentionally ignored, print that ignored status in `warded --print` and document why. * Add regression coverage for selected-bundle default harness and inherited engineer harness. * Keep baked defaults only as fallback when no selected bundle value exists.
Owner

we should make unknown keys fail ward doctor

we should make unknown keys fail `ward doctor`
Owner

unknown values too, in the cases where we can enumerate possible values

unknown values too, in the cases where we can enumerate possible values
Author
Member

P1 clarity note from Kai on 2026-07-15: treat this as a config inheritance/precedence question. The engineer should explicitly inspect urfave/cli default/env/file handling before inventing custom precedence. The likely tree to make explicit is config file defaults, env overrides, and CLI flags, with CLI flags winning.

P1 clarity note from Kai on 2026-07-15: treat this as a config inheritance/precedence question. The engineer should explicitly inspect urfave/cli default/env/file handling before inventing custom precedence. The likely tree to make explicit is config file defaults, env overrides, and CLI flags, with CLI flags winning.
Author
Member

WARD-TRIAGE: warded control plane coherence milestone

This issue is part of the warded control plane coherence sprint. The release thesis is to make warded feel like one dependable control plane for agent work: higher safe parallelism, coherent config defaults, reliable broker/container behavior, human-feedback gates, and enough structured evidence for the next actor after a paused or failed run.

For this sprint, headless means an engineer should be able to carry the issue from current issue context to a merged change without new human decisions. If the issue discovers a missing decision, split or demote the unclear part instead of guessing.

WARD-TRIAGE: warded control plane coherence milestone This issue is part of the `warded control plane coherence` sprint. The release thesis is to make `warded` feel like one dependable control plane for agent work: higher safe parallelism, coherent config defaults, reliable broker/container behavior, human-feedback gates, and enough structured evidence for the next actor after a paused or failed run. For this sprint, `headless` means an engineer should be able to carry the issue from current issue context to a merged change without new human decisions. If the issue discovers a missing decision, split or demote the unclear part instead of guessing.
Author
Member

WARDED_WORKFLOW: reservation-held

reservation details

Holder: launch intent for container engineer-codex-ward-1227 on host kais-macbook-pro-2.local.

Accepted by ward agent --harness codex (reserved 2026-07-15T10:03:31Z). Concurrent ward agent runs are blocked until this intent becomes visible or the intent is released. The stale-intent fallback is still TTL-bounded (3h TTL). --override-reservation overrides.

Do not comment on or edit this issue to steer the run while it is reserved. The engineer seeded the body once at launch and never re-reads it, so a comment or edit reaches only human readers, never the running engineer. A correction goes to a new issue, dispatched fresh. That is the only channel that reaches a run in flight. Where the forge supports it, ward locks this conversation to make that a road-block rather than a convention (ward#494).

run seed context — what this run is carrying (ward#609)
  • Resolved: coilyco-flight-deck/ward#1227 · branch issue-1227 · harness codex · workflow pull-request-and-merge
  • Run: engineer-codex-ward-1227 · ward v0.710.0 · dispatched 2026-07-15T10:03:23Z
  • Comment thread: 4 included in the pre-flight read, 0 stripped (ward's own automated comments).

Static container doctrine and seed boilerplate are identical every run and omitted here (they ride ward v0.710.0).

— Codex, via ward agent

<!-- ward-agent-reservation --> WARDED_WORKFLOW: reservation-held <details><summary>reservation details</summary> Holder: launch intent for container `engineer-codex-ward-1227` on host `kais-macbook-pro-2.local`. Accepted by `ward agent --harness codex` (reserved 2026-07-15T10:03:31Z). Concurrent `ward agent` runs are blocked until this intent becomes visible or the intent is released. The stale-intent fallback is still TTL-bounded (3h TTL). `--override-reservation` overrides. **Do not comment on or edit this issue to steer the run while it is reserved.** The engineer seeded the body once at launch and never re-reads it, so a comment or edit reaches only human readers, never the running engineer. A correction goes to a **new issue, dispatched fresh**. That is the only channel that reaches a run in flight. Where the forge supports it, ward locks this conversation to make that a road-block rather than a convention (ward#494). <details><summary>run seed context — what this run is carrying (ward#609)</summary> - **Resolved:** `coilyco-flight-deck/ward#1227` · branch `issue-1227` · harness `codex` · workflow `pull-request-and-merge` - **Run:** `engineer-codex-ward-1227` · ward `v0.710.0` · dispatched `2026-07-15T10:03:23Z` - **Comment thread:** 4 included in the pre-flight read, 0 stripped (ward's own automated comments). - included: @coilysiren (2026-07-14T05:58:20Z), @coilysiren (2026-07-14T05:58:41Z), @coilyco-ops (2026-07-15T07:08:46Z), @coilyco-ops (2026-07-15T07:16:35Z) Static container doctrine and seed boilerplate are identical every run and omitted here (they ride ward v0.710.0). </details> </details> <!-- ward-agent-signature --> — Codex, via `ward agent`
Author
Member

QA follow-up: PASS. PR #1383 merged at afd3b815db. PR test run 8455 succeeded, promote run 8457 succeeded, and release run 8458 succeeded.

Evidence checked:

  • agentHarness now resolves the no-flag default through the selected bundle via selectedAgentMode(), while explicit --harness / --agent still win.
  • directorEngineerHarness still inherits the resolved director mode unless --engineer-harness is explicitly set.
  • ward agents list --json and role definitions now read selected bundle fleet/role defaults, with baked defaults as fallback.
  • Focused tests passed: TestAgentHarnessUsesSelectedBundleDefault, TestAgentsListJSONUsesSelectedBundleDefaults, TestAgentRoleDefinitionsUseSelectedBundleCatalog, TestBacklogPrintDirectorPlanIncludesCLIConfig, and TestDirectorEngineerHarness.
  • Command smoke test against a scratch selected bundle with defaults { agent codex } printed director harness: codex, engineer-harness: codex, and dispatch argv with --harness codex.

The issue criteria are met; no follow-up issue needed.

QA follow-up: PASS. PR #1383 merged at afd3b815dbbb151981406fa9c21b37189085193e. PR test run 8455 succeeded, promote run 8457 succeeded, and release run 8458 succeeded. Evidence checked: - `agentHarness` now resolves the no-flag default through the selected bundle via `selectedAgentMode()`, while explicit `--harness` / `--agent` still win. - `directorEngineerHarness` still inherits the resolved director mode unless `--engineer-harness` is explicitly set. - `ward agents list --json` and role definitions now read selected bundle fleet/role defaults, with baked defaults as fallback. - Focused tests passed: `TestAgentHarnessUsesSelectedBundleDefault`, `TestAgentsListJSONUsesSelectedBundleDefaults`, `TestAgentRoleDefinitionsUseSelectedBundleCatalog`, `TestBacklogPrintDirectorPlanIncludesCLIConfig`, and `TestDirectorEngineerHarness`. - Command smoke test against a scratch selected bundle with `defaults { agent codex }` printed `director harness: codex`, `engineer-harness: codex`, and dispatch argv with `--harness codex`. The issue criteria are met; no follow-up issue needed.
Sign in to join this conversation.
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
coilyco-flight-deck/ward#1227
No description provided.