opencode-swarm 7.176.2 → 7.177.1

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 (101) hide show
  1. package/.opencode/skills/writing-tests/SKILL.md +1 -1
  2. package/binaries/win32-arm64/swarm-sandbox-runner.exe +0 -0
  3. package/binaries/win32-x64/swarm-sandbox-runner.exe +0 -0
  4. package/dist/agents/architect.d.ts +1 -1
  5. package/dist/background/delegation-lifecycle.d.ts +1 -0
  6. package/dist/cli/{coder-settlement-q81p8cdw.js → coder-settlement-c0kysest.js} +12 -12
  7. package/dist/cli/{config-doctor-g8yj2ax5.js → config-doctor-bqwse4pd.js} +3 -3
  8. package/dist/cli/{core-qhsd6kh4.js → core-e6vtme4x.js} +4 -4
  9. package/dist/cli/{curation-policy-62k3tfy2.js → curation-policy-d8s9w1z8.js} +5 -5
  10. package/dist/cli/{curator-33h6tpkm.js → curator-2xb1d80j.js} +37 -37
  11. package/dist/cli/{curator-drift-j1ggdamr.js → curator-drift-4m984tvy.js} +4 -4
  12. package/dist/cli/curator-llm-factory-fywmb8jh.js +72 -0
  13. package/dist/cli/{evidence-summary-service-h58msp28.js → evidence-summary-service-9yxm6jkq.js} +16 -16
  14. package/dist/cli/{gate-evidence-2mzqng35.js → gate-evidence-43bnst3v.js} +7 -7
  15. package/dist/cli/guardrail-explain-gm69b76w.js +73 -0
  16. package/dist/cli/{guardrail-log-8pm5hfaf.js → guardrail-log-j7cj3rjy.js} +8 -8
  17. package/dist/cli/{guardrail-reset-qygfp430.js → guardrail-reset-jcsyfvf4.js} +37 -37
  18. package/dist/cli/{hive-promoter-1921z8af.js → hive-promoter-hc0r0z9h.js} +37 -37
  19. package/dist/cli/{index-30dx8h76.js → index-1042jnb9.js} +2 -2
  20. package/dist/cli/{index-p2r8cejw.js → index-1bq6hkw5.js} +1 -1
  21. package/dist/cli/{index-68nc7zev.js → index-2jtmevrr.js} +68 -47
  22. package/dist/cli/{index-tfvtf8z5.js → index-4ygb35m1.js} +11 -11
  23. package/dist/cli/{index-yss54mb9.js → index-5d2avnj9.js} +2 -2
  24. package/dist/cli/{index-gq1qbzsw.js → index-634pjhe4.js} +7 -7
  25. package/dist/cli/{index-3gmfzg4w.js → index-67amf4my.js} +3 -3
  26. package/dist/cli/{index-nmrcgs2v.js → index-7c24bb1r.js} +2 -2
  27. package/dist/cli/{index-b6xgqf81.js → index-7nsvszwn.js} +2 -2
  28. package/dist/cli/{index-hc00tn5a.js → index-7ntcak58.js} +7 -7
  29. package/dist/cli/{index-ycb3h9gp.js → index-822hhbkc.js} +8 -8
  30. package/dist/cli/{index-pa9gk6qe.js → index-bc4x76z7.js} +37 -37
  31. package/dist/cli/{index-pgtrsc2t.js → index-bqmxxbrw.js} +7 -7
  32. package/dist/cli/{index-yg3aqync.js → index-cv191ybt.js} +8 -8
  33. package/dist/cli/{index-6kn88mce.js → index-drgt81xf.js} +6 -6
  34. package/dist/cli/{index-1d28c88a.js → index-e48h8m73.js} +3 -2
  35. package/dist/cli/{index-fsrfamds.js → index-eefz8ghz.js} +1 -1
  36. package/dist/cli/{index-bh07vpsw.js → index-en0p0hqp.js} +1 -1
  37. package/dist/cli/{index-ytg10jza.js → index-epsy1rh1.js} +39 -39
  38. package/dist/cli/{index-gaa1h7rv.js → index-exhm2ztr.js} +1 -1
  39. package/dist/cli/{index-yj8hn89a.js → index-eya03h5m.js} +7 -7
  40. package/dist/cli/{index-vqhpemaw.js → index-fgv6qp10.js} +4 -4
  41. package/dist/cli/{index-g364gm8a.js → index-fnq5ac3f.js} +4 -4
  42. package/dist/cli/{index-psvgm17t.js → index-fnw6zfh0.js} +1 -1
  43. package/dist/cli/{index-bsw3v6fa.js → index-hp5eet6g.js} +4 -4
  44. package/dist/cli/{index-mezy2tc7.js → index-j82xdrqp.js} +4 -4
  45. package/dist/cli/{index-d3mzw88v.js → index-k330631a.js} +5 -5
  46. package/dist/cli/{index-36gm5wzh.js → index-k6bjkqw8.js} +1 -1
  47. package/dist/cli/{index-pedvpj59.js → index-m0cdjvtv.js} +1 -1
  48. package/dist/cli/{index-5frh43fj.js → index-n7nzwz0q.js} +4 -0
  49. package/dist/cli/{index-7yms2y29.js → index-qgf5xexz.js} +4 -4
  50. package/dist/cli/{index-fwjenx4w.js → index-t2nf57mv.js} +4 -3
  51. package/dist/cli/{index-dp0zm7mj.js → index-t6q73twc.js} +2 -2
  52. package/dist/cli/{index-swhxs3n7.js → index-tbswvz8s.js} +2 -2
  53. package/dist/cli/{index-25aq56s9.js → index-tj0sdxg9.js} +2 -2
  54. package/dist/cli/{index-mw5k6s43.js → index-v2he8xfj.js} +2 -2
  55. package/dist/cli/{index-02sbqp2j.js → index-vfp9hjgv.js} +1 -1
  56. package/dist/cli/{index-agwajtws.js → index-wemtrnch.js} +1 -1
  57. package/dist/cli/{index-nxgbfgmc.js → index-xnednxvm.js} +1 -1
  58. package/dist/cli/{index-kc9jbsxh.js → index-yepxmq4f.js} +893 -786
  59. package/dist/cli/{index-g4m0t1y4.js → index-yhaxn5r7.js} +1 -1
  60. package/dist/cli/{index-z7f3z7t0.js → index-yrs4wwfq.js} +4 -4
  61. package/dist/cli/index.js +38 -38
  62. package/dist/cli/{knowledge-escalator-m88njezt.js → knowledge-escalator-j4jcpver.js} +13 -13
  63. package/dist/cli/{knowledge-events-ncwzpmne.js → knowledge-events-fcpzfp2m.js} +11 -11
  64. package/dist/cli/{knowledge-link-1n4kjc0c.js → knowledge-link-9z3fha35.js} +4 -4
  65. package/dist/cli/{knowledge-store-qsebf29s.js → knowledge-store-6evy197p.js} +5 -5
  66. package/dist/cli/{knowledge-validator-c345kv1x.js → knowledge-validator-s28b1ddg.js} +7 -7
  67. package/dist/cli/{mcp-0wqnyca5.js → mcp-9kqsnehc.js} +1 -1
  68. package/dist/cli/{model-preflight-gk1jysa8.js → model-preflight-1pp1a4yf.js} +1 -1
  69. package/dist/cli/{pending-delegations-fry2r78r.js → pending-delegations-e15f26e0.js} +11 -11
  70. package/dist/cli/{pr-subscriptions-sd3fyt8p.js → pr-subscriptions-mqv51zvm.js} +11 -11
  71. package/dist/cli/{pr-workflow-gate-c84n5x8x.js → pr-workflow-gate-fj31btdv.js} +37 -37
  72. package/dist/cli/{runner-91q995mh.js → runner-yhfmejzb.js} +5 -5
  73. package/dist/cli/{scan-cursor-ptg9wsmv.js → scan-cursor-tpnq7e56.js} +6 -6
  74. package/dist/cli/{schema-dwxscxbv.js → schema-1wwcyaxp.js} +2 -2
  75. package/dist/cli/{scope-persistence-effvw96s.js → scope-persistence-332nvn9b.js} +15 -15
  76. package/dist/cli/{server-91c44cv8.js → server-19bpfaps.js} +37 -37
  77. package/dist/cli/{skill-generator-kv7b5ync.js → skill-generator-gn1k4yxj.js} +15 -15
  78. package/dist/cli/{snapshot-coordination-init-1kxmhy02.js → snapshot-coordination-init-6ztt4v99.js} +37 -37
  79. package/dist/cli/{telemetry-1cfatyt0.js → telemetry-w774xb8g.js} +1 -1
  80. package/dist/cli/{workspace-snapshot-f81xc1vd.js → workspace-snapshot-9gqna7gq.js} +3 -3
  81. package/dist/cli/{worktree-collision-ownership-esshj9p9.js → worktree-collision-ownership-q2ydb0ph.js} +12 -12
  82. package/dist/cli/{worktree-isolation-gvy7b6nq.js → worktree-isolation-fsqe1qdv.js} +37 -37
  83. package/dist/events/core-events.d.ts +1 -1
  84. package/dist/full-auto/state.d.ts +37 -2
  85. package/dist/hooks/delegation-gate.d.ts +26 -0
  86. package/dist/index.js +261 -262
  87. package/dist/observability/catalog.d.ts +2 -2
  88. package/dist/prm/escalation.d.ts +42 -1
  89. package/dist/prm/index.d.ts +4 -0
  90. package/dist/prm/types.d.ts +36 -0
  91. package/dist/state.d.ts +8 -1
  92. package/dist/telemetry.d.ts +17 -0
  93. package/dist/tools/approve-retry-sounding-board.d.ts +5 -0
  94. package/dist/tools/index.d.ts +1 -0
  95. package/dist/tools/manifest.d.ts +1 -0
  96. package/dist/tools/repo-map.d.ts +1 -0
  97. package/dist/tools/tool-metadata.d.ts +4 -0
  98. package/dist/types/events.d.ts +20 -2
  99. package/package.json +2 -1
  100. package/dist/cli/curator-llm-factory-bvck3388.js +0 -72
  101. package/dist/cli/guardrail-explain-vs575z3y.js +0 -73
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * The event catalog (issue #2029).
3
3
  *
4
- * Exactly 63 entries, matching the `TelemetryEvent` union at
4
+ * Exactly 64 entries, matching the `TelemetryEvent` union at
5
5
  * `src/telemetry.ts:20-172`. Thirty-eight predate the #2029 contract; the 39th is
6
6
  * `agent_conflict_detected` (previously emitted through a force-cast past the
7
7
  * type system), the 40th is `close_archive_result` (issue #2030 — the
@@ -89,7 +89,7 @@ export interface CatalogEntry {
89
89
  /**
90
90
  * Whether an event of this kind must carry `trace.parentSpanId`.
91
91
  *
92
- * `false` for all 63 entries today, and that is a truthful statement about
92
+ * `false` for all 64 entries today, and that is a truthful statement about
93
93
  * the current system rather than a placeholder: no producer supplies a
94
94
  * parent span, so `createObservation` never sets one. Setting this to `true`
95
95
  * for a kind whose producer cannot supply a parent would make every
@@ -2,7 +2,19 @@
2
2
  * Escalation Tracker Module
3
3
  * Implements a 3-strike protocol for pattern detection escalation
4
4
  */
5
- import type { CourseCorrection, EscalationState, PatternMatch } from './types';
5
+ import type { CourseCorrection, EscalationState, PatternMatch, PrmEpisodeState } from './types';
6
+ export { PRM_HARD_STOP_TERMINAL_EVENT } from './types';
7
+ /**
8
+ * Issue #2678 — hard-stop detections after the first one (within one episode)
9
+ * before the episode escalates to its bounded TERMINAL/handoff state.
10
+ */
11
+ export declare const PRM_HARD_STOP_TERMINAL_REPEATS = 1;
12
+ /**
13
+ * Issue #2678 — after a terminal handoff, re-escalation of the SAME ladder is
14
+ * suppressed for this window unless an owner-verified `clearAction` clears the
15
+ * episode first. 15 minutes mirrors the pattern-persistence cooldown budget.
16
+ */
17
+ export declare const PRM_TERMINAL_COOLDOWN_MS: number;
6
18
  /**
7
19
  * Resolves the LADDER key for a match — the identity whose 1→2→3 strike count
8
20
  * this detection belongs to (issue #2134 follow-up).
@@ -65,6 +77,9 @@ export declare class EscalationTracker {
65
77
  level: number;
66
78
  correction: CourseCorrection | null;
67
79
  hardStop: boolean;
80
+ /** Issue #2678 — this detection is the (or is inside the) bounded
81
+ * TERMINAL/handoff state of the ladder's episode. */
82
+ terminal: boolean;
68
83
  };
69
84
  /**
70
85
  * Returns a defensive copy of the current escalation state.
@@ -82,6 +97,32 @@ export declare class EscalationTracker {
82
97
  * per-tool-call hot path, for one field.
83
98
  */
84
99
  getLadderCounts(): Map<string, number>;
100
+ /**
101
+ * Defensive copy of the per-ladder episode state (issue #2678) — the
102
+ * `getLadderCounts` precedent: producers mirror this onto the session so a
103
+ * tracker rebuilt mid-session restores the same episode keyspace.
104
+ */
105
+ getEpisodes(): Map<string, PrmEpisodeState>;
106
+ /** Current generation (issue #2678) — advances on every episode-state
107
+ * transition; owner-checked resets must match it exactly. */
108
+ getGeneration(): number;
109
+ /**
110
+ * Action-local corrected-success clear (issue #2678): clears ONLY the
111
+ * matching ladder (its strike count and its episode record — the next
112
+ * detection starts at level 1) and leaves every unrelated ladder touched.
113
+ *
114
+ * Owner semantics: an ownerless call (in-session corrected success —
115
+ * possession of the tracker IS the session binding) proceeds. When an
116
+ * `owner` is provided it must match this tracker's exact `sessionId` AND
117
+ * the current `generation`, else the clear fails closed (returns false,
118
+ * state untouched) — a stale-generation or foreign-session reset can never
119
+ * clear current recovery state. Generation advances only on an
120
+ * owner-provided, matching clear.
121
+ */
122
+ clearAction(matchOrKey: PatternMatch | string, owner?: {
123
+ sessionId: string;
124
+ generation: number;
125
+ }): boolean;
85
126
  /**
86
127
  * Resets all escalation counts and flags to their default values.
87
128
  * Clears pattern counts and all flags.
@@ -82,6 +82,10 @@ interface ResettablePrmSessionState {
82
82
  prmStruckEpisodes?: Map<string, number>;
83
83
  /** Issue #2134 follow-up — ladder counts; reset with the ledger. */
84
84
  prmLadderCounts?: Map<string, number>;
85
+ /** Issue #2678 — hard-stop episodes; reset with the ladder counts. */
86
+ prmEpisodes?: Map<string, import('./types.js').PrmEpisodeState>;
87
+ /** Issue #2678 — tracker generation; reset with the episodes. */
88
+ prmEpisodeGeneration?: number;
85
89
  replayArtifactPath?: string | null;
86
90
  }
87
91
  export declare function resetPrmSessionState(session: ResettablePrmSessionState, sessionId?: string): void;
@@ -2,6 +2,12 @@
2
2
  * PRM (Prompt Response Monitoring) Type Definitions
3
3
  * Core types for trajectory logging, pattern detection, and course correction
4
4
  */
5
+ /**
6
+ * Issue #2678 — telemetry event name for the TERMINAL/handoff transition of a
7
+ * PRM hard-stop episode. Lives here (not in `escalation.ts`) so the telemetry
8
+ * emitter can import it without a cycle; `escalation.ts` re-exports it.
9
+ */
10
+ export declare const PRM_HARD_STOP_TERMINAL_EVENT = "prm_hard_stop_terminal";
5
11
  /**
6
12
  * All detectable pattern types in the SWE-PRM system
7
13
  */
@@ -112,6 +118,28 @@ export interface PrmConfig {
112
118
  /** Max time for detection in milliseconds */
113
119
  detection_timeout_ms: number;
114
120
  }
121
+ /**
122
+ * Per-ladder hard-stop episode state (issue #2678).
123
+ *
124
+ * Keyed by the ladder identity (`resolveLadderKey`), so the episode is scoped
125
+ * to the exact session (the tracker is per-session) + ladder (pattern|target,
126
+ * or bare pattern for a growing target set — the pattern type is the failure
127
+ * category). This is the bounded-episode record that turns an unbounded
128
+ * repeated-stop loop into: first stop → (one repeat) → TERMINAL handoff with
129
+ * a cooldown, after which a fresh episode may re-escalate.
130
+ */
131
+ export interface PrmEpisodeState {
132
+ /** False-to-true latch for the `prm_hard_stop` TRIGGER telemetry — the
133
+ * trigger fires exactly once per episode, on the transition. */
134
+ hardStopTriggered: boolean;
135
+ /** Hard-stop detections after the first one, within this episode. */
136
+ repeats: number;
137
+ /** This episode has terminally handed off — no further stop re-arming
138
+ * for this ladder until the cooldown lapses or an owner-verified clear. */
139
+ terminal: boolean;
140
+ /** Epoch-ms deadline until which re-escalation is suppressed. */
141
+ cooldownUntil: number;
142
+ }
115
143
  /**
116
144
  * Per-session escalation tracking state
117
145
  */
@@ -134,4 +162,12 @@ export interface EscalationState {
134
162
  lastPatternDetected: PatternMatch | null;
135
163
  /** Whether a hard stop has been triggered */
136
164
  hardStopPending: boolean;
165
+ /** Issue #2678 — per-ladder bounded hard-stop episodes (terminal state,
166
+ * cooldown, and the trigger latch live here, evicted together with the
167
+ * ladder's count under `MAX_TRACKED_LADDERS`). */
168
+ episodes: Map<string, PrmEpisodeState>;
169
+ /** Issue #2678 — advances on every episode-state transition (hard-stop
170
+ * trigger, terminal transition, owner-verified clear). Resets carrying an
171
+ * older generation fail closed in `clearAction`. */
172
+ generation: number;
137
173
  }
package/dist/state.d.ts CHANGED
@@ -12,7 +12,7 @@ import { type QaGates } from './db/qa-gate-profile.js';
12
12
  import { type EnvironmentProfile } from './environment/profile.js';
13
13
  import { type TaskWorkflowMetadata } from './gate-evidence';
14
14
  import type { EscalationTracker } from './prm/escalation.js';
15
- import type { PatternMatch } from './prm/types.js';
15
+ import type { PatternMatch, PrmEpisodeState } from './prm/types.js';
16
16
  import type { ReviewRouteEvidence } from './review/routing-enforcement.js';
17
17
  import { AgentRunContext } from './state/agent-run-context.js';
18
18
  export { AgentRunContext } from './state/agent-run-context.js';
@@ -510,6 +510,13 @@ export interface AgentSessionState {
510
510
  * mis-restore every count.
511
511
  */
512
512
  prmLadderCounts?: Map<string, number>;
513
+ /** Issue #2678 — per-ladder hard-stop episode state mirrored from the
514
+ * escalation tracker (terminal flag, cooldown, trigger latch); reset with
515
+ * the ladder counts it is keyed alongside. Not serialized. */
516
+ prmEpisodes?: Map<string, PrmEpisodeState>;
517
+ /** Issue #2678 — tracker generation mirrored per strike; owner-checked
518
+ * PRM resets must match it exactly or fail closed. */
519
+ prmEpisodeGeneration?: number;
513
520
  /**
514
521
  * Issue #2134 — dispatch identity of the delegation whose start already reset
515
522
  * this session's PRM state. Holds the Task tool `callID`, which is unique per
@@ -28,6 +28,14 @@ export type TelemetryEvent = 'session_started' | 'session_ended' | 'agent_activa
28
28
  * package root so no user home path is written to the ledger.
29
29
  */
30
30
  | 'swarm_internals_read_denied' | 'prm_pattern_detected' | 'prm_course_correction_injected' | 'prm_escalation_triggered' | 'prm_hard_stop'
31
+ /**
32
+ * Issue #2678 — a PRM hard-stop EPISODE reached its bounded TERMINAL/handoff
33
+ * state, fired exactly once per terminal transition by
34
+ * `src/prm/escalation.ts`. The third of the three noninterchangeable PRM
35
+ * stop counters: TRIGGER (`prm_hard_stop`), DELIVERY
36
+ * (`prm_hard_stop_delivered`), TERMINAL (this member).
37
+ */
38
+ | 'prm_hard_stop_terminal'
31
39
  /**
32
40
  * Issue #2063 C2 — DELIVERY of a PRM hard stop, as distinct from the
33
41
  * `prm_hard_stop` TRIGGER emitted by `src/prm/escalation.ts`. A trigger with
@@ -253,6 +261,15 @@ export declare const telemetry: {
253
261
  prmCourseCorrectionInjected(sessionId: string, pattern: string, level: number): void;
254
262
  prmEscalationTriggered(sessionId: string, pattern: string, level: number, occurrenceCount: number): void;
255
263
  prmHardStop(sessionId: string, pattern: string, level: number, occurrenceCount: number): void;
264
+ /**
265
+ * Issue #2678 — a PRM hard-stop EPISODE reached its bounded TERMINAL/handoff
266
+ * state. Fired exactly once per terminal transition by the escalation
267
+ * tracker. Distinct from `prm_hard_stop` (the TRIGGER, once per
268
+ * false-to-true transition) and `prm_hard_stop_delivered` (the DELIVERY,
269
+ * emitted by the guardrails deny consumer): the three counters are
270
+ * noninterchangeable.
271
+ */
272
+ prmHardStopTerminal(sessionId: string, pattern: string, level: number, occurrenceCount: number): void;
256
273
  /**
257
274
  * Close/archive structured result (issue #2030). This single event is the
258
275
  * shared source of truth for both the user-facing close summary prose and
@@ -0,0 +1,5 @@
1
+ import { createSwarmTool } from './create-tool.js';
2
+ export declare function executeApproveRetrySoundingBoard(args: unknown, directory: string, context?: {
3
+ sessionID?: string;
4
+ }): Promise<string>;
5
+ export declare const approve_retry_sounding_board: ReturnType<typeof createSwarmTool>;
@@ -98,6 +98,7 @@ export type { FlakyTestEntry } from '../test-impact/flaky-detector.js';
98
98
  export { computeFlakyScore, detectFlakyTests, isTestQuarantined, } from '../test-impact/flaky-detector.js';
99
99
  export { abort_pr_workflow, executeAbortPrWorkflow, } from './abort-pr-workflow';
100
100
  export { approve_plan_critic, executeApprovePlanCritic, } from './approve-plan-critic';
101
+ export { approve_retry_sounding_board, executeApproveRetrySoundingBoard, } from './approve-retry-sounding-board';
101
102
  export { authorize_pr_review_reentry } from './authorize-pr-review-reentry';
102
103
  export { complete_pr_workflow, executeCompletePrWorkflow, } from './complete-pr-workflow';
103
104
  export { epic_plan_waves } from './epic-plan-waves';
@@ -47,6 +47,7 @@ export declare const TOOL_MANIFEST: {
47
47
  authorize_pr_review_reentry: () => ToolDefinition;
48
48
  submit_pr_review_result: () => ToolDefinition;
49
49
  approve_plan_critic: () => ToolDefinition;
50
+ approve_retry_sounding_board: () => ToolDefinition;
50
51
  prepare_pr_workflow_checkout: () => ToolDefinition;
51
52
  record_implementation_review: () => ToolDefinition;
52
53
  record_issue_publication: () => ToolDefinition;
@@ -60,6 +60,7 @@ export declare const _internals: {
60
60
  prmCourseCorrectionInjected(sessionId: string, pattern: string, level: number): void;
61
61
  prmEscalationTriggered(sessionId: string, pattern: string, level: number, occurrenceCount: number): void;
62
62
  prmHardStop(sessionId: string, pattern: string, level: number, occurrenceCount: number): void;
63
+ prmHardStopTerminal(sessionId: string, pattern: string, level: number, occurrenceCount: number): void;
63
64
  closeArchiveResult(data: {
64
65
  archive_valid: boolean;
65
66
  archive_empty: boolean;
@@ -173,6 +173,10 @@ export declare const TOOL_METADATA: {
173
173
  description: string;
174
174
  agents: "architect"[];
175
175
  };
176
+ approve_retry_sounding_board: {
177
+ description: string;
178
+ agents: "architect"[];
179
+ };
176
180
  prepare_pr_workflow_checkout: {
177
181
  description: string;
178
182
  agents: "architect"[];
@@ -52,7 +52,11 @@ export interface CoderRetryCircuitBreakerEvent {
52
52
  rejectionCount: number;
53
53
  rejectionHistory: string[];
54
54
  phase: number;
55
- action: 'sounding_board_consultation' | 'simplification' | 'user_escalation';
55
+ action: 'sounding_board_consultation' | 'simplification' | 'user_escalation' | 'sounding_board_manual_approval';
56
+ /** Present only on sounding_board_manual_approval (issue #2703): the
57
+ * architect-stated justification for the manual override, bounded to 500
58
+ * chars by the recorder. */
59
+ reason?: string;
56
60
  }
57
61
  export interface AgentConflictDetectedEvent {
58
62
  type: 'agent_conflict_detected';
@@ -183,4 +187,18 @@ export interface PrmHardStopDeliveredEvent {
183
187
  level: number;
184
188
  occurrenceCount: number;
185
189
  }
186
- export type V619Event = SoundingBoardConsultedEvent | ArchitectLoopDetectedEvent | PrecedentManipulationDetectedEvent | CoderSelfAuditEvent | CoderRetryCircuitBreakerEvent | AgentConflictDetectedEvent | AuthorityHandoffResolvedEvent | SpecStaleDetectedEvent | SpecDriftAcknowledgedEvent | SpecDriftRepairedEvent | TaskWorkflowRepairedEvent | TaskRemovedEvent | PrmPatternDetectedEvent | PrmCourseCorrectionInjectedEvent | PrmEscalationTriggeredEvent | PrmHardStopEvent | PrmHardStopDeliveredEvent;
190
+ /**
191
+ * Issue #2678 — a PRM hard-stop EPISODE reached its bounded TERMINAL/handoff
192
+ * state (fired exactly once per terminal transition). The third of the three
193
+ * noninterchangeable counters: TRIGGER (`prm_hard_stop`), DELIVERY
194
+ * (`prm_hard_stop_delivered`), TERMINAL (this event).
195
+ */
196
+ export interface PrmHardStopTerminalEvent {
197
+ type: 'prm_hard_stop_terminal';
198
+ timestamp: string;
199
+ sessionId: string;
200
+ pattern: string;
201
+ level: number;
202
+ occurrenceCount: number;
203
+ }
204
+ export type V619Event = SoundingBoardConsultedEvent | ArchitectLoopDetectedEvent | PrecedentManipulationDetectedEvent | CoderSelfAuditEvent | CoderRetryCircuitBreakerEvent | AgentConflictDetectedEvent | AuthorityHandoffResolvedEvent | SpecStaleDetectedEvent | SpecDriftAcknowledgedEvent | SpecDriftRepairedEvent | TaskWorkflowRepairedEvent | TaskRemovedEvent | PrmPatternDetectedEvent | PrmCourseCorrectionInjectedEvent | PrmEscalationTriggeredEvent | PrmHardStopEvent | PrmHardStopTerminalEvent | PrmHardStopDeliveredEvent;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-swarm",
3
- "version": "7.176.2",
3
+ "version": "7.177.1",
4
4
  "description": "Architect-centric agentic swarm plugin for OpenCode - hub-and-spoke orchestration with SME consultation, code generation, and QA review",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -98,6 +98,7 @@
98
98
  "lint": "biome lint .",
99
99
  "lint:ci": "biome ci .",
100
100
  "test:unit:ci": "bun scripts/ci/run-unit-tests-local.ts",
101
+ "validate:repo": "bun scripts/ci/repository-validation.ts",
101
102
  "drift:check": "bun run scripts/drift-check.ts",
102
103
  "check:pre-push": "bun run scripts/drift-check.ts --enforce --no-report && bun run check:registry-citations",
103
104
  "schema:generate": "bun run scripts/generate-config-schema.ts",
@@ -1,72 +0,0 @@
1
- // @bun
2
- import {
3
- createCuratorLLMDelegate
4
- } from "./index-kc9jbsxh.js";
5
- import"./index-hnvmj9wx.js";
6
- import"./index-02sbqp2j.js";
7
- import"./index-vqhpemaw.js";
8
- import"./index-fsrfamds.js";
9
- import"./index-30dx8h76.js";
10
- import"./index-tfvtf8z5.js";
11
- import"./index-36gm5wzh.js";
12
- import"./index-txdagbh7.js";
13
- import"./index-n1tcj1q7.js";
14
- import"./index-fpbcxykc.js";
15
- import"./index-7yms2y29.js";
16
- import"./index-d3mzw88v.js";
17
- import"./index-nmrcgs2v.js";
18
- import"./index-fyfbpz4f.js";
19
- import"./index-yj8hn89a.js";
20
- import"./index-549wxbe1.js";
21
- import"./index-zsrtt42s.js";
22
- import"./index-ycb3h9gp.js";
23
- import"./index-yss54mb9.js";
24
- import"./index-b6xgqf81.js";
25
- import"./index-pt7h91zc.js";
26
- import"./index-q7sjgr1y.js";
27
- import"./index-g364gm8a.js";
28
- import"./index-mezy2tc7.js";
29
- import"./index-pgtrsc2t.js";
30
- import"./index-yg3aqync.js";
31
- import"./index-gaa1h7rv.js";
32
- import"./index-2s7dvzff.js";
33
- import"./index-z7f3z7t0.js";
34
- import"./index-agwajtws.js";
35
- import"./index-rtry5xyf.js";
36
- import"./index-3gmfzg4w.js";
37
- import"./index-frcemc0b.js";
38
- import"./index-wrt875kh.js";
39
- import"./index-hc00tn5a.js";
40
- import"./index-6kn88mce.js";
41
- import"./index-fwjenx4w.js";
42
- import"./index-mw5k6s43.js";
43
- import"./index-p2r8cejw.js";
44
- import"./index-nxgbfgmc.js";
45
- import"./index-rdm3px0g.js";
46
- import"./index-ry16d01s.js";
47
- import"./index-swhxs3n7.js";
48
- import"./index-gq1qbzsw.js";
49
- import"./index-vzm6zre7.js";
50
- import"./index-ae75rja9.js";
51
- import"./index-bh07vpsw.js";
52
- import"./index-25aq56s9.js";
53
- import"./index-7g4c7s5r.js";
54
- import"./index-68nc7zev.js";
55
- import"./index-g4m0t1y4.js";
56
- import"./index-1xnse449.js";
57
- import"./index-c1ggtmpm.js";
58
- import"./index-pedvpj59.js";
59
- import"./index-zz7gzw57.js";
60
- import"./index-4ddpvd5c.js";
61
- import"./index-1d28c88a.js";
62
- import"./index-5frh43fj.js";
63
- import"./index-bk5tah7q.js";
64
- import"./index-gknz3bv1.js";
65
- import"./index-zpsr8rpc.js";
66
- import"./index-76qm2c2y.js";
67
- import"./index-yzjaj53h.js";
68
- import"./index-zgwm4ryv.js";
69
- import"./index-a76rekgs.js";
70
- export {
71
- createCuratorLLMDelegate
72
- };
@@ -1,73 +0,0 @@
1
- // @bun
2
- import {
3
- handleGuardrailExplain
4
- } from "./index-dp0zm7mj.js";
5
- import"./index-kc9jbsxh.js";
6
- import"./index-hnvmj9wx.js";
7
- import"./index-02sbqp2j.js";
8
- import"./index-vqhpemaw.js";
9
- import"./index-fsrfamds.js";
10
- import"./index-30dx8h76.js";
11
- import"./index-tfvtf8z5.js";
12
- import"./index-36gm5wzh.js";
13
- import"./index-txdagbh7.js";
14
- import"./index-n1tcj1q7.js";
15
- import"./index-fpbcxykc.js";
16
- import"./index-7yms2y29.js";
17
- import"./index-d3mzw88v.js";
18
- import"./index-nmrcgs2v.js";
19
- import"./index-fyfbpz4f.js";
20
- import"./index-yj8hn89a.js";
21
- import"./index-549wxbe1.js";
22
- import"./index-zsrtt42s.js";
23
- import"./index-ycb3h9gp.js";
24
- import"./index-yss54mb9.js";
25
- import"./index-b6xgqf81.js";
26
- import"./index-pt7h91zc.js";
27
- import"./index-q7sjgr1y.js";
28
- import"./index-g364gm8a.js";
29
- import"./index-mezy2tc7.js";
30
- import"./index-pgtrsc2t.js";
31
- import"./index-yg3aqync.js";
32
- import"./index-gaa1h7rv.js";
33
- import"./index-2s7dvzff.js";
34
- import"./index-z7f3z7t0.js";
35
- import"./index-agwajtws.js";
36
- import"./index-rtry5xyf.js";
37
- import"./index-3gmfzg4w.js";
38
- import"./index-frcemc0b.js";
39
- import"./index-wrt875kh.js";
40
- import"./index-hc00tn5a.js";
41
- import"./index-6kn88mce.js";
42
- import"./index-fwjenx4w.js";
43
- import"./index-mw5k6s43.js";
44
- import"./index-p2r8cejw.js";
45
- import"./index-nxgbfgmc.js";
46
- import"./index-rdm3px0g.js";
47
- import"./index-ry16d01s.js";
48
- import"./index-swhxs3n7.js";
49
- import"./index-gq1qbzsw.js";
50
- import"./index-vzm6zre7.js";
51
- import"./index-ae75rja9.js";
52
- import"./index-bh07vpsw.js";
53
- import"./index-25aq56s9.js";
54
- import"./index-7g4c7s5r.js";
55
- import"./index-68nc7zev.js";
56
- import"./index-g4m0t1y4.js";
57
- import"./index-1xnse449.js";
58
- import"./index-c1ggtmpm.js";
59
- import"./index-pedvpj59.js";
60
- import"./index-zz7gzw57.js";
61
- import"./index-4ddpvd5c.js";
62
- import"./index-1d28c88a.js";
63
- import"./index-5frh43fj.js";
64
- import"./index-bk5tah7q.js";
65
- import"./index-gknz3bv1.js";
66
- import"./index-zpsr8rpc.js";
67
- import"./index-76qm2c2y.js";
68
- import"./index-yzjaj53h.js";
69
- import"./index-zgwm4ryv.js";
70
- import"./index-a76rekgs.js";
71
- export {
72
- handleGuardrailExplain
73
- };