agent-afk 5.321.8 → 5.321.9

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.
@@ -13,7 +13,7 @@ export interface HandoffMaintenanceOpts {
13
13
  intervalMs?: number;
14
14
  }
15
15
  export interface HandoffMaintenanceHandle {
16
- stop(): void;
16
+ stop(): Promise<void>;
17
17
  }
18
18
  export declare function runStartupRecovery(opts: HandoffMaintenanceOpts, resumeDir: string): Promise<void>;
19
19
  export declare function consumeAndResume(opts: HandoffMaintenanceOpts, resumeDir: string): Promise<void>;
@@ -1,5 +1,6 @@
1
1
  import type { ToolCall, ToolResult } from '../../anthropic-direct/types.js';
2
2
  import type { AccumulatedToolCall } from '../translate.js';
3
+ export declare const LOST_ARGS_FAILURE_CLASS: "lost-args";
3
4
  export declare function parseErrorResult(name: string, diagnostic: string, argumentsLost: boolean): ToolResult;
4
5
  export declare function dispatchableCalls(calls: readonly ToolCall[], parseErrors: ReadonlyMap<string, string>): ToolCall[];
5
6
  export declare function mergeUndispatchedResults(calls: readonly ToolCall[], accumulated: readonly AccumulatedToolCall[], parseErrors: ReadonlyMap<string, string>, dispatchedResults: readonly ToolResult[]): ToolResult[];
@@ -11,6 +11,7 @@ export interface ResolvedComposeAgent {
11
11
  canUseTool?: CanUseTool;
12
12
  namedAgentAllowedTools?: string[];
13
13
  readOnlyBash?: true;
14
+ readOnly?: true;
14
15
  }
15
16
  export declare function buildAllowlistCanUseTool(allowed: string[]): CanUseTool;
16
17
  export declare function resolveComposeNodeAgent(agentType: string | undefined, agentRegistry: AgentRegistry | undefined): ResolvedComposeAgent;
@@ -0,0 +1 @@
1
+ export declare function isChildWriteCapable(effectiveAllowedTools: readonly string[] | undefined, effectiveReadOnlyBash: boolean): boolean;
@@ -0,0 +1,11 @@
1
+ import type { RegisteredAgent } from '../agents/index.js';
2
+ import type { ToolResult } from './types.js';
3
+ export declare function classifyDispatchIntent(prompt: string): string | undefined;
4
+ export declare function checkReadOnlyDispatchIntent(childWriteCapable: boolean, namedAgent: RegisteredAgent | undefined, prompt: string, classifyFn: (p: string) => string | undefined): ToolResult | undefined;
5
+ export declare function checkComposeReadOnlyDispatchIntent(nodes: ReadonlyArray<{
6
+ id: string;
7
+ prompt: string;
8
+ agent_type?: string;
9
+ }>, resolvedAgents: ReadonlyArray<{
10
+ readOnly?: true;
11
+ }>, classifyFn?: (p: string) => string | undefined): ToolResult | undefined;
@@ -103,4 +103,3 @@ export interface RunBackgroundDispatchArgs {
103
103
  }
104
104
  export declare function runBackgroundDispatch(args: RunBackgroundDispatchArgs): Promise<ToolResult>;
105
105
  export declare function checkNestedScope(nestedScope: readonly string[], requestedType: string | undefined): ToolResult | undefined;
106
- export declare function checkReadOnlyDispatchIntent(childWriteCapable: boolean, namedAgent: RegisteredAgent | undefined, prompt: string, classifyFn: (p: string) => boolean): ToolResult | undefined;
@@ -1,2 +1 @@
1
- export declare function classifyDispatchIntent(prompt: string): boolean;
2
1
  export declare function collectPostRunWarnings(model: string, hasAttachments: boolean, agentName: string | undefined, prompt: string, childWriteCapable: boolean, supportsVisionFn: (m: string) => boolean): string;
@@ -36,6 +36,7 @@ export declare const ToolCallCompletedPayloadSchema: z.ZodObject<{
36
36
  "repeat-failure": "repeat-failure";
37
37
  "no-such-target": "no-such-target";
38
38
  "hook-block-repeat": "hook-block-repeat";
39
+ "lost-args": "lost-args";
39
40
  }>>;
40
41
  batchIndex: z.ZodOptional<z.ZodNumber>;
41
42
  batchSize: z.ZodOptional<z.ZodNumber>;
@@ -73,6 +74,7 @@ export declare const ToolCallPayloadSchema: z.ZodDiscriminatedUnion<[z.ZodObject
73
74
  "repeat-failure": "repeat-failure";
74
75
  "no-such-target": "no-such-target";
75
76
  "hook-block-repeat": "hook-block-repeat";
77
+ "lost-args": "lost-args";
76
78
  }>>;
77
79
  batchIndex: z.ZodOptional<z.ZodNumber>;
78
80
  batchSize: z.ZodOptional<z.ZodNumber>;
@@ -339,6 +341,7 @@ export declare const TraceEventInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject
339
341
  "repeat-failure": "repeat-failure";
340
342
  "no-such-target": "no-such-target";
341
343
  "hook-block-repeat": "hook-block-repeat";
344
+ "lost-args": "lost-args";
342
345
  }>>;
343
346
  batchIndex: z.ZodOptional<z.ZodNumber>;
344
347
  batchSize: z.ZodOptional<z.ZodNumber>;
@@ -436,6 +439,7 @@ export declare const TraceEventInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject
436
439
  "repeat-failure": "repeat-failure";
437
440
  "no-such-target": "no-such-target";
438
441
  "hook-block-repeat": "hook-block-repeat";
442
+ "lost-args": "lost-args";
439
443
  }>>;
440
444
  }, z.core.$strip>, z.ZodObject<{
441
445
  provider: z.ZodOptional<z.ZodString>;
@@ -766,6 +770,7 @@ export declare const TraceEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
766
770
  "repeat-failure": "repeat-failure";
767
771
  "no-such-target": "no-such-target";
768
772
  "hook-block-repeat": "hook-block-repeat";
773
+ "lost-args": "lost-args";
769
774
  }>>;
770
775
  batchIndex: z.ZodOptional<z.ZodNumber>;
771
776
  batchSize: z.ZodOptional<z.ZodNumber>;
@@ -869,6 +874,7 @@ export declare const TraceEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
869
874
  "repeat-failure": "repeat-failure";
870
875
  "no-such-target": "no-such-target";
871
876
  "hook-block-repeat": "hook-block-repeat";
877
+ "lost-args": "lost-args";
872
878
  }>>;
873
879
  }, z.core.$strip>, z.ZodObject<{
874
880
  provider: z.ZodOptional<z.ZodString>;
@@ -11,6 +11,7 @@ export declare const ToolFailureClassSchema: z.ZodEnum<{
11
11
  "repeat-failure": "repeat-failure";
12
12
  "no-such-target": "no-such-target";
13
13
  "hook-block-repeat": "hook-block-repeat";
14
+ "lost-args": "lost-args";
14
15
  }>;
15
16
  export declare const SubagentStartedPayloadSchema: z.ZodObject<{
16
17
  transition: z.ZodLiteral<"started">;
@@ -65,6 +66,7 @@ export declare const SubagentFailedPayloadSchema: z.ZodObject<{
65
66
  "repeat-failure": "repeat-failure";
66
67
  "no-such-target": "no-such-target";
67
68
  "hook-block-repeat": "hook-block-repeat";
69
+ "lost-args": "lost-args";
68
70
  }>>;
69
71
  }, z.core.$strip>;
70
72
  export declare const SubagentCancelledPayloadSchema: z.ZodObject<{
@@ -134,6 +136,7 @@ export declare const SubagentLifecyclePayloadSchema: z.ZodDiscriminatedUnion<[z.
134
136
  "repeat-failure": "repeat-failure";
135
137
  "no-such-target": "no-such-target";
136
138
  "hook-block-repeat": "hook-block-repeat";
139
+ "lost-args": "lost-args";
137
140
  }>>;
138
141
  }, z.core.$strip>, z.ZodObject<{
139
142
  provider: z.ZodOptional<z.ZodString>;
@@ -8,7 +8,7 @@ export interface ToolCallStartedPayload {
8
8
  resourceFingerprint?: string;
9
9
  subagentId?: string;
10
10
  }
11
- export declare const TOOL_FAILURE_CLASSES: readonly ["policy-refusal", "timeout", "budget", "permission-denied", "hook-block", "abort", "elicitation-declined", "denial-breaker", "repeat-failure", "no-such-target", "hook-block-repeat"];
11
+ export declare const TOOL_FAILURE_CLASSES: readonly ["policy-refusal", "timeout", "budget", "permission-denied", "hook-block", "abort", "elicitation-declined", "denial-breaker", "repeat-failure", "no-such-target", "hook-block-repeat", "lost-args"];
12
12
  export type ToolFailureClass = (typeof TOOL_FAILURE_CLASSES)[number];
13
13
  export declare const BENIGN_FAILURE_CLASSES: ReadonlySet<ToolFailureClass>;
14
14
  export interface ToolCallCompletedPayload {