agent-afk 5.328.2 → 5.330.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent/agents/index.d.ts +1 -1
- package/dist/agent/agents/tool-def.d.ts +1 -0
- package/dist/agent/hooks.d.ts +2 -0
- package/dist/agent/providers/anthropic-direct/query/prompt-assembly.d.ts +1 -0
- package/dist/agent/providers/anthropic-direct/query/system-prompt.d.ts +1 -0
- package/dist/agent/providers/openai-compatible/query/turn-driver.d.ts +2 -1
- package/dist/agent/providers/openai-compatible/system-prompt-wiring.d.ts +1 -0
- package/dist/agent/safe-destruct-detect.d.ts +2 -1
- package/dist/agent/session/agent-session.lifecycle.d.ts +2 -0
- package/dist/agent/session/model-slots.utils.d.ts +1 -2
- package/dist/agent/subagent/continuation-guards.d.ts +28 -0
- package/dist/agent/subagent/continuation-registry.d.ts +85 -0
- package/dist/agent/subagent/fork-lifecycle.d.ts +5 -0
- package/dist/agent/subagent/fork-resolution.d.ts +2 -1
- package/dist/agent/subagent/fork-types.d.ts +7 -1
- package/dist/agent/subagent/handle.d.ts +1 -0
- package/dist/agent/subagent/handle.streaming.d.ts +1 -0
- package/dist/agent/subagent/identity-preamble.d.ts +2 -0
- package/dist/agent/subagent/result.d.ts +8 -0
- package/dist/agent/tools/handlers/lsp-shared.d.ts +1 -0
- package/dist/agent/tools/handlers/lsp-symbols.d.ts +4 -2
- package/dist/agent/tools/schemas.order.d.ts +1 -1
- package/dist/agent/tools/subagent/child-config.d.ts +1 -0
- package/dist/agent/tools/subagent/continuation-dispatch.d.ts +88 -0
- package/dist/agent/tools/subagent/continuation-run.d.ts +33 -0
- package/dist/agent/tools/subagent/foreground-promotion.d.ts +1 -0
- package/dist/agent/tools/subagent/input-parse.d.ts +1 -0
- package/dist/agent/tools/subagent-executor/types.d.ts +1 -0
- package/dist/agent/tools/subagent-executor.d.ts +1 -0
- package/dist/agent/tools/subagent-executor.execute-once.d.ts +2 -1
- package/dist/agent/tools/subagent-executor.execute-once.gates.d.ts +8 -0
- package/dist/agent/tools/subagent-executor.execute-once.helpers.d.ts +1 -0
- package/dist/agent/tools/subagent-executor.execute-once.remote.d.ts +3 -0
- package/dist/agent/trace/events.d.ts +10 -0
- package/dist/agent/trace/events.session-phase.d.ts +4 -0
- package/dist/agent/trace/events.subagent-lifecycle.d.ts +6 -0
- package/dist/agent/trace/types.d.ts +3 -0
- package/dist/agent/trace/types.session-phase.d.ts +1 -1
- package/dist/agent/types/session-types.d.ts +5 -0
- package/dist/bundled-plugins/awa-bundled/skills/refactor/SKILL.md +1 -1
- package/dist/cli/commands/interactive/tool-lane-format-bash-family.d.ts +3 -0
- package/dist/cli/commands/interactive/tool-lane-format-bash.d.ts +9 -0
- package/dist/cli/palette.d.ts +3 -0
- package/dist/cli.mjs +444 -433
- package/dist/config/env.continuation.d.ts +17 -0
- package/dist/config/env.d.ts +24 -0
- package/dist/config/env.tools.d.ts +8 -0
- package/dist/improve/eval-run/contracts.sab.d.ts +4 -0
- package/dist/improve/eval-run/runner.d.ts +2 -0
- package/dist/index.mjs +229 -222
- package/dist/telegram/handlers/insights.d.ts +3 -1
- package/dist/telegram.mjs +250 -243
- package/dist/web-server/command-gate.d.ts +2 -0
- package/dist/web-server/routes.commands.d.ts +6 -0
- package/dist/web-server/routes.d.ts +1 -0
- package/dist/web-server/session-owner.autosave.d.ts +1 -1
- package/dist/web-server/session-owner.d.ts +1 -0
- package/dist/web-server/session-owner.slash.d.ts +11 -0
- package/dist/web-server/shared/command-wire.d.ts +24 -0
- package/dist/web-server/slash-context.web.d.ts +5 -0
- package/dist/web-server/slash-dispatch.d.ts +2 -0
- package/dist/web-server/slash-registry.d.ts +2 -0
- package/dist/web-server/writer.buffer.d.ts +11 -0
- package/dist/web-ui-assets/assets/{angular-html-CC3lIXKP.js → angular-html-DstdpUqJ.js} +1 -1
- package/dist/web-ui-assets/assets/{angular-ts-B55StdDa.js → angular-ts--ZQlERbq.js} +1 -1
- package/dist/web-ui-assets/assets/{apl-CodQVCEj.js → apl-DA1d-c4u.js} +1 -1
- package/dist/web-ui-assets/assets/{astro-D_fPYeDd.js → astro-BI2EXHYx.js} +1 -1
- package/dist/web-ui-assets/assets/{blade-BNccT06L.js → blade-ZMs7qeoC.js} +1 -1
- package/dist/web-ui-assets/assets/{c-C-qzdgmp.js → c-C6TcqW_H.js} +1 -1
- package/dist/web-ui-assets/assets/{chapel-DsZFg65P.js → chapel-9FMsQky4.js} +1 -1
- package/dist/web-ui-assets/assets/{cobol-B2ulHFSx.js → cobol-BZH-GKgp.js} +1 -1
- package/dist/web-ui-assets/assets/{coffee-D0yCs5eE.js → coffee-CLaEmmJx.js} +1 -1
- package/dist/web-ui-assets/assets/{cpp-Bxbsp_nz.js → cpp-Bj3Zkt25.js} +1 -1
- package/dist/web-ui-assets/assets/{crystal-BY2bY632.js → crystal-Ddsq7z4p.js} +1 -1
- package/dist/web-ui-assets/assets/{css-DCCzboh8.js → css-DxguajHw.js} +1 -1
- package/dist/web-ui-assets/assets/{dist-UwYaNxlm.js → dist-Dze9FWYd.js} +2 -2
- package/dist/web-ui-assets/assets/{edge-9TiGLit-.js → edge-DrSIr9wQ.js} +1 -1
- package/dist/web-ui-assets/assets/{elixir-B83WkyBZ.js → elixir-BIDAnpuG.js} +1 -1
- package/dist/web-ui-assets/assets/{elm-jejqKQFX.js → elm-B75HTYQR.js} +1 -1
- package/dist/web-ui-assets/assets/{erb-CJKGWEWI.js → erb-DzDzzMBx.js} +1 -1
- package/dist/web-ui-assets/assets/{git-rebase-ob6EunlV.js → git-rebase-DQxmfkdA.js} +1 -1
- package/dist/web-ui-assets/assets/{glimmer-js-DRRkpqBC.js → glimmer-js-Bz1hBKOO.js} +1 -1
- package/dist/web-ui-assets/assets/{glimmer-ts-DdPZl6xW.js → glimmer-ts-BwidATwh.js} +1 -1
- package/dist/web-ui-assets/assets/{glsl-D1CrBs2Z.js → glsl-BPubH4Yr.js} +1 -1
- package/dist/web-ui-assets/assets/{graphql-DOEPJbJj.js → graphql-K_od5qE9.js} +1 -1
- package/dist/web-ui-assets/assets/{hack-Bhnm8i0e.js → hack-BdxCTdfu.js} +1 -1
- package/dist/web-ui-assets/assets/{haml-Bmonj8m3.js → haml-Uk7td7aJ.js} +1 -1
- package/dist/web-ui-assets/assets/{handlebars-D7Ai8STP.js → handlebars-Cux2s7cw.js} +1 -1
- package/dist/web-ui-assets/assets/{html-CSHkoXuE.js → html-MrEarUDb.js} +1 -1
- package/dist/web-ui-assets/assets/{html-derivative-N9AU_aiL.js → html-derivative-AZFgQZNG.js} +1 -1
- package/dist/web-ui-assets/assets/{http-yFDJl3gv.js → http-ChXH1Vix.js} +1 -1
- package/dist/web-ui-assets/assets/{hurl-CIGeOBK2.js → hurl-tZM-zRVL.js} +1 -1
- package/dist/web-ui-assets/assets/index-BTPdNino.css +2 -0
- package/dist/web-ui-assets/assets/index-CHknBrIe.js +86 -0
- package/dist/web-ui-assets/assets/{java-Ar_hCEd5.js → java-B_Ff6LfQ.js} +1 -1
- package/dist/web-ui-assets/assets/{javascript-CAN1vxRM.js → javascript-Bk1Ckb1o.js} +1 -1
- package/dist/web-ui-assets/assets/{jinja-CUnd_v0D.js → jinja-BbXj58a5.js} +1 -1
- package/dist/web-ui-assets/assets/{jison-DkTpZHxU.js → jison-BnfuW5zg.js} +1 -1
- package/dist/web-ui-assets/assets/{json-4JHHm6tv.js → json-CG4eymVn.js} +1 -1
- package/dist/web-ui-assets/assets/{jsx-B_H-_0Li.js → jsx-BlcGKASI.js} +1 -1
- package/dist/web-ui-assets/assets/{julia-dnSsLWEc.js → julia-BLD9fhRy.js} +1 -1
- package/dist/web-ui-assets/assets/{just-CEwIOa2N.js → just-c7u3pqSR.js} +1 -1
- package/dist/web-ui-assets/assets/{latex-B1ICfqDe.js → latex-vuUgVJqz.js} +1 -1
- package/dist/web-ui-assets/assets/{liquid-B1fj2wiT.js → liquid-ByXaqjkG.js} +1 -1
- package/dist/web-ui-assets/assets/{lua-CQf9tEbB.js → lua-CKmgvTDc.js} +1 -1
- package/dist/web-ui-assets/assets/{marko-B14iEITE.js → marko-C3ky0MWx.js} +1 -1
- package/dist/web-ui-assets/assets/{mdc-_KQwbym8.js → mdc-B64U3tqF.js} +1 -1
- package/dist/web-ui-assets/assets/{nginx-ClNzgFQl.js → nginx-C90tAf8x.js} +1 -1
- package/dist/web-ui-assets/assets/{nim-Dw8QObp-.js → nim-CYtid-ea.js} +1 -1
- package/dist/web-ui-assets/assets/{org-B51yx_Tx.js → org-BI_L1rME.js} +1 -1
- package/dist/web-ui-assets/assets/{perl-DLCCwaC1.js → perl-DdEy98bA.js} +1 -1
- package/dist/web-ui-assets/assets/{php-CL-uaO29.js → php-C-GxuMEl.js} +1 -1
- package/dist/web-ui-assets/assets/{pug-DkBENREJ.js → pug-CtWAZuVY.js} +1 -1
- package/dist/web-ui-assets/assets/{qml-ClbJFFI5.js → qml-D5yRCrVl.js} +1 -1
- package/dist/web-ui-assets/assets/{r-XUrK4grx.js → r-Db7j7yK9.js} +1 -1
- package/dist/web-ui-assets/assets/{razor-DqSMwGmL.js → razor-aYp5Guo-.js} +1 -1
- package/dist/web-ui-assets/assets/{regexp-BSFJ_-TJ.js → regexp-6uSK8pdU.js} +1 -1
- package/dist/web-ui-assets/assets/{rst-B7tMGYn-.js → rst-DSxMNPBG.js} +1 -1
- package/dist/web-ui-assets/assets/{ruby-BYrWHkBB.js → ruby-B_YQuMec.js} +1 -1
- package/dist/web-ui-assets/assets/{sas-D-Mi-ZRr.js → sas-M2CyVhwb.js} +1 -1
- package/dist/web-ui-assets/assets/{scss-55HhYd4M.js → scss-DXRgFgmQ.js} +1 -1
- package/dist/web-ui-assets/assets/{shellscript-WUEN4iWi.js → shellscript-DBPquDVd.js} +1 -1
- package/dist/web-ui-assets/assets/{shellsession-Ciheliad.js → shellsession-DBSRVvdy.js} +1 -1
- package/dist/web-ui-assets/assets/{soy-CafU_uPV.js → soy-7cKQNIH5.js} +1 -1
- package/dist/web-ui-assets/assets/{sql-DeKe_haY.js → sql-Eomc9xJE.js} +1 -1
- package/dist/web-ui-assets/assets/{stata-BBkdAkCn.js → stata-CVsCl2Q7.js} +1 -1
- package/dist/web-ui-assets/assets/{surrealql-wu5RlJnG.js → surrealql-CNHwzmzE.js} +1 -1
- package/dist/web-ui-assets/assets/{svelte-DxIeVq8R.js → svelte-D1kVfiMi.js} +1 -1
- package/dist/web-ui-assets/assets/{templ-Lj5RUv5J.js → templ-CY0baYpe.js} +1 -1
- package/dist/web-ui-assets/assets/{tex-9jYK7mHi.js → tex-CKNqH5xl.js} +1 -1
- package/dist/web-ui-assets/assets/{ts-tags-BuzwQUez.js → ts-tags-2YP65O09.js} +1 -1
- package/dist/web-ui-assets/assets/{tsx-UsxPa86A.js → tsx-DMj32x8W.js} +1 -1
- package/dist/web-ui-assets/assets/{twig-B51i7Ozb.js → twig-Dx7tn1oz.js} +1 -1
- package/dist/web-ui-assets/assets/{typescript-DMHh-0ba.js → typescript-BjZXK-hy.js} +1 -1
- package/dist/web-ui-assets/assets/{typst-BOD5AJSC.js → typst-D7ldBl4E.js} +1 -1
- package/dist/web-ui-assets/assets/{vue-uYltmeEy.js → vue-DQnTvAjS.js} +1 -1
- package/dist/web-ui-assets/assets/{vue-html-B9IwtKYs.js → vue-html-BIgFCNvD.js} +1 -1
- package/dist/web-ui-assets/assets/{vue-vine-DLZ0OiIA.js → vue-vine-DXncxst0.js} +1 -1
- package/dist/web-ui-assets/assets/{xml-hKTv5UOt.js → xml-Cq923i6L.js} +1 -1
- package/dist/web-ui-assets/assets/{xsl-CQdCmkQ2.js → xsl-C8IANOxG.js} +1 -1
- package/dist/web-ui-assets/assets/{yaml-CUNK3s1f.js → yaml-10xbdA0J.js} +1 -1
- package/dist/web-ui-assets/index.html +2 -2
- package/package.json +1 -1
- package/dist/web-ui-assets/assets/index-Bx-32Qg4.css +0 -2
- package/dist/web-ui-assets/assets/index-zkBC82Wl.js +0 -85
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export type { AgentRegistry, RegisteredAgent, } from './types.js';
|
|
2
2
|
export { resolveAgentToolAccess } from './resolve.js';
|
|
3
3
|
export { loadAgentRegistry } from './registry.js';
|
|
4
|
-
export { buildAgentToolDef } from './tool-def.js';
|
|
4
|
+
export { buildAgentToolDef, buildAgentTypeListing } from './tool-def.js';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import type { AnthropicToolDef } from '../tools/types.js';
|
|
2
2
|
import type { AgentRegistry } from './types.js';
|
|
3
3
|
export declare function buildAgentToolDef(registry: AgentRegistry | undefined): AnthropicToolDef;
|
|
4
|
+
export declare function buildAgentTypeListing(registry: AgentRegistry | undefined): string;
|
package/dist/agent/hooks.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { ProviderEvent, ProviderUserTurn } from '../../../provider.js';
|
|
|
2
2
|
import { type IterationContext, type FinishTurnContext } from './turn-iteration.js';
|
|
3
3
|
import type { AbortCoordinator } from '../../shared/abort-coordinator.js';
|
|
4
4
|
import type { ToolDispatcher } from '../../anthropic-direct/tool-dispatcher.js';
|
|
5
|
-
import type { TraceSink } from '../../../trace/
|
|
5
|
+
import type { TraceSink } from '../../../trace/writer.js';
|
|
6
6
|
import type { OpenAIMessage } from '../messages.js';
|
|
7
7
|
import type { OpenAIJournalWiring } from './journal-wiring.js';
|
|
8
8
|
import type { AgentConfig } from '../../../types/config-types.js';
|
|
@@ -28,4 +28,5 @@ export interface TurnDriverContext extends IterationContext, FinishTurnContext {
|
|
|
28
28
|
}
|
|
29
29
|
export declare function applyBeforeNextRound(priorTurns: OpenAIMessage[], steeringText: string | undefined, traceWriter: TraceSink | undefined, subagentId: string | undefined): void;
|
|
30
30
|
export declare function applyAndSyncSteering(ctx: TurnDriverContext): void;
|
|
31
|
+
export declare function injectRoundCapNotice(priorTurns: OpenAIMessage[], round: number, maxIterations: number, traceWriter: TraceSink | undefined): void;
|
|
31
32
|
export declare function runTurnInner(ctx: TurnDriverContext, content: ProviderUserTurn['content'], controller: AbortController, turnStartTime: number, taskId: string): AsyncGenerator<ProviderEvent>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { HookContext, HookDecision } from './hooks.js';
|
|
2
2
|
export declare const SAFE_DESTRUCT_DETECT_REASON_PREFIX = "safe-destruct observe-only: destructive-command attempt";
|
|
3
3
|
export declare const SAFE_DESTRUCT_BLOCK_INJECT_CONTEXT: string;
|
|
4
|
+
export declare const WORKTREE_SCOPED_BLOCK_IDS: ReadonlySet<string>;
|
|
4
5
|
export declare function detectDestructiveCommands(command: string): string[];
|
|
5
|
-
export declare function createSafeDestructDetect(): (context: HookContext) => HookDecision;
|
|
6
|
+
export declare function createSafeDestructDetect(sessionCwd?: string): (context: HookContext) => HookDecision;
|
|
@@ -6,6 +6,7 @@ import type { SessionStateManager } from './session-state.js';
|
|
|
6
6
|
import type { HookRegistry } from '../hooks.js';
|
|
7
7
|
import type { ProviderQuery, ProviderEvent } from '../provider.js';
|
|
8
8
|
import type { QueryInputStream } from './input-iterable.js';
|
|
9
|
+
import type { OutputEvent } from '../types/session-types.js';
|
|
9
10
|
export interface SessionRunnerSlots {
|
|
10
11
|
getConfig: () => AgentConfig;
|
|
11
12
|
getAbortController: () => AbortController;
|
|
@@ -53,6 +54,7 @@ export interface BuildInitPromiseOptions {
|
|
|
53
54
|
shutdown: SessionShutdown;
|
|
54
55
|
hookRegistry: HookRegistry | undefined;
|
|
55
56
|
queueFrameworkContext: (text: string) => void;
|
|
57
|
+
pushSidebandEvent: (event: OutputEvent) => void;
|
|
56
58
|
getRunner: () => TurnStreamRunner;
|
|
57
59
|
stateManager: SessionStateManager;
|
|
58
60
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
type SlotProvider
|
|
1
|
+
import type { SlotProvider } from './model-slots.js';
|
|
2
2
|
export declare function normalizeSlotProvider(value: unknown): SlotProvider | undefined;
|
|
3
3
|
export declare function parseStringField(value: unknown): string;
|
|
4
|
-
export {};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type { ChainRecord, WorkspaceCheckpoint } from './continuation-registry.js';
|
|
2
|
+
export interface ContinuationOverrides {
|
|
3
|
+
agent_type?: string;
|
|
4
|
+
model?: string;
|
|
5
|
+
cwd?: string;
|
|
6
|
+
readRoots?: string[];
|
|
7
|
+
writeRoots?: string[];
|
|
8
|
+
isolation?: 'worktree';
|
|
9
|
+
host?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare function checkContinuationOverrides(chain: ChainRecord, call: ContinuationOverrides): string | undefined;
|
|
12
|
+
export type GitOutcome = {
|
|
13
|
+
ok: true;
|
|
14
|
+
stdout: string;
|
|
15
|
+
} | {
|
|
16
|
+
ok: false;
|
|
17
|
+
timedOut: boolean;
|
|
18
|
+
};
|
|
19
|
+
export type CheckpointGitExec = (cwd: string, args: string[]) => Promise<GitOutcome>;
|
|
20
|
+
export declare const CHECKPOINT_GIT_GLOBAL_ARGS: readonly string[];
|
|
21
|
+
export declare const CHECKPOINT_GIT_TIMEOUT_MS = 10000;
|
|
22
|
+
export declare const CHECKPOINT_GIT_KILL_GRACE_MS = 1000;
|
|
23
|
+
export declare const CHECKPOINT_CAPTURE_DEADLINE_MS = 25000;
|
|
24
|
+
export declare function captureCheckpointWithin(cwd: string, capture?: (cwd: string) => Promise<WorkspaceCheckpoint>, ms?: number): Promise<WorkspaceCheckpoint>;
|
|
25
|
+
export declare function captureWorkspaceCheckpoint(cwd: string, exec?: CheckpointGitExec): Promise<WorkspaceCheckpoint>;
|
|
26
|
+
export declare const CHECKPOINT_UNAVAILABLE_REASON = "workspace checkpoint unavailable (git status failed or timed out), so drift cannot be ruled out; retry the continuation";
|
|
27
|
+
export declare const PRIOR_CHECKPOINT_UNAVAILABLE_REASON: string;
|
|
28
|
+
export declare function checkWorkspaceDrift(chain: ChainRecord, recapture?: (cwd: string) => Promise<WorkspaceCheckpoint>): Promise<string | undefined>;
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
export interface WorkspaceCheckpoint {
|
|
2
|
+
cwd: string;
|
|
3
|
+
git: boolean;
|
|
4
|
+
branch?: string;
|
|
5
|
+
head?: string;
|
|
6
|
+
dirtyFingerprint?: string;
|
|
7
|
+
unavailable?: true;
|
|
8
|
+
}
|
|
9
|
+
export interface ChainDispatchInputs {
|
|
10
|
+
agent_type?: string;
|
|
11
|
+
model?: string;
|
|
12
|
+
cwd?: string;
|
|
13
|
+
readRoots?: string[];
|
|
14
|
+
writeRoots?: string[];
|
|
15
|
+
isolation?: 'worktree';
|
|
16
|
+
writeCapable: boolean;
|
|
17
|
+
}
|
|
18
|
+
export interface ContinuationLimits {
|
|
19
|
+
maxRounds: number;
|
|
20
|
+
maxContinuations: number;
|
|
21
|
+
}
|
|
22
|
+
export interface ChainRecord {
|
|
23
|
+
chainId: string;
|
|
24
|
+
owner: string;
|
|
25
|
+
rootSessionId: string | undefined;
|
|
26
|
+
latestChildId: string | undefined;
|
|
27
|
+
inputs: ChainDispatchInputs;
|
|
28
|
+
roundsCharged: number;
|
|
29
|
+
continuations: number;
|
|
30
|
+
limits: ContinuationLimits;
|
|
31
|
+
inFlight: boolean;
|
|
32
|
+
initialUncharged: boolean;
|
|
33
|
+
checkpoint: WorkspaceCheckpoint | undefined;
|
|
34
|
+
lastEndReason: string | undefined;
|
|
35
|
+
settling: Promise<void> | undefined;
|
|
36
|
+
admitting: boolean;
|
|
37
|
+
}
|
|
38
|
+
export type AdmissionResult = {
|
|
39
|
+
ok: true;
|
|
40
|
+
chain: ChainRecord;
|
|
41
|
+
allowance: number;
|
|
42
|
+
index: number;
|
|
43
|
+
rollback: () => void;
|
|
44
|
+
} | {
|
|
45
|
+
ok: false;
|
|
46
|
+
reason: string;
|
|
47
|
+
};
|
|
48
|
+
export interface TerminalUpdate {
|
|
49
|
+
childId: string;
|
|
50
|
+
journalUsable: boolean;
|
|
51
|
+
roundsUsed: number;
|
|
52
|
+
checkpoint: WorkspaceCheckpoint | undefined;
|
|
53
|
+
endReason: string;
|
|
54
|
+
}
|
|
55
|
+
export declare const CONTINUATION_DEFAULTS: ContinuationLimits;
|
|
56
|
+
export declare function resolveContinuationLimits(): ContinuationLimits;
|
|
57
|
+
export declare const MAX_CHAINS = 256;
|
|
58
|
+
export declare class ContinuationRegistry {
|
|
59
|
+
private readonly limits;
|
|
60
|
+
private readonly maxChains;
|
|
61
|
+
private readonly chains;
|
|
62
|
+
readonly rootActor: string;
|
|
63
|
+
constructor(limits?: ContinuationLimits, maxChains?: number);
|
|
64
|
+
get size(): number;
|
|
65
|
+
private evictForInsert;
|
|
66
|
+
createChain(args: {
|
|
67
|
+
owner: string;
|
|
68
|
+
rootSessionId: string | undefined;
|
|
69
|
+
inputs: ChainDispatchInputs;
|
|
70
|
+
roundCap: number;
|
|
71
|
+
}): ChainRecord;
|
|
72
|
+
get(chainId: string): ChainRecord | undefined;
|
|
73
|
+
admitContinuation(chainId: string, caller: string, requested: number | undefined, defaultAllowance: number, reserved?: boolean): AdmissionResult;
|
|
74
|
+
reserveAdmission(chainId: string): {
|
|
75
|
+
ok: true;
|
|
76
|
+
release: () => void;
|
|
77
|
+
} | {
|
|
78
|
+
ok: false;
|
|
79
|
+
reason: string;
|
|
80
|
+
};
|
|
81
|
+
chargeInitialRounds(chainId: string, roundsUsed: number): void;
|
|
82
|
+
setSettling(chainId: string, settling: Promise<void>): void;
|
|
83
|
+
recordTerminal(chainId: string, update: TerminalUpdate): void;
|
|
84
|
+
}
|
|
85
|
+
export declare function formatContinuationLine(chain: ChainRecord): string;
|
|
@@ -10,6 +10,11 @@ export interface EmitForkStartedArgs {
|
|
|
10
10
|
promptHead: string | undefined;
|
|
11
11
|
effectiveAgentType: string | undefined;
|
|
12
12
|
effectiveResolvedAgentType: string | undefined;
|
|
13
|
+
continuation?: {
|
|
14
|
+
chainId: string;
|
|
15
|
+
continuationOf: string;
|
|
16
|
+
continuationIndex: number;
|
|
17
|
+
} | undefined;
|
|
13
18
|
}
|
|
14
19
|
export declare function emitForkStarted(args: EmitForkStartedArgs): string;
|
|
15
20
|
export interface AppendForkTelemetryArgs {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { HookRegistry } from '../hooks.js';
|
|
2
2
|
import type { TraceSink } from '../trace/index.js';
|
|
3
|
-
import type { AgentModelInput } from '../types.js';
|
|
3
|
+
import type { AgentConfig, AgentModelInput } from '../types.js';
|
|
4
4
|
import type { ForkSubagentOptions } from './fork-types.js';
|
|
5
5
|
export interface ResolveForkInputsArgs {
|
|
6
6
|
options: ForkSubagentOptions;
|
|
@@ -19,3 +19,4 @@ export interface ForkResolved {
|
|
|
19
19
|
effectiveTimeoutMs: number;
|
|
20
20
|
}
|
|
21
21
|
export declare function resolveForkInputs(args: ResolveForkInputsArgs): ForkResolved;
|
|
22
|
+
export declare function applyContinuationSeed(config: AgentConfig, options: Pick<ForkSubagentOptions, 'continuation'>): AgentConfig;
|
|
@@ -7,7 +7,7 @@ import type { SubagentProgressSink, OutputEvent } from '../types/session-types.j
|
|
|
7
7
|
import type { TraceSink } from '../trace/index.js';
|
|
8
8
|
import type { Surface } from '../awareness/types.js';
|
|
9
9
|
import type { PhaseRole } from '../tools/nesting.js';
|
|
10
|
-
import type { MessageJournal } from '../journal/index.js';
|
|
10
|
+
import type { MessageJournal, JournalMessage } from '../journal/index.js';
|
|
11
11
|
export interface ForkParent {
|
|
12
12
|
sessionId?: string;
|
|
13
13
|
id?: string;
|
|
@@ -27,6 +27,12 @@ export interface ForkSubagentOptions<T = unknown> {
|
|
|
27
27
|
parentId?: string;
|
|
28
28
|
promptHead?: string;
|
|
29
29
|
denyElicitations?: boolean;
|
|
30
|
+
continuation?: {
|
|
31
|
+
messages: JournalMessage[];
|
|
32
|
+
chainId: string;
|
|
33
|
+
continuationOf: string;
|
|
34
|
+
continuationIndex: number;
|
|
35
|
+
};
|
|
30
36
|
progressEvents?: boolean;
|
|
31
37
|
phaseRole?: PhaseRole;
|
|
32
38
|
nestedAgentAllowlist?: readonly string[];
|
|
@@ -56,6 +56,7 @@ export declare class SubagentHandleImpl<T> implements SubagentHandle<T> {
|
|
|
56
56
|
_parentId: string | undefined;
|
|
57
57
|
_currentTrace: SubagentTrace;
|
|
58
58
|
_lastStreamedContent: string;
|
|
59
|
+
_runtimeRoundsUsed: number;
|
|
59
60
|
_pauseCeiling: PauseAwareCeiling | undefined;
|
|
60
61
|
_lastStopReason: string | undefined;
|
|
61
62
|
_billingContext: RunBillingContext;
|
|
@@ -10,3 +10,4 @@ export declare function runInBackground<T>(handle: SubagentHandleImpl<T>, prompt
|
|
|
10
10
|
export declare function dispatchStopAndRelease<T>(handle: SubagentHandleImpl<T>, reportedStatus: SubagentStatus, options?: {
|
|
11
11
|
deferInjectContextToCaller?: boolean;
|
|
12
12
|
}): Promise<void>;
|
|
13
|
+
export declare function countRuntimeRounds<T>(handle: Pick<SubagentHandleImpl<T>, '_runtimeRoundsUsed'>, event: OutputEvent, last: number): number;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import type { AgentConfig } from '../types/config-types.js';
|
|
2
|
+
export declare const WORKTREE_STASH_RULE: string;
|
|
2
3
|
export interface SubagentIdentityFacts {
|
|
3
4
|
isNonInteractive: boolean | undefined;
|
|
4
5
|
depth: number | undefined;
|
|
5
6
|
maxDepth: number | undefined;
|
|
6
7
|
nestedAgentAllowlist?: readonly string[];
|
|
8
|
+
cwd?: string;
|
|
7
9
|
}
|
|
8
10
|
export declare function renderSubagentIdentityPreamble(facts: SubagentIdentityFacts): string;
|
|
9
11
|
export declare function injectSubagentIdentityPreamble(config: AgentConfig, nestedAgentAllowlist?: readonly string[]): AgentConfig;
|
|
@@ -49,6 +49,14 @@ export interface SubagentResult<T = unknown> extends Partial<CappedHandoff> {
|
|
|
49
49
|
trace?: SubagentTrace;
|
|
50
50
|
signal?: Signal;
|
|
51
51
|
stopReason?: string;
|
|
52
|
+
continuation?: {
|
|
53
|
+
chainId: string;
|
|
54
|
+
roundsCharged: number;
|
|
55
|
+
maxRounds: number;
|
|
56
|
+
continuations: number;
|
|
57
|
+
maxContinuations: number;
|
|
58
|
+
continuable: boolean;
|
|
59
|
+
};
|
|
52
60
|
setupNotice?: string;
|
|
53
61
|
}
|
|
54
62
|
export declare function buildResultFromMessage<T>(id: string, status: SubagentStatus, message: Message, outputSchema: ZodType<T> | undefined, trace?: SubagentTrace, stopReason?: string): SubagentResult<T>;
|
|
@@ -9,12 +9,14 @@ export interface LspSymbolResult {
|
|
|
9
9
|
error?: string;
|
|
10
10
|
}
|
|
11
11
|
export type SymbolSubcommand = 'definition' | 'references';
|
|
12
|
+
export declare const DEFAULT_LSP_CMD: readonly string[];
|
|
13
|
+
export declare function parseLocation(raw: unknown): LspLocation | null;
|
|
12
14
|
export declare function isLspSymbolsEnabled(): boolean;
|
|
13
|
-
export declare function queryLspSymbol(filePath: string, subcommand: SymbolSubcommand, line: number, col: number, rootDir?: string, serverCmd?: readonly string[]): Promise<LspSymbolResult>;
|
|
15
|
+
export declare function queryLspSymbol(filePath: string, subcommand: SymbolSubcommand, line: number, col: number, rootDir?: string, serverCmd?: readonly string[], signal?: AbortSignal): Promise<LspSymbolResult>;
|
|
14
16
|
export declare function formatSymbolResult(filePath: string, subcommand: SymbolSubcommand, line: number, col: number, result: LspSymbolResult): string;
|
|
15
17
|
export declare function handleCodeSymbols(input: {
|
|
16
18
|
file_path: string;
|
|
17
19
|
subcommand: SymbolSubcommand;
|
|
18
20
|
line: number;
|
|
19
21
|
col: number;
|
|
20
|
-
}, context?: ToolHandlerContext, cwd?: string, serverCmd?: readonly string[]): Promise<string>;
|
|
22
|
+
}, context?: ToolHandlerContext, cwd?: string, serverCmd?: readonly string[], signal?: AbortSignal): Promise<string>;
|
|
@@ -42,6 +42,7 @@ export interface BuildChildConfigArgs {
|
|
|
42
42
|
onSubagentSucceeded?: import('../../subagent/fork-types.js').SubagentManagerOptions['onSubagentSucceeded'];
|
|
43
43
|
workspaceStore?: import('../../workspace/index.js').WorkspaceStore;
|
|
44
44
|
delegationBudget?: import('../../tools/delegation-budget.js').DelegationBudget;
|
|
45
|
+
continuationRegistry?: import('../../subagent/continuation-registry.js').ContinuationRegistry;
|
|
45
46
|
hookRegistry?: import('../../hooks.js').HookRegistry;
|
|
46
47
|
parentRootSessionId?: string;
|
|
47
48
|
parentBillingStreams?: Set<Promise<void>>;
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import type { ToolResult } from '../types.js';
|
|
2
|
+
import { type AgentInput } from './input-parse.js';
|
|
3
|
+
import { type ChainRecord, type ContinuationRegistry, type WorkspaceCheckpoint } from '../../subagent/continuation-registry.js';
|
|
4
|
+
import type { ContinuationPlan } from './continuation-run.js';
|
|
5
|
+
import type { TraceSink } from '../../trace/writer.js';
|
|
6
|
+
export interface ContinuationResultFields {
|
|
7
|
+
continuation?: {
|
|
8
|
+
chainId: string;
|
|
9
|
+
roundsCharged: number;
|
|
10
|
+
maxRounds: number;
|
|
11
|
+
continuations: number;
|
|
12
|
+
maxContinuations: number;
|
|
13
|
+
continuable: boolean;
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
export declare function parseDispatchInput(input: unknown): {
|
|
17
|
+
parsed: AgentInput;
|
|
18
|
+
} | {
|
|
19
|
+
error: ToolResult;
|
|
20
|
+
};
|
|
21
|
+
export interface ActorCtx {
|
|
22
|
+
depth: number;
|
|
23
|
+
continuationRegistry?: ContinuationRegistry;
|
|
24
|
+
parentSession: {
|
|
25
|
+
sessionId?: string | undefined;
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
export declare function actorIdentity(ctx: ActorCtx): string | undefined;
|
|
29
|
+
export interface MintChainArgs {
|
|
30
|
+
registry: ContinuationRegistry | undefined;
|
|
31
|
+
owner: string | undefined;
|
|
32
|
+
rootSessionId: string | undefined;
|
|
33
|
+
parsed: AgentInput;
|
|
34
|
+
model: string | undefined;
|
|
35
|
+
cwd: string | undefined;
|
|
36
|
+
writeCapable: boolean;
|
|
37
|
+
roundCap: number | undefined;
|
|
38
|
+
}
|
|
39
|
+
export declare function mintDispatchChain(args: MintChainArgs): ChainRecord | undefined;
|
|
40
|
+
export interface ChainTerminalArgs {
|
|
41
|
+
registry: ContinuationRegistry | undefined;
|
|
42
|
+
chain: ChainRecord | undefined;
|
|
43
|
+
childId: string;
|
|
44
|
+
cwd: string | undefined;
|
|
45
|
+
roundsUsed: number | undefined;
|
|
46
|
+
journalUsable: boolean;
|
|
47
|
+
endReason: string;
|
|
48
|
+
capture?: (cwd: string) => Promise<WorkspaceCheckpoint>;
|
|
49
|
+
traceWriter?: TraceSink | undefined;
|
|
50
|
+
}
|
|
51
|
+
export declare function recordChainTerminal(args: ChainTerminalArgs): Promise<WorkspaceCheckpoint | undefined>;
|
|
52
|
+
export declare function markChainPromoted(handle: object): void;
|
|
53
|
+
export declare function annotateChainResult<R extends ToolResult>(result: R, chain: ChainRecord | undefined, always?: boolean, handle?: object): R & ContinuationResultFields;
|
|
54
|
+
export declare function endReasonOf(result: ToolResult): string;
|
|
55
|
+
type ChainHandle = {
|
|
56
|
+
readonly id: string;
|
|
57
|
+
runToResult(prompt: never, ...rest: never[]): Promise<import('../../subagent/result.js').SubagentResult>;
|
|
58
|
+
runInBackground(prompt: never, onResult?: (r: import('../../subagent/result.js').SubagentResult) => void, ...rest: never[]): unknown;
|
|
59
|
+
};
|
|
60
|
+
export declare function instrumentHandleForChain(handle: ChainHandle, terminal: Omit<ChainTerminalArgs, 'childId' | 'roundsUsed' | 'endReason' | 'journalUsable'> & {
|
|
61
|
+
journalUsable: () => boolean;
|
|
62
|
+
flushJournal?: () => Promise<void>;
|
|
63
|
+
rollbackIfNotStarted?: () => void;
|
|
64
|
+
alwaysLine?: boolean;
|
|
65
|
+
}): void;
|
|
66
|
+
export type SettleDegradedReason = 'flush_timeout' | 'checkpoint_unavailable' | 'error';
|
|
67
|
+
export declare const JOURNAL_FLUSH_TIMEOUT_MS = 5000;
|
|
68
|
+
export declare function wireDispatchChain(args: {
|
|
69
|
+
ctx: ActorCtx & {
|
|
70
|
+
parentRootSessionId?: string;
|
|
71
|
+
traceWriter?: TraceSink | undefined;
|
|
72
|
+
};
|
|
73
|
+
parsed: AgentInput;
|
|
74
|
+
handle: ChainHandle & {
|
|
75
|
+
session?: {
|
|
76
|
+
messageJournal?: unknown;
|
|
77
|
+
};
|
|
78
|
+
};
|
|
79
|
+
childConfig: {
|
|
80
|
+
model?: string;
|
|
81
|
+
cwd?: string;
|
|
82
|
+
maxToolUseIterations?: number;
|
|
83
|
+
};
|
|
84
|
+
currentCwd: string | undefined;
|
|
85
|
+
writeCapable: boolean;
|
|
86
|
+
plan?: ContinuationPlan | undefined;
|
|
87
|
+
}): ChainRecord | undefined;
|
|
88
|
+
export {};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { ToolCall, ToolResult } from '../types.js';
|
|
2
|
+
import type { AgentInput } from './input-parse.js';
|
|
3
|
+
import type { ForkSubagentOptions } from '../../subagent/fork-types.js';
|
|
4
|
+
import type { ChainRecord, ContinuationRegistry, WorkspaceCheckpoint } from '../../subagent/continuation-registry.js';
|
|
5
|
+
export interface ContinuationPlan {
|
|
6
|
+
chain: ChainRecord;
|
|
7
|
+
allowance: number;
|
|
8
|
+
rollback: () => void;
|
|
9
|
+
wired: boolean;
|
|
10
|
+
fork: NonNullable<ForkSubagentOptions['continuation']>;
|
|
11
|
+
}
|
|
12
|
+
interface AdmitCtx {
|
|
13
|
+
depth: number;
|
|
14
|
+
continuationRegistry?: ContinuationRegistry;
|
|
15
|
+
parentSession: {
|
|
16
|
+
sessionId?: string | undefined;
|
|
17
|
+
};
|
|
18
|
+
parentRootSessionId?: string;
|
|
19
|
+
recaptureCheckpoint?: (cwd: string) => Promise<WorkspaceCheckpoint>;
|
|
20
|
+
}
|
|
21
|
+
export declare function refuseContinuation(reason: string): {
|
|
22
|
+
error: ToolResult;
|
|
23
|
+
};
|
|
24
|
+
export declare function continuationNote(chain: ChainRecord, index: number, allowance: number): string;
|
|
25
|
+
export declare const SETTLING_WAIT_MS = 15000;
|
|
26
|
+
export declare function admitContinuationCall(parsed: AgentInput, ctx: AdmitCtx): Promise<{
|
|
27
|
+
plan: ContinuationPlan;
|
|
28
|
+
input: Record<string, unknown>;
|
|
29
|
+
} | {
|
|
30
|
+
error: ToolResult;
|
|
31
|
+
}>;
|
|
32
|
+
export declare function runContinuation(call: ToolCall, parsed: AgentInput, ctx: AdmitCtx, dispatch: (call: ToolCall, plan: ContinuationPlan) => Promise<ToolResult>): Promise<ToolResult>;
|
|
33
|
+
export {};
|
|
@@ -36,6 +36,7 @@ export interface SubagentExecutorContext {
|
|
|
36
36
|
traceWriter?: TraceSink;
|
|
37
37
|
workspaceStore?: import('../../workspace/index.js').WorkspaceStore;
|
|
38
38
|
delegationBudget?: DelegationBudget;
|
|
39
|
+
continuationRegistry?: import('../../subagent/continuation-registry.js').ContinuationRegistry;
|
|
39
40
|
hookRegistry?: HookRegistry;
|
|
40
41
|
allowedTools?: string[];
|
|
41
42
|
readOnlyBash?: boolean;
|
|
@@ -16,6 +16,7 @@ export declare class SubagentExecutor implements SubagentControl {
|
|
|
16
16
|
setCwd(cwd: string): void;
|
|
17
17
|
setTraceWriter(writer: TraceSink | undefined): void;
|
|
18
18
|
describeAgentTool(): AnthropicToolDef;
|
|
19
|
+
describeAgentTypeListing(): string;
|
|
19
20
|
private readonly promotionTriggers;
|
|
20
21
|
private readonly activeForegroundHandles;
|
|
21
22
|
private readonly waveTracker;
|
|
@@ -4,6 +4,7 @@ import { type PromotionTrigger } from './subagent/foreground-promotion.js';
|
|
|
4
4
|
import type { StreamCutProbe } from '../subagent/stream-cut-retry.js';
|
|
5
5
|
import { WaveManifestTracker } from './subagent-executor.wave-manifest.js';
|
|
6
6
|
import type { SubagentExecutorContext } from './subagent-executor/types.js';
|
|
7
|
+
import { type ContinuationPlan } from './subagent/continuation-run.js';
|
|
7
8
|
export interface ExecuteOnceArgs {
|
|
8
9
|
ctx: SubagentExecutorContext;
|
|
9
10
|
currentCwd: string | undefined;
|
|
@@ -19,4 +20,4 @@ export interface ExecuteOnceArgs {
|
|
|
19
20
|
inheritedChildConfigArgs: () => Partial<BuildChildConfigArgs>;
|
|
20
21
|
updateCurrentWaveUnit: (callId: string, status: 'running' | 'done' | 'failed', error?: string, cwd?: string) => void;
|
|
21
22
|
}
|
|
22
|
-
export declare function executeOnce(call: ToolCall, args: ExecuteOnceArgs, probe?: StreamCutProbe, retryCancelGeneration?: number): Promise<ToolResult>;
|
|
23
|
+
export declare function executeOnce(call: ToolCall, args: ExecuteOnceArgs, probe?: StreamCutProbe, retryCancelGeneration?: number, plan?: ContinuationPlan): Promise<ToolResult>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { RegisteredAgent } from '../agents/index.js';
|
|
2
|
+
import type { ToolResult } from './types.js';
|
|
3
|
+
import type { SubagentExecutorContext } from './subagent-executor/types.js';
|
|
4
|
+
export declare function resolveNamedAgent(ctx: Pick<SubagentExecutorContext, 'agentRegistry'>, agentType: string | undefined): {
|
|
5
|
+
namedAgent: RegisteredAgent | undefined;
|
|
6
|
+
} | {
|
|
7
|
+
error: ToolResult;
|
|
8
|
+
};
|
|
@@ -64,6 +64,7 @@ export interface ForkAndCheckCancelArgs {
|
|
|
64
64
|
updateCurrentWaveUnit: (callId: string, status: 'running' | 'done' | 'failed', error?: string, cwd?: string) => void;
|
|
65
65
|
callId: string;
|
|
66
66
|
modelFallback?: ForkSubagentOptions['modelFallback'];
|
|
67
|
+
continuation?: ForkSubagentOptions['continuation'];
|
|
67
68
|
}
|
|
68
69
|
export type ForkResult = {
|
|
69
70
|
handle: Awaited<ReturnType<SubagentManager['forkSubagent']>>;
|
|
@@ -2,6 +2,9 @@ import type { AgentInput } from './subagent/input-parse.js';
|
|
|
2
2
|
import type { ToolResult } from './types.js';
|
|
3
3
|
import { readUnlockPassword } from '../../remote/keychain-unlock.js';
|
|
4
4
|
import { defaultSshRunner } from '../../remote/ssh-runner.js';
|
|
5
|
+
import { type RemoteRunOutcome } from '../../remote/remote-run.js';
|
|
6
|
+
import type { RemoteHost } from '../../remote/hosts.js';
|
|
7
|
+
export declare function formatRemoteOutcome(outcome: RemoteRunOutcome, host: RemoteHost, runId: string, sessionId: string): ToolResult;
|
|
5
8
|
export interface RemoteAgentDispatchDeps {
|
|
6
9
|
runner?: typeof defaultSshRunner;
|
|
7
10
|
loadHostsFn?: () => Promise<Record<string, import('../../remote/hosts.js').RemoteHost>>;
|
|
@@ -435,6 +435,9 @@ export declare const TraceEventInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject
|
|
|
435
435
|
agentType: z.ZodOptional<z.ZodString>;
|
|
436
436
|
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
437
437
|
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
438
|
+
chainId: z.ZodOptional<z.ZodString>;
|
|
439
|
+
continuationOf: z.ZodOptional<z.ZodString>;
|
|
440
|
+
continuationIndex: z.ZodOptional<z.ZodNumber>;
|
|
438
441
|
}, z.core.$strip>, z.ZodObject<{
|
|
439
442
|
provider: z.ZodOptional<z.ZodString>;
|
|
440
443
|
tokens: z.ZodOptional<z.ZodObject<{
|
|
@@ -752,6 +755,8 @@ export declare const TraceEventInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject
|
|
|
752
755
|
hook_block_repeat_tripped: "hook_block_repeat_tripped";
|
|
753
756
|
billing_settled: "billing_settled";
|
|
754
757
|
subagent_model_fallback: "subagent_model_fallback";
|
|
758
|
+
round_cap_notice_dropped: "round_cap_notice_dropped";
|
|
759
|
+
continuation_settle_degraded: "continuation_settle_degraded";
|
|
755
760
|
}>;
|
|
756
761
|
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
757
762
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>;
|
|
@@ -890,6 +895,9 @@ export declare const TraceEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
890
895
|
agentType: z.ZodOptional<z.ZodString>;
|
|
891
896
|
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
892
897
|
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
898
|
+
chainId: z.ZodOptional<z.ZodString>;
|
|
899
|
+
continuationOf: z.ZodOptional<z.ZodString>;
|
|
900
|
+
continuationIndex: z.ZodOptional<z.ZodNumber>;
|
|
893
901
|
}, z.core.$strip>, z.ZodObject<{
|
|
894
902
|
provider: z.ZodOptional<z.ZodString>;
|
|
895
903
|
tokens: z.ZodOptional<z.ZodObject<{
|
|
@@ -1231,6 +1239,8 @@ export declare const TraceEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1231
1239
|
hook_block_repeat_tripped: "hook_block_repeat_tripped";
|
|
1232
1240
|
billing_settled: "billing_settled";
|
|
1233
1241
|
subagent_model_fallback: "subagent_model_fallback";
|
|
1242
|
+
round_cap_notice_dropped: "round_cap_notice_dropped";
|
|
1243
|
+
continuation_settle_degraded: "continuation_settle_degraded";
|
|
1234
1244
|
}>;
|
|
1235
1245
|
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
1236
1246
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>;
|
|
@@ -51,6 +51,8 @@ export declare const SessionPhaseNameSchema: z.ZodEnum<{
|
|
|
51
51
|
hook_block_repeat_tripped: "hook_block_repeat_tripped";
|
|
52
52
|
billing_settled: "billing_settled";
|
|
53
53
|
subagent_model_fallback: "subagent_model_fallback";
|
|
54
|
+
round_cap_notice_dropped: "round_cap_notice_dropped";
|
|
55
|
+
continuation_settle_degraded: "continuation_settle_degraded";
|
|
54
56
|
}>;
|
|
55
57
|
export declare const SessionPhasePayloadSchema: z.ZodObject<{
|
|
56
58
|
phase: z.ZodEnum<{
|
|
@@ -105,6 +107,8 @@ export declare const SessionPhasePayloadSchema: z.ZodObject<{
|
|
|
105
107
|
hook_block_repeat_tripped: "hook_block_repeat_tripped";
|
|
106
108
|
billing_settled: "billing_settled";
|
|
107
109
|
subagent_model_fallback: "subagent_model_fallback";
|
|
110
|
+
round_cap_notice_dropped: "round_cap_notice_dropped";
|
|
111
|
+
continuation_settle_degraded: "continuation_settle_degraded";
|
|
108
112
|
}>;
|
|
109
113
|
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
110
114
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>;
|
|
@@ -24,6 +24,9 @@ export declare const SubagentStartedPayloadSchema: z.ZodObject<{
|
|
|
24
24
|
agentType: z.ZodOptional<z.ZodString>;
|
|
25
25
|
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
26
26
|
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
27
|
+
chainId: z.ZodOptional<z.ZodString>;
|
|
28
|
+
continuationOf: z.ZodOptional<z.ZodString>;
|
|
29
|
+
continuationIndex: z.ZodOptional<z.ZodNumber>;
|
|
27
30
|
}, z.core.$strip>;
|
|
28
31
|
export declare const SubagentSucceededPayloadSchema: z.ZodObject<{
|
|
29
32
|
provider: z.ZodOptional<z.ZodString>;
|
|
@@ -96,6 +99,9 @@ export declare const SubagentLifecyclePayloadSchema: z.ZodDiscriminatedUnion<[z.
|
|
|
96
99
|
agentType: z.ZodOptional<z.ZodString>;
|
|
97
100
|
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
98
101
|
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
102
|
+
chainId: z.ZodOptional<z.ZodString>;
|
|
103
|
+
continuationOf: z.ZodOptional<z.ZodString>;
|
|
104
|
+
continuationIndex: z.ZodOptional<z.ZodNumber>;
|
|
99
105
|
}, z.core.$strip>, z.ZodObject<{
|
|
100
106
|
provider: z.ZodOptional<z.ZodString>;
|
|
101
107
|
tokens: z.ZodOptional<z.ZodObject<{
|
|
@@ -60,6 +60,9 @@ export interface SubagentStartedPayload {
|
|
|
60
60
|
agentType?: string;
|
|
61
61
|
resolvedAgentType?: string;
|
|
62
62
|
maxToolUseIterations?: number;
|
|
63
|
+
chainId?: string;
|
|
64
|
+
continuationOf?: string;
|
|
65
|
+
continuationIndex?: number;
|
|
63
66
|
}
|
|
64
67
|
export interface SubagentSucceededPayload extends SubagentBillingFields {
|
|
65
68
|
incomplete?: true;
|