agent-afk 5.228.0 → 5.230.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/dag-subagent.d.ts +2 -0
- package/dist/agent/tools/compose-executor.d.ts +2 -0
- package/dist/agent/tools/compose-input-parse.d.ts +1 -0
- package/dist/agent/tools/dispatcher.execute-batch.d.ts +2 -0
- package/dist/agent/trace/events.d.ts +12 -0
- package/dist/agent/trace/types.d.ts +1 -1
- package/dist/cli.mjs +241 -241
- package/dist/index.mjs +110 -110
- package/dist/telegram.mjs +133 -133
- package/package.json +1 -1
|
@@ -5,6 +5,7 @@ import type { ModelProvider } from './provider.js';
|
|
|
5
5
|
import type { SubagentManager } from './subagent.js';
|
|
6
6
|
import { type DAGEdge, type DAGRunResult } from './dag.js';
|
|
7
7
|
import type { DelegationBudget } from './tools/delegation-budget.js';
|
|
8
|
+
import type { ImageBlockAttachment } from './content/image-blocks.js';
|
|
8
9
|
export interface SubagentDAGNode {
|
|
9
10
|
id: string;
|
|
10
11
|
systemPrompt: string;
|
|
@@ -24,6 +25,7 @@ export interface SubagentDAGNode {
|
|
|
24
25
|
maxTurns?: number;
|
|
25
26
|
provider?: ModelProvider;
|
|
26
27
|
buildPromptAsync?: (inputs: Record<string, unknown>) => Promise<string | ContentBlockParam[]>;
|
|
28
|
+
resolvedAttachments?: ImageBlockAttachment[];
|
|
27
29
|
}
|
|
28
30
|
export interface SubagentDAGOptions {
|
|
29
31
|
manager: SubagentManager;
|
|
@@ -5,6 +5,7 @@ import type { Surface } from '../awareness/types.js';
|
|
|
5
5
|
import type { WorkspaceStore } from '../workspace/index.js';
|
|
6
6
|
import type { TraceSink } from '../trace/index.js';
|
|
7
7
|
import type { ToolCall, ToolResult } from './types.js';
|
|
8
|
+
import type { InboundAttachmentReader } from '../content/attachment-registry.js';
|
|
8
9
|
export interface ComposeExecutorContext {
|
|
9
10
|
parentSession: Pick<IAgentSession, 'sessionId' | 'abortSignal'>;
|
|
10
11
|
defaultModel?: AgentModelInput;
|
|
@@ -23,6 +24,7 @@ export interface ComposeExecutorContext {
|
|
|
23
24
|
workspaceStore?: WorkspaceStore;
|
|
24
25
|
agentRegistry?: AgentRegistry;
|
|
25
26
|
delegationBudget?: import('./delegation-budget.js').DelegationBudget;
|
|
27
|
+
inboundAttachmentRegistry?: InboundAttachmentReader;
|
|
26
28
|
onSubagentSucceeded?: (usage: import('../subagent/result.js').SubagentTrace['usage'], costUsd: number | undefined) => void;
|
|
27
29
|
}
|
|
28
30
|
export interface TruncationEvent {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { RunPreDispatchGatesOpts, PreDispatchGateDeps } from './dispatcher.pre-dispatch-gates.js';
|
|
2
|
+
import type { TraceSink } from '../trace/index.js';
|
|
2
3
|
import type { ToolCall, ToolResult } from '../providers/anthropic-direct/types.js';
|
|
3
4
|
import type { ToolActivityReporter } from '../providers/shared/tool-activity.js';
|
|
4
5
|
import type { RepeatFailureGuard } from './repeat-failure-guard.js';
|
|
@@ -16,5 +17,6 @@ export interface ExecuteBatchDeps {
|
|
|
16
17
|
sessionId: string | undefined;
|
|
17
18
|
maxConcurrentSafeCalls: number;
|
|
18
19
|
gateDeps: () => PreDispatchGateDeps;
|
|
20
|
+
traceWriter: TraceSink | undefined;
|
|
19
21
|
}
|
|
20
22
|
export declare function executeBatchImpl(calls: ToolCall[], deps: ExecuteBatchDeps, onActivity?: ToolActivityReporter): Promise<ToolResult[]>;
|
|
@@ -523,6 +523,9 @@ export declare const SessionPhaseNameSchema: z.ZodEnum<{
|
|
|
523
523
|
suspected_loop: "suspected_loop";
|
|
524
524
|
compaction_disabled: "compaction_disabled";
|
|
525
525
|
boot_warning: "boot_warning";
|
|
526
|
+
workspace_subscribed: "workspace_subscribed";
|
|
527
|
+
workspace_delivery: "workspace_delivery";
|
|
528
|
+
gate_shape: "gate_shape";
|
|
526
529
|
}>;
|
|
527
530
|
export declare const SessionPhasePayloadSchema: z.ZodObject<{
|
|
528
531
|
phase: z.ZodEnum<{
|
|
@@ -549,6 +552,9 @@ export declare const SessionPhasePayloadSchema: z.ZodObject<{
|
|
|
549
552
|
suspected_loop: "suspected_loop";
|
|
550
553
|
compaction_disabled: "compaction_disabled";
|
|
551
554
|
boot_warning: "boot_warning";
|
|
555
|
+
workspace_subscribed: "workspace_subscribed";
|
|
556
|
+
workspace_delivery: "workspace_delivery";
|
|
557
|
+
gate_shape: "gate_shape";
|
|
552
558
|
}>;
|
|
553
559
|
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
554
560
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>;
|
|
@@ -909,6 +915,9 @@ export declare const TraceEventInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject
|
|
|
909
915
|
suspected_loop: "suspected_loop";
|
|
910
916
|
compaction_disabled: "compaction_disabled";
|
|
911
917
|
boot_warning: "boot_warning";
|
|
918
|
+
workspace_subscribed: "workspace_subscribed";
|
|
919
|
+
workspace_delivery: "workspace_delivery";
|
|
920
|
+
gate_shape: "gate_shape";
|
|
912
921
|
}>;
|
|
913
922
|
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
914
923
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>;
|
|
@@ -1279,6 +1288,9 @@ export declare const TraceEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1279
1288
|
suspected_loop: "suspected_loop";
|
|
1280
1289
|
compaction_disabled: "compaction_disabled";
|
|
1281
1290
|
boot_warning: "boot_warning";
|
|
1291
|
+
workspace_subscribed: "workspace_subscribed";
|
|
1292
|
+
workspace_delivery: "workspace_delivery";
|
|
1293
|
+
gate_shape: "gate_shape";
|
|
1282
1294
|
}>;
|
|
1283
1295
|
durationMs: z.ZodOptional<z.ZodNumber>;
|
|
1284
1296
|
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>;
|
|
@@ -177,7 +177,7 @@ export interface BrowserEventPayload {
|
|
|
177
177
|
};
|
|
178
178
|
durationMs: number;
|
|
179
179
|
}
|
|
180
|
-
export type SessionPhaseName = 'bootstrap_start' | 'bootstrap_done' | 'session_init_start' | 'session_init_done' | 'mcp_connect_start' | 'mcp_connect_done' | 'mcp_server_start' | 'mcp_server_done' | 'loop_start' | 'loop_end' | 'model_ttfb' | 'interrupt_halt' | 'rate_limit' | 'ttfb_timeout' | 'usage_limit_pause' | 'usage_limit_resume' | 'overload_pause' | 'overload_resume' | 'idle_watchdog_fired' | 'pause_extension_granted' | 'suspected_loop' | 'compaction_disabled' | 'boot_warning' | 'workspace_subscribed' | 'workspace_delivery';
|
|
180
|
+
export type SessionPhaseName = 'bootstrap_start' | 'bootstrap_done' | 'session_init_start' | 'session_init_done' | 'mcp_connect_start' | 'mcp_connect_done' | 'mcp_server_start' | 'mcp_server_done' | 'loop_start' | 'loop_end' | 'model_ttfb' | 'interrupt_halt' | 'rate_limit' | 'ttfb_timeout' | 'usage_limit_pause' | 'usage_limit_resume' | 'overload_pause' | 'overload_resume' | 'idle_watchdog_fired' | 'pause_extension_granted' | 'suspected_loop' | 'compaction_disabled' | 'boot_warning' | 'workspace_subscribed' | 'workspace_delivery' | 'gate_shape';
|
|
181
181
|
export interface SessionPhasePayload {
|
|
182
182
|
phase: SessionPhaseName;
|
|
183
183
|
durationMs?: number;
|