Skip to content

T-MVK5-wire-config-explain-doctor-provenance

State: closed/done · Impact: low · Complexity: medium

Make sdlc config explain workflows.<name> and sdlc config explain hooks.<hookname> show the real {layer, mode} resolution instead of the generic local | project | default | unset VALUE_SOURCES answer every other config key still uses.

resolveKeyValue (config-file.ts:286) answers every dotted config key, including workflows.*/hooks.*/chain.stages.*, through the generic local/project/default/unset lookup — it can report only whether the workflows map was touched in local/project, not which layer actually produced check’s effective step list, nor whether a project-set list came from an override or a wrap.

resolveKeyValue special-cases a dotted key rooted at workflows./hooks./chain.stages.: instead of the generic lookup, it calls resolveWorkflow/resolveHook/resolveChain and projects their per-step (or per-stage) provenance into the existing source/value/ ignored output shape. explain’s renderer grows a branch that prints one layer/mode line per step for a lifecycle key. Every other config key’s resolution is untouched.

  1. lib/services/config/config-file.ts: resolveKeyValue gains a special case for a dotted key rooted at workflows./hooks./chain.stages.: instead of the generic local/project/default/unset lookup, call resolveWorkflow/resolveHook/resolveChain (T-4OUZ/T-4KYN/ T-Q65Q) and project their per-step (or per-stage) provenance into the existing source/value/ignored output shape — one line per resolved step when there is more than one, or the single scalar {layer} for a chain stage. Every other key’s resolution is untouched.
  2. lib/services/config/ops/explain.ts’s render grows a branch that prints one layer/mode line per step for a workflows.*/hooks.* key, instead of the single effective: ... (from ...) line.
  3. lib/services/project/ops/doctor.ts’s drift section: grep first — update its own output strings only if it names VerbSource/WorkflowStepSource literally anywhere; if it only reports trust state, not provenance, this file needs no change.
AreaNote
solutions/ontological/lib/services/config/config-file.tsresolveKeyValue special-case for lifecycle keys
solutions/ontological/lib/services/config/ops/explain.tsRender per-step provenance
solutions/ontological/lib/services/config/ops/list.tsSame special-case if list also surfaces per-key source
solutions/ontological/lib/services/project/ops/doctor.tsUpdate citations if any (verify by grep)
  • AC-1: sdlc config explain workflows.check against a project that sets workflows.check in sdlc.yaml only prints a project/replace (or equivalent rendered form) provenance line per step, not the generic (from project) single-value line.
  • AC-2: sdlc config explain orchestrator.max_implementations (an ordinary scalar key, untouched by this decision) renders exactly as it does today — proving the special-case is additive, not a rewrite of the generic path.
  • AC-3: Existing config/ops/explain.test.ts/list.test.ts cases for non-lifecycle keys pass unmodified; new cases cover the workflows.*/hooks.* branch.
  • AC-4: sdlc config explain workflows.nonexistent-name renders the envelope’s layer: 'none' distinctly (e.g. “not configured — no builtin, project, local, or env entry”), not as an empty resolved list with no explanation.
  • Redesigning VALUE_SOURCES for every other config key.

T-4OUZ, T-4KYN, T-Q65Q (needs the final provenance shape and resolveChain signature settled).

Drawn from D-LSLH-collapse-verbs-workflows-chain-hooks’s “Provenance shape” section.

T-4OUZ, T-4KYN, T-Q65Q


← Back to Tasks