@ordewell/core 0.5.0 → 0.5.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 (35) hide show
  1. package/dist/{ITerminalRunner-DXlJop_f.d.mts → ITerminalRunner-DCjsa2-I.d.mts} +6 -1
  2. package/dist/{ITerminalRunner-nupxhtPb.d.ts → ITerminalRunner-H1yT8LTy.d.ts} +6 -1
  3. package/dist/{ModeResolver-D1-2xJsE.d.mts → ModeResolver-DVJ7HV3k.d.mts} +1 -1
  4. package/dist/{ModeResolver-BBVktyiP.d.ts → ModeResolver-Dkig8ghQ.d.ts} +1 -1
  5. package/dist/{Task-CfTjRQeS.d.mts → Task-BxQkPlXO.d.mts} +88 -10
  6. package/dist/{Task-CfTjRQeS.d.ts → Task-BxQkPlXO.d.ts} +88 -10
  7. package/dist/{chunk-HQICT7HQ.mjs → chunk-T2S5O36I.mjs} +17 -4
  8. package/dist/chunk-T2S5O36I.mjs.map +1 -0
  9. package/dist/index.d.mts +82 -57
  10. package/dist/index.d.ts +82 -57
  11. package/dist/index.js +658 -252
  12. package/dist/index.js.map +1 -1
  13. package/dist/index.mjs +657 -264
  14. package/dist/index.mjs.map +1 -1
  15. package/dist/order-labels.d.mts +1 -1
  16. package/dist/order-labels.d.ts +1 -1
  17. package/dist/{parsing-Bv3g2Tu_.d.ts → parsing-CF_grC29.d.ts} +2 -2
  18. package/dist/{parsing-BJECTMOD.d.mts → parsing-DRp4dPC0.d.mts} +2 -2
  19. package/dist/parsing.d.mts +3 -3
  20. package/dist/parsing.d.ts +3 -3
  21. package/dist/{plan-utils-Cy-RsBSV.d.ts → plan-utils-CkNbqAmS.d.ts} +36 -3
  22. package/dist/{plan-utils-B5oIZkuI.d.mts → plan-utils-CtB3_Ovf.d.mts} +36 -3
  23. package/dist/plan-utils.d.mts +3 -3
  24. package/dist/plan-utils.d.ts +3 -3
  25. package/dist/plan-utils.js +7 -0
  26. package/dist/plan-utils.js.map +1 -1
  27. package/dist/plan-utils.mjs +4 -0
  28. package/dist/testing.d.mts +20 -8
  29. package/dist/testing.d.ts +20 -8
  30. package/dist/testing.js +52 -4
  31. package/dist/testing.js.map +1 -1
  32. package/dist/testing.mjs +47 -4
  33. package/dist/testing.mjs.map +1 -1
  34. package/package.json +1 -1
  35. package/dist/chunk-HQICT7HQ.mjs.map +0 -1
package/dist/index.d.mts CHANGED
@@ -1,17 +1,17 @@
1
- import { B as RunnerId, t as PlanStatus, L as LegacyPlanState, j as IsolationMergeResult, I as IWorktreeIsolation, p as IsolationTaskStatus, P as PlanIsolation, R as RepoGroupLayout, a as DiscoveredModel, T as Task, w as ResearchProgress, v as ResearchLogEntry, C as ConversationMessage, O as TaskSnapshot, c as IsolationHandoff, G as TaskIsolation, q as IsolationView, Q as QueuedMessage, A as ActiveTaskSession, z as ResearchToolType, s as PlanState, a1 as Verdict } from './Task-CfTjRQeS.mjs';
2
- export { D as DiscoveredMode, b as IsolationAvailability, d as IsolationHandoffRepo, e as IsolationInactiveReason, f as IsolationLandedTask, g as IsolationLanding, h as IsolationMergeBlock, i as IsolationMergeBlockReason, k as IsolationOutcome, l as IsolationRepo, m as IsolationRun, n as IsolationTaskRecord, o as IsolationTaskRepo, M as Message, r as PlanModificationWarnings, u as PreparedTask, x as ResearchStep, y as ResearchStepOutcome, S as StreamEvent, E as StreamStepEvent, F as StreamThinkingEvent, H as TaskIsolationState, J as TaskMode, K as TaskModelAssignment, N as TaskOutputSummary, U as TaskStatus, V as TaskType, W as TaskWithParent, X as ThinkingBlock, Y as UserPromptEntry, Z as UserStep, _ as ValidationCheck, $ as ValidationContext, a0 as ValidationResult, a2 as VerificationCheck, a3 as addTaskToPlan, a4 as createEmptyPlan, a5 as createTask, a6 as emptyWarnings, a7 as flattenTasks, a8 as flattenTasksWithParents, a9 as migrateLegacyPlan, aa as migratePlanState, ab as migrateTask, ac as removeTaskFromPlan, ad as renumberTasks, ae as updateTaskInPlan, af as validateModifiedPlan, ag as warningsText } from './Task-CfTjRQeS.mjs';
3
- import { f as IFileSystem, R as ReadFileOpts, T as ToolOutcome, d as GrepOptions, c as GlobOptions, b as FindSymbolOptions, I as IConfig, A as AiProvider, r as ProviderModelLists, i as ITerminalSession, h as ITerminalRunner, w as RunnerRegistry, k as OrchestratorOption, u as RunnerInvocation, g as IPluginStore, v as RunnerPluginManifest, t as ResolveContext } from './ITerminalRunner-DXlJop_f.mjs';
4
- export { a as AllProviderModels, C as CatalogModel, D as DiscoveryCommand, F as FetchAllProviderModelsOptions, G as GREP_DEFAULT_HEAD_LIMIT, e as GrepOutputMode, M as ModelCatalog, j as ModelShortcut, O as ORCHESTRATOR_SHORTCUTS, P as PluginCloneFn, l as PluginEntry, m as PluginFeatures, n as PluginMode, o as PluginModelDiscovery, p as PluginRunnerDef, q as ProviderCredentialSource, s as ProviderModelsResult, S as SEARCH_EXCLUSIONS, x as collectProviderCredentials, y as enabledRunners, z as fetchAllProviderModels, B as isReservedRunnerName, E as knownModelId, H as resolveModelShortcut, J as resolveProvider, K as toOrchestratorOptions } from './ITerminalRunner-DXlJop_f.mjs';
1
+ import { F as RunnerId, u as PlanStatus, L as LegacyPlanState, k as IsolationMergeResult, g as IsolationLandedTask, I as IWorktreeIsolation, w as RepoGroupLayout, a as DiscoveredModel, T as Task, y as ResearchProgress, x as ResearchLogEntry, C as ConversationMessage, V as TaskSnapshot, d as IsolationHandoff, J as TaskIsolation, r as IsolationView, P as PlanIsolation, Q as QueuedMessage, A as ActiveTaskSession, E as ResearchToolType, t as PlanState, a3 as Verdict } from './Task-BxQkPlXO.mjs';
2
+ export { D as DiscoveredMode, b as IntegrationDisposal, c as IsolationAvailability, e as IsolationHandoffRepo, f as IsolationInactiveReason, h as IsolationLanding, i as IsolationMergeBlock, j as IsolationMergeBlockReason, l as IsolationOutcome, m as IsolationRepo, n as IsolationRun, o as IsolationTaskRecord, p as IsolationTaskRepo, q as IsolationTaskStatus, M as Message, s as PlanModificationWarnings, v as PreparedTask, R as RepairEvidence, z as ResearchStep, B as ResearchStepOutcome, S as StreamEvent, G as StreamStepEvent, H as StreamThinkingEvent, K as TaskIsolationState, N as TaskMode, O as TaskModelAssignment, U as TaskOutputSummary, W as TaskStatus, X as TaskType, Y as TaskWithParent, Z as ThinkingBlock, _ as UserPromptEntry, $ as UserStep, a0 as ValidationCheck, a1 as ValidationContext, a2 as ValidationResult, a4 as VerificationCheck, a5 as addTaskToPlan, a6 as createEmptyPlan, a7 as createTask, a8 as emptyWarnings, a9 as flattenTasks, aa as flattenTasksWithParents, ab as migrateLegacyPlan, ac as migratePlanState, ad as migrateTask, ae as removeTaskFromPlan, af as renumberTasks, ag as updateTaskInPlan, ah as validateModifiedPlan, ai as warningsText } from './Task-BxQkPlXO.mjs';
3
+ import { f as IFileSystem, R as ReadFileOpts, T as ToolOutcome, d as GrepOptions, c as GlobOptions, b as FindSymbolOptions, I as IConfig, A as AiProvider, r as ProviderModelLists, i as ITerminalSession, h as ITerminalRunner, w as RunnerRegistry, k as OrchestratorOption, u as RunnerInvocation, g as IPluginStore, v as RunnerPluginManifest, t as ResolveContext } from './ITerminalRunner-DCjsa2-I.mjs';
4
+ export { a as AllProviderModels, C as CatalogModel, D as DiscoveryCommand, F as FetchAllProviderModelsOptions, G as GREP_DEFAULT_HEAD_LIMIT, e as GrepOutputMode, M as ModelCatalog, j as ModelShortcut, O as ORCHESTRATOR_SHORTCUTS, P as PluginCloneFn, l as PluginEntry, m as PluginFeatures, n as PluginMode, o as PluginModelDiscovery, p as PluginRunnerDef, q as ProviderCredentialSource, s as ProviderModelsResult, S as SEARCH_EXCLUSIONS, x as collectProviderCredentials, y as enabledRunners, z as fetchAllProviderModels, B as isReservedRunnerName, E as knownModelId, H as resolveModelShortcut, J as resolveProvider, K as toOrchestratorOptions } from './ITerminalRunner-DCjsa2-I.mjs';
5
5
  import { I as IApproval, d as ApprovalRequest, a as ApprovalMode } from './ApprovalPolicy-BVhGdECT.mjs';
6
6
  export { A as ApprovalKind, b as ApprovalPolicy, c as ApprovalPolicyOptions, e as ApprovalSource, D as DENY_ALL } from './ApprovalPolicy-BVhGdECT.mjs';
7
- import { R as RunnerModeInfo } from './ModeResolver-D1-2xJsE.mjs';
8
- export { M as ManifestLookup, b as buildModeGuide, f as filteredBuildModes, r as resolveDefaultMode, a as resolveTaskMode, c as runnerModesFrom } from './ModeResolver-D1-2xJsE.mjs';
9
- import { T as TaskOp, c as SessionBroadcaster, e as SessionNotice } from './plan-utils-B5oIZkuI.mjs';
10
- export { A as ApplyTaskOpsResult, C as CHECKPOINT_TRUNCATE_LENGTH, S as SerializedPlan, a as SerializedTask, b as SerializedTaskStatus, d as SessionMessage, f as TaskRef, g as applyTaskOps, h as canMergeTasks, i as canSetDependencies, j as canSplitTask, k as classifyOutcome, l as dependencyCandidates, m as dependentsOf, n as executionSummary, p as parseTaskOpsJson, s as serializePlan, o as serializeTask, q as serializeTaskStatus, r as summarizeToolCall, t as textHasTaskOps, u as truncateCheckpointSummary } from './plan-utils-B5oIZkuI.mjs';
7
+ import { T as TaskOp, f as SessionBroadcaster, h as SessionNotice } from './plan-utils-CtB3_Ovf.mjs';
8
+ export { A as Adr0013IsolationRun, a as Adr0013PlanIsolation, b as Adr0013TaskRecord, c as ApplyTaskOpsResult, C as CHECKPOINT_TRUNCATE_LENGTH, S as SerializedPlan, d as SerializedTask, e as SerializedTaskStatus, g as SessionMessage, i as TaskRef, j as applyTaskOps, k as canMergeTasks, l as canSetDependencies, m as canSplitTask, n as capConflictFiles, o as classifyOutcome, p as dependencyCandidates, q as dependentsOf, r as executionSummary, s as migratePlanIsolation, t as parseTaskOpsJson, u as serializePlan, v as serializeTask, w as serializeTaskStatus, x as summarizeToolCall, y as textHasTaskOps, z as truncateCheckpointSummary } from './plan-utils-CtB3_Ovf.mjs';
9
+ import { R as RunnerModeInfo } from './ModeResolver-DVJ7HV3k.mjs';
10
+ export { M as ManifestLookup, b as buildModeGuide, f as filteredBuildModes, r as resolveDefaultMode, a as resolveTaskMode, c as runnerModesFrom } from './ModeResolver-DVJ7HV3k.mjs';
11
11
  import { ChildProcess } from 'child_process';
12
12
  import { EventEmitter } from 'events';
13
- import { b as PlanParseError } from './parsing-BJECTMOD.mjs';
14
- export { P as PLAN_ENVELOPE_KEY, a as PartialPlanTask, T as TASK_OPS_ENVELOPE_KEY, c as TASK_QUERY_ENVELOPE_KEY, d as checkDepsResolve, e as checkImmutableLog, f as checkInProgress, g as checkNoCycles, h as checkUniqueIds, i as escapeControlCharsInStrings, j as extractJsonObject, k as extractObjectWithBalance, l as extractObjectsWithKey, m as looksLikePlanAttempt, p as parsePartialPlan, n as parsePlanJson, s as stripModelNoise, o as stripTrailingCommas, v as validatePlanModification } from './parsing-BJECTMOD.mjs';
13
+ import { b as PlanParseError } from './parsing-DRp4dPC0.mjs';
14
+ export { P as PLAN_ENVELOPE_KEY, a as PartialPlanTask, T as TASK_OPS_ENVELOPE_KEY, c as TASK_QUERY_ENVELOPE_KEY, d as checkDepsResolve, e as checkImmutableLog, f as checkInProgress, g as checkNoCycles, h as checkUniqueIds, i as escapeControlCharsInStrings, j as extractJsonObject, k as extractObjectWithBalance, l as extractObjectsWithKey, m as looksLikePlanAttempt, p as parsePartialPlan, n as parsePlanJson, s as stripModelNoise, o as stripTrailingCommas, v as validatePlanModification } from './parsing-DRp4dPC0.mjs';
15
15
  export { resolveOrderLabel, taskOrderLabel } from './order-labels.mjs';
16
16
 
17
17
  interface SessionMeta {
@@ -527,6 +527,7 @@ declare abstract class BaseConfig implements IConfig {
527
527
  get worktreeSetupCommand(): string | undefined;
528
528
  get workspaceRepos(): string[];
529
529
  get worktreeLinks(): string[];
530
+ get conflictRepairAttempts(): number;
530
531
  get approvalMode(): ApprovalMode;
531
532
  get approvalPreApproved(): string[];
532
533
  protected static detectProvider(fallback: AiProvider): AiProvider;
@@ -560,9 +561,11 @@ interface INotification {
560
561
  /**
561
562
  * How "Merge all" went, in words every surface shares. `group` is whether the
562
563
  * run spans more than a lone repo at `.`; only a merge into every repository
563
- * has something to say about that.
564
+ * has something to say about that. `repaired` names the landed tasks that only
565
+ * landed after a conflict repair (ADR-0015), so a clean-looking merge still
566
+ * points review at what changed to get there.
564
567
  */
565
- declare function describeMergeResult(result: IsolationMergeResult, branch: string, group: boolean): {
568
+ declare function describeMergeResult(result: IsolationMergeResult, branch: string, group: boolean, repaired?: IsolationLandedTask[]): {
566
569
  level: 'info' | 'warn' | 'error';
567
570
  message: string;
568
571
  };
@@ -584,37 +587,6 @@ interface WorktreeIsolationDeps {
584
587
  }
585
588
  declare function createWorktreeIsolation(deps: WorktreeIsolationDeps): IWorktreeIsolation;
586
589
 
587
- /** A task record as ADR-0013 persisted it, for one repository. */
588
- interface Adr0013TaskRecord {
589
- taskId: string;
590
- order: number;
591
- title: string;
592
- branch: string;
593
- worktree: string;
594
- status: IsolationTaskStatus;
595
- linked: string[];
596
- }
597
- /** A run as ADR-0013 persisted it (0.4.23): one repository, its refs on the run itself. */
598
- interface Adr0013IsolationRun {
599
- id: string;
600
- workspaceRoot: string;
601
- baseRef: string;
602
- baseBranch?: string;
603
- integrationBranch: string;
604
- tasks: Record<string, Adr0013TaskRecord>;
605
- }
606
- interface Adr0013PlanIsolation {
607
- run: Adr0013IsolationRun;
608
- resolvers: Record<string, string>;
609
- }
610
- /**
611
- * A persisted plan isolation in today's shape. A run saved in the ADR-0013
612
- * format — recognised by its own `integrationBranch` — becomes a group of one
613
- * at `.`, keeping its branches, so a session saved by 0.4.23 resumes and hands
614
- * off exactly as it would have.
615
- */
616
- declare function migratePlanIsolation(state: PlanIsolation | Adr0013PlanIsolation): PlanIsolation;
617
-
618
590
  interface ILogger {
619
591
  warn(scope: string, message: string, err?: unknown): void;
620
592
  }
@@ -1933,12 +1905,19 @@ declare class TaskOrchestrator {
1933
1905
  */
1934
1906
  adoptIsolation(state: PlanIsolation | null): Promise<void>;
1935
1907
  reviewRunDiff(): Promise<string>;
1936
- /** "Merge all": the run's integration branches into whatever the user has checked out, in every repo or none. */
1908
+ /**
1909
+ * "Merge all": the run's integration branches into whatever the user has
1910
+ * checked out, in every repo or none. Once everything merged, the run has
1911
+ * nothing left to hand over, so it is cleared up and forgotten; a branch
1912
+ * the user's HEAD somehow does not contain stays for the next run's sweep.
1913
+ */
1937
1914
  mergeRun(): Promise<IsolationMergeResult>;
1915
+ private clearMergedRun;
1938
1916
  /** Worktrees and task branches go; the integration branch and the record stay for review and merge. */
1939
1917
  cleanupRun(): Promise<void>;
1940
1918
  /** The run and everything it made go, and the plan forgets it; the next run starts afresh. */
1941
1919
  discardRun(): Promise<void>;
1920
+ private forgetRun;
1942
1921
  private requireRun;
1943
1922
  /** What the plan persists of isolated execution; null when no run ever isolated. */
1944
1923
  get isolationRecord(): PlanIsolation | null;
@@ -1964,6 +1943,24 @@ declare class TaskOrchestrator {
1964
1943
  stop(): void;
1965
1944
  onUserTaskComplete(taskId: string): Promise<void>;
1966
1945
  private onVerdict;
1946
+ private afterVerdict;
1947
+ /**
1948
+ * A repair's verdict decides only whether its work may try to land. It never
1949
+ * replaces the verdict the task's own work earned, and a repair that does not
1950
+ * land leaves the task waiting on the user — never a failed task, so never a
1951
+ * halted run.
1952
+ */
1953
+ private settleRepair;
1954
+ /**
1955
+ * Evidence before the queue: the repair's work is committed and checked, and
1956
+ * only then merged, through the same serialized landing as any other task —
1957
+ * so a repair the tip has moved past again is a fresh conflict, not a pass.
1958
+ */
1959
+ private landRepair;
1960
+ private landedRepair;
1961
+ /** A repair that did not land leaves the task as its conflict did: waiting on the user, worktree and refs kept. */
1962
+ private unrepaired;
1963
+ private describeEvidence;
1967
1964
  /**
1968
1965
  * Merge a passed attempt's worktree. The attempt stays live while it waits on
1969
1966
  * the module's merge queue, so a cancel, retry or stop in that window still
@@ -1977,6 +1974,9 @@ declare class TaskOrchestrator {
1977
1974
  /** Settle a task whose work passed, by what its integration reported. */
1978
1975
  private landPassed;
1979
1976
  private landUnmerged;
1977
+ /** The repair a conflicted task is owed next; null when repair is off, used up, or there is no isolated run to repair it in. */
1978
+ private nextRepair;
1979
+ private noRepairReason;
1980
1980
  /**
1981
1981
  * Mark which added task resolves which conflict. The resolver merges the
1982
1982
  * conflicted task's branch by hand in its own worktree; once that lands, the
@@ -2064,6 +2064,7 @@ declare class TaskOrchestrator {
2064
2064
  * attempt may have decided the task since (mark complete, cancel, retry).
2065
2065
  */
2066
2066
  private abandonSpawn;
2067
+ private repairPrompt;
2067
2068
  /**
2068
2069
  * The one place an attempt's working directory is decided. Async so a
2069
2070
  * per-attempt workspace (worktree isolation, #12) can be prepared here.
@@ -2088,6 +2089,8 @@ declare class TaskOrchestrator {
2088
2089
  plannerIsolation(): Promise<IsolatedExecution>;
2089
2090
  private decideRun;
2090
2091
  private activate;
2092
+ /** What earlier runs left merged in the group goes; a failure here is worth a word, never a stopped run. */
2093
+ private sweep;
2091
2094
  /**
2092
2095
  * The plan's run carries on while anything has landed on its integration
2093
2096
  * branch: a resumed plan's dependents must start from a tip that holds their
@@ -2097,8 +2100,8 @@ declare class TaskOrchestrator {
2097
2100
  /**
2098
2101
  * A run with nothing landed holds only superseded attempts, so it goes whole.
2099
2102
  * One that cannot be continued for another reason — it ran from a different
2100
- * workspace path — keeps its integration branch: only the user gives landed
2101
- * work up.
2103
+ * workspace path — keeps its integration branch in each repo that has not
2104
+ * merged it: only the user gives landed work up.
2102
2105
  */
2103
2106
  private mintRun;
2104
2107
  /** Close the open run. An isolated one hands its integration branch over for review. */
@@ -2697,11 +2700,13 @@ declare class ConversationEditError extends Error {
2697
2700
  declare class ConversationBusyError extends ConversationEditError {
2698
2701
  constructor(operation: string);
2699
2702
  }
2700
- /** A user message the conversation can be rewound to just before. */
2703
+ /** A user message a rewind can fork the conversation from just before. */
2701
2704
  interface RewindTarget {
2702
- /** Position in the transcript — what {@link PlannerConversation.rewind} takes. */
2705
+ /** Position in the transcript — what {@link PlannerConversation.cloneBefore} takes. */
2703
2706
  index: number;
2704
2707
  preview: string;
2708
+ /** The whole message — the preview cuts it to one line, and a surface confirming the rewind quotes it. */
2709
+ content: string;
2705
2710
  timestamp: string;
2706
2711
  }
2707
2712
  /** What a compaction left behind. */
@@ -2807,6 +2812,10 @@ interface ConversationFork {
2807
2812
  goal: string;
2808
2813
  workspace: string;
2809
2814
  }
2815
+ /** A fork made by a rewind, and the full text of the message it was made just before. */
2816
+ interface ConversationRewind extends ConversationFork {
2817
+ rewoundMessage: string;
2818
+ }
2810
2819
  interface SessionDeps {
2811
2820
  config: IConfig;
2812
2821
  notifications: INotification;
@@ -3029,16 +3038,18 @@ declare class Session {
3029
3038
  */
3030
3039
  forkConversation(): ConversationFork;
3031
3040
  /**
3032
- * Cut the conversation back to just before a user message (a transcript
3033
- * position from {@link rewindTargets}). Conversation only: the task list,
3034
- * and any run executing it, carry on as they are. The planner's live context
3035
- * is dropped, so the next message replays from the shortened transcript.
3041
+ * Fork the conversation from just before a user message (a transcript
3042
+ * position from {@link rewindTargets}): the fork holds everything said
3043
+ * before it and the current task list, like {@link forkConversation}, and
3044
+ * this session keeps its whole history. The message's full text comes back
3045
+ * so a surface can offer it for resending.
3036
3046
  */
3037
- rewindConversation(userMessageIndex: number): LegacyPlanState;
3047
+ rewindConversation(userMessageIndex: number): ConversationRewind;
3048
+ private saveFork;
3038
3049
  /**
3039
3050
  * Condense the conversation on the user's say-so: a hidden planner turn
3040
3051
  * summarises it, and the summary replaces everything but the last two
3041
- * exchanges. Conversation only, like a rewind — the tasks, and any run
3052
+ * exchanges. Conversation only — the tasks, and any run
3042
3053
  * executing them, are untouched. Atomic: a failed or stopped turn changes
3043
3054
  * nothing.
3044
3055
  */
@@ -3128,8 +3139,9 @@ declare class Session {
3128
3139
  * The opt-in way through a merge conflict: add an AI task, on the conflicted
3129
3140
  * task's own runner and model, that merges its branch by hand in a worktree
3130
3141
  * of its own. When that task lands, the conflicted one lands through it (see
3131
- * {@link TaskOrchestrator.linkConflictResolver}). Never automatic — nothing
3132
- * but this call adds it.
3142
+ * {@link TaskOrchestrator.linkConflictResolver}). The automatic answer to a
3143
+ * conflict is a repair, a new attempt of the same task (ADR-0015); a task is
3144
+ * only ever added to the plan by this call.
3133
3145
  */
3134
3146
  resolveConflictAsTask(taskId: string): Promise<LegacyPlanState | null>;
3135
3147
  stopExecution(): void;
@@ -3508,6 +3520,19 @@ declare function buildConflictResolutionPrompt(task: Task, conflict: {
3508
3520
  repos: string[];
3509
3521
  conflictRepo?: string;
3510
3522
  }, integrationBranch: string): string;
3523
+ /**
3524
+ * Runner prompt for a conflict repair (ADR-0015): a new attempt of the
3525
+ * conflicted task itself, in its kept worktree, so the merge runs the other
3526
+ * way round from {@link buildConflictResolutionPrompt} — the integration tip
3527
+ * into the task's branch. Whether it worked is decided by the evidence checks
3528
+ * and the landing that follow, never by the agent's word.
3529
+ */
3530
+ declare function buildConflictRepairPrompt(task: Task, conflict: {
3531
+ branch: string;
3532
+ repos: string[];
3533
+ conflictRepo?: string;
3534
+ conflictFiles?: string[];
3535
+ }, integrationBranch: string): string;
3511
3536
 
3512
3537
  /**
3513
3538
  * The one owner of "the model emitted something unusable — correct it and
@@ -4162,4 +4187,4 @@ declare class PlannerModelMemory {
4162
4187
  recall(provider: string, catalog: PlannerModelCandidate[]): PlannerModelRecall;
4163
4188
  }
4164
4189
 
4165
- export { ALLOWED_PLUGIN_HOSTS, ALL_PROVIDERS, AUTO_COMMANDS, AbstractRunner, AbstractTerminalSession, ActiveTaskSession, type Adr0013IsolationRun, type Adr0013PlanIsolation, type Adr0013TaskRecord, type AgentAdapter, type AgentAdapterFactory, type AgentEvent, type AgentProcessDeps, type AgentStartOptions, AiProvider, ApprovalMode, ApprovalRequest, BUILTIN_SKILL_NAMES, BaseAiService, BaseConfig, BaseFileSystem, BufferedTaskOutputSource, CLAUDE_CODE_MANIFEST, CLI_PROVIDERS, CMD_EXE_MAX_COMMAND_LINE, CORE_PLANNER_PROMPT, type CappedRows, type CheckpointListener, ClaudeCodeAdapter, CliAgentAiService, type CliAgentAiServiceDeps, CodexAdapter, type CommandClassification, CommandLineTooLongError, type CommandTier, type ComposeOptions, ConsoleLogger, ContextCollector, ConversationBusyError, type ConversationCompaction, ConversationEditError, type ConversationFork, ConversationMessage, type ConversationRequest, type ConversationTurn, type ConversationVariant, DAEMON_SUBPROTOCOL, DAEMON_TOKEN_SUBPROTOCOL_PREFIX, DiscoveredModel, EmbeddedNewlineError, type EnvAdmission, EnvConfig, type ExecFileFn, type ExecImpl, ExecutableNotFoundError, FindSymbolOptions, FsPluginStore, GIT_READONLY_SUBCOMMANDS, GeminiService, type GitExecFn, GlobOptions, type GrepInvocation, GrepOptions, type HasBinFn, HeadlessRunner, type HeadlessRunnerDeps, HeadlessSession, HomeTranscriptReader, type IAiService, IApproval, IConfig, IFileSystem, type ILogger, type INotification, IPluginStore, ITerminalRunner, ITerminalSession, IWorktreeIsolation, IsolationHandoff, IsolationMergeResult, IsolationTaskStatus, IsolationView, JSON_REPAIR_INSTRUCTION, type KillTreeDeps, type LaunchDeps, type LaunchPlan, LegacyPlanState, LineBuffer, type LiveOutputLookup, type LiveTail, type LiveTailOptions, type MappedTool, ModelResolver, type ModelResolverDeps, type ModifyPlanRequest, type NotificationAction, OPENCODE_MANIFEST, ORDEWELL_SETTABLE_ENV, OUTPUT_LINES_DEFAULT, OUTPUT_LINES_MAX, OpenAiService, OpenCodeAdapter, type OrchestratorObserver, OrchestratorOption, PLUGIN_NAME_PATTERN, PROVIDER_CREDENTIAL_ENV, PROVIDER_DETECT_PRIORITY, PROVIDER_LABEL, PROVIDER_PRIORITY, PROVIDER_SHORT_LABEL, type PendingApproval, PendingApprovals, type PendingApprovalsOptions, PlanEditError, PlanIsolation, PlanParseError, type PlanRequest, PlanState, PlanStatus, PlanStore, Planner, type PlannerModelCandidate, type PlannerModelChoice, PlannerModelMemory, type PlannerModelRecall, type PlannerModelStore, type PlannerReplyClassification, type PlannerRuntimeToggles, type PluginSource, type PrdBlock, type PreparedLaunch, type PriorOutput, type ProbeFn, ProviderModelLists, type ProviderRegistration, type PtySize, type PtyWrapOptions, QueuedMessage, REFUSED_COMMANDS, ReadFileOpts, type RepairLoopOpts, type RepairVerdict, RepoGroupLayout, type ResearchChat, ResearchLogEntry, ResearchProgress, type ResearchShell, type ResearchShellDeps, ResearchToolType, type ResearchTurn, ResolveContext, type RewindTarget, type RunnerCatalog, RunnerId, RunnerInstallation, RunnerInvocation, type RunnerMode, RunnerModeInfo, RunnerPluginManifest, RunnerRegistry, type RunnerSpawnOptions, SETTINGS_ENV_ALLOWLIST, SETTINGS_ENV_REFUSED, STATE_DIR, STOPPED_TOOL_RESULT, SYMBOL_LANGUAGES, Session, SessionBroadcaster, type SessionData, type SessionDeps, type SessionMeta, SessionNotice, type SessionPlanner, type SessionRuntimeSettings, SettingsService, type ShellDialect, type SkillInfo, type SkillMetadata, SkillsService, type SpawnSpec, StdioAgentAdapter, TASK_QUERY_ANSWER_MAX_CHARS, TASK_QUERY_ANSWER_OR_OPS, TASK_QUERY_FIELDS, TASK_QUERY_PROTOCOL, TASK_QUERY_REMINDER, TRUNCATED_PLAN_REPAIR_INSTRUCTION, Task, type TaskAttemptSnapshot, TaskIsolation, TaskOp, TaskOrchestrator, type TaskOutputAttempt, type TaskOutputSource, type TaskQuery, type TaskQueryCatalog, type TaskQueryField, TaskSnapshot, TmuxRunner, type TmuxRunnerDeps, type TokenCarriers, type ToolCall, ToolOutcome, type ToolResult, type TranscriptQuery, type TranscriptReader, type UserSettings, Verdict, VerdictEngine, type VerdictListener, WINDOWS_MAX_COMMAND_LINE, type WorkspaceCheckDeps, WorkspaceNotAProjectError, WorkspaceNotFoundError, type WorkspaceProjectCheckDeps, type WorktreeIsolationDeps, admitSettingsEnv, applyHeadLimit, assertInstallablePluginUrl, assertPlainPluginName, assertWorkspaceExists, assertWorkspaceIsProject, augmentPromptWithPriorOutputs, augmentedPath, bearerHeaderValue, buildConflictResolutionPrompt, buildConversationSystemPrompt, buildFallbackGrepArgs, buildGlobArgs, buildGrepArgs, buildMergePrompt, buildModifyDuringExecutionPrompt, buildModifyPlanPrompt, buildPlanWithResults, buildResearchPrompt, buildResearchToolsPrompt, buildRunnerInvocation, buildShellInvocation, buildSplitPrompt, buildSubagentSystemPrompt, clampThinkingEffort, classifyCommand, classifyPlannerReply, classifyPluginSource, clearAugmentedPathCache, clearDaemonToken, clearResearchShellCache, clearState, clipboardCopyCommand, coerceAssignments, collectDirectDependencyOutputs, composeAugmentedPrompt, configuredProviders, createAiService, createSkillsService, createWorktreeIsolation, daemonTokenPath, defaultLogger, definitionPattern, deleteSession, describeMergeResult, discoverGeminiModels, effectiveAllowlist, ensureDir, ensureStateDirIgnored, executionLogBlock, extractPrdBlock, extractPresentedToken, filterFallbackByAnchoredInclude, filterModelsForPrompt, formatSearchOutput, generatePlanWithRepair, getLatestSession, getProviderMeta, getSettingsPath, getStateDir, globalDataDir, grantScopeFor, hasTmux, includeGlobFor, isCliProvider, isExecutableResolved, isOpenAiProvider, isPlainPluginName, isValidManifest, killTree, languageForId, listSessions, loadSession, loadSessionPlanState, loadState, mapAgentTool, migrateOldConfigDir, migratePlanIsolation, mintDaemonToken, mintSessionId, modelContextBlock, modifyValidationFeedback, normalizeAgentArgs, normalizeGeminiModel, parseTaskQueryJson, pendingEditRulesBlock, planDirectLaunch, planShellLaunch, posixShellQuote, prefixModelId, providerForRunner, reEmitPlanPrompt, reEmitTaskOpsPrompt, reEmitTaskQueryPrompt, readDaemonToken, referencePattern, renderPlanMap, renderPriorOutputs, renderTaskQueryAnswer, repairLoop, researchShellWarning, researchToolsPath, resolveArgs, resolvePluginInstallDir, resolveProviderFromPrefix, resolveResearchShell, resolveSkillInvocation, resolveWithin, retargetTaskRunner, runnerAssignment, runnerForProvider, sanitizeSlug, savePrdMarkdown, saveSession, saveState, sessionRuntimeSettings, stateExists, stripAnsi, stripModelPrefix, summarizeOutput, taskOpsRejectedPrompt, taskQuerySignature, textHasTaskQuery, tmuxSessionName, tmuxSocketName, tmuxWindowName, tokenSubprotocols, tokensMatch, truncatedPlanReEmitPrompt, wellKnownBinDirs, windowsCommandLine, withPath, wrapWithPty };
4190
+ export { ALLOWED_PLUGIN_HOSTS, ALL_PROVIDERS, AUTO_COMMANDS, AbstractRunner, AbstractTerminalSession, ActiveTaskSession, type AgentAdapter, type AgentAdapterFactory, type AgentEvent, type AgentProcessDeps, type AgentStartOptions, AiProvider, ApprovalMode, ApprovalRequest, BUILTIN_SKILL_NAMES, BaseAiService, BaseConfig, BaseFileSystem, BufferedTaskOutputSource, CLAUDE_CODE_MANIFEST, CLI_PROVIDERS, CMD_EXE_MAX_COMMAND_LINE, CORE_PLANNER_PROMPT, type CappedRows, type CheckpointListener, ClaudeCodeAdapter, CliAgentAiService, type CliAgentAiServiceDeps, CodexAdapter, type CommandClassification, CommandLineTooLongError, type CommandTier, type ComposeOptions, ConsoleLogger, ContextCollector, ConversationBusyError, type ConversationCompaction, ConversationEditError, type ConversationFork, ConversationMessage, type ConversationRequest, type ConversationRewind, type ConversationTurn, type ConversationVariant, DAEMON_SUBPROTOCOL, DAEMON_TOKEN_SUBPROTOCOL_PREFIX, DiscoveredModel, EmbeddedNewlineError, type EnvAdmission, EnvConfig, type ExecFileFn, type ExecImpl, ExecutableNotFoundError, FindSymbolOptions, FsPluginStore, GIT_READONLY_SUBCOMMANDS, GeminiService, type GitExecFn, GlobOptions, type GrepInvocation, GrepOptions, type HasBinFn, HeadlessRunner, type HeadlessRunnerDeps, HeadlessSession, HomeTranscriptReader, type IAiService, IApproval, IConfig, IFileSystem, type ILogger, type INotification, IPluginStore, ITerminalRunner, ITerminalSession, IWorktreeIsolation, IsolationHandoff, IsolationLandedTask, IsolationMergeResult, IsolationView, JSON_REPAIR_INSTRUCTION, type KillTreeDeps, type LaunchDeps, type LaunchPlan, LegacyPlanState, LineBuffer, type LiveOutputLookup, type LiveTail, type LiveTailOptions, type MappedTool, ModelResolver, type ModelResolverDeps, type ModifyPlanRequest, type NotificationAction, OPENCODE_MANIFEST, ORDEWELL_SETTABLE_ENV, OUTPUT_LINES_DEFAULT, OUTPUT_LINES_MAX, OpenAiService, OpenCodeAdapter, type OrchestratorObserver, OrchestratorOption, PLUGIN_NAME_PATTERN, PROVIDER_CREDENTIAL_ENV, PROVIDER_DETECT_PRIORITY, PROVIDER_LABEL, PROVIDER_PRIORITY, PROVIDER_SHORT_LABEL, type PendingApproval, PendingApprovals, type PendingApprovalsOptions, PlanEditError, PlanIsolation, PlanParseError, type PlanRequest, PlanState, PlanStatus, PlanStore, Planner, type PlannerModelCandidate, type PlannerModelChoice, PlannerModelMemory, type PlannerModelRecall, type PlannerModelStore, type PlannerReplyClassification, type PlannerRuntimeToggles, type PluginSource, type PrdBlock, type PreparedLaunch, type PriorOutput, type ProbeFn, ProviderModelLists, type ProviderRegistration, type PtySize, type PtyWrapOptions, QueuedMessage, REFUSED_COMMANDS, ReadFileOpts, type RepairLoopOpts, type RepairVerdict, RepoGroupLayout, type ResearchChat, ResearchLogEntry, ResearchProgress, type ResearchShell, type ResearchShellDeps, ResearchToolType, type ResearchTurn, ResolveContext, type RewindTarget, type RunnerCatalog, RunnerId, RunnerInstallation, RunnerInvocation, type RunnerMode, RunnerModeInfo, RunnerPluginManifest, RunnerRegistry, type RunnerSpawnOptions, SETTINGS_ENV_ALLOWLIST, SETTINGS_ENV_REFUSED, STATE_DIR, STOPPED_TOOL_RESULT, SYMBOL_LANGUAGES, Session, SessionBroadcaster, type SessionData, type SessionDeps, type SessionMeta, SessionNotice, type SessionPlanner, type SessionRuntimeSettings, SettingsService, type ShellDialect, type SkillInfo, type SkillMetadata, SkillsService, type SpawnSpec, StdioAgentAdapter, TASK_QUERY_ANSWER_MAX_CHARS, TASK_QUERY_ANSWER_OR_OPS, TASK_QUERY_FIELDS, TASK_QUERY_PROTOCOL, TASK_QUERY_REMINDER, TRUNCATED_PLAN_REPAIR_INSTRUCTION, Task, type TaskAttemptSnapshot, TaskIsolation, TaskOp, TaskOrchestrator, type TaskOutputAttempt, type TaskOutputSource, type TaskQuery, type TaskQueryCatalog, type TaskQueryField, TaskSnapshot, TmuxRunner, type TmuxRunnerDeps, type TokenCarriers, type ToolCall, ToolOutcome, type ToolResult, type TranscriptQuery, type TranscriptReader, type UserSettings, Verdict, VerdictEngine, type VerdictListener, WINDOWS_MAX_COMMAND_LINE, type WorkspaceCheckDeps, WorkspaceNotAProjectError, WorkspaceNotFoundError, type WorkspaceProjectCheckDeps, type WorktreeIsolationDeps, admitSettingsEnv, applyHeadLimit, assertInstallablePluginUrl, assertPlainPluginName, assertWorkspaceExists, assertWorkspaceIsProject, augmentPromptWithPriorOutputs, augmentedPath, bearerHeaderValue, buildConflictRepairPrompt, buildConflictResolutionPrompt, buildConversationSystemPrompt, buildFallbackGrepArgs, buildGlobArgs, buildGrepArgs, buildMergePrompt, buildModifyDuringExecutionPrompt, buildModifyPlanPrompt, buildPlanWithResults, buildResearchPrompt, buildResearchToolsPrompt, buildRunnerInvocation, buildShellInvocation, buildSplitPrompt, buildSubagentSystemPrompt, clampThinkingEffort, classifyCommand, classifyPlannerReply, classifyPluginSource, clearAugmentedPathCache, clearDaemonToken, clearResearchShellCache, clearState, clipboardCopyCommand, coerceAssignments, collectDirectDependencyOutputs, composeAugmentedPrompt, configuredProviders, createAiService, createSkillsService, createWorktreeIsolation, daemonTokenPath, defaultLogger, definitionPattern, deleteSession, describeMergeResult, discoverGeminiModels, effectiveAllowlist, ensureDir, ensureStateDirIgnored, executionLogBlock, extractPrdBlock, extractPresentedToken, filterFallbackByAnchoredInclude, filterModelsForPrompt, formatSearchOutput, generatePlanWithRepair, getLatestSession, getProviderMeta, getSettingsPath, getStateDir, globalDataDir, grantScopeFor, hasTmux, includeGlobFor, isCliProvider, isExecutableResolved, isOpenAiProvider, isPlainPluginName, isValidManifest, killTree, languageForId, listSessions, loadSession, loadSessionPlanState, loadState, mapAgentTool, migrateOldConfigDir, mintDaemonToken, mintSessionId, modelContextBlock, modifyValidationFeedback, normalizeAgentArgs, normalizeGeminiModel, parseTaskQueryJson, pendingEditRulesBlock, planDirectLaunch, planShellLaunch, posixShellQuote, prefixModelId, providerForRunner, reEmitPlanPrompt, reEmitTaskOpsPrompt, reEmitTaskQueryPrompt, readDaemonToken, referencePattern, renderPlanMap, renderPriorOutputs, renderTaskQueryAnswer, repairLoop, researchShellWarning, researchToolsPath, resolveArgs, resolvePluginInstallDir, resolveProviderFromPrefix, resolveResearchShell, resolveSkillInvocation, resolveWithin, retargetTaskRunner, runnerAssignment, runnerForProvider, sanitizeSlug, savePrdMarkdown, saveSession, saveState, sessionRuntimeSettings, stateExists, stripAnsi, stripModelPrefix, summarizeOutput, taskOpsRejectedPrompt, taskQuerySignature, textHasTaskQuery, tmuxSessionName, tmuxSocketName, tmuxWindowName, tokenSubprotocols, tokensMatch, truncatedPlanReEmitPrompt, wellKnownBinDirs, windowsCommandLine, withPath, wrapWithPty };
package/dist/index.d.ts CHANGED
@@ -1,17 +1,17 @@
1
- import { B as RunnerId, t as PlanStatus, L as LegacyPlanState, j as IsolationMergeResult, I as IWorktreeIsolation, p as IsolationTaskStatus, P as PlanIsolation, R as RepoGroupLayout, a as DiscoveredModel, T as Task, w as ResearchProgress, v as ResearchLogEntry, C as ConversationMessage, O as TaskSnapshot, c as IsolationHandoff, G as TaskIsolation, q as IsolationView, Q as QueuedMessage, A as ActiveTaskSession, z as ResearchToolType, s as PlanState, a1 as Verdict } from './Task-CfTjRQeS.js';
2
- export { D as DiscoveredMode, b as IsolationAvailability, d as IsolationHandoffRepo, e as IsolationInactiveReason, f as IsolationLandedTask, g as IsolationLanding, h as IsolationMergeBlock, i as IsolationMergeBlockReason, k as IsolationOutcome, l as IsolationRepo, m as IsolationRun, n as IsolationTaskRecord, o as IsolationTaskRepo, M as Message, r as PlanModificationWarnings, u as PreparedTask, x as ResearchStep, y as ResearchStepOutcome, S as StreamEvent, E as StreamStepEvent, F as StreamThinkingEvent, H as TaskIsolationState, J as TaskMode, K as TaskModelAssignment, N as TaskOutputSummary, U as TaskStatus, V as TaskType, W as TaskWithParent, X as ThinkingBlock, Y as UserPromptEntry, Z as UserStep, _ as ValidationCheck, $ as ValidationContext, a0 as ValidationResult, a2 as VerificationCheck, a3 as addTaskToPlan, a4 as createEmptyPlan, a5 as createTask, a6 as emptyWarnings, a7 as flattenTasks, a8 as flattenTasksWithParents, a9 as migrateLegacyPlan, aa as migratePlanState, ab as migrateTask, ac as removeTaskFromPlan, ad as renumberTasks, ae as updateTaskInPlan, af as validateModifiedPlan, ag as warningsText } from './Task-CfTjRQeS.js';
3
- import { f as IFileSystem, R as ReadFileOpts, T as ToolOutcome, d as GrepOptions, c as GlobOptions, b as FindSymbolOptions, I as IConfig, A as AiProvider, r as ProviderModelLists, i as ITerminalSession, h as ITerminalRunner, w as RunnerRegistry, k as OrchestratorOption, u as RunnerInvocation, g as IPluginStore, v as RunnerPluginManifest, t as ResolveContext } from './ITerminalRunner-nupxhtPb.js';
4
- export { a as AllProviderModels, C as CatalogModel, D as DiscoveryCommand, F as FetchAllProviderModelsOptions, G as GREP_DEFAULT_HEAD_LIMIT, e as GrepOutputMode, M as ModelCatalog, j as ModelShortcut, O as ORCHESTRATOR_SHORTCUTS, P as PluginCloneFn, l as PluginEntry, m as PluginFeatures, n as PluginMode, o as PluginModelDiscovery, p as PluginRunnerDef, q as ProviderCredentialSource, s as ProviderModelsResult, S as SEARCH_EXCLUSIONS, x as collectProviderCredentials, y as enabledRunners, z as fetchAllProviderModels, B as isReservedRunnerName, E as knownModelId, H as resolveModelShortcut, J as resolveProvider, K as toOrchestratorOptions } from './ITerminalRunner-nupxhtPb.js';
1
+ import { F as RunnerId, u as PlanStatus, L as LegacyPlanState, k as IsolationMergeResult, g as IsolationLandedTask, I as IWorktreeIsolation, w as RepoGroupLayout, a as DiscoveredModel, T as Task, y as ResearchProgress, x as ResearchLogEntry, C as ConversationMessage, V as TaskSnapshot, d as IsolationHandoff, J as TaskIsolation, r as IsolationView, P as PlanIsolation, Q as QueuedMessage, A as ActiveTaskSession, E as ResearchToolType, t as PlanState, a3 as Verdict } from './Task-BxQkPlXO.js';
2
+ export { D as DiscoveredMode, b as IntegrationDisposal, c as IsolationAvailability, e as IsolationHandoffRepo, f as IsolationInactiveReason, h as IsolationLanding, i as IsolationMergeBlock, j as IsolationMergeBlockReason, l as IsolationOutcome, m as IsolationRepo, n as IsolationRun, o as IsolationTaskRecord, p as IsolationTaskRepo, q as IsolationTaskStatus, M as Message, s as PlanModificationWarnings, v as PreparedTask, R as RepairEvidence, z as ResearchStep, B as ResearchStepOutcome, S as StreamEvent, G as StreamStepEvent, H as StreamThinkingEvent, K as TaskIsolationState, N as TaskMode, O as TaskModelAssignment, U as TaskOutputSummary, W as TaskStatus, X as TaskType, Y as TaskWithParent, Z as ThinkingBlock, _ as UserPromptEntry, $ as UserStep, a0 as ValidationCheck, a1 as ValidationContext, a2 as ValidationResult, a4 as VerificationCheck, a5 as addTaskToPlan, a6 as createEmptyPlan, a7 as createTask, a8 as emptyWarnings, a9 as flattenTasks, aa as flattenTasksWithParents, ab as migrateLegacyPlan, ac as migratePlanState, ad as migrateTask, ae as removeTaskFromPlan, af as renumberTasks, ag as updateTaskInPlan, ah as validateModifiedPlan, ai as warningsText } from './Task-BxQkPlXO.js';
3
+ import { f as IFileSystem, R as ReadFileOpts, T as ToolOutcome, d as GrepOptions, c as GlobOptions, b as FindSymbolOptions, I as IConfig, A as AiProvider, r as ProviderModelLists, i as ITerminalSession, h as ITerminalRunner, w as RunnerRegistry, k as OrchestratorOption, u as RunnerInvocation, g as IPluginStore, v as RunnerPluginManifest, t as ResolveContext } from './ITerminalRunner-H1yT8LTy.js';
4
+ export { a as AllProviderModels, C as CatalogModel, D as DiscoveryCommand, F as FetchAllProviderModelsOptions, G as GREP_DEFAULT_HEAD_LIMIT, e as GrepOutputMode, M as ModelCatalog, j as ModelShortcut, O as ORCHESTRATOR_SHORTCUTS, P as PluginCloneFn, l as PluginEntry, m as PluginFeatures, n as PluginMode, o as PluginModelDiscovery, p as PluginRunnerDef, q as ProviderCredentialSource, s as ProviderModelsResult, S as SEARCH_EXCLUSIONS, x as collectProviderCredentials, y as enabledRunners, z as fetchAllProviderModels, B as isReservedRunnerName, E as knownModelId, H as resolveModelShortcut, J as resolveProvider, K as toOrchestratorOptions } from './ITerminalRunner-H1yT8LTy.js';
5
5
  import { I as IApproval, d as ApprovalRequest, a as ApprovalMode } from './ApprovalPolicy-BVhGdECT.js';
6
6
  export { A as ApprovalKind, b as ApprovalPolicy, c as ApprovalPolicyOptions, e as ApprovalSource, D as DENY_ALL } from './ApprovalPolicy-BVhGdECT.js';
7
- import { R as RunnerModeInfo } from './ModeResolver-BBVktyiP.js';
8
- export { M as ManifestLookup, b as buildModeGuide, f as filteredBuildModes, r as resolveDefaultMode, a as resolveTaskMode, c as runnerModesFrom } from './ModeResolver-BBVktyiP.js';
9
- import { T as TaskOp, c as SessionBroadcaster, e as SessionNotice } from './plan-utils-Cy-RsBSV.js';
10
- export { A as ApplyTaskOpsResult, C as CHECKPOINT_TRUNCATE_LENGTH, S as SerializedPlan, a as SerializedTask, b as SerializedTaskStatus, d as SessionMessage, f as TaskRef, g as applyTaskOps, h as canMergeTasks, i as canSetDependencies, j as canSplitTask, k as classifyOutcome, l as dependencyCandidates, m as dependentsOf, n as executionSummary, p as parseTaskOpsJson, s as serializePlan, o as serializeTask, q as serializeTaskStatus, r as summarizeToolCall, t as textHasTaskOps, u as truncateCheckpointSummary } from './plan-utils-Cy-RsBSV.js';
7
+ import { T as TaskOp, f as SessionBroadcaster, h as SessionNotice } from './plan-utils-CkNbqAmS.js';
8
+ export { A as Adr0013IsolationRun, a as Adr0013PlanIsolation, b as Adr0013TaskRecord, c as ApplyTaskOpsResult, C as CHECKPOINT_TRUNCATE_LENGTH, S as SerializedPlan, d as SerializedTask, e as SerializedTaskStatus, g as SessionMessage, i as TaskRef, j as applyTaskOps, k as canMergeTasks, l as canSetDependencies, m as canSplitTask, n as capConflictFiles, o as classifyOutcome, p as dependencyCandidates, q as dependentsOf, r as executionSummary, s as migratePlanIsolation, t as parseTaskOpsJson, u as serializePlan, v as serializeTask, w as serializeTaskStatus, x as summarizeToolCall, y as textHasTaskOps, z as truncateCheckpointSummary } from './plan-utils-CkNbqAmS.js';
9
+ import { R as RunnerModeInfo } from './ModeResolver-Dkig8ghQ.js';
10
+ export { M as ManifestLookup, b as buildModeGuide, f as filteredBuildModes, r as resolveDefaultMode, a as resolveTaskMode, c as runnerModesFrom } from './ModeResolver-Dkig8ghQ.js';
11
11
  import { ChildProcess } from 'child_process';
12
12
  import { EventEmitter } from 'events';
13
- import { b as PlanParseError } from './parsing-Bv3g2Tu_.js';
14
- export { P as PLAN_ENVELOPE_KEY, a as PartialPlanTask, T as TASK_OPS_ENVELOPE_KEY, c as TASK_QUERY_ENVELOPE_KEY, d as checkDepsResolve, e as checkImmutableLog, f as checkInProgress, g as checkNoCycles, h as checkUniqueIds, i as escapeControlCharsInStrings, j as extractJsonObject, k as extractObjectWithBalance, l as extractObjectsWithKey, m as looksLikePlanAttempt, p as parsePartialPlan, n as parsePlanJson, s as stripModelNoise, o as stripTrailingCommas, v as validatePlanModification } from './parsing-Bv3g2Tu_.js';
13
+ import { b as PlanParseError } from './parsing-CF_grC29.js';
14
+ export { P as PLAN_ENVELOPE_KEY, a as PartialPlanTask, T as TASK_OPS_ENVELOPE_KEY, c as TASK_QUERY_ENVELOPE_KEY, d as checkDepsResolve, e as checkImmutableLog, f as checkInProgress, g as checkNoCycles, h as checkUniqueIds, i as escapeControlCharsInStrings, j as extractJsonObject, k as extractObjectWithBalance, l as extractObjectsWithKey, m as looksLikePlanAttempt, p as parsePartialPlan, n as parsePlanJson, s as stripModelNoise, o as stripTrailingCommas, v as validatePlanModification } from './parsing-CF_grC29.js';
15
15
  export { resolveOrderLabel, taskOrderLabel } from './order-labels.js';
16
16
 
17
17
  interface SessionMeta {
@@ -527,6 +527,7 @@ declare abstract class BaseConfig implements IConfig {
527
527
  get worktreeSetupCommand(): string | undefined;
528
528
  get workspaceRepos(): string[];
529
529
  get worktreeLinks(): string[];
530
+ get conflictRepairAttempts(): number;
530
531
  get approvalMode(): ApprovalMode;
531
532
  get approvalPreApproved(): string[];
532
533
  protected static detectProvider(fallback: AiProvider): AiProvider;
@@ -560,9 +561,11 @@ interface INotification {
560
561
  /**
561
562
  * How "Merge all" went, in words every surface shares. `group` is whether the
562
563
  * run spans more than a lone repo at `.`; only a merge into every repository
563
- * has something to say about that.
564
+ * has something to say about that. `repaired` names the landed tasks that only
565
+ * landed after a conflict repair (ADR-0015), so a clean-looking merge still
566
+ * points review at what changed to get there.
564
567
  */
565
- declare function describeMergeResult(result: IsolationMergeResult, branch: string, group: boolean): {
568
+ declare function describeMergeResult(result: IsolationMergeResult, branch: string, group: boolean, repaired?: IsolationLandedTask[]): {
566
569
  level: 'info' | 'warn' | 'error';
567
570
  message: string;
568
571
  };
@@ -584,37 +587,6 @@ interface WorktreeIsolationDeps {
584
587
  }
585
588
  declare function createWorktreeIsolation(deps: WorktreeIsolationDeps): IWorktreeIsolation;
586
589
 
587
- /** A task record as ADR-0013 persisted it, for one repository. */
588
- interface Adr0013TaskRecord {
589
- taskId: string;
590
- order: number;
591
- title: string;
592
- branch: string;
593
- worktree: string;
594
- status: IsolationTaskStatus;
595
- linked: string[];
596
- }
597
- /** A run as ADR-0013 persisted it (0.4.23): one repository, its refs on the run itself. */
598
- interface Adr0013IsolationRun {
599
- id: string;
600
- workspaceRoot: string;
601
- baseRef: string;
602
- baseBranch?: string;
603
- integrationBranch: string;
604
- tasks: Record<string, Adr0013TaskRecord>;
605
- }
606
- interface Adr0013PlanIsolation {
607
- run: Adr0013IsolationRun;
608
- resolvers: Record<string, string>;
609
- }
610
- /**
611
- * A persisted plan isolation in today's shape. A run saved in the ADR-0013
612
- * format — recognised by its own `integrationBranch` — becomes a group of one
613
- * at `.`, keeping its branches, so a session saved by 0.4.23 resumes and hands
614
- * off exactly as it would have.
615
- */
616
- declare function migratePlanIsolation(state: PlanIsolation | Adr0013PlanIsolation): PlanIsolation;
617
-
618
590
  interface ILogger {
619
591
  warn(scope: string, message: string, err?: unknown): void;
620
592
  }
@@ -1933,12 +1905,19 @@ declare class TaskOrchestrator {
1933
1905
  */
1934
1906
  adoptIsolation(state: PlanIsolation | null): Promise<void>;
1935
1907
  reviewRunDiff(): Promise<string>;
1936
- /** "Merge all": the run's integration branches into whatever the user has checked out, in every repo or none. */
1908
+ /**
1909
+ * "Merge all": the run's integration branches into whatever the user has
1910
+ * checked out, in every repo or none. Once everything merged, the run has
1911
+ * nothing left to hand over, so it is cleared up and forgotten; a branch
1912
+ * the user's HEAD somehow does not contain stays for the next run's sweep.
1913
+ */
1937
1914
  mergeRun(): Promise<IsolationMergeResult>;
1915
+ private clearMergedRun;
1938
1916
  /** Worktrees and task branches go; the integration branch and the record stay for review and merge. */
1939
1917
  cleanupRun(): Promise<void>;
1940
1918
  /** The run and everything it made go, and the plan forgets it; the next run starts afresh. */
1941
1919
  discardRun(): Promise<void>;
1920
+ private forgetRun;
1942
1921
  private requireRun;
1943
1922
  /** What the plan persists of isolated execution; null when no run ever isolated. */
1944
1923
  get isolationRecord(): PlanIsolation | null;
@@ -1964,6 +1943,24 @@ declare class TaskOrchestrator {
1964
1943
  stop(): void;
1965
1944
  onUserTaskComplete(taskId: string): Promise<void>;
1966
1945
  private onVerdict;
1946
+ private afterVerdict;
1947
+ /**
1948
+ * A repair's verdict decides only whether its work may try to land. It never
1949
+ * replaces the verdict the task's own work earned, and a repair that does not
1950
+ * land leaves the task waiting on the user — never a failed task, so never a
1951
+ * halted run.
1952
+ */
1953
+ private settleRepair;
1954
+ /**
1955
+ * Evidence before the queue: the repair's work is committed and checked, and
1956
+ * only then merged, through the same serialized landing as any other task —
1957
+ * so a repair the tip has moved past again is a fresh conflict, not a pass.
1958
+ */
1959
+ private landRepair;
1960
+ private landedRepair;
1961
+ /** A repair that did not land leaves the task as its conflict did: waiting on the user, worktree and refs kept. */
1962
+ private unrepaired;
1963
+ private describeEvidence;
1967
1964
  /**
1968
1965
  * Merge a passed attempt's worktree. The attempt stays live while it waits on
1969
1966
  * the module's merge queue, so a cancel, retry or stop in that window still
@@ -1977,6 +1974,9 @@ declare class TaskOrchestrator {
1977
1974
  /** Settle a task whose work passed, by what its integration reported. */
1978
1975
  private landPassed;
1979
1976
  private landUnmerged;
1977
+ /** The repair a conflicted task is owed next; null when repair is off, used up, or there is no isolated run to repair it in. */
1978
+ private nextRepair;
1979
+ private noRepairReason;
1980
1980
  /**
1981
1981
  * Mark which added task resolves which conflict. The resolver merges the
1982
1982
  * conflicted task's branch by hand in its own worktree; once that lands, the
@@ -2064,6 +2064,7 @@ declare class TaskOrchestrator {
2064
2064
  * attempt may have decided the task since (mark complete, cancel, retry).
2065
2065
  */
2066
2066
  private abandonSpawn;
2067
+ private repairPrompt;
2067
2068
  /**
2068
2069
  * The one place an attempt's working directory is decided. Async so a
2069
2070
  * per-attempt workspace (worktree isolation, #12) can be prepared here.
@@ -2088,6 +2089,8 @@ declare class TaskOrchestrator {
2088
2089
  plannerIsolation(): Promise<IsolatedExecution>;
2089
2090
  private decideRun;
2090
2091
  private activate;
2092
+ /** What earlier runs left merged in the group goes; a failure here is worth a word, never a stopped run. */
2093
+ private sweep;
2091
2094
  /**
2092
2095
  * The plan's run carries on while anything has landed on its integration
2093
2096
  * branch: a resumed plan's dependents must start from a tip that holds their
@@ -2097,8 +2100,8 @@ declare class TaskOrchestrator {
2097
2100
  /**
2098
2101
  * A run with nothing landed holds only superseded attempts, so it goes whole.
2099
2102
  * One that cannot be continued for another reason — it ran from a different
2100
- * workspace path — keeps its integration branch: only the user gives landed
2101
- * work up.
2103
+ * workspace path — keeps its integration branch in each repo that has not
2104
+ * merged it: only the user gives landed work up.
2102
2105
  */
2103
2106
  private mintRun;
2104
2107
  /** Close the open run. An isolated one hands its integration branch over for review. */
@@ -2697,11 +2700,13 @@ declare class ConversationEditError extends Error {
2697
2700
  declare class ConversationBusyError extends ConversationEditError {
2698
2701
  constructor(operation: string);
2699
2702
  }
2700
- /** A user message the conversation can be rewound to just before. */
2703
+ /** A user message a rewind can fork the conversation from just before. */
2701
2704
  interface RewindTarget {
2702
- /** Position in the transcript — what {@link PlannerConversation.rewind} takes. */
2705
+ /** Position in the transcript — what {@link PlannerConversation.cloneBefore} takes. */
2703
2706
  index: number;
2704
2707
  preview: string;
2708
+ /** The whole message — the preview cuts it to one line, and a surface confirming the rewind quotes it. */
2709
+ content: string;
2705
2710
  timestamp: string;
2706
2711
  }
2707
2712
  /** What a compaction left behind. */
@@ -2807,6 +2812,10 @@ interface ConversationFork {
2807
2812
  goal: string;
2808
2813
  workspace: string;
2809
2814
  }
2815
+ /** A fork made by a rewind, and the full text of the message it was made just before. */
2816
+ interface ConversationRewind extends ConversationFork {
2817
+ rewoundMessage: string;
2818
+ }
2810
2819
  interface SessionDeps {
2811
2820
  config: IConfig;
2812
2821
  notifications: INotification;
@@ -3029,16 +3038,18 @@ declare class Session {
3029
3038
  */
3030
3039
  forkConversation(): ConversationFork;
3031
3040
  /**
3032
- * Cut the conversation back to just before a user message (a transcript
3033
- * position from {@link rewindTargets}). Conversation only: the task list,
3034
- * and any run executing it, carry on as they are. The planner's live context
3035
- * is dropped, so the next message replays from the shortened transcript.
3041
+ * Fork the conversation from just before a user message (a transcript
3042
+ * position from {@link rewindTargets}): the fork holds everything said
3043
+ * before it and the current task list, like {@link forkConversation}, and
3044
+ * this session keeps its whole history. The message's full text comes back
3045
+ * so a surface can offer it for resending.
3036
3046
  */
3037
- rewindConversation(userMessageIndex: number): LegacyPlanState;
3047
+ rewindConversation(userMessageIndex: number): ConversationRewind;
3048
+ private saveFork;
3038
3049
  /**
3039
3050
  * Condense the conversation on the user's say-so: a hidden planner turn
3040
3051
  * summarises it, and the summary replaces everything but the last two
3041
- * exchanges. Conversation only, like a rewind — the tasks, and any run
3052
+ * exchanges. Conversation only — the tasks, and any run
3042
3053
  * executing them, are untouched. Atomic: a failed or stopped turn changes
3043
3054
  * nothing.
3044
3055
  */
@@ -3128,8 +3139,9 @@ declare class Session {
3128
3139
  * The opt-in way through a merge conflict: add an AI task, on the conflicted
3129
3140
  * task's own runner and model, that merges its branch by hand in a worktree
3130
3141
  * of its own. When that task lands, the conflicted one lands through it (see
3131
- * {@link TaskOrchestrator.linkConflictResolver}). Never automatic — nothing
3132
- * but this call adds it.
3142
+ * {@link TaskOrchestrator.linkConflictResolver}). The automatic answer to a
3143
+ * conflict is a repair, a new attempt of the same task (ADR-0015); a task is
3144
+ * only ever added to the plan by this call.
3133
3145
  */
3134
3146
  resolveConflictAsTask(taskId: string): Promise<LegacyPlanState | null>;
3135
3147
  stopExecution(): void;
@@ -3508,6 +3520,19 @@ declare function buildConflictResolutionPrompt(task: Task, conflict: {
3508
3520
  repos: string[];
3509
3521
  conflictRepo?: string;
3510
3522
  }, integrationBranch: string): string;
3523
+ /**
3524
+ * Runner prompt for a conflict repair (ADR-0015): a new attempt of the
3525
+ * conflicted task itself, in its kept worktree, so the merge runs the other
3526
+ * way round from {@link buildConflictResolutionPrompt} — the integration tip
3527
+ * into the task's branch. Whether it worked is decided by the evidence checks
3528
+ * and the landing that follow, never by the agent's word.
3529
+ */
3530
+ declare function buildConflictRepairPrompt(task: Task, conflict: {
3531
+ branch: string;
3532
+ repos: string[];
3533
+ conflictRepo?: string;
3534
+ conflictFiles?: string[];
3535
+ }, integrationBranch: string): string;
3511
3536
 
3512
3537
  /**
3513
3538
  * The one owner of "the model emitted something unusable — correct it and
@@ -4162,4 +4187,4 @@ declare class PlannerModelMemory {
4162
4187
  recall(provider: string, catalog: PlannerModelCandidate[]): PlannerModelRecall;
4163
4188
  }
4164
4189
 
4165
- export { ALLOWED_PLUGIN_HOSTS, ALL_PROVIDERS, AUTO_COMMANDS, AbstractRunner, AbstractTerminalSession, ActiveTaskSession, type Adr0013IsolationRun, type Adr0013PlanIsolation, type Adr0013TaskRecord, type AgentAdapter, type AgentAdapterFactory, type AgentEvent, type AgentProcessDeps, type AgentStartOptions, AiProvider, ApprovalMode, ApprovalRequest, BUILTIN_SKILL_NAMES, BaseAiService, BaseConfig, BaseFileSystem, BufferedTaskOutputSource, CLAUDE_CODE_MANIFEST, CLI_PROVIDERS, CMD_EXE_MAX_COMMAND_LINE, CORE_PLANNER_PROMPT, type CappedRows, type CheckpointListener, ClaudeCodeAdapter, CliAgentAiService, type CliAgentAiServiceDeps, CodexAdapter, type CommandClassification, CommandLineTooLongError, type CommandTier, type ComposeOptions, ConsoleLogger, ContextCollector, ConversationBusyError, type ConversationCompaction, ConversationEditError, type ConversationFork, ConversationMessage, type ConversationRequest, type ConversationTurn, type ConversationVariant, DAEMON_SUBPROTOCOL, DAEMON_TOKEN_SUBPROTOCOL_PREFIX, DiscoveredModel, EmbeddedNewlineError, type EnvAdmission, EnvConfig, type ExecFileFn, type ExecImpl, ExecutableNotFoundError, FindSymbolOptions, FsPluginStore, GIT_READONLY_SUBCOMMANDS, GeminiService, type GitExecFn, GlobOptions, type GrepInvocation, GrepOptions, type HasBinFn, HeadlessRunner, type HeadlessRunnerDeps, HeadlessSession, HomeTranscriptReader, type IAiService, IApproval, IConfig, IFileSystem, type ILogger, type INotification, IPluginStore, ITerminalRunner, ITerminalSession, IWorktreeIsolation, IsolationHandoff, IsolationMergeResult, IsolationTaskStatus, IsolationView, JSON_REPAIR_INSTRUCTION, type KillTreeDeps, type LaunchDeps, type LaunchPlan, LegacyPlanState, LineBuffer, type LiveOutputLookup, type LiveTail, type LiveTailOptions, type MappedTool, ModelResolver, type ModelResolverDeps, type ModifyPlanRequest, type NotificationAction, OPENCODE_MANIFEST, ORDEWELL_SETTABLE_ENV, OUTPUT_LINES_DEFAULT, OUTPUT_LINES_MAX, OpenAiService, OpenCodeAdapter, type OrchestratorObserver, OrchestratorOption, PLUGIN_NAME_PATTERN, PROVIDER_CREDENTIAL_ENV, PROVIDER_DETECT_PRIORITY, PROVIDER_LABEL, PROVIDER_PRIORITY, PROVIDER_SHORT_LABEL, type PendingApproval, PendingApprovals, type PendingApprovalsOptions, PlanEditError, PlanIsolation, PlanParseError, type PlanRequest, PlanState, PlanStatus, PlanStore, Planner, type PlannerModelCandidate, type PlannerModelChoice, PlannerModelMemory, type PlannerModelRecall, type PlannerModelStore, type PlannerReplyClassification, type PlannerRuntimeToggles, type PluginSource, type PrdBlock, type PreparedLaunch, type PriorOutput, type ProbeFn, ProviderModelLists, type ProviderRegistration, type PtySize, type PtyWrapOptions, QueuedMessage, REFUSED_COMMANDS, ReadFileOpts, type RepairLoopOpts, type RepairVerdict, RepoGroupLayout, type ResearchChat, ResearchLogEntry, ResearchProgress, type ResearchShell, type ResearchShellDeps, ResearchToolType, type ResearchTurn, ResolveContext, type RewindTarget, type RunnerCatalog, RunnerId, RunnerInstallation, RunnerInvocation, type RunnerMode, RunnerModeInfo, RunnerPluginManifest, RunnerRegistry, type RunnerSpawnOptions, SETTINGS_ENV_ALLOWLIST, SETTINGS_ENV_REFUSED, STATE_DIR, STOPPED_TOOL_RESULT, SYMBOL_LANGUAGES, Session, SessionBroadcaster, type SessionData, type SessionDeps, type SessionMeta, SessionNotice, type SessionPlanner, type SessionRuntimeSettings, SettingsService, type ShellDialect, type SkillInfo, type SkillMetadata, SkillsService, type SpawnSpec, StdioAgentAdapter, TASK_QUERY_ANSWER_MAX_CHARS, TASK_QUERY_ANSWER_OR_OPS, TASK_QUERY_FIELDS, TASK_QUERY_PROTOCOL, TASK_QUERY_REMINDER, TRUNCATED_PLAN_REPAIR_INSTRUCTION, Task, type TaskAttemptSnapshot, TaskIsolation, TaskOp, TaskOrchestrator, type TaskOutputAttempt, type TaskOutputSource, type TaskQuery, type TaskQueryCatalog, type TaskQueryField, TaskSnapshot, TmuxRunner, type TmuxRunnerDeps, type TokenCarriers, type ToolCall, ToolOutcome, type ToolResult, type TranscriptQuery, type TranscriptReader, type UserSettings, Verdict, VerdictEngine, type VerdictListener, WINDOWS_MAX_COMMAND_LINE, type WorkspaceCheckDeps, WorkspaceNotAProjectError, WorkspaceNotFoundError, type WorkspaceProjectCheckDeps, type WorktreeIsolationDeps, admitSettingsEnv, applyHeadLimit, assertInstallablePluginUrl, assertPlainPluginName, assertWorkspaceExists, assertWorkspaceIsProject, augmentPromptWithPriorOutputs, augmentedPath, bearerHeaderValue, buildConflictResolutionPrompt, buildConversationSystemPrompt, buildFallbackGrepArgs, buildGlobArgs, buildGrepArgs, buildMergePrompt, buildModifyDuringExecutionPrompt, buildModifyPlanPrompt, buildPlanWithResults, buildResearchPrompt, buildResearchToolsPrompt, buildRunnerInvocation, buildShellInvocation, buildSplitPrompt, buildSubagentSystemPrompt, clampThinkingEffort, classifyCommand, classifyPlannerReply, classifyPluginSource, clearAugmentedPathCache, clearDaemonToken, clearResearchShellCache, clearState, clipboardCopyCommand, coerceAssignments, collectDirectDependencyOutputs, composeAugmentedPrompt, configuredProviders, createAiService, createSkillsService, createWorktreeIsolation, daemonTokenPath, defaultLogger, definitionPattern, deleteSession, describeMergeResult, discoverGeminiModels, effectiveAllowlist, ensureDir, ensureStateDirIgnored, executionLogBlock, extractPrdBlock, extractPresentedToken, filterFallbackByAnchoredInclude, filterModelsForPrompt, formatSearchOutput, generatePlanWithRepair, getLatestSession, getProviderMeta, getSettingsPath, getStateDir, globalDataDir, grantScopeFor, hasTmux, includeGlobFor, isCliProvider, isExecutableResolved, isOpenAiProvider, isPlainPluginName, isValidManifest, killTree, languageForId, listSessions, loadSession, loadSessionPlanState, loadState, mapAgentTool, migrateOldConfigDir, migratePlanIsolation, mintDaemonToken, mintSessionId, modelContextBlock, modifyValidationFeedback, normalizeAgentArgs, normalizeGeminiModel, parseTaskQueryJson, pendingEditRulesBlock, planDirectLaunch, planShellLaunch, posixShellQuote, prefixModelId, providerForRunner, reEmitPlanPrompt, reEmitTaskOpsPrompt, reEmitTaskQueryPrompt, readDaemonToken, referencePattern, renderPlanMap, renderPriorOutputs, renderTaskQueryAnswer, repairLoop, researchShellWarning, researchToolsPath, resolveArgs, resolvePluginInstallDir, resolveProviderFromPrefix, resolveResearchShell, resolveSkillInvocation, resolveWithin, retargetTaskRunner, runnerAssignment, runnerForProvider, sanitizeSlug, savePrdMarkdown, saveSession, saveState, sessionRuntimeSettings, stateExists, stripAnsi, stripModelPrefix, summarizeOutput, taskOpsRejectedPrompt, taskQuerySignature, textHasTaskQuery, tmuxSessionName, tmuxSocketName, tmuxWindowName, tokenSubprotocols, tokensMatch, truncatedPlanReEmitPrompt, wellKnownBinDirs, windowsCommandLine, withPath, wrapWithPty };
4190
+ export { ALLOWED_PLUGIN_HOSTS, ALL_PROVIDERS, AUTO_COMMANDS, AbstractRunner, AbstractTerminalSession, ActiveTaskSession, type AgentAdapter, type AgentAdapterFactory, type AgentEvent, type AgentProcessDeps, type AgentStartOptions, AiProvider, ApprovalMode, ApprovalRequest, BUILTIN_SKILL_NAMES, BaseAiService, BaseConfig, BaseFileSystem, BufferedTaskOutputSource, CLAUDE_CODE_MANIFEST, CLI_PROVIDERS, CMD_EXE_MAX_COMMAND_LINE, CORE_PLANNER_PROMPT, type CappedRows, type CheckpointListener, ClaudeCodeAdapter, CliAgentAiService, type CliAgentAiServiceDeps, CodexAdapter, type CommandClassification, CommandLineTooLongError, type CommandTier, type ComposeOptions, ConsoleLogger, ContextCollector, ConversationBusyError, type ConversationCompaction, ConversationEditError, type ConversationFork, ConversationMessage, type ConversationRequest, type ConversationRewind, type ConversationTurn, type ConversationVariant, DAEMON_SUBPROTOCOL, DAEMON_TOKEN_SUBPROTOCOL_PREFIX, DiscoveredModel, EmbeddedNewlineError, type EnvAdmission, EnvConfig, type ExecFileFn, type ExecImpl, ExecutableNotFoundError, FindSymbolOptions, FsPluginStore, GIT_READONLY_SUBCOMMANDS, GeminiService, type GitExecFn, GlobOptions, type GrepInvocation, GrepOptions, type HasBinFn, HeadlessRunner, type HeadlessRunnerDeps, HeadlessSession, HomeTranscriptReader, type IAiService, IApproval, IConfig, IFileSystem, type ILogger, type INotification, IPluginStore, ITerminalRunner, ITerminalSession, IWorktreeIsolation, IsolationHandoff, IsolationLandedTask, IsolationMergeResult, IsolationView, JSON_REPAIR_INSTRUCTION, type KillTreeDeps, type LaunchDeps, type LaunchPlan, LegacyPlanState, LineBuffer, type LiveOutputLookup, type LiveTail, type LiveTailOptions, type MappedTool, ModelResolver, type ModelResolverDeps, type ModifyPlanRequest, type NotificationAction, OPENCODE_MANIFEST, ORDEWELL_SETTABLE_ENV, OUTPUT_LINES_DEFAULT, OUTPUT_LINES_MAX, OpenAiService, OpenCodeAdapter, type OrchestratorObserver, OrchestratorOption, PLUGIN_NAME_PATTERN, PROVIDER_CREDENTIAL_ENV, PROVIDER_DETECT_PRIORITY, PROVIDER_LABEL, PROVIDER_PRIORITY, PROVIDER_SHORT_LABEL, type PendingApproval, PendingApprovals, type PendingApprovalsOptions, PlanEditError, PlanIsolation, PlanParseError, type PlanRequest, PlanState, PlanStatus, PlanStore, Planner, type PlannerModelCandidate, type PlannerModelChoice, PlannerModelMemory, type PlannerModelRecall, type PlannerModelStore, type PlannerReplyClassification, type PlannerRuntimeToggles, type PluginSource, type PrdBlock, type PreparedLaunch, type PriorOutput, type ProbeFn, ProviderModelLists, type ProviderRegistration, type PtySize, type PtyWrapOptions, QueuedMessage, REFUSED_COMMANDS, ReadFileOpts, type RepairLoopOpts, type RepairVerdict, RepoGroupLayout, type ResearchChat, ResearchLogEntry, ResearchProgress, type ResearchShell, type ResearchShellDeps, ResearchToolType, type ResearchTurn, ResolveContext, type RewindTarget, type RunnerCatalog, RunnerId, RunnerInstallation, RunnerInvocation, type RunnerMode, RunnerModeInfo, RunnerPluginManifest, RunnerRegistry, type RunnerSpawnOptions, SETTINGS_ENV_ALLOWLIST, SETTINGS_ENV_REFUSED, STATE_DIR, STOPPED_TOOL_RESULT, SYMBOL_LANGUAGES, Session, SessionBroadcaster, type SessionData, type SessionDeps, type SessionMeta, SessionNotice, type SessionPlanner, type SessionRuntimeSettings, SettingsService, type ShellDialect, type SkillInfo, type SkillMetadata, SkillsService, type SpawnSpec, StdioAgentAdapter, TASK_QUERY_ANSWER_MAX_CHARS, TASK_QUERY_ANSWER_OR_OPS, TASK_QUERY_FIELDS, TASK_QUERY_PROTOCOL, TASK_QUERY_REMINDER, TRUNCATED_PLAN_REPAIR_INSTRUCTION, Task, type TaskAttemptSnapshot, TaskIsolation, TaskOp, TaskOrchestrator, type TaskOutputAttempt, type TaskOutputSource, type TaskQuery, type TaskQueryCatalog, type TaskQueryField, TaskSnapshot, TmuxRunner, type TmuxRunnerDeps, type TokenCarriers, type ToolCall, ToolOutcome, type ToolResult, type TranscriptQuery, type TranscriptReader, type UserSettings, Verdict, VerdictEngine, type VerdictListener, WINDOWS_MAX_COMMAND_LINE, type WorkspaceCheckDeps, WorkspaceNotAProjectError, WorkspaceNotFoundError, type WorkspaceProjectCheckDeps, type WorktreeIsolationDeps, admitSettingsEnv, applyHeadLimit, assertInstallablePluginUrl, assertPlainPluginName, assertWorkspaceExists, assertWorkspaceIsProject, augmentPromptWithPriorOutputs, augmentedPath, bearerHeaderValue, buildConflictRepairPrompt, buildConflictResolutionPrompt, buildConversationSystemPrompt, buildFallbackGrepArgs, buildGlobArgs, buildGrepArgs, buildMergePrompt, buildModifyDuringExecutionPrompt, buildModifyPlanPrompt, buildPlanWithResults, buildResearchPrompt, buildResearchToolsPrompt, buildRunnerInvocation, buildShellInvocation, buildSplitPrompt, buildSubagentSystemPrompt, clampThinkingEffort, classifyCommand, classifyPlannerReply, classifyPluginSource, clearAugmentedPathCache, clearDaemonToken, clearResearchShellCache, clearState, clipboardCopyCommand, coerceAssignments, collectDirectDependencyOutputs, composeAugmentedPrompt, configuredProviders, createAiService, createSkillsService, createWorktreeIsolation, daemonTokenPath, defaultLogger, definitionPattern, deleteSession, describeMergeResult, discoverGeminiModels, effectiveAllowlist, ensureDir, ensureStateDirIgnored, executionLogBlock, extractPrdBlock, extractPresentedToken, filterFallbackByAnchoredInclude, filterModelsForPrompt, formatSearchOutput, generatePlanWithRepair, getLatestSession, getProviderMeta, getSettingsPath, getStateDir, globalDataDir, grantScopeFor, hasTmux, includeGlobFor, isCliProvider, isExecutableResolved, isOpenAiProvider, isPlainPluginName, isValidManifest, killTree, languageForId, listSessions, loadSession, loadSessionPlanState, loadState, mapAgentTool, migrateOldConfigDir, mintDaemonToken, mintSessionId, modelContextBlock, modifyValidationFeedback, normalizeAgentArgs, normalizeGeminiModel, parseTaskQueryJson, pendingEditRulesBlock, planDirectLaunch, planShellLaunch, posixShellQuote, prefixModelId, providerForRunner, reEmitPlanPrompt, reEmitTaskOpsPrompt, reEmitTaskQueryPrompt, readDaemonToken, referencePattern, renderPlanMap, renderPriorOutputs, renderTaskQueryAnswer, repairLoop, researchShellWarning, researchToolsPath, resolveArgs, resolvePluginInstallDir, resolveProviderFromPrefix, resolveResearchShell, resolveSkillInvocation, resolveWithin, retargetTaskRunner, runnerAssignment, runnerForProvider, sanitizeSlug, savePrdMarkdown, saveSession, saveState, sessionRuntimeSettings, stateExists, stripAnsi, stripModelPrefix, summarizeOutput, taskOpsRejectedPrompt, taskQuerySignature, textHasTaskQuery, tmuxSessionName, tmuxSocketName, tmuxWindowName, tokenSubprotocols, tokensMatch, truncatedPlanReEmitPrompt, wellKnownBinDirs, windowsCommandLine, withPath, wrapWithPty };