@sjawhar/pi-legion-envoy 5.3.0 → 5.3.2

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/dist/envoy.js CHANGED
@@ -30130,7 +30130,7 @@ var dispatchToolSpecs = [
30130
30130
  ask: "01234567-0000-4000-8000-000000000001",
30131
30131
  question: "Ship the revised plan?"
30132
30132
  },
30133
- description: "Edit an open question in place. Use it to correct or refine the same decision; retract the " + "old ask and open a new one when the decision itself changes. Previous text remains in the " + "event log. Only the asking session can edit it; answered or resolved asks cannot be edited. " + "An ask that lives as an `ask` block in a document is written in the document too, changing " + "only the fields you name - pass urgency alone and the question's wording, formatting, links " + "and comment anchors are untouched - so the edit writes a document version and closes a " + "spec's design gate until that version is " + 'approved; an option label containing ": " and a question with a line beginning ":::" are ' + "refused, naming the field, because the block cannot carry them unchanged.",
30133
+ description: "Edit an open question in place. Use it to correct or refine the same decision; retract the " + "old ask and open a new one when the decision itself changes. Previous text remains in the " + "event log. Only the asking session can edit it; answered or resolved asks cannot be edited. " + "An ask that lives as an `ask` block in a document is written in the document too, changing " + "only the fields you name - pass urgency alone and the question's wording, formatting, links " + "and comment anchors are untouched - so the edit writes a document version and closes a " + "spec's design gate until that version is " + "approved; text the block cannot carry back unchanged is refused, naming the field - an " + 'option label containing ": ", the separator between a label and its description, is one ' + "example.",
30134
30134
  arguments: (z2) => ({
30135
30135
  ask: z2.string().describe("Ask id (uuid); an 8+ hex prefix unique among this session's own open asks works too."),
30136
30136
  question: z2.string({ max: ASK_QUESTION_MAX }).describe(`Replacement decision question, at most ${ASK_QUESTION_MAX} characters.`).optional(),
package/dist/legion.js CHANGED
@@ -16142,7 +16142,7 @@ import { logger } from "@oh-my-pi/pi-utils";
16142
16142
  // package.json
16143
16143
  var package_default = {
16144
16144
  name: "@sjawhar/pi-legion-envoy",
16145
- version: "5.3.0",
16145
+ version: "5.3.2",
16146
16146
  type: "module",
16147
16147
  omp: {
16148
16148
  extensions: [
@@ -30203,7 +30203,7 @@ var dispatchToolSpecs = [
30203
30203
  ask: "01234567-0000-4000-8000-000000000001",
30204
30204
  question: "Ship the revised plan?"
30205
30205
  },
30206
- description: "Edit an open question in place. Use it to correct or refine the same decision; retract the " + "old ask and open a new one when the decision itself changes. Previous text remains in the " + "event log. Only the asking session can edit it; answered or resolved asks cannot be edited. " + "An ask that lives as an `ask` block in a document is written in the document too, changing " + "only the fields you name - pass urgency alone and the question's wording, formatting, links " + "and comment anchors are untouched - so the edit writes a document version and closes a " + "spec's design gate until that version is " + 'approved; an option label containing ": " and a question with a line beginning ":::" are ' + "refused, naming the field, because the block cannot carry them unchanged.",
30206
+ description: "Edit an open question in place. Use it to correct or refine the same decision; retract the " + "old ask and open a new one when the decision itself changes. Previous text remains in the " + "event log. Only the asking session can edit it; answered or resolved asks cannot be edited. " + "An ask that lives as an `ask` block in a document is written in the document too, changing " + "only the fields you name - pass urgency alone and the question's wording, formatting, links " + "and comment anchors are untouched - so the edit writes a document version and closes a " + "spec's design gate until that version is " + "approved; text the block cannot carry back unchanged is refused, naming the field - an " + 'option label containing ": ", the separator between a label and its description, is one ' + "example.",
30207
30207
  arguments: (z2) => ({
30208
30208
  ask: z2.string().describe("Ask id (uuid); an 8+ hex prefix unique among this session's own open asks works too."),
30209
30209
  question: z2.string({ max: ASK_QUESTION_MAX }).describe(`Replacement decision question, at most ${ASK_QUESTION_MAX} characters.`).optional(),
@@ -31484,7 +31484,7 @@ var LegionGoErrorResponse = exports_external.union([
31484
31484
  var legionGoDeliveryView = exports_external.strictObject({
31485
31485
  id: nonEmptyString2,
31486
31486
  task: nonEmptyString2,
31487
- phase: exports_external.enum(LEGION_GO_PHASES).optional(),
31487
+ phase: exports_external.enum(LEGION_GO_WORKFLOW_PHASES).optional(),
31488
31488
  queuedAt: timestamp,
31489
31489
  deliveredAt: timestamp.optional(),
31490
31490
  confirmedAt: timestamp.optional()
@@ -452,8 +452,8 @@ is rewritten, so anchors inside the text you replaced move as they would for any
452
452
  writes a new version, which on a spec awaiting approval closes the design gate until the new version is approved. Editing the block
453
453
  with `dispatch_doc_edit` works too and is the way to change anything else about it, including adding formatting to a question.
454
454
  Re-sending a field unchanged rewrites nothing, so retrying the whole ask is safe.
455
- Two shapes the block cannot carry are refused outright, naming the field and writing nothing: an option label containing `": "`,
456
- which is what separates a label from its description, and a question with a line beginning `:::`. Blank lines separate paragraphs;
455
+ Text the block cannot carry back unchanged is refused outright, naming the field and writing nothing - an option label containing
456
+ `": "`, the separator between a label and its description, is one example of text that cannot survive the round trip. Blank lines separate paragraphs;
457
457
  a single newline is kept as a line break.
458
458
 
459
459
  An ask stays open until a human answers, unless its question no longer needs that answer. Retract a moot or superseded question, or
@@ -603,6 +603,28 @@ This publishes your phase's completion to the architect's role and clears the da
603
603
  record of this issue's active phase. Do not add pipeline labels, run a controller loop, or
604
604
  invent a different completion protocol — this is the whole contract.
605
605
 
606
+ **A refused completion is information, not a retry loop.** The daemon attributes your report to
607
+ the run whose task you took, and answers with what it found. What each answer carries, and what to
608
+ do:
609
+
610
+ - `HANDOFF_STALE_GENERATION` — names the issue, the run it is on, and the run your completion
611
+ reported. The issue has moved to a newer run since your task was given, so the work you just
612
+ reported belongs to a run that is over. Nothing you can repeat changes that: stop, push nothing
613
+ further, and tell the architect what you completed and that its run has been superseded. A task
614
+ for the current run arrives in this same session if the phase still needs you.
615
+ - `HANDOFF_NOT_CURRENT_PHASE` — names your role, the issue, and the phase it is in now. The issue
616
+ has left your phase; report to the architect rather than completing again.
617
+ - `HANDOFF_NO_RUN` — names neither: it says this claim has taken no task, so the daemon cannot
618
+ tell which run you are reporting. Your pane is completing outside any assignment. Say so to the
619
+ architect; do not re-run the phase.
620
+ - `HANDOFF_ALREADY_RECORDED` — names your role, the phase, the review round and the commit. This
621
+ exact call was received before, and its first answer stands — accepted, or one of the refusals
622
+ above. Sending it again changes nothing; if you did not see that first answer, tell the
623
+ architect so and quote this one.
624
+
625
+ Quote the answer verbatim in what you tell the architect: with the run and phase it names, the
626
+ difference between "my work is lost" and "my work belongs to the previous run" is visible.
627
+
606
628
  **Stay in this session afterward.** Your process does not exit when your phase completes;
607
629
  it goes idle in its pane, and after `worker_idle_retire_seconds` (default 600 s) idle with no
608
630
  active phase the daemon retires it — your next assignment resumes this same session from its
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sjawhar/pi-legion-envoy",
3
- "version": "5.3.0",
3
+ "version": "5.3.2",
4
4
  "type": "module",
5
5
  "omp": {
6
6
  "extensions": [