ultimate-pi 0.16.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (137) hide show
  1. package/.agents/skills/harness-context/SKILL.md +13 -6
  2. package/.agents/skills/harness-debate-plan/SKILL.md +37 -20
  3. package/.agents/skills/harness-eval/SKILL.md +6 -21
  4. package/.agents/skills/harness-governor/SKILL.md +4 -3
  5. package/.agents/skills/harness-orchestration/SKILL.md +39 -51
  6. package/.agents/skills/harness-plan/SKILL.md +23 -12
  7. package/.agents/skills/harness-review/SKILL.md +52 -0
  8. package/.agents/skills/harness-sentrux-setup/SKILL.md +13 -1
  9. package/.agents/skills/harness-steer/SKILL.md +14 -0
  10. package/.pi/agents/harness/adversary.md +3 -10
  11. package/.pi/agents/harness/evaluator.md +3 -12
  12. package/.pi/agents/harness/executor.md +12 -14
  13. package/.pi/agents/harness/planning/decompose.md +7 -4
  14. package/.pi/agents/harness/planning/hypothesis-validator.md +2 -0
  15. package/.pi/agents/harness/planning/hypothesis.md +4 -2
  16. package/.pi/agents/harness/planning/implementation-researcher.md +1 -1
  17. package/.pi/agents/harness/planning/plan-adversary.md +2 -0
  18. package/.pi/agents/harness/planning/plan-evaluator.md +2 -0
  19. package/.pi/agents/harness/planning/plan-synthesizer.md +25 -0
  20. package/.pi/agents/harness/planning/planning-context.md +48 -0
  21. package/.pi/agents/harness/planning/review-integrator.md +2 -0
  22. package/.pi/agents/harness/planning/scout-graphify.md +3 -1
  23. package/.pi/agents/harness/planning/scout-semantic.md +3 -1
  24. package/.pi/agents/harness/planning/scout-structure.md +3 -1
  25. package/.pi/agents/harness/planning/sprint-contract-auditor.md +2 -0
  26. package/.pi/agents/harness/sentrux-steward.md +51 -0
  27. package/.pi/extensions/00-posthog-network-bootstrap.ts +11 -0
  28. package/.pi/extensions/harness-debate-tools.ts +12 -3
  29. package/.pi/extensions/harness-live-widget.ts +27 -1
  30. package/.pi/extensions/harness-plan-approval.ts +62 -56
  31. package/.pi/extensions/harness-run-context.ts +553 -84
  32. package/.pi/extensions/harness-subagent-submit.ts +43 -33
  33. package/.pi/extensions/harness-telemetry.ts +29 -4
  34. package/.pi/extensions/lib/debate-bus-core.ts +15 -9
  35. package/.pi/extensions/lib/harness-artifact-gate.ts +182 -0
  36. package/.pi/extensions/lib/harness-posthog.ts +9 -5
  37. package/.pi/extensions/lib/harness-spawn-topology.ts +188 -0
  38. package/.pi/extensions/lib/harness-subagent-auth.ts +105 -19
  39. package/.pi/extensions/lib/harness-subagent-policy.ts +37 -19
  40. package/.pi/extensions/lib/harness-subagent-precheck.ts +35 -9
  41. package/.pi/extensions/lib/harness-subagent-submit-pipeline.ts +66 -2
  42. package/.pi/extensions/lib/harness-subagent-submit-registry.ts +21 -3
  43. package/.pi/extensions/lib/harness-subagents-bridge.ts +91 -28
  44. package/.pi/extensions/lib/harness-subprocess-bootstrap.ts +73 -0
  45. package/.pi/extensions/lib/plan-approval/create-plan.ts +2 -3
  46. package/.pi/extensions/lib/plan-approval/resolve-disk.ts +102 -0
  47. package/.pi/extensions/lib/plan-approval/schema.ts +22 -8
  48. package/.pi/extensions/lib/plan-approval/types.ts +1 -1
  49. package/.pi/extensions/lib/plan-approval/validate.ts +2 -2
  50. package/.pi/extensions/lib/plan-approval-readiness.ts +241 -0
  51. package/.pi/extensions/lib/plan-debate-eligibility.ts +67 -7
  52. package/.pi/extensions/lib/plan-debate-focus.ts +21 -9
  53. package/.pi/extensions/lib/plan-debate-gate.ts +101 -17
  54. package/.pi/extensions/lib/plan-debate-lanes.ts +57 -3
  55. package/.pi/extensions/lib/plan-debate-round-status.ts +18 -7
  56. package/.pi/extensions/lib/plan-messenger.ts +4 -0
  57. package/.pi/extensions/lib/plan-review-gate.ts +59 -0
  58. package/.pi/extensions/lib/posthog-client.ts +76 -0
  59. package/.pi/extensions/policy-gate.ts +24 -19
  60. package/.pi/extensions/trace-recorder.ts +1 -0
  61. package/.pi/harness/agents.manifest.json +24 -16
  62. package/.pi/harness/corpus/cron.example +8 -0
  63. package/.pi/harness/corpus/graphify-kb-updater.config.json +159 -0
  64. package/.pi/harness/corpus/systemd/graphify-kb-updater.env.template +4 -0
  65. package/.pi/harness/corpus/systemd/graphify-kb-updater.service +17 -0
  66. package/.pi/harness/corpus/systemd/graphify-kb-updater.timer +11 -0
  67. package/.pi/harness/docs/adrs/0001-harness-constitution.md +2 -1
  68. package/.pi/harness/docs/adrs/0006-sentrux-dual-layer.md +7 -6
  69. package/.pi/harness/docs/adrs/0009-sentrux-rules-lifecycle.md +6 -1
  70. package/.pi/harness/docs/adrs/0031-harness-run-context.md +1 -1
  71. package/.pi/harness/docs/adrs/0032-harness-command-orchestration.md +7 -0
  72. package/.pi/harness/docs/adrs/0034-darwin-plan-research-pipeline.md +3 -3
  73. package/.pi/harness/docs/adrs/0036-implementation-research-and-selective-debate.md +8 -5
  74. package/.pi/harness/docs/adrs/0039-harness-post-run-review-gate.md +47 -0
  75. package/.pi/harness/docs/adrs/0040-practice-grounded-orchestration.md +40 -0
  76. package/.pi/harness/docs/adrs/0041-intelligent-planning-reconnaissance.md +39 -0
  77. package/.pi/harness/docs/adrs/0042-agent-native-orchestration.md +35 -0
  78. package/.pi/harness/docs/adrs/0043-path-first-harness-tools.md +38 -0
  79. package/.pi/harness/docs/adrs/0044-harness-steer-loop.md +36 -0
  80. package/.pi/harness/docs/adrs/README.md +10 -0
  81. package/.pi/harness/docs/graphify-kb-updater-runbook.md +157 -0
  82. package/.pi/harness/docs/practice-map.md +110 -0
  83. package/.pi/harness/env.harness.template +5 -3
  84. package/.pi/harness/evals/smoke/fixtures/plan-phase/minimal-med-fast/artifacts/implementation-research.yaml +28 -0
  85. package/.pi/harness/evals/smoke/fixtures/plan-phase/minimal-med-fast/artifacts/review-round-consolidated.yaml +25 -0
  86. package/.pi/harness/evals/smoke/fixtures/plan-phase/minimal-med-fast/plan-packet.yaml +196 -0
  87. package/.pi/harness/evals/smoke/fixtures/plan-phase/minimal-med-fast/plan-review.md +14 -0
  88. package/.pi/harness/evals/smoke/fixtures/plan-phase/minimal-med-fast/research-brief.yaml +62 -0
  89. package/.pi/harness/evals/smoke/sentrux-stub.json +1 -1
  90. package/.pi/harness/evals/smoke/smoke-harness-plan.mjs +43 -17
  91. package/.pi/harness/specs/README.md +1 -1
  92. package/.pi/harness/specs/harness-run-context.schema.json +11 -0
  93. package/.pi/harness/specs/harness-spawn-context.schema.json +14 -0
  94. package/.pi/harness/specs/plan-execution-plan.schema.json +39 -1
  95. package/.pi/harness/specs/plan-packet.schema.json +4 -0
  96. package/.pi/harness/specs/plan-phase-status.schema.json +17 -0
  97. package/.pi/harness/specs/plan-phase-waiver.schema.json +25 -0
  98. package/.pi/harness/specs/plan-planning-context.schema.json +50 -0
  99. package/.pi/harness/specs/plan-review-round-draft.schema.json +1 -1
  100. package/.pi/harness/specs/repair-brief.schema.json +45 -0
  101. package/.pi/harness/specs/review-outcome.schema.json +46 -0
  102. package/.pi/harness/specs/sentrux-manifest-proposal.schema.json +80 -0
  103. package/.pi/harness/specs/sentrux-signal.schema.json +43 -0
  104. package/.pi/harness/specs/steer-state.schema.json +20 -0
  105. package/.pi/lib/harness-context-mode-policy.ts +256 -0
  106. package/.pi/lib/harness-repair-brief.ts +145 -0
  107. package/.pi/lib/harness-run-context.ts +591 -32
  108. package/.pi/lib/harness-ui-state.ts +87 -9
  109. package/.pi/model-router.example.json +13 -4
  110. package/.pi/prompts/harness-auto.md +9 -9
  111. package/.pi/prompts/harness-critic.md +3 -30
  112. package/.pi/prompts/harness-eval.md +4 -37
  113. package/.pi/prompts/harness-plan.md +139 -57
  114. package/.pi/prompts/harness-review.md +150 -15
  115. package/.pi/prompts/harness-run.md +62 -10
  116. package/.pi/prompts/harness-sentrux-steward.md +55 -0
  117. package/.pi/prompts/harness-setup.md +4 -4
  118. package/.pi/prompts/harness-steer.md +30 -0
  119. package/.pi/scripts/graphify-kb-updater.mjs +358 -0
  120. package/.pi/scripts/harness-generate-model-router.mjs +118 -36
  121. package/.pi/scripts/harness-model-router-routing.test.mjs +97 -0
  122. package/.pi/scripts/harness-sync-model-router.mjs +15 -2
  123. package/.pi/scripts/harness-verify.mjs +51 -6
  124. package/.pi/scripts/harness-web-policy-guard.mjs +68 -0
  125. package/.pi/scripts/validate-plan-dag.mjs +3 -3
  126. package/AGENTS.md +1 -0
  127. package/CHANGELOG.md +22 -0
  128. package/package.json +5 -4
  129. package/vendor/pi-model-router/UPSTREAM_PIN.md +3 -1
  130. package/vendor/pi-model-router/extensions/commands.ts +4 -4
  131. package/vendor/pi-model-router/extensions/index.ts +21 -0
  132. package/vendor/pi-model-router/extensions/provider.ts +130 -79
  133. package/vendor/pi-model-router/extensions/routing.ts +148 -0
  134. package/vendor/pi-model-router/extensions/state.ts +3 -0
  135. package/vendor/pi-model-router/extensions/types.ts +9 -0
  136. package/vendor/pi-model-router/extensions/ui.ts +16 -2
  137. package/.pi/prompts/git-sync.md +0 -124
@@ -0,0 +1,62 @@
1
+ decomposition:
2
+ schema_version: "1.0.0"
3
+ problem_restatement: Light-profile smoke for two-focus debate
4
+ hypothesis:
5
+ schema_version: "1.0.0"
6
+ primary:
7
+ claim: Light debate covers spec and quality only
8
+ mechanism: Eligibility profile light with min_focus_rounds 2
9
+ prediction: planDebateOutcomeComplete passes with two rounds
10
+ experiment: Run smoke-harness-plan.mjs --fixture minimal-low-light
11
+ implementation:
12
+ schema_version: "1.0.0"
13
+ problem_framing: Low-risk fixture for selective debate
14
+ sub_problems: [spec coverage, quality coverage]
15
+ internal_references:
16
+ - path: test/plan-debate-eligibility.test.mjs
17
+ relevance: Eligibility unit tests
18
+ reuse_signal: high
19
+ external_references: []
20
+ solution_patterns:
21
+ - name: light profile gate
22
+ provenance: ADR-0036
23
+ fit: Reduces debate cost on trivial tasks
24
+ tradeoffs:
25
+ pros: [Fewer rounds]
26
+ cons: []
27
+ risks: []
28
+ similar_implementations:
29
+ - name: minimal-med four-focus fixture
30
+ what_it_solves: Full debate coverage
31
+ gap_vs_us: Light uses two focuses only
32
+ recommended_approach:
33
+ summary: Two review rounds with spec then quality
34
+ recommended_approach_confidence: high
35
+ confidence_rationale: Deterministic fixture aligned with eligibility rules
36
+ evidence_refs:
37
+ - .pi/extensions/lib/plan-debate-eligibility.ts
38
+ - test/plan-debate-eligibility.test.mjs
39
+ anti_patterns: []
40
+ open_questions: []
41
+ stack:
42
+ schema_version: "1.0.0"
43
+ problem_framing: Node harness tooling
44
+ constraints: []
45
+ options:
46
+ - name: extend current stack
47
+ category: brownfield
48
+ fit_summary: Use existing ultimate-pi harness
49
+ tradeoffs:
50
+ pros: [No new deps]
51
+ cons: []
52
+ risks: []
53
+ evidence_refs: []
54
+ recommendation_rank: 1
55
+ recommended_primary: extend current stack
56
+ rationale: Fixture validates in-repo harness
57
+ eval:
58
+ schema_version: "1.0.0"
59
+ revision_recommended: false
60
+ relevance:
61
+ passes: true
62
+ rationale: Hypothesis matches light smoke task
@@ -2,5 +2,5 @@
2
2
  "schema_version": "1.0.0",
3
3
  "signal_type": "stub",
4
4
  "score": 0.5,
5
- "note": "Placeholder until Sentrux MCP is wired. Satisfies HARNESS_SENTRUX_REQUIRED gate in harness:verify."
5
+ "note": "Fallback when HARNESS_RUN_DIR/artifacts/sentrux-signal.yaml is absent. Prefer run signal from /harness-run (ADR 0006)."
6
6
  }
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  /**
3
3
  * smoke-harness-plan — fixture validation for plan-phase pipeline (CI).
4
- * Usage: node .pi/harness/evals/smoke/smoke-harness-plan.mjs --fixture [minimal-med|minimal-low-light]
4
+ * Usage: node .pi/harness/evals/smoke/smoke-harness-plan.mjs --fixture [minimal-med|minimal-low-light|minimal-med-fast]
5
5
  */
6
6
 
7
7
  import { access, readFile } from "node:fs/promises";
@@ -26,16 +26,26 @@ async function scanFocusCoverage(fixtureRoot, requiredFocus) {
26
26
  let last_round_index = 0;
27
27
  const { readdir } = await import("node:fs/promises");
28
28
  const files = (await readdir(art)).filter((f) =>
29
- /^review-round-r\d+\.yaml$/i.test(f),
29
+ /^review-round(?:-r\d+|-consolidated|-parallel-probes)\.yaml$/i.test(f),
30
30
  );
31
31
  for (const name of files.sort()) {
32
- const m = /^review-round-r(\d+)\.yaml$/i.exec(name);
32
+ const consolidated = /^review-round-consolidated\.yaml$/i.test(name);
33
+ const parallelProbes = /^review-round-parallel-probes\.yaml$/i.test(name);
34
+ const m = consolidated
35
+ ? ["review-round-consolidated.yaml", "1"]
36
+ : parallelProbes
37
+ ? ["review-round-parallel-probes.yaml", "1"]
38
+ : /^review-round-r(\d+)\.yaml$/i.exec(name);
33
39
  if (!m) continue;
34
- const roundIndex = Number(m[1]);
40
+ const roundIndex = consolidated ? 1 : Number(m[1]);
35
41
  if (roundIndex > last_round_index) last_round_index = roundIndex;
36
42
  const draft = parseYaml(await readFile(join(art, name), "utf-8"));
37
43
  const focus = String(draft.debate_round_focus ?? "").trim();
38
- if (requiredFocus.includes(focus)) covered.add(focus);
44
+ if (focus === "all") {
45
+ for (const f of requiredFocus) covered.add(f);
46
+ } else if (requiredFocus.includes(focus)) {
47
+ covered.add(focus);
48
+ }
39
49
  if (roundIndex === last_round_index) {
40
50
  last_review_gate_ready = draft.review_gate_ready === true;
41
51
  }
@@ -110,22 +120,33 @@ async function runFixture(name) {
110
120
  ok("research-brief.yaml structure");
111
121
 
112
122
  const isLight = name === "minimal-low-light";
113
- const requiredFocus = isLight ? ["spec", "quality"] : ["spec", "wbs", "schedule", "quality"];
114
- const debateRounds = isLight
115
- ? ["review-round-r1.yaml", "review-round-r2.yaml"]
116
- : [
117
- "review-round-r1.yaml",
118
- "review-round-r2.yaml",
119
- "review-round-r3.yaml",
120
- "review-round-r4.yaml",
121
- ];
123
+ const isFast = name === "minimal-med-fast";
124
+ const requiredFocus =
125
+ isLight || isFast
126
+ ? ["spec", "quality"]
127
+ : ["spec", "wbs", "schedule", "quality"];
128
+ const debateRounds = isFast
129
+ ? ["review-round-consolidated.yaml"]
130
+ : isLight
131
+ ? ["review-round-r1.yaml", "review-round-r2.yaml"]
132
+ : [
133
+ "review-round-r1.yaml",
134
+ "review-round-r2.yaml",
135
+ "review-round-r3.yaml",
136
+ "review-round-r4.yaml",
137
+ ];
122
138
  const seenFocus = new Set();
123
139
  for (const fileName of debateRounds) {
124
140
  const p = join(fixtureRoot, "artifacts", fileName);
125
141
  await access(p, constants.R_OK);
126
142
  const draft = parseYaml(await readFile(p, "utf-8"));
127
143
  if (!draft.schema_version) fail(`${fileName} missing schema_version`);
128
- if (draft.debate_round_focus) seenFocus.add(draft.debate_round_focus);
144
+ const f = String(draft.debate_round_focus ?? "").trim();
145
+ if (f === "all") {
146
+ for (const req of requiredFocus) seenFocus.add(req);
147
+ } else if (f) {
148
+ seenFocus.add(f);
149
+ }
129
150
  }
130
151
  for (const focus of requiredFocus) {
131
152
  if (!seenFocus.has(focus)) {
@@ -135,7 +156,7 @@ async function runFixture(name) {
135
156
  ok(`debate round YAML artifacts (${requiredFocus.length} focuses)`);
136
157
 
137
158
  const coverage = await scanFocusCoverage(fixtureRoot, requiredFocus);
138
- const minRounds = isLight ? 2 : 4;
159
+ const minRounds = isFast ? 1 : isLight ? 2 : 4;
139
160
  if (!planOutcomeComplete(coverage, requiredFocus, minRounds)) {
140
161
  fail("debate outcome incomplete for fixture coverage");
141
162
  }
@@ -144,6 +165,9 @@ async function runFixture(name) {
144
165
  if (isLight && packet.risk_level !== "low") {
145
166
  fail("minimal-low-light fixture must use risk_level low");
146
167
  }
168
+ if (isFast && packet.risk_level !== "med") {
169
+ fail("minimal-med-fast fixture must use risk_level med");
170
+ }
147
171
 
148
172
  console.log(`smoke-harness-plan: all ${name} fixture checks passed`);
149
173
  }
@@ -161,7 +185,9 @@ async function main() {
161
185
  );
162
186
  return;
163
187
  }
164
- fail("Usage: smoke-harness-plan.mjs --fixture [minimal-med|minimal-low-light] | --live");
188
+ fail(
189
+ "Usage: smoke-harness-plan.mjs --fixture [minimal-med|minimal-low-light|minimal-med-fast] | --live",
190
+ );
165
191
  }
166
192
 
167
193
  main().catch((err) => {
@@ -13,7 +13,7 @@ This directory is the canonical contract surface for Phase 1 harness artifacts.
13
13
 
14
14
  These schemas define the minimum machine-readable contracts for:
15
15
 
16
- - planning (`PlanPacket`, `PlanDecompositionBrief`, `PlanHypothesisBrief`, `PlanHypothesisEval`, `PlanAdversaryBrief`)
16
+ - planning (`PlanPacket`, `PlanPlanningContext`, `PlanDecompositionBrief`, `PlanHypothesisBrief`, `PlanHypothesisEval`, `PlanAdversaryBrief`, legacy `PlanScoutFindings`)
17
17
  - execution telemetry (`RunTrace`, `HarnessRunRecord`)
18
18
  - PostHog harness events (`HarnessPostHogEvent`)
19
19
  - observation bus (`HarnessObservation`)
@@ -75,6 +75,17 @@
75
75
  },
76
76
  "turn_override_run_id": {
77
77
  "type": ["string", "null"]
78
+ },
79
+ "steer_approved": {
80
+ "type": "boolean"
81
+ },
82
+ "steer_attempt": {
83
+ "type": "integer",
84
+ "minimum": 0
85
+ },
86
+ "steer_max_attempts": {
87
+ "type": "integer",
88
+ "minimum": 1
78
89
  }
79
90
  }
80
91
  }
@@ -23,6 +23,7 @@
23
23
  "revise",
24
24
  "plan_review",
25
25
  "execute",
26
+ "repair",
26
27
  "benchmark",
27
28
  "verdict",
28
29
  "adversary",
@@ -61,6 +62,19 @@
61
62
  "handoff_summary": {
62
63
  "type": "string",
63
64
  "description": "Prior phase bullet summary for chained spawns (harness-auto)"
65
+ },
66
+ "critical_path_work_item_ids": {
67
+ "type": "array",
68
+ "items": { "type": "string", "minLength": 1 },
69
+ "description": "Limiting-step work item ids from execution_plan.schedule_metadata (execute phase)"
70
+ },
71
+ "repair_brief_path": {
72
+ "type": "string",
73
+ "description": "Path to repair-brief.yaml (steer / repair mode)"
74
+ },
75
+ "executor_strategy": {
76
+ "type": "string",
77
+ "enum": ["single_pass", "per_lake", "per_work_item"]
64
78
  }
65
79
  }
66
80
  }
@@ -36,9 +36,41 @@
36
36
  "items": { "$ref": "#/$defs/risk" }
37
37
  },
38
38
  "schedule_metadata": { "$ref": "#/$defs/schedule_metadata" },
39
- "dag_validation": { "$ref": "#/$defs/dag_validation" }
39
+ "dag_validation": { "$ref": "#/$defs/dag_validation" },
40
+ "lakes": {
41
+ "type": "array",
42
+ "items": { "$ref": "#/$defs/lake" }
43
+ },
44
+ "executor_strategy": {
45
+ "type": "string",
46
+ "enum": ["single_pass", "per_lake", "per_work_item"]
47
+ },
48
+ "critical_path_lake_ids": {
49
+ "type": "array",
50
+ "items": { "type": "string", "minLength": 1 }
51
+ }
40
52
  },
41
53
  "$defs": {
54
+ "lake": {
55
+ "type": "object",
56
+ "additionalProperties": false,
57
+ "required": ["lake_id", "title", "outcome", "done_criteria"],
58
+ "properties": {
59
+ "lake_id": { "type": "string", "minLength": 1 },
60
+ "title": { "type": "string", "minLength": 1 },
61
+ "outcome": { "type": "string", "minLength": 1 },
62
+ "done_criteria": { "type": "string", "minLength": 1 },
63
+ "context_bundle_path": { "type": "string", "minLength": 1 },
64
+ "files": {
65
+ "type": "array",
66
+ "items": { "type": "string", "minLength": 1 }
67
+ },
68
+ "out_of_scope": {
69
+ "type": "array",
70
+ "items": { "type": "string", "minLength": 1 }
71
+ }
72
+ }
73
+ },
42
74
  "phase": {
43
75
  "type": "object",
44
76
  "additionalProperties": false,
@@ -107,6 +139,12 @@
107
139
  "type": "array",
108
140
  "minItems": 1,
109
141
  "items": { "type": "string", "minLength": 1 }
142
+ },
143
+ "lake_id": { "type": "string", "minLength": 1 },
144
+ "context_bundle_path": { "type": "string", "minLength": 1 },
145
+ "context_refs": {
146
+ "type": "array",
147
+ "items": { "type": "string", "minLength": 1 }
110
148
  }
111
149
  }
112
150
  },
@@ -94,6 +94,10 @@
94
94
  },
95
95
  "execution_plan": {
96
96
  "$ref": "plan-execution-plan.schema.json"
97
+ },
98
+ "executor_strategy": {
99
+ "type": "string",
100
+ "enum": ["single_pass", "per_lake", "per_work_item"]
97
101
  }
98
102
  }
99
103
  }
@@ -0,0 +1,17 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/plan-phase-status.schema.json",
4
+ "title": "PlanPhaseStatus",
5
+ "description": "Orchestrator-recorded plan phase outcome before baseline approval.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": ["schema_version", "plan_status"],
9
+ "properties": {
10
+ "schema_version": { "type": "string", "const": "1.0.0" },
11
+ "plan_status": {
12
+ "type": "string",
13
+ "enum": ["ready", "partial", "needs_clarification"]
14
+ },
15
+ "notes": { "type": "string" }
16
+ }
17
+ }
@@ -0,0 +1,25 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/plan-phase-waiver.schema.json",
4
+ "title": "PlanPhaseWaiver",
5
+ "description": "Explicit human waiver for partial scouts or plan-phase blockers before approve_plan.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": ["schema_version", "waived"],
9
+ "properties": {
10
+ "schema_version": { "type": "string", "const": "1.0.0" },
11
+ "waived": {
12
+ "type": "array",
13
+ "minItems": 1,
14
+ "items": {
15
+ "type": "object",
16
+ "additionalProperties": false,
17
+ "required": ["reason", "rationale"],
18
+ "properties": {
19
+ "reason": { "type": "string", "minLength": 1 },
20
+ "rationale": { "type": "string", "minLength": 1 }
21
+ }
22
+ }
23
+ }
24
+ }
25
+ }
@@ -0,0 +1,50 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/plan-planning-context.schema.json",
4
+ "title": "PlanPlanningContext",
5
+ "type": "object",
6
+ "additionalProperties": true,
7
+ "required": ["schema_version", "status", "summary", "coverage"],
8
+ "properties": {
9
+ "schema_version": { "type": "string", "const": "1.0.0" },
10
+ "status": {
11
+ "type": "string",
12
+ "enum": ["ok", "partial", "failed", "error"]
13
+ },
14
+ "task_ref": { "type": "string" },
15
+ "summary": { "type": "string", "minLength": 1 },
16
+ "coverage": {
17
+ "type": "object",
18
+ "required": ["architecture", "structure"],
19
+ "properties": {
20
+ "architecture": { "$ref": "#/$defs/coverageLane" },
21
+ "structure": { "$ref": "#/$defs/coverageLane" },
22
+ "semantic": { "$ref": "#/$defs/coverageLane" }
23
+ },
24
+ "additionalProperties": true
25
+ },
26
+ "findings": { "type": "array" },
27
+ "key_paths": { "type": "array", "items": { "type": "string" } },
28
+ "evidence_refs": { "type": "array" },
29
+ "open_questions": { "type": "array" }
30
+ },
31
+ "$defs": {
32
+ "coverageLane": {
33
+ "type": "object",
34
+ "required": ["status"],
35
+ "properties": {
36
+ "status": {
37
+ "type": "string",
38
+ "enum": ["ok", "partial", "skipped", "failed", "error"]
39
+ },
40
+ "tools_used": {
41
+ "type": "array",
42
+ "items": { "type": "string" }
43
+ },
44
+ "summary": { "type": "string" },
45
+ "key_paths": { "type": "array", "items": { "type": "string" } }
46
+ },
47
+ "additionalProperties": true
48
+ }
49
+ }
50
+ }
@@ -16,7 +16,7 @@
16
16
  "round_index": { "type": "integer", "minimum": 1, "maximum": 12 },
17
17
  "debate_round_focus": {
18
18
  "type": "string",
19
- "enum": ["spec", "wbs", "schedule", "quality"]
19
+ "enum": ["spec", "wbs", "schedule", "quality", "all"]
20
20
  },
21
21
  "round_summary": { "type": "string", "minLength": 1 },
22
22
  "validation_summary": { "type": "string" },
@@ -0,0 +1,45 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/repair-brief.schema.json",
4
+ "title": "RepairBrief",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "schema_version",
9
+ "run_id",
10
+ "steer_attempt",
11
+ "remediation_class",
12
+ "source_artifacts",
13
+ "fix_directives"
14
+ ],
15
+ "properties": {
16
+ "schema_version": { "type": "string", "const": "1.0.0" },
17
+ "run_id": { "type": "string", "minLength": 1 },
18
+ "steer_attempt": { "type": "integer", "minimum": 1 },
19
+ "remediation_class": {
20
+ "type": "string",
21
+ "enum": ["implementation_gap", "plan_gap", "rollback", "inconclusive"]
22
+ },
23
+ "source_artifacts": {
24
+ "type": "object",
25
+ "additionalProperties": { "type": "string" }
26
+ },
27
+ "failed_acceptance_check_ids": {
28
+ "type": "array",
29
+ "items": { "type": "string", "minLength": 1 }
30
+ },
31
+ "priority_lake_ids": {
32
+ "type": "array",
33
+ "items": { "type": "string", "minLength": 1 }
34
+ },
35
+ "fix_directives": {
36
+ "type": "array",
37
+ "minItems": 1,
38
+ "items": { "type": "string", "minLength": 1 }
39
+ },
40
+ "constraints": {
41
+ "type": "array",
42
+ "items": { "type": "string", "minLength": 1 }
43
+ }
44
+ }
45
+ }
@@ -0,0 +1,46 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/review-outcome.schema.json",
4
+ "title": "ReviewOutcome",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "schema_version",
9
+ "run_id",
10
+ "status",
11
+ "remediation_class",
12
+ "recommended_next"
13
+ ],
14
+ "properties": {
15
+ "schema_version": { "type": "string", "const": "1.0.0" },
16
+ "run_id": { "type": "string", "minLength": 1 },
17
+ "status": {
18
+ "type": "string",
19
+ "enum": ["pass", "fail", "inconclusive"]
20
+ },
21
+ "remediation_class": {
22
+ "type": "string",
23
+ "enum": [
24
+ "pass",
25
+ "implementation_gap",
26
+ "plan_gap",
27
+ "rollback",
28
+ "inconclusive"
29
+ ]
30
+ },
31
+ "recommended_next": { "type": "string", "minLength": 1 },
32
+ "failed_acceptance_check_ids": {
33
+ "type": "array",
34
+ "items": { "type": "string", "minLength": 1 }
35
+ },
36
+ "steer_attempt": { "type": "integer", "minimum": 0 },
37
+ "review_tier": {
38
+ "type": "string",
39
+ "enum": ["full", "lite"]
40
+ },
41
+ "source_artifacts": {
42
+ "type": "object",
43
+ "additionalProperties": { "type": "string" }
44
+ }
45
+ }
46
+ }
@@ -0,0 +1,80 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/sentrux-manifest-proposal.schema.json",
4
+ "title": "SentruxManifestProposal",
5
+ "description": "Graphify-grounded proposal to evolve architecture.manifest.json (intent layer). Chair applies after approval.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "schema_version",
10
+ "change_class",
11
+ "summary",
12
+ "evidence",
13
+ "manifest_patch",
14
+ "adr_required",
15
+ "human_required"
16
+ ],
17
+ "properties": {
18
+ "schema_version": {
19
+ "type": "string",
20
+ "const": "1.0.0"
21
+ },
22
+ "change_class": {
23
+ "type": "string",
24
+ "enum": [
25
+ "none",
26
+ "tune_constraint",
27
+ "add_boundary",
28
+ "add_layer",
29
+ "split_layer"
30
+ ]
31
+ },
32
+ "summary": {
33
+ "type": "string",
34
+ "minLength": 1
35
+ },
36
+ "evidence": {
37
+ "type": "array",
38
+ "items": {
39
+ "type": "object",
40
+ "additionalProperties": false,
41
+ "required": ["source", "ref", "summary"],
42
+ "properties": {
43
+ "source": {
44
+ "type": "string",
45
+ "enum": ["graphify", "sg", "sentrux", "plan", "manifest"]
46
+ },
47
+ "ref": {
48
+ "type": "string",
49
+ "minLength": 1
50
+ },
51
+ "summary": {
52
+ "type": "string",
53
+ "minLength": 1
54
+ }
55
+ }
56
+ }
57
+ },
58
+ "manifest_patch": {
59
+ "type": "object",
60
+ "description": "JSON Merge Patch (RFC 7396) ops against architecture.manifest.json",
61
+ "additionalProperties": true
62
+ },
63
+ "adr_required": {
64
+ "type": "boolean"
65
+ },
66
+ "adr_draft": {
67
+ "type": "string"
68
+ },
69
+ "human_required": {
70
+ "type": "boolean"
71
+ },
72
+ "open_questions": {
73
+ "type": "array",
74
+ "items": {
75
+ "type": "string",
76
+ "minLength": 1
77
+ }
78
+ }
79
+ }
80
+ }
@@ -0,0 +1,43 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/sentrux-signal.schema.json",
4
+ "title": "SentruxSignal",
5
+ "description": "Per-run Sentrux CLI observation for evaluator and harness-verify promotion.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "schema_version",
10
+ "run_id",
11
+ "check_pass",
12
+ "gate_status",
13
+ "recorded_at"
14
+ ],
15
+ "properties": {
16
+ "schema_version": {
17
+ "type": "string",
18
+ "const": "1.0.0"
19
+ },
20
+ "run_id": {
21
+ "type": "string",
22
+ "minLength": 1
23
+ },
24
+ "check_pass": {
25
+ "type": "boolean"
26
+ },
27
+ "gate_status": {
28
+ "type": "string",
29
+ "enum": ["pass", "degraded", "skipped", "not_installed"]
30
+ },
31
+ "quality_signal_summary": {
32
+ "type": "string"
33
+ },
34
+ "recorded_at": {
35
+ "type": "string",
36
+ "format": "date-time"
37
+ },
38
+ "phase": {
39
+ "type": "string",
40
+ "enum": ["execute", "evaluate", "review"]
41
+ }
42
+ }
43
+ }
@@ -0,0 +1,20 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://ultimate-pi.local/.pi/harness/specs/steer-state.schema.json",
4
+ "title": "SteerState",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": ["schema_version", "run_id", "attempt", "max_attempts", "active"],
8
+ "properties": {
9
+ "schema_version": { "type": "string", "const": "1.0.0" },
10
+ "run_id": { "type": "string", "minLength": 1 },
11
+ "attempt": { "type": "integer", "minimum": 0 },
12
+ "max_attempts": { "type": "integer", "minimum": 1 },
13
+ "active": { "type": "boolean" },
14
+ "steer_approved": { "type": "boolean" },
15
+ "last_review_tier": {
16
+ "type": "string",
17
+ "enum": ["full", "lite"]
18
+ }
19
+ }
20
+ }