@wrongstack/core 0.281.1 → 0.282.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.
- package/dist/{agent-subagent-runner-DyOSK2Wy.d.ts → agent-subagent-runner-Dksf0QVU.d.ts} +15 -4
- package/dist/{config-CN-vdDEI.d.ts → config-BCAEJicb.d.ts} +33 -1
- package/dist/coordination/index.d.ts +147 -48
- package/dist/coordination/index.js +1244 -274
- package/dist/coordination/index.js.map +1 -1
- package/dist/defaults/index.d.ts +18 -18
- package/dist/defaults/index.js +991 -173
- package/dist/defaults/index.js.map +1 -1
- package/dist/{director-state-BfeCUbmk.d.ts → director-state-B_GPa78Q.d.ts} +14 -0
- package/dist/{events-C5hLU0AT.d.ts → events-CovDylaH.d.ts} +2 -1
- package/dist/execution/index.d.ts +10 -10
- package/dist/execution/index.js +69 -3
- package/dist/execution/index.js.map +1 -1
- package/dist/extension/index.d.ts +4 -4
- package/dist/{global-mailbox-CHM1QkCi.d.ts → global-mailbox-CNfgvRw3.d.ts} +1 -1
- package/dist/{goal-store-BLGZq16t.d.ts → goal-store-CBd749M4.d.ts} +1 -1
- package/dist/hq/index.d.ts +4 -4
- package/dist/{index-C1E-_71T.d.ts → index-D5HB7WkV.d.ts} +4 -3
- package/dist/index.d.ts +3005 -2704
- package/dist/index.js +51869 -49930
- package/dist/index.js.map +1 -1
- package/dist/infrastructure/index.d.ts +3 -3
- package/dist/kernel/index.d.ts +7 -7
- package/dist/kernel/index.js.map +1 -1
- package/dist/{mcp-servers-EKRAcJDi.d.ts → mcp-servers-DJYwZXyH.d.ts} +1 -1
- package/dist/models/index.d.ts +2 -2
- package/dist/models/index.js +111 -21
- package/dist/models/index.js.map +1 -1
- package/dist/{multi-agent-coordinator-IpHCuHUa.d.ts → multi-agent-coordinator-4DC31QWu.d.ts} +1 -1
- package/dist/{null-fleet-bus-ZBkKGR9j.d.ts → null-fleet-bus-DuvA8PIR.d.ts} +74 -6
- package/dist/observability/index.d.ts +1 -1
- package/dist/{parallel-eternal-engine-Cc2CNgmv.d.ts → parallel-eternal-engine-BwcA0bAt.d.ts} +4 -4
- package/dist/{pipeline-E7_jqGyV.d.ts → pipeline-DM-CPTUs.d.ts} +1 -1
- package/dist/{provider-model-resolve-KgIdiEQ6.d.ts → provider-model-resolve-hNUbewMd.d.ts} +1 -1
- package/dist/{provider-runner-DxWXNHL1.d.ts → provider-runner-Bz4GyUqo.d.ts} +1 -1
- package/dist/sdd/index.d.ts +6 -6
- package/dist/sdd/index.js +76 -2
- package/dist/sdd/index.js.map +1 -1
- package/dist/{session-event-bridge-vA2fLV58.d.ts → session-event-bridge-Bkp7ORfc.d.ts} +2 -2
- package/dist/skills/index.d.ts +84 -84
- package/dist/storage/index.d.ts +168 -168
- package/dist/storage/index.js +19 -7
- package/dist/storage/index.js.map +1 -1
- package/dist/{todos-checkpoint-B1QVkoa8.d.ts → todos-checkpoint-addCdQ9f.d.ts} +2 -2
- package/dist/{tool-executor-BWtYwuPI.d.ts → tool-executor-B3spV_Q6.d.ts} +7 -7
- package/dist/tools/index.d.ts +1 -1
- package/dist/types/index.d.ts +33 -33
- package/dist/types/index.js.map +1 -1
- package/dist/utils/index.d.ts +113 -113
- package/dist/{worktree-manager-C6CIilTT.d.ts → worktree-manager-BBXdJq-Y.d.ts} +1 -1
- package/instructions/agents/reviewer.md +25 -0
- package/instructions/agents/verifier.md +24 -0
- package/instructions/coordination/director-preamble.md +24 -2
- package/instructions/coordination/subagent-baseline.md +8 -1
- package/package.json +1 -1
package/dist/{multi-agent-coordinator-IpHCuHUa.d.ts → multi-agent-coordinator-4DC31QWu.d.ts}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { S as SubagentConfig, M as MultiAgentCoordinator, b as MultiAgentConfig, c as SubagentRunner, B as BudgetSessionIdSource, F as FleetBus, d as SpawnResult, T as TaskSpec, e as BridgeMessage, f as AgentBridge, C as CoordinatorStatus, g as TaskResult, h as AwaitAnyResult } from './agent-subagent-runner-
|
|
1
|
+
import { S as SubagentConfig, M as MultiAgentCoordinator, b as MultiAgentConfig, c as SubagentRunner, B as BudgetSessionIdSource, F as FleetBus, d as SpawnResult, T as TaskSpec, e as BridgeMessage, f as AgentBridge, C as CoordinatorStatus, g as TaskResult, h as AwaitAnyResult } from './agent-subagent-runner-Dksf0QVU.js';
|
|
2
2
|
import { EventEmitter } from 'node:events';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { i as BridgeTransport, e as BridgeMessage, f as AgentBridge, j as AgentBridgeConfig,
|
|
2
|
-
import { A as AgentPhase, b as AgentDefinition, a as DefaultMultiAgentCoordinator, D as DispatchClassifier } from './multi-agent-coordinator-
|
|
3
|
-
import { E as EventBus, B as BrainArbiter } from './events-
|
|
1
|
+
import { i as BridgeTransport, e as BridgeMessage, f as AgentBridge, j as AgentBridgeConfig, c as SubagentRunner, T as TaskSpec, S as SubagentConfig, F as FleetBus, k as FleetUsage, l as FleetUsageAggregator, g as TaskResult, C as CoordinatorStatus, b as MultiAgentConfig, h as AwaitAnyResult } from './agent-subagent-runner-Dksf0QVU.js';
|
|
2
|
+
import { A as AgentPhase, b as AgentDefinition, a as DefaultMultiAgentCoordinator, D as DispatchClassifier } from './multi-agent-coordinator-4DC31QWu.js';
|
|
3
|
+
import { E as EventBus, B as BrainArbiter } from './events-CovDylaH.js';
|
|
4
4
|
import { b as SessionWriter, g as Tool, k as SessionStore } from './tool-LVSLiE1s.js';
|
|
5
5
|
import { EventEmitter } from 'node:events';
|
|
6
|
+
import { D as DirectorStateSnapshot } from './director-state-B_GPa78Q.js';
|
|
7
|
+
import { F as FleetConfig, a as ModelMatrixEntry } from './config-BCAEJicb.js';
|
|
6
8
|
import { L as Logger } from './logger-B63L5bTg.js';
|
|
7
|
-
import {
|
|
8
|
-
import { a as ModelMatrixEntry } from './config-CN-vdDEI.js';
|
|
9
|
+
import { W as WorktreeManager } from './worktree-manager-BBXdJq-Y.js';
|
|
9
10
|
|
|
10
11
|
/**
|
|
11
12
|
* In-memory pub/sub transport for agent-to-agent messaging.
|
|
@@ -109,6 +110,48 @@ interface AutoExtendPolicy {
|
|
|
109
110
|
*/
|
|
110
111
|
declare function attachAutoExtend(events: EventBus, policy?: AutoExtendPolicy): () => void;
|
|
111
112
|
|
|
113
|
+
type FleetWorktreePolicy = NonNullable<FleetConfig['worktrees']>;
|
|
114
|
+
type WorktreeIsolationDecision = 'off' | 'optional' | 'required';
|
|
115
|
+
interface WorktreeTaskStateUpdate {
|
|
116
|
+
taskId: string;
|
|
117
|
+
subagentId: string;
|
|
118
|
+
handleId: string;
|
|
119
|
+
dir: string;
|
|
120
|
+
branch: string;
|
|
121
|
+
baseBranch: string;
|
|
122
|
+
status: 'allocated' | 'fallback' | 'committed' | 'merged' | 'kept' | 'released' | 'conflict' | 'failed';
|
|
123
|
+
commitSha?: string | undefined;
|
|
124
|
+
conflictFiles?: string[] | undefined;
|
|
125
|
+
error?: string | undefined;
|
|
126
|
+
}
|
|
127
|
+
interface WorktreeTaskRunnerOptions {
|
|
128
|
+
runner: SubagentRunner;
|
|
129
|
+
worktrees?: WorktreeManager | undefined;
|
|
130
|
+
policy?: FleetWorktreePolicy | undefined;
|
|
131
|
+
conflictResolver?: ((info: {
|
|
132
|
+
task: TaskSpec;
|
|
133
|
+
config: SubagentConfig;
|
|
134
|
+
conflictFiles: string[];
|
|
135
|
+
cwd: string;
|
|
136
|
+
}) => Promise<boolean>) | undefined;
|
|
137
|
+
onUpdate?: ((update: WorktreeTaskStateUpdate) => void) | undefined;
|
|
138
|
+
}
|
|
139
|
+
declare class WorktreeIntegrationError extends Error {
|
|
140
|
+
readonly taskId: string;
|
|
141
|
+
readonly subagentId: string;
|
|
142
|
+
readonly branch?: string | undefined;
|
|
143
|
+
readonly conflictFiles?: string[] | undefined;
|
|
144
|
+
constructor(message: string, opts: {
|
|
145
|
+
taskId: string;
|
|
146
|
+
subagentId: string;
|
|
147
|
+
branch?: string | undefined;
|
|
148
|
+
conflictFiles?: string[] | undefined;
|
|
149
|
+
});
|
|
150
|
+
}
|
|
151
|
+
declare function subagentNeedsWorktree(config: SubagentConfig): boolean;
|
|
152
|
+
declare function resolveSubagentWorktreeDecision(config: SubagentConfig, policy?: FleetWorktreePolicy | undefined): WorktreeIsolationDecision;
|
|
153
|
+
declare function wrapSubagentRunnerWithWorktrees(opts: WorktreeTaskRunnerOptions): SubagentRunner;
|
|
154
|
+
|
|
112
155
|
/**
|
|
113
156
|
* Interface for fleet-level lifecycle and policy. Covers:
|
|
114
157
|
* - Spawn lifecycle hooks (canSpawn check, recordSpawn after-effects)
|
|
@@ -213,6 +256,8 @@ interface IFleetManager {
|
|
|
213
256
|
* the description is available in `status()` without host-side storage.
|
|
214
257
|
*/
|
|
215
258
|
addPendingTask(taskId: string, subagentId: string, description: string): void;
|
|
259
|
+
/** Record the latest git-worktree lifecycle state for a task. */
|
|
260
|
+
recordTaskWorktree(update: WorktreeTaskStateUpdate): void;
|
|
216
261
|
/**
|
|
217
262
|
* Remove a pending task. Called when the task completes so the
|
|
218
263
|
* pending list stays accurate.
|
|
@@ -428,6 +473,7 @@ declare class FleetManager implements IFleetManager {
|
|
|
428
473
|
* `Director.assign()` after the coordinator assigns a task.
|
|
429
474
|
*/
|
|
430
475
|
addTaskToSubagent(subagentId: string, taskId: string): void;
|
|
476
|
+
recordTaskWorktree(update: WorktreeTaskStateUpdate): void;
|
|
431
477
|
/**
|
|
432
478
|
* Debounced manifest write. Call after any state mutation
|
|
433
479
|
* (spawn, assign, complete) so a burst collapses into one write.
|
|
@@ -867,6 +913,24 @@ interface DirectorOptions {
|
|
|
867
913
|
* is also accepted for tests and one-shot runs.
|
|
868
914
|
*/
|
|
869
915
|
modelMatrix?: ModelMatrixSource | undefined;
|
|
916
|
+
/**
|
|
917
|
+
* Optional git-worktree manager for Director fleet isolation. When supplied,
|
|
918
|
+
* task runners can execute side-effectful subagents in per-task worktrees and
|
|
919
|
+
* squash-merge successful branches back into the base checkout.
|
|
920
|
+
*/
|
|
921
|
+
worktrees?: WorktreeManager | undefined;
|
|
922
|
+
/** Worktree policy. Defaults to `auto` when `worktrees` is provided. */
|
|
923
|
+
worktreePolicy?: FleetWorktreePolicy | undefined;
|
|
924
|
+
/**
|
|
925
|
+
* Optional guarded merge-conflict resolver invoked by WorktreeManager when a
|
|
926
|
+
* successful task branch cannot squash-merge cleanly.
|
|
927
|
+
*/
|
|
928
|
+
worktreeConflictResolver?: ((info: {
|
|
929
|
+
task: TaskSpec;
|
|
930
|
+
config: SubagentConfig;
|
|
931
|
+
conflictFiles: string[];
|
|
932
|
+
cwd: string;
|
|
933
|
+
}) => Promise<boolean>) | undefined;
|
|
870
934
|
}
|
|
871
935
|
/** Either a static matrix or a live getter (re-read on every spawn). */
|
|
872
936
|
type ModelMatrixSource = Record<string, ModelMatrixEntry> | (() => Record<string, ModelMatrixEntry> | undefined);
|
|
@@ -987,6 +1051,8 @@ declare class Director implements ICoordinator {
|
|
|
987
1051
|
/** Resolves task descriptions back from `assign()` so completion events
|
|
988
1052
|
* can also carry a human-readable title. */
|
|
989
1053
|
private readonly taskDescriptions;
|
|
1054
|
+
/** Latest worktree state per task id (allocated/committed/merged/conflict/etc.). */
|
|
1055
|
+
private readonly taskWorktrees;
|
|
990
1056
|
/** Snapshot of which subagent owns each task — drives state-checkpoint
|
|
991
1057
|
* status updates without re-walking the manifest. */
|
|
992
1058
|
private readonly taskOwners;
|
|
@@ -1128,6 +1194,7 @@ declare class Director implements ICoordinator {
|
|
|
1128
1194
|
* synchronously (no debounce); set to negative to disable entirely. */
|
|
1129
1195
|
private scheduleManifest;
|
|
1130
1196
|
private clearManifestTimer;
|
|
1197
|
+
private recordWorktreeTaskUpdate;
|
|
1131
1198
|
/**
|
|
1132
1199
|
* Spawn a subagent. Identical to the coordinator's `spawn()` but
|
|
1133
1200
|
* captures provider/model metadata for the usage aggregator and
|
|
@@ -1891,6 +1958,7 @@ interface DirectorSessionFactory {
|
|
|
1891
1958
|
declare function makeDirectorSessionFactory(opts: DirectorSessionFactoryOptions): DirectorSessionFactory;
|
|
1892
1959
|
|
|
1893
1960
|
declare function makeSpawnTool(director: Director, roster?: Record<string, SubagentConfig>): Tool;
|
|
1961
|
+
declare function makeQualityGateTool(director: Director, roster?: Record<string, SubagentConfig>): Tool;
|
|
1894
1962
|
declare function makeAssignTool(director: Director): Tool;
|
|
1895
1963
|
declare function makeAwaitTasksTool(director: Director): Tool;
|
|
1896
1964
|
declare function makeAskTool(director: Director): Tool;
|
|
@@ -2009,4 +2077,4 @@ declare const FLEET_ROSTER_WITHACP: Record<string, SubagentConfig>;
|
|
|
2009
2077
|
*/
|
|
2010
2078
|
declare const NULL_FLEET_BUS: FleetBus;
|
|
2011
2079
|
|
|
2012
|
-
export {
|
|
2080
|
+
export { type WorktreeIsolationDecision as $, ACP_AGENTS as A, BUG_HUNTER_AGENT as B, type CollabBudgetConfig as C, DEFAULT_DIRECTOR_PREAMBLE as D, FLEET_ROSTER_WITHACP as E, FLEET_ROSTER as F, FleetCostCapError as G, FleetManager as H, type FleetManagerOptions as I, type FleetRosterBudget as J, FleetSpawnBudgetError as K, type FleetWorktreePolicy as L, type ICoordinator as M, type IFleetManager as N, InMemoryAgentBridge as O, InMemoryBridgeTransport as P, LargeAnswerStore as Q, NULL_FLEET_BUS as R, REFACTOR_PLANNER_AGENT as S, type RefactorPhase as T, type RefactorPlan as U, SECURITY_SCANNER_AGENT as V, type SharedFileEntry as W, type SharedFileSnapshot as X, type SubagentPromptParts as Y, type TaskResultNotification as Z, WorktreeIntegrationError as _, AGENTS_BY_PHASE as a, type WorktreeTaskRunnerOptions as a0, type WorktreeTaskStateUpdate as a1, applyRosterBudget as a2, attachAutoExtend as a3, composeDirectorPrompt as a4, composeSubagentPrompt as a5, createDelegateTool as a6, createMessage as a7, getAgentDefinition as a8, makeAskResultTool as a9, makeAskTool as aa, makeAssignTool as ab, makeAwaitTasksTool as ac, makeCollabDebugTool as ad, makeDirectorSessionFactory as ae, makeFleetEmitTool as af, makeFleetTool as ag, makeQualityGateTool as ah, makeRollUpTool as ai, makeSpawnTool as aj, makeTerminateAllTool as ak, makeTerminateTool as al, makeWorkCompleteTool as am, resolveSubagentWorktreeDecision as an, rosterSummaryFromConfigs as ao, subagentNeedsWorktree as ap, wrapSubagentRunnerWithWorktrees as aq, AGENT_CATALOG as b, ALL_AGENT_DEFINITIONS as c, ALL_FLEET_AGENTS as d, AUDIT_LOG_AGENT as e, type AutoExtendCeiling as f, type AutoExtendPolicy as g, type BugFinding as h, type CollabBudgetOverrides as i, type CollabBudgetWarningPayload as j, type CollabDebugReport as k, CollabSession as l, type CollabSessionOptions as m, type CreateDelegateToolOptions as n, type CriticConcern as o, type CriticEvaluation as p, DEFAULT_SUBAGENT_BASELINE as q, type DelegateHost as r, Director as s, type DirectorAlert as t, DirectorAlertLevel as u, type DirectorCancelCollabPayload as v, type DirectorPromptParts as w, type DirectorSessionFactory as x, type DirectorSessionFactoryOptions as y, FLEET_ROSTER_BUDGETS as z };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { M as MetricsSink, d as MetricLabels, f as MetricsSnapshot, H as HealthRegistry, a as HealthCheck, A as AggregateHealth, T as Tracer, S as Span } from '../observability-D-HZN_mF.js';
|
|
2
|
-
import { E as EventBus } from '../events-
|
|
2
|
+
import { E as EventBus } from '../events-CovDylaH.js';
|
|
3
3
|
import '../tool-LVSLiE1s.js';
|
|
4
4
|
import '../permission-B6YAtNFz.js';
|
|
5
5
|
|
package/dist/{parallel-eternal-engine-Cc2CNgmv.d.ts → parallel-eternal-engine-BwcA0bAt.d.ts}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { A as Agent, a as AgentFactory } from './agent-subagent-runner-
|
|
2
|
-
import { B as BrainArbiter, E as EventBus } from './events-
|
|
1
|
+
import { A as Agent, a as AgentFactory } from './agent-subagent-runner-Dksf0QVU.js';
|
|
2
|
+
import { B as BrainArbiter, E as EventBus } from './events-CovDylaH.js';
|
|
3
3
|
import { C as Compactor } from './compactor-BxddyCFu.js';
|
|
4
|
-
import { J as JournalEntry } from './goal-store-
|
|
5
|
-
import { D as DispatchClassifier, a as DefaultMultiAgentCoordinator } from './multi-agent-coordinator-
|
|
4
|
+
import { J as JournalEntry } from './goal-store-CBd749M4.js';
|
|
5
|
+
import { D as DispatchClassifier, a as DefaultMultiAgentCoordinator } from './multi-agent-coordinator-4DC31QWu.js';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Design Studio — curated frontend/mobile UI design kits.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { g as Tool, s as TextBlock, i as ContentBlock } from './tool-LVSLiE1s.js';
|
|
2
2
|
import { a as MailboxAgentStatus } from './mailbox-types-BGZWrYTJ.js';
|
|
3
|
-
import { H as HookEvent, f as HookMatcher, I as InProcessHook, S as ShellHook, g as HookEntry, T as ToolResultRenderMode } from './config-
|
|
3
|
+
import { H as HookEvent, f as HookMatcher, I as InProcessHook, S as ShellHook, g as HookEntry, T as ToolResultRenderMode } from './config-BCAEJicb.js';
|
|
4
4
|
|
|
5
5
|
/** Model capabilities relevant to prompt composition. */
|
|
6
6
|
interface ModelCapabilities {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { P as Provider, M as Message } from './tool-LVSLiE1s.js';
|
|
2
2
|
import { M as MessageSelector, S as SelectorResult } from './selector-Bx2HgUkU.js';
|
|
3
3
|
import { M as ModeStore, a as ModeConfig, b as Mode } from './mode-CZlO9iU1.js';
|
|
4
|
-
import { M as ModelsRegistry, c as ModelsDevPayload, d as ResolvedProvider, R as ResolvedModel, W as WireFamily, e as ModelsDevModel } from './config-
|
|
4
|
+
import { M as ModelsRegistry, c as ModelsDevPayload, d as ResolvedProvider, R as ResolvedModel, W as WireFamily, e as ModelsDevModel } from './config-BCAEJicb.js';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Offline **floor** for the ChatGPT "Sign in with ChatGPT" (`openai-codex`)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { E as EventBus } from './events-
|
|
1
|
+
import { E as EventBus } from './events-CovDylaH.js';
|
|
2
2
|
import { L as Logger } from './logger-B63L5bTg.js';
|
|
3
3
|
import { T as Tracer } from './observability-D-HZN_mF.js';
|
|
4
4
|
import { P as Provider, c as Request, d as Context, e as Response } from './tool-LVSLiE1s.js';
|
package/dist/sdd/index.d.ts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { h as Specification, e as SpecStatus, S as SpecAnalysis, g as SpecValidationResult, f as SpecTemplate, b as SpecRequirement } from '../spec-TBi3Jr6T.js';
|
|
2
2
|
import { d as TaskGraph, e as TaskNode, i as TaskFilter, j as TaskSort, c as TaskProgress, T as TaskType, a as TaskPriority } from '../task-graph-u1q9Jkyk.js';
|
|
3
|
-
import { E as EventBus, B as BrainArbiter } from '../events-
|
|
4
|
-
import { A as Agent, a as AgentFactory, g as TaskResult, D as DoneCondition } from '../agent-subagent-runner-
|
|
5
|
-
import { W as WorktreeManager } from '../worktree-manager-
|
|
3
|
+
import { E as EventBus, B as BrainArbiter } from '../events-CovDylaH.js';
|
|
4
|
+
import { A as Agent, a as AgentFactory, g as TaskResult, D as DoneCondition } from '../agent-subagent-runner-Dksf0QVU.js';
|
|
5
|
+
import { W as WorktreeManager } from '../worktree-manager-BBXdJq-Y.js';
|
|
6
6
|
import '../tool-LVSLiE1s.js';
|
|
7
7
|
import '../permission-B6YAtNFz.js';
|
|
8
|
-
import '../index-
|
|
8
|
+
import '../index-D5HB7WkV.js';
|
|
9
9
|
import '../logger-B63L5bTg.js';
|
|
10
|
-
import '../pipeline-
|
|
10
|
+
import '../pipeline-DM-CPTUs.js';
|
|
11
11
|
import '../mailbox-types-BGZWrYTJ.js';
|
|
12
|
-
import '../config-
|
|
12
|
+
import '../config-BCAEJicb.js';
|
|
13
13
|
import '../observability-D-HZN_mF.js';
|
|
14
14
|
import '../secret-scrubber-3MHDDAtm.js';
|
|
15
15
|
import '../retry-policy-V67lBOJz.js';
|
package/dist/sdd/index.js
CHANGED
|
@@ -4341,6 +4341,34 @@ var BUILD_AGENTS = [
|
|
|
4341
4341
|
|
|
4342
4342
|
// src/coordination/agents/phase4-verify.ts
|
|
4343
4343
|
var VERIFY_AGENTS = [
|
|
4344
|
+
{
|
|
4345
|
+
config: {
|
|
4346
|
+
id: "verifier",
|
|
4347
|
+
name: "Verifier",
|
|
4348
|
+
role: "verifier",
|
|
4349
|
+
tools: [...TOOLS.inspect, "bash", "exec", "lint", "typecheck", "test", "git"],
|
|
4350
|
+
prompt: agentPrompt("verifier")
|
|
4351
|
+
},
|
|
4352
|
+
budget: HEAVY_BUDGET,
|
|
4353
|
+
capability: {
|
|
4354
|
+
phase: "verify",
|
|
4355
|
+
summary: "Independent verification gate: runs the relevant checks until they pass or returns exact failures that need another implementation pass.",
|
|
4356
|
+
keywords: [
|
|
4357
|
+
"verify",
|
|
4358
|
+
"verification",
|
|
4359
|
+
"quality gate",
|
|
4360
|
+
"prove it works",
|
|
4361
|
+
"run checks",
|
|
4362
|
+
"run tests until pass",
|
|
4363
|
+
"test pass",
|
|
4364
|
+
"green build",
|
|
4365
|
+
"typecheck",
|
|
4366
|
+
"lint",
|
|
4367
|
+
"regression check",
|
|
4368
|
+
"acceptance gate"
|
|
4369
|
+
]
|
|
4370
|
+
}
|
|
4371
|
+
},
|
|
4344
4372
|
{
|
|
4345
4373
|
config: {
|
|
4346
4374
|
id: "test",
|
|
@@ -4607,6 +4635,34 @@ var VERIFY_AGENTS = [
|
|
|
4607
4635
|
|
|
4608
4636
|
// src/coordination/agents/phase5-review.ts
|
|
4609
4637
|
var REVIEW_AGENTS = [
|
|
4638
|
+
{
|
|
4639
|
+
config: {
|
|
4640
|
+
id: "reviewer",
|
|
4641
|
+
name: "Reviewer",
|
|
4642
|
+
role: "reviewer",
|
|
4643
|
+
tools: [...TOOLS.inspect, "git"],
|
|
4644
|
+
prompt: agentPrompt("reviewer")
|
|
4645
|
+
},
|
|
4646
|
+
budget: MEDIUM_BUDGET,
|
|
4647
|
+
capability: {
|
|
4648
|
+
phase: "review",
|
|
4649
|
+
summary: "Independent AI reviewer: audits another agent's output, flags uncertainty, correlated-failure risk, and must-fix defects.",
|
|
4650
|
+
keywords: [
|
|
4651
|
+
"reviewer",
|
|
4652
|
+
"independent review",
|
|
4653
|
+
"ai review",
|
|
4654
|
+
"review agent",
|
|
4655
|
+
"quality review",
|
|
4656
|
+
"second opinion",
|
|
4657
|
+
"check another agent",
|
|
4658
|
+
"cross check",
|
|
4659
|
+
"uncertainty",
|
|
4660
|
+
"correlated error",
|
|
4661
|
+
"verify output",
|
|
4662
|
+
"quality control"
|
|
4663
|
+
]
|
|
4664
|
+
}
|
|
4665
|
+
},
|
|
4610
4666
|
{
|
|
4611
4667
|
config: {
|
|
4612
4668
|
id: "code-reviewer",
|
|
@@ -7660,6 +7716,15 @@ var WorktreeManager = class {
|
|
|
7660
7716
|
async merge(handle, opts = {}) {
|
|
7661
7717
|
const squash = opts.squash ?? true;
|
|
7662
7718
|
this.setStatus(handle, "merging");
|
|
7719
|
+
const status = await this.runGit(
|
|
7720
|
+
["status", "--porcelain", "--untracked-files=no"],
|
|
7721
|
+
this.projectRoot
|
|
7722
|
+
);
|
|
7723
|
+
if (status.stdout.trim().length > 0) {
|
|
7724
|
+
const reason = "working tree has uncommitted changes \u2014 commit or stash first";
|
|
7725
|
+
this.fail(handle, reason);
|
|
7726
|
+
return { ok: false, stderr: reason };
|
|
7727
|
+
}
|
|
7663
7728
|
const checkout = await this.runGit(["checkout", handle.baseBranch], this.projectRoot);
|
|
7664
7729
|
if (checkout.code !== 0) {
|
|
7665
7730
|
this.fail(handle, checkout.stderr || `checkout ${handle.baseBranch} failed`);
|
|
@@ -7887,7 +7952,12 @@ ${merged.stderr}`);
|
|
|
7887
7952
|
const fromIndex = await this.unmergedFiles();
|
|
7888
7953
|
const conflictFiles = [.../* @__PURE__ */ new Set([...fromOutput, ...fromIndex])];
|
|
7889
7954
|
await this.runGit(["reset", "--hard", "HEAD"], this.projectRoot).catch(() => void 0);
|
|
7890
|
-
return {
|
|
7955
|
+
return {
|
|
7956
|
+
ok: false,
|
|
7957
|
+
conflict: true,
|
|
7958
|
+
conflictFiles,
|
|
7959
|
+
reason: merged.stderr || "merge conflict"
|
|
7960
|
+
};
|
|
7891
7961
|
}
|
|
7892
7962
|
const idArgs = await this.identityArgs(this.projectRoot);
|
|
7893
7963
|
const commit = await this.runGit(
|
|
@@ -7989,7 +8059,11 @@ ${merged.stderr}`);
|
|
|
7989
8059
|
if (shas.length === 0) return { ok: true, reverted: 0, reason: "nothing to revert" };
|
|
7990
8060
|
const status = await this.runGit(["status", "--porcelain"], this.projectRoot);
|
|
7991
8061
|
if (status.stdout.trim().length > 0) {
|
|
7992
|
-
return {
|
|
8062
|
+
return {
|
|
8063
|
+
ok: false,
|
|
8064
|
+
reverted: 0,
|
|
8065
|
+
reason: "working tree has uncommitted changes \u2014 commit or stash first"
|
|
8066
|
+
};
|
|
7993
8067
|
}
|
|
7994
8068
|
const co = await this.runGit(["checkout", baseBranch], this.projectRoot);
|
|
7995
8069
|
if (co.code !== 0) {
|