@ordewell/core 0.4.9 → 0.4.10
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/ModeResolver-Dx5gzNPC.d.ts +44 -0
- package/dist/ModeResolver-F5wnlSz1.d.mts +44 -0
- package/dist/{chunk-SRGQBGI5.mjs → chunk-IO6PEEN6.mjs} +3 -1
- package/dist/{chunk-SRGQBGI5.mjs.map → chunk-IO6PEEN6.mjs.map} +1 -1
- package/dist/{chunk-YXAIQKVE.mjs → chunk-TUGJXD4G.mjs} +2 -2
- package/dist/chunk-YI4ZDZEE.mjs +862 -0
- package/dist/chunk-YI4ZDZEE.mjs.map +1 -0
- package/dist/index.d.mts +170 -17
- package/dist/index.d.ts +170 -17
- package/dist/index.js +1031 -359
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +482 -160
- package/dist/index.mjs.map +1 -1
- package/dist/{parsing-RjN9JbyG.d.ts → parsing-BqbJySeo.d.mts} +5 -43
- package/dist/{parsing-xpozY5ac.d.mts → parsing-X0Gvuz-q.d.ts} +5 -43
- package/dist/parsing.d.mts +2 -1
- package/dist/parsing.d.ts +2 -1
- package/dist/parsing.js.map +1 -1
- package/dist/parsing.mjs +2 -2
- package/dist/{plan-utils-nfHKSbd3.d.mts → plan-utils-B5rVXNVI.d.mts} +27 -5
- package/dist/{plan-utils-Cgc0cCH1.d.ts → plan-utils-DtsfHnn_.d.ts} +27 -5
- package/dist/plan-utils.d.mts +2 -1
- package/dist/plan-utils.d.ts +2 -1
- package/dist/plan-utils.js +1 -9
- package/dist/plan-utils.js.map +1 -1
- package/dist/plan-utils.mjs +2 -2
- package/package.json +1 -1
- package/dist/chunk-4KIWPW4K.mjs +0 -510
- package/dist/chunk-4KIWPW4K.mjs.map +0 -1
- /package/dist/{chunk-YXAIQKVE.mjs.map → chunk-TUGJXD4G.mjs.map} +0 -0
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,15 @@
|
|
|
1
|
-
import { h as RunnerId, c as PlanStatus, L as LegacyPlanState,
|
|
1
|
+
import { h as RunnerId, c as PlanStatus, L as LegacyPlanState, a as DiscoveredModel, T as Task, d as ResearchProgress, R as ResearchLogEntry, C as ConversationMessage, n as TaskSnapshot, Q as QueuedMessage, A as ActiveTaskSession, g as ResearchToolType, u as Verdict, e as ResearchStep, b as PlanState } from './Task-1NwmUImI.js';
|
|
2
2
|
export { D as DiscoveredMode, M as Message, P as PlanModificationWarnings, f as ResearchStepOutcome, S as StreamEvent, i as StreamStepEvent, j as StreamThinkingEvent, k as TaskMode, l as TaskModelAssignment, m as TaskOutputSummary, o as TaskStatus, p as TaskType, q as ThinkingBlock, U as UserPromptEntry, r as UserStep, V as ValidationCheck, s as ValidationContext, t as ValidationResult, v as VerificationCheck, w as addTaskToPlan, x as createEmptyPlan, y as createTask, z as emptyWarnings, B as flattenTasks, E as migrateLegacyPlan, F as migratePlanState, G as migrateTask, H as removeTaskFromPlan, I as renumberTasks, J as updateTaskInPlan, K as validateModifiedPlan, N as warningsText } from './Task-1NwmUImI.js';
|
|
3
3
|
import { n as IFileSystem, I as IApproval, R as ReadFileOpts, T as ToolOutcome, k as GrepOptions, j as GlobOptions, i as FindSymbolOptions, f as ApprovalRequest, m as IConfig, A as AiProvider, z as ProviderModelLists, c as ApprovalMode, q as ITerminalSession, p as ITerminalRunner, K as RunnerRegistry, s as OrchestratorOption, b as ApprovalKind, g as ApprovalSource, H as RunnerInvocation, o as IPluginStore, J as RunnerPluginManifest, E as ResolveContext } from './ITerminalRunner-CbE6gKLI.js';
|
|
4
4
|
export { a as AllProviderModels, d as ApprovalPolicy, e as ApprovalPolicyOptions, C as CatalogModel, D as DENY_ALL, h as DiscoveryCommand, F as FetchAllProviderModelsOptions, G as GREP_DEFAULT_HEAD_LIMIT, l as GrepOutputMode, M as ModelCatalog, r as ModelShortcut, O as ORCHESTRATOR_SHORTCUTS, P as PluginCloneFn, t as PluginEntry, u as PluginFeatures, v as PluginMode, w as PluginModelDiscovery, x as PluginRunnerDef, y as ProviderCredentialSource, B as ProviderModelsResult, S as SEARCH_EXCLUSIONS, L as collectProviderCredentials, N as enabledRunners, Q as fetchAllProviderModels, U as isReservedRunnerName, V as knownModelId, W as resolveModelShortcut, X as resolveProvider, Y as toOrchestratorOptions } from './ITerminalRunner-CbE6gKLI.js';
|
|
5
|
-
import { R as RunnerModeInfo
|
|
6
|
-
export { M as ManifestLookup,
|
|
7
|
-
import { T as TaskOp } from './plan-utils-
|
|
8
|
-
export { A as ApplyTaskOpsResult, a as TaskRef, b as applyTaskOps, c as canMergeTasks, d as canSetDependencies, e as canSplitTask, f as classifyOutcome, g as dependencyCandidates, h as dependentsOf, p as parseTaskOpsJson, s as summarizeToolCall, t as textHasTaskOps } from './plan-utils-
|
|
5
|
+
import { R as RunnerModeInfo } from './ModeResolver-Dx5gzNPC.js';
|
|
6
|
+
export { M as ManifestLookup, b as buildModeGuide, f as filteredBuildModes, r as resolveDefaultMode, a as resolveTaskMode, c as runnerModesFrom } from './ModeResolver-Dx5gzNPC.js';
|
|
7
|
+
import { T as TaskOp } from './plan-utils-DtsfHnn_.js';
|
|
8
|
+
export { A as ApplyTaskOpsResult, a as TaskRef, b as applyTaskOps, c as canMergeTasks, d as canSetDependencies, e as canSplitTask, f as classifyOutcome, g as dependencyCandidates, h as dependentsOf, p as parseTaskOpsJson, s as summarizeToolCall, t as textHasTaskOps } from './plan-utils-DtsfHnn_.js';
|
|
9
9
|
import { ChildProcess } from 'child_process';
|
|
10
10
|
import { EventEmitter } from 'events';
|
|
11
|
+
import { b as PlanParseError } from './parsing-X0Gvuz-q.js';
|
|
12
|
+
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-X0Gvuz-q.js';
|
|
11
13
|
|
|
12
14
|
interface SessionMeta {
|
|
13
15
|
id: string;
|
|
@@ -656,6 +658,65 @@ interface PlannerModes {
|
|
|
656
658
|
researchSubagents: boolean;
|
|
657
659
|
}
|
|
658
660
|
|
|
661
|
+
/**
|
|
662
|
+
* The planner's read channel: a `{"taskQuery":{...}}` reply asking Ordewell to
|
|
663
|
+
* show it what the per-turn plan block deliberately leaves out.
|
|
664
|
+
*
|
|
665
|
+
* The plan block carries only short fields, so a planner asked to "add a line
|
|
666
|
+
* to task 3's prompt" would be rewriting text it has never read. Inlining every
|
|
667
|
+
* body on every turn was rejected — a twenty-task plan re-sends thousands of
|
|
668
|
+
* tokens per message — so the planner asks instead, and pays for the detail
|
|
669
|
+
* only on the turns it uses it.
|
|
670
|
+
*
|
|
671
|
+
* This module owns the wire shape and the rendering of the answer; the loop,
|
|
672
|
+
* the budgets and the injection live in the Session, and the classification
|
|
673
|
+
* lives in PlanRepair alongside the plan and task-ops envelopes.
|
|
674
|
+
*/
|
|
675
|
+
/** The long fields a query may ask for. Everything else is already in the plan block. */
|
|
676
|
+
declare const TASK_QUERY_FIELDS: readonly ["description", "prompt", "userSteps", "verdict", "outputSummary", "userStoriesCovered"];
|
|
677
|
+
type TaskQueryField = typeof TASK_QUERY_FIELDS[number];
|
|
678
|
+
interface TaskQuery {
|
|
679
|
+
/** Task references to read in full — an id, "#order", a bare order, or a title. */
|
|
680
|
+
tasks: string[];
|
|
681
|
+
/** Narrows what comes back. Omitted means every field in {@link TASK_QUERY_FIELDS}. */
|
|
682
|
+
fields?: TaskQueryField[];
|
|
683
|
+
/** Also return the full runner/model catalog with labels, variants and mode descriptions. */
|
|
684
|
+
catalog: boolean;
|
|
685
|
+
}
|
|
686
|
+
declare function textHasTaskQuery(text: string): boolean;
|
|
687
|
+
/** Parse a `{"taskQuery":...}` reply. Throws PlanParseError when the JSON is unusable. */
|
|
688
|
+
declare function parseTaskQueryJson(text: string): TaskQuery;
|
|
689
|
+
/** Stable identity of a query, so a turn can recognise the planner asking the same thing twice. */
|
|
690
|
+
declare function taskQuerySignature(query: TaskQuery): string;
|
|
691
|
+
/** What a full-catalog read is answered from. Models arrive already allowlist-filtered. */
|
|
692
|
+
interface TaskQueryCatalog {
|
|
693
|
+
runners: RunnerId[];
|
|
694
|
+
models: Partial<Record<RunnerId, DiscoveredModel[]>>;
|
|
695
|
+
modes: Record<RunnerId, RunnerModeInfo[]>;
|
|
696
|
+
autonomousDefault: boolean;
|
|
697
|
+
}
|
|
698
|
+
/**
|
|
699
|
+
* Appended when the planner has spent its read budget, or asked the identical
|
|
700
|
+
* question twice. The detail still comes back — refusing it would leave the
|
|
701
|
+
* planner editing text it has not read, which is the whole failure this
|
|
702
|
+
* channel exists to prevent — but the turn is told to land.
|
|
703
|
+
*/
|
|
704
|
+
declare const TASK_QUERY_ANSWER_OR_OPS: string;
|
|
705
|
+
/**
|
|
706
|
+
* The protocol as the planner is taught it, owned here beside the parser so the
|
|
707
|
+
* two cannot drift. Both planner backends get these lines verbatim (ADR-0009):
|
|
708
|
+
* a harness planner has no tool loop to reach, so the envelope is the channel.
|
|
709
|
+
*/
|
|
710
|
+
declare const TASK_QUERY_PROTOCOL: string[];
|
|
711
|
+
/** The one-line reminder the per-turn plan block carries, so the protocol has a single owner. */
|
|
712
|
+
declare const TASK_QUERY_REMINDER = "- To READ a task in full (prompt, user steps, verdict, output, user stories) or the whole model/mode catalog before editing, reply with ONLY {\"taskQuery\":{\"tasks\":[\"<id or #order>\"],\"catalog\":true}} \u2014 it changes nothing, and you then reply again with your ops.";
|
|
713
|
+
/**
|
|
714
|
+
* Render the injected answer to one read. Never persisted — it is context for
|
|
715
|
+
* the planner's next reply and nothing else — so it is built fresh from live
|
|
716
|
+
* state on every query rather than cached.
|
|
717
|
+
*/
|
|
718
|
+
declare function renderTaskQueryAnswer(query: TaskQuery, tasks: Task[], catalog: TaskQueryCatalog): string;
|
|
719
|
+
|
|
659
720
|
declare abstract class AbstractTerminalSession implements ITerminalSession {
|
|
660
721
|
id: string;
|
|
661
722
|
taskId: string;
|
|
@@ -928,6 +989,17 @@ type AgentEvent =
|
|
|
928
989
|
name: string;
|
|
929
990
|
detail: string;
|
|
930
991
|
}
|
|
992
|
+
/**
|
|
993
|
+
* The agent delegated work to a subagent it left running in the background,
|
|
994
|
+
* and may end its turn before that work reports. Ordewell's conversation is
|
|
995
|
+
* request/response: a turn that ends hands control back to the user, and
|
|
996
|
+
* anything the agent says afterwards arrives with no turn open and is lost.
|
|
997
|
+
* Naming the launch is what lets the service ask for the results in time.
|
|
998
|
+
*/
|
|
999
|
+
| {
|
|
1000
|
+
type: 'background_agent';
|
|
1001
|
+
id: string;
|
|
1002
|
+
}
|
|
931
1003
|
/** The agent finished its turn and is waiting for the next user message. */
|
|
932
1004
|
| {
|
|
933
1005
|
type: 'turn_end';
|
|
@@ -1132,9 +1204,11 @@ interface ConversationRequest {
|
|
|
1132
1204
|
}
|
|
1133
1205
|
/**
|
|
1134
1206
|
* One planner turn's outcome. The planner talks to the user (`message`),
|
|
1135
|
-
* commits a full plan (`plan`, a `{tasks:[...]}` JSON object),
|
|
1136
|
-
*
|
|
1137
|
-
*
|
|
1207
|
+
* commits a full plan (`plan`, a `{tasks:[...]}` JSON object), emits targeted
|
|
1208
|
+
* task edits (`task_ops`, a `{taskOps:[...]}` JSON object), or asks to read
|
|
1209
|
+
* task bodies and the full catalog before editing (`task_query`, a
|
|
1210
|
+
* `{taskQuery:{...}}` JSON object). The Session validates and applies task ops
|
|
1211
|
+
* atomically and answers queries out of its own state; the AI service only
|
|
1138
1212
|
* parses them.
|
|
1139
1213
|
*/
|
|
1140
1214
|
type ConversationTurn = {
|
|
@@ -1151,6 +1225,11 @@ type ConversationTurn = {
|
|
|
1151
1225
|
ops: TaskOp[];
|
|
1152
1226
|
text: string;
|
|
1153
1227
|
researchLog: ResearchLogEntry[];
|
|
1228
|
+
} | {
|
|
1229
|
+
kind: 'task_query';
|
|
1230
|
+
query: TaskQuery;
|
|
1231
|
+
text: string;
|
|
1232
|
+
researchLog: ResearchLogEntry[];
|
|
1154
1233
|
};
|
|
1155
1234
|
interface IAiService {
|
|
1156
1235
|
/**
|
|
@@ -1993,12 +2072,19 @@ declare abstract class StdioAgentAdapter implements AgentAdapter {
|
|
|
1993
2072
|
/** Set for the duration of a turn. Outside one, events are buffered rather than dropped. */
|
|
1994
2073
|
private turnEmit;
|
|
1995
2074
|
/**
|
|
1996
|
-
* Events the agent produced
|
|
1997
|
-
* that arrive during the handshake. Dropping them hid the one
|
|
1998
|
-
* that explains a planner which cannot read the workspace, so they
|
|
1999
|
-
* until a turn exists to show them in.
|
|
2075
|
+
* Events the agent produced before its first turn — in practice the startup
|
|
2076
|
+
* warnings that arrive during the handshake. Dropping them hid the one
|
|
2077
|
+
* diagnostic that explains a planner which cannot read the workspace, so they
|
|
2078
|
+
* are held until a turn exists to show them in.
|
|
2079
|
+
*
|
|
2080
|
+
* Only before the *first* turn. Once one has run, anything arriving outside a
|
|
2081
|
+
* turn is that closed turn's straggling work — a backgrounded subagent
|
|
2082
|
+
* finishing, a late read — and replaying it into the next turn presents it as
|
|
2083
|
+
* research done for the user's new message.
|
|
2000
2084
|
*/
|
|
2001
2085
|
private betweenTurns;
|
|
2086
|
+
/** Set once a turn has ended: after that, out-of-turn events are stale, not startup. */
|
|
2087
|
+
private hadTurn;
|
|
2002
2088
|
private disposed;
|
|
2003
2089
|
/** Resolves when the process ends, so a handshake can lose the race instead of waiting out its timeout. */
|
|
2004
2090
|
protected processEnded: Promise<void>;
|
|
@@ -2041,6 +2127,8 @@ declare abstract class StdioAgentAdapter implements AgentAdapter {
|
|
|
2041
2127
|
*/
|
|
2042
2128
|
declare class ClaudeCodeAdapter extends StdioAgentAdapter {
|
|
2043
2129
|
readonly agentId = "claude-code";
|
|
2130
|
+
/** Whether this turn has already emitted reply text — see {@link handleLine}. */
|
|
2131
|
+
private turnHasText;
|
|
2044
2132
|
protected spawnSpec(opts: AgentStartOptions): SpawnSpec;
|
|
2045
2133
|
protected turnPayload(message: string): string;
|
|
2046
2134
|
protected handleLine(line: string, emit: (event: AgentEvent) => void): void;
|
|
@@ -2127,6 +2215,8 @@ declare class OpenCodeAdapter implements AgentAdapter {
|
|
|
2127
2215
|
private exited;
|
|
2128
2216
|
private disposed;
|
|
2129
2217
|
private opts;
|
|
2218
|
+
/** Whether this turn has already emitted reply text — see {@link emitPart}. */
|
|
2219
|
+
private turnHasText;
|
|
2130
2220
|
constructor(deps: AgentProcessDeps);
|
|
2131
2221
|
start(opts: AgentStartOptions): Promise<void>;
|
|
2132
2222
|
send(message: string, onEvent: (event: AgentEvent) => void, signal?: AbortSignal): Promise<void>;
|
|
@@ -2475,6 +2565,15 @@ declare class Session {
|
|
|
2475
2565
|
*/
|
|
2476
2566
|
reset(): void;
|
|
2477
2567
|
private runnerModesFor;
|
|
2568
|
+
/**
|
|
2569
|
+
* The catalog a model/task-mode edit is checked against — the same
|
|
2570
|
+
* discovered models and manifest modes the per-turn catalog block shows the
|
|
2571
|
+
* planner, so a refusal here can never name something invalid that the
|
|
2572
|
+
* planner was never told about. `modelsCache` is read live, not filtered by
|
|
2573
|
+
* the allowlist here — {@link checkModelAndModeValidity} narrows by
|
|
2574
|
+
* allowlist itself, the same way `coerceAssignments` does.
|
|
2575
|
+
*/
|
|
2576
|
+
private editCatalog;
|
|
2478
2577
|
get planState(): LegacyPlanState | null;
|
|
2479
2578
|
/**
|
|
2480
2579
|
* The live plan in the shape a saved session is read back as. The disk
|
|
@@ -2517,6 +2616,26 @@ declare class Session {
|
|
|
2517
2616
|
* answers, PRD accept/adjust, outline confirm. One branch, no phase ladder.
|
|
2518
2617
|
*/
|
|
2519
2618
|
continueConversation(userMessage: string, options?: GeneratePlanOptions): Promise<LegacyPlanState>;
|
|
2619
|
+
/**
|
|
2620
|
+
* Answer every read the planner emits until it says something else.
|
|
2621
|
+
*
|
|
2622
|
+
* The channel is a text envelope rather than a registered tool because the
|
|
2623
|
+
* protocol has to be identical on both planner backends (ADR-0009): Ordewell
|
|
2624
|
+
* owns a tool loop only in the API case, and a harness planner running as a
|
|
2625
|
+
* coding-agent subprocess can only be reached this way.
|
|
2626
|
+
*
|
|
2627
|
+
* Draining here — outside {@link repairLoop} — is what keeps reads free of
|
|
2628
|
+
* the repair budget. A planner that looks a task up and *then* fumbles its
|
|
2629
|
+
* ops JSON still gets its two corrective retries; charging it for the read
|
|
2630
|
+
* would cost it the chance to fix the edit.
|
|
2631
|
+
*/
|
|
2632
|
+
private drainTaskQueries;
|
|
2633
|
+
/**
|
|
2634
|
+
* Render one read out of live state. Never persisted to the transcript: the
|
|
2635
|
+
* detail is context for the planner's next reply, and re-sending it on every
|
|
2636
|
+
* later turn is exactly the cost this channel exists to avoid.
|
|
2637
|
+
*/
|
|
2638
|
+
private taskQueryAnswer;
|
|
2520
2639
|
/**
|
|
2521
2640
|
* Drive a planner turn to a persisted, broadcast outcome. Task edits apply
|
|
2522
2641
|
* atomically; validation failures are fed back to the model for up to 2
|
|
@@ -2525,6 +2644,24 @@ declare class Session {
|
|
|
2525
2644
|
* path, not two.
|
|
2526
2645
|
*/
|
|
2527
2646
|
private settleTurn;
|
|
2647
|
+
/**
|
|
2648
|
+
* The catalog the planner may actually draw from — model ids and task-mode
|
|
2649
|
+
* ids, per selected runner — emitted on EVERY turn, before any plan exists
|
|
2650
|
+
* or after. The system prompt shows this once at conversation start; a long
|
|
2651
|
+
* grill-me interview or PRD negotiation outlives that single showing and the
|
|
2652
|
+
* planner starts misquoting it, so this re-states it per turn instead.
|
|
2653
|
+
*
|
|
2654
|
+
* Built from the allowlist-filtered view (`filterModelsForPrompt`), the same
|
|
2655
|
+
* one the system prompt used — a restricted allowlist stays a hard bound on
|
|
2656
|
+
* every turn, not just the first. `this.modelsCache` itself is never
|
|
2657
|
+
* filtered: `coerceAssignments` needs the full discovered catalog alongside
|
|
2658
|
+
* the allowlist to resolve labels and clamp effort to real variants.
|
|
2659
|
+
*
|
|
2660
|
+
* Reads `this.plan.runners` live, so a runner admitted mid-session by a
|
|
2661
|
+
* retarget (`admitRunner`) is filtered and shown like every other — there is
|
|
2662
|
+
* no separate "originally selected" list to fall stale.
|
|
2663
|
+
*/
|
|
2664
|
+
private catalogBlock;
|
|
2528
2665
|
/**
|
|
2529
2666
|
* The "you are here" block for post-plan chat: current tasks with stable
|
|
2530
2667
|
* references, plus the task-ops protocol. Injected per turn (never
|
|
@@ -2594,10 +2731,14 @@ declare class Session {
|
|
|
2594
2731
|
*/
|
|
2595
2732
|
private editPlan;
|
|
2596
2733
|
/**
|
|
2597
|
-
* Patch one task's fields. A hand-set dependency list
|
|
2598
|
-
*
|
|
2599
|
-
*
|
|
2600
|
-
*
|
|
2734
|
+
* Patch one task's fields. A hand-set dependency list, or a type flip
|
|
2735
|
+
* between AI and MAN, are the patches that can leave a task incoherent
|
|
2736
|
+
* (unschedulable, or carrying fields that mean nothing for its new type),
|
|
2737
|
+
* so both go through the same {@link validateTaskEdit} guard the planner's
|
|
2738
|
+
* task-ops applier uses (as the 'direct' actor, which skips the lock rule)
|
|
2739
|
+
* rather than a second copy of the rules — and throws, so the surface can
|
|
2740
|
+
* say why. Gated on the task existing so an edit to an unknown id still
|
|
2741
|
+
* falls through to the no-op `store.update` below instead of throwing.
|
|
2601
2742
|
*/
|
|
2602
2743
|
updateTask(taskId: string, changes: Partial<Task>): Promise<LegacyPlanState | null>;
|
|
2603
2744
|
/**
|
|
@@ -2885,6 +3026,8 @@ declare function reEmitPlanPrompt(detail: string): string;
|
|
|
2885
3026
|
declare function truncatedPlanReEmitPrompt(historyCompacted: boolean): string;
|
|
2886
3027
|
/** A task-ops attempt was botched (unparseable JSON): re-emit the ops object. */
|
|
2887
3028
|
declare function reEmitTaskOpsPrompt(detail: string): string;
|
|
3029
|
+
/** A read attempt was botched (unparseable or unknown selector): re-emit the query object. */
|
|
3030
|
+
declare function reEmitTaskQueryPrompt(detail: string): string;
|
|
2888
3031
|
/** Task ops parsed but failed semantic validation (cycles, unknown refs, locked tasks). */
|
|
2889
3032
|
declare function taskOpsRejectedPrompt(errors: string[]): string;
|
|
2890
3033
|
/** A modified plan failed validation during execution: full re-prompt feedback block. */
|
|
@@ -2896,6 +3039,11 @@ type PlannerReplyClassification = {
|
|
|
2896
3039
|
kind: 'task_ops';
|
|
2897
3040
|
ops: TaskOp[];
|
|
2898
3041
|
}
|
|
3042
|
+
/** A read: show me these tasks in full (and/or the whole catalog) before I edit anything. */
|
|
3043
|
+
| {
|
|
3044
|
+
kind: 'task_query';
|
|
3045
|
+
query: TaskQuery;
|
|
3046
|
+
}
|
|
2899
3047
|
/** Clearly attempted a plan (tasks-keyed object, or JSON cut off mid-stream) and botched it — worth a corrective retry. */
|
|
2900
3048
|
| {
|
|
2901
3049
|
kind: 'broken_plan';
|
|
@@ -2905,6 +3053,11 @@ type PlannerReplyClassification = {
|
|
|
2905
3053
|
| {
|
|
2906
3054
|
kind: 'broken_task_ops';
|
|
2907
3055
|
error: PlanParseError;
|
|
3056
|
+
}
|
|
3057
|
+
/** Clearly attempted a read and botched it — worth a corrective retry. */
|
|
3058
|
+
| {
|
|
3059
|
+
kind: 'broken_task_query';
|
|
3060
|
+
error: PlanParseError;
|
|
2908
3061
|
} | {
|
|
2909
3062
|
kind: 'prose';
|
|
2910
3063
|
};
|
|
@@ -3492,4 +3645,4 @@ declare class PlannerModelMemory {
|
|
|
3492
3645
|
recall(provider: string, catalog: PlannerModelCandidate[]): PlannerModelRecall;
|
|
3493
3646
|
}
|
|
3494
3647
|
|
|
3495
|
-
export { ALLOWED_PLUGIN_HOSTS, ALL_PROVIDERS, AUTO_COMMANDS, AbstractRunner, AbstractTerminalSession, ActiveTaskSession, type AgentAdapter, type AgentAdapterFactory, type AgentEvent, type AgentProcessDeps, type AgentStartOptions, AiProvider, ApprovalKind, ApprovalMode, ApprovalRequest, ApprovalSource, BaseAiService, BaseConfig, BaseFileSystem, 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, ConversationMessage, type ConversationRequest, type ConversationTurn, DAEMON_SUBPROTOCOL, DAEMON_TOKEN_SUBPROTOCOL_PREFIX, DiscoveredModel, EmbeddedNewlineError, type EnvAdmission, EnvConfig, type ExecFileFn, type ExecImpl, ExecutableNotFoundError, FindSymbolOptions, FsPluginStore, GIT_READONLY_SUBCOMMANDS, GeminiService, GlobOptions, type GrepInvocation, GrepOptions, type HasBinFn, HeadlessRunner, type HeadlessRunnerDeps, HeadlessSession, type IAiService, IApproval, IConfig, IFileSystem, type ILogger, type INotification, IPluginStore, ITerminalRunner, ITerminalSession, JSON_REPAIR_INSTRUCTION, type KillTreeDeps, type LaunchDeps, type LaunchPlan, LegacyPlanState, LineBuffer, type MappedTool, ModelResolver, type ModelResolverDeps, type ModifyPlanRequest, type NotificationAction, OPENCODE_MANIFEST, ORDEWELL_SETTABLE_ENV, 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, 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, QueuedMessage, REFUSED_COMMANDS, ReadFileOpts, type RepairLoopOpts, type RepairVerdict, type ResearchChat, ResearchLogEntry, ResearchProgress, type ResearchShell, type ResearchShellDeps, ResearchStep, ResearchToolType, type ResearchTurn, ResolveContext, 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, type SerializedPlan, type SerializedTask, type SerializedTaskStatus, Session, type SessionBroadcaster, type SessionData, type SessionDeps, type SessionMessage, type SessionMeta, type SessionPlanner, type SessionRuntimeSettings, SettingsService, type ShellDialect, type SpawnSpec, StdioAgentAdapter, TRUNCATED_PLAN_REPAIR_INSTRUCTION, Task, TaskOp, TaskOrchestrator, TaskSnapshot, TmuxRunner, type TmuxRunnerDeps, type TokenCarriers, type ToolCall, ToolOutcome, type ToolResult, type UserSettings, Verdict, VerdictEngine, type VerdictListener, WINDOWS_MAX_COMMAND_LINE, type WorkspaceCheckDeps, WorkspaceNotAProjectError, WorkspaceNotFoundError, type WorkspaceProjectCheckDeps, admitSettingsEnv, applyHeadLimit, assertInstallablePluginUrl, assertPlainPluginName, assertWorkspaceExists, assertWorkspaceIsProject, augmentPromptWithPriorOutputs, augmentedPath, bearerHeaderValue, 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, daemonTokenPath, defaultLogger, definitionPattern, deleteSession, discoverGeminiModels, effectiveAllowlist, ensureDir, ensureStateDirIgnored, executionLogBlock, executionSummary, extractPrdBlock, extractPresentedToken, filterFallbackByAnchoredInclude, filterModelsForPrompt, formatSearchOutput, generatePlanWithRepair, getLatestSession, getProviderMeta, getSettingsPath, getStateDir, grantScopeFor, hasTmux, includeGlobFor, isCliProvider, isExecutableResolved, isOpenAiProvider, isPlainPluginName, isValidManifest, killTree, languageForId, listSessions, loadSession, loadSessionPlanState, loadState, mapAgentTool, mintDaemonToken, mintSessionId, modelContextBlock, modifyValidationFeedback, normalizeAgentArgs, normalizeGeminiModel, pendingEditRulesBlock, planDirectLaunch, planShellLaunch, posixShellQuote, prefixModelId, providerForRunner, reEmitPlanPrompt, reEmitTaskOpsPrompt, readDaemonToken, referencePattern, renderPlanMap, renderPriorOutputs, repairLoop, researchShellWarning, researchToolsPath, resolveArgs, resolvePluginInstallDir, resolveProviderFromPrefix, resolveResearchShell, resolveWithin, retargetTaskRunner, runnerAssignment, runnerForProvider, sanitizeSlug, savePrdMarkdown, saveSession, saveState, serializePlan, serializeTask, serializeTaskStatus, sessionRuntimeSettings, stateExists, stripAnsi, stripModelPrefix, summarizeOutput, taskOpsRejectedPrompt, tmuxSessionName, tmuxSocketName, tmuxWindowName, tokenSubprotocols, tokensMatch, truncatedPlanReEmitPrompt, wellKnownBinDirs, windowsCommandLine, withPath, wrapWithPty };
|
|
3648
|
+
export { ALLOWED_PLUGIN_HOSTS, ALL_PROVIDERS, AUTO_COMMANDS, AbstractRunner, AbstractTerminalSession, ActiveTaskSession, type AgentAdapter, type AgentAdapterFactory, type AgentEvent, type AgentProcessDeps, type AgentStartOptions, AiProvider, ApprovalKind, ApprovalMode, ApprovalRequest, ApprovalSource, BaseAiService, BaseConfig, BaseFileSystem, 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, ConversationMessage, type ConversationRequest, type ConversationTurn, DAEMON_SUBPROTOCOL, DAEMON_TOKEN_SUBPROTOCOL_PREFIX, DiscoveredModel, EmbeddedNewlineError, type EnvAdmission, EnvConfig, type ExecFileFn, type ExecImpl, ExecutableNotFoundError, FindSymbolOptions, FsPluginStore, GIT_READONLY_SUBCOMMANDS, GeminiService, GlobOptions, type GrepInvocation, GrepOptions, type HasBinFn, HeadlessRunner, type HeadlessRunnerDeps, HeadlessSession, type IAiService, IApproval, IConfig, IFileSystem, type ILogger, type INotification, IPluginStore, ITerminalRunner, ITerminalSession, JSON_REPAIR_INSTRUCTION, type KillTreeDeps, type LaunchDeps, type LaunchPlan, LegacyPlanState, LineBuffer, type MappedTool, ModelResolver, type ModelResolverDeps, type ModifyPlanRequest, type NotificationAction, OPENCODE_MANIFEST, ORDEWELL_SETTABLE_ENV, 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, 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, QueuedMessage, REFUSED_COMMANDS, ReadFileOpts, type RepairLoopOpts, type RepairVerdict, type ResearchChat, ResearchLogEntry, ResearchProgress, type ResearchShell, type ResearchShellDeps, ResearchStep, ResearchToolType, type ResearchTurn, ResolveContext, 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, type SerializedPlan, type SerializedTask, type SerializedTaskStatus, Session, type SessionBroadcaster, type SessionData, type SessionDeps, type SessionMessage, type SessionMeta, type SessionPlanner, type SessionRuntimeSettings, SettingsService, type ShellDialect, type SpawnSpec, StdioAgentAdapter, TASK_QUERY_ANSWER_OR_OPS, TASK_QUERY_FIELDS, TASK_QUERY_PROTOCOL, TASK_QUERY_REMINDER, TRUNCATED_PLAN_REPAIR_INSTRUCTION, Task, TaskOp, TaskOrchestrator, type TaskQuery, type TaskQueryCatalog, type TaskQueryField, TaskSnapshot, TmuxRunner, type TmuxRunnerDeps, type TokenCarriers, type ToolCall, ToolOutcome, type ToolResult, type UserSettings, Verdict, VerdictEngine, type VerdictListener, WINDOWS_MAX_COMMAND_LINE, type WorkspaceCheckDeps, WorkspaceNotAProjectError, WorkspaceNotFoundError, type WorkspaceProjectCheckDeps, admitSettingsEnv, applyHeadLimit, assertInstallablePluginUrl, assertPlainPluginName, assertWorkspaceExists, assertWorkspaceIsProject, augmentPromptWithPriorOutputs, augmentedPath, bearerHeaderValue, 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, daemonTokenPath, defaultLogger, definitionPattern, deleteSession, discoverGeminiModels, effectiveAllowlist, ensureDir, ensureStateDirIgnored, executionLogBlock, executionSummary, extractPrdBlock, extractPresentedToken, filterFallbackByAnchoredInclude, filterModelsForPrompt, formatSearchOutput, generatePlanWithRepair, getLatestSession, getProviderMeta, getSettingsPath, getStateDir, grantScopeFor, hasTmux, includeGlobFor, isCliProvider, isExecutableResolved, isOpenAiProvider, isPlainPluginName, isValidManifest, killTree, languageForId, listSessions, loadSession, loadSessionPlanState, loadState, mapAgentTool, 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, resolveWithin, retargetTaskRunner, runnerAssignment, runnerForProvider, sanitizeSlug, savePrdMarkdown, saveSession, saveState, serializePlan, serializeTask, serializeTaskStatus, sessionRuntimeSettings, stateExists, stripAnsi, stripModelPrefix, summarizeOutput, taskOpsRejectedPrompt, taskQuerySignature, textHasTaskQuery, tmuxSessionName, tmuxSocketName, tmuxWindowName, tokenSubprotocols, tokensMatch, truncatedPlanReEmitPrompt, wellKnownBinDirs, windowsCommandLine, withPath, wrapWithPty };
|