@emiliosp/pi-maestro 0.9.3 → 0.9.4

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  This file summarizes meaningful changes to the codebase, including behavior, data formats, architecture, and development tools. Git tags identify version boundaries; GitHub Releases are not required. Version-only changes and routine maintenance are omitted.
4
4
 
5
+ ## 0.9.3
6
+
7
+ 1. Added a parent `pi-subagents` availability check during activation. A matching successful version 1 `ping` reply is required within 2000 ms. See [PR #35](https://github.com/emilioSp/pi-maestro/pull/35).
8
+ 2. Failed or invalid replies, emission errors, and timeouts prevent activation. The error includes "Maestro flow requires pi-subagents installed in the Pi environment." The check makes no automatic retry.
9
+ 3. Preserved existing activation checks, UI-only notices, and unchanged session history. The availability check starts no agent, makes no model request, and does not run when turning `Maestro` off.
10
+
5
11
  ## 0.9.2
6
12
 
7
13
  1. Added code-quality review to `verifier` guidance for code affected by the approved change when applicable `AGENTS.md` directives exist. See [PR #34](https://github.com/emilioSp/pi-maestro/pull/34). All existing verification duties remain unchanged.
package/ROADMAP.md CHANGED
@@ -74,26 +74,35 @@ All 5 `acceptance criteria` passed through independent inspection of the written
74
74
 
75
75
  [Specification](.specs/20261013-185941-verify-code-quality-against-agents-md-instructions/spec.md), [verifier report](.specs/20261013-185941-verify-code-quality-against-agents-md-instructions/handoffs/verifier/V1.json), and [merged PR #34](https://github.com/emilioSp/pi-maestro/pull/34).
76
76
 
77
+ ### R-06: Check subagent extensions at activation
78
+
79
+ Implemented in `0.9.3`. Activation requires a matching successful version 1 `ping` reply from the parent `pi-subagents` extension within 2000 ms. A failed or invalid reply, emission error, or timeout prevents activation and reports the installation requirement. The check starts no agent and makes no model request. It confirms parent extension availability, not child execution readiness.
80
+
81
+ All 7 `acceptance criteria` passed using controlled replies and code inspection, with no `verifier` `findings`. The saved workflow reached `candidate-ready`.
82
+
83
+ A later integration test requested by the `owner` directly checks the environment check's failed-reply error. This test addition is outside the completed independent verification.
84
+
85
+ #### Evidence
86
+
87
+ [Specification](.specs/20261013-194407-check-pi-subagents-availability-with-ping-at-activation/spec.md), [verifier report](.specs/20261013-194407-check-pi-subagents-availability-with-ping-at-activation/handoffs/verifier/V1.json), and [merged PR #35](https://github.com/emilioSp/pi-maestro/pull/35).
88
+
77
89
  ## Now
78
90
 
79
- ### R-06: Check subagent extensions at activation
91
+ ### R-05: Keep acceptance criterion numbering continuous
80
92
 
81
93
  #### Objective
82
94
 
83
- Make `pi-subagents` availability problems visible before a `builder` or `verifier` `run` starts.
84
-
85
- #### Implementation status
95
+ When criteria are removed during `spec` preparation or revision, renumber the remaining criteria without gaps. Numbering starts at `AC1` and continues through the final criterion.
86
96
 
87
- Activation now requires a successful version 1 `ping` reply from the parent `pi-subagents` extension within 2000 ms. The check does not start an agent. All 7 `acceptance criteria` passed with no `verifier` `findings`; the workflow reached `candidate-ready`.
97
+ #### Current state
88
98
 
89
- A later integration test requested by the `owner` directly checks the environment check's failed-reply error. This test addition is outside the completed independent verification.
99
+ Implemented approval-time numbering validation and `Maestro` guidance for numbering-only recovery using the existing GREEN FLAG. Rejected numbering leaves saved files unchanged. Independent verification is pending.
90
100
 
91
- [Specification](.specs/20261013-194407-check-pi-subagents-availability-with-ping-at-activation/spec.md).
101
+ [Specification](.specs/20261013-202811-check-acceptance-criterion-numbering-before-builder-execution/spec.md).
92
102
 
93
103
  #### Completed when
94
104
 
95
- Unavailable `pi-subagents` prevents activation. The error identifies the problem.
96
-
105
+ The `spec` and its current references use consistent numbering.
97
106
 
98
107
  ## Next
99
108
 
@@ -113,16 +122,6 @@ Compatibility with installations under the old name must be decided in the `spec
113
122
 
114
123
  Package metadata and installation documentation use the new name. The package is available under that name.
115
124
 
116
- ### R-05: Keep acceptance criterion numbering continuous
117
-
118
- #### Objective
119
-
120
- When criteria are removed during `spec` preparation or revision, renumber the remaining criteria without gaps. Numbering starts at `AC1` and continues through the final criterion.
121
-
122
- #### Completed when
123
-
124
- The `spec` and its current references use consistent numbering.
125
-
126
125
  ### R-07: Guide initial configuration
127
126
 
128
127
  #### Objective
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@emiliosp/pi-maestro",
3
- "version": "0.9.3",
3
+ "version": "0.9.4",
4
4
  "description": "A spec-driven multiagent development workflow for Pi.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -54,6 +54,14 @@ Wait for each tool result before taking the next workflow action. Do not launch
54
54
  10. On approval, freeze the spec as the contract. Call maestro_mark_spec_ready with the active specId.
55
55
  11. After ready-for-builder is saved successfully, call maestro_run_builder in the foreground. Do not request a separate start approval.
56
56
 
57
+ If maestro_mark_spec_ready fails with "Fix acceptance criterion ordering in spec.md." after GREEN FLAG, keep the current phase unchanged.
58
+ In drafting-spec, escalation-decision, or findings-decision, correct only numbering and affected references in the current spec.md.
59
+ Do not change criterion order or requirements.
60
+ For example, change headings AC1 and AC3 to AC1 and AC2, and change the affected AC3 references to AC2.
61
+ Retry maestro_mark_spec_ready with the active specId using the existing GREEN FLAG. Do not request another approval.
62
+ After the transition succeeds, call maestro_run_builder in the foreground.
63
+ This edit exception applies only to failed numbering validation. It does not apply after successful approval or during agent runs.
64
+
57
65
  Write spec.md for the owner. Keep detail proportional to the change and state each requirement once.
58
66
  Use the template topics as guidance. Omit empty subsections instead of filling them with Not applicable.
59
67
  Keep behavior, scope, constraints, and approved architectural decisions in the spec. Leave routine implementation choices to the builder.
@@ -74,6 +82,7 @@ In spec.md, keep only a brief reason, essential references, and unresolved limit
74
82
  ### Spec edits, checks, and experiments
75
83
 
76
84
  Edit the active spec.md and its prototypes/ directory only in drafting-spec or during owner-directed contract revisions in decision phases.
85
+ The numbering-only recovery procedure above also permits spec.md corrections after failed numbering validation in those phases.
77
86
  The decision phases are escalation-decision and findings-decision. Do not edit the spec or prototypes in other phases.
78
87
  The approved spec is frozen. Never change it during builder or verifier execution.
79
88
  Use any available tool for these permitted edits. Do not change other workflow artifacts.
@@ -3,6 +3,7 @@
3
3
  * Used: When the owner approves the spec content.
4
4
  */
5
5
 
6
+ import { readFile } from 'node:fs/promises';
6
7
  import type { MaestroPaths } from '#MaestroPaths.ts';
7
8
  import { pathExists } from '#utils/path-exists.ts';
8
9
  import { readWorkflowState } from '#workflow/state/readWorkflowState.ts';
@@ -10,6 +11,14 @@ import { WORKFLOW_EVENTS, type WorkflowState } from '#workflow/state/schema.ts';
10
11
  import { writeWorkflowState } from '#workflow/state/writeWorkflowState.ts';
11
12
  import { transitionWorkflow } from '#workflow/transitions.ts';
12
13
 
14
+ function assertAcceptanceCriterionOrdering(markdown: string): void {
15
+ const criteria = [...markdown.matchAll(/^### AC(\d+):/gm)];
16
+
17
+ if (criteria.some((match, index) => Number(match[1]) !== index + 1)) {
18
+ throw new Error('Fix acceptance criterion ordering in spec.md.');
19
+ }
20
+ }
21
+
13
22
  type MarkSpecReadyInput = {
14
23
  paths: MaestroPaths;
15
24
  specId: string;
@@ -51,6 +60,8 @@ export const markSpecReady = async ({
51
60
  event: WORKFLOW_EVENTS.MARK_SPEC_READY,
52
61
  });
53
62
 
63
+ assertAcceptanceCriterionOrdering(await readFile(specFilePath, 'utf8'));
64
+
54
65
  await writeWorkflowState({
55
66
  path: workflowPath,
56
67
  state,