agent-afk 5.302.0 → 5.302.2
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/bg-job-log.d.ts +4 -0
- package/dist/agent/bg-job-log.orphan.d.ts +3 -0
- package/dist/agent/trace/events.d.ts +2 -138
- package/dist/agent/trace/events.subagent-lifecycle.d.ts +2 -0
- package/dist/bundled-plugins/awa-bundled/skills/automate/SKILL.md +1 -1
- package/dist/bundled-plugins/awa-bundled/skills/shadow-verify/SKILL.md +1 -1
- package/dist/cli.mjs +334 -334
- package/dist/index.mjs +139 -139
- package/dist/telegram.mjs +162 -162
- package/package.json +1 -1
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
import { reconcileOrphanedMeta } from './bg-job-log.orphan.js';
|
|
1
2
|
import type { OutputEvent } from './types/session-types.js';
|
|
3
|
+
export { reconcileOrphanedMeta };
|
|
2
4
|
export interface BgJobMeta {
|
|
3
5
|
jobId: string;
|
|
4
6
|
subagentId: string;
|
|
@@ -10,6 +12,8 @@ export interface BgJobMeta {
|
|
|
10
12
|
status: 'running' | 'completed' | 'failed' | 'cancelled';
|
|
11
13
|
parentSessionId?: string;
|
|
12
14
|
stopReason?: string;
|
|
15
|
+
ownerPid?: number;
|
|
16
|
+
ownerStartTime?: number;
|
|
13
17
|
schemaVersion: 1;
|
|
14
18
|
}
|
|
15
19
|
export interface BgJobResult {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
export { BackgroundAgentCancelledPayloadSchema } from './background-agent-schema.js';
|
|
2
|
+
export { BackgroundAgentCancelledPayloadSchema, BackgroundAgentCompletedPayloadSchema, BackgroundAgentDeliveredPayloadSchema, BackgroundAgentFailedPayloadSchema, BackgroundAgentJoinedPayloadSchema, BackgroundAgentStartedPayloadSchema, } from './background-agent-schema.js';
|
|
3
|
+
export { SubagentStartedPayloadSchema, SubagentSucceededPayloadSchema, SubagentFailedPayloadSchema, SubagentCancelledPayloadSchema, SubagentLifecyclePayloadSchema, } from './events.subagent-lifecycle.js';
|
|
3
4
|
export { BrowserEventToolSchema, BrowserActActionSchema, BrowserEventTargetSchema, BrowserEventPayloadSchema, } from './events.browser.js';
|
|
4
5
|
export { CompactionTriggerSchema, CompactionSidecarRefSchema, CompactionPayloadInputSchema, CompactionPayloadPersistedSchema, } from './events.compaction.js';
|
|
5
6
|
export { SessionPhaseNameSchema, SessionPhasePayloadSchema } from './events.session-phase.js';
|
|
@@ -126,143 +127,6 @@ export declare const HookDecisionPayloadSchema: z.ZodObject<{
|
|
|
126
127
|
"hard-block": "hard-block";
|
|
127
128
|
}>>;
|
|
128
129
|
}, z.core.$strip>;
|
|
129
|
-
export declare const SubagentStartedPayloadSchema: z.ZodObject<{
|
|
130
|
-
transition: z.ZodLiteral<"started">;
|
|
131
|
-
subagentId: z.ZodString;
|
|
132
|
-
parentId: z.ZodString;
|
|
133
|
-
model: z.ZodString;
|
|
134
|
-
allowedTools: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
|
|
135
|
-
systemPromptHash: z.ZodOptional<z.ZodString>;
|
|
136
|
-
promptHead: z.ZodOptional<z.ZodString>;
|
|
137
|
-
agentType: z.ZodOptional<z.ZodString>;
|
|
138
|
-
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
139
|
-
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
140
|
-
}, z.core.$strip>;
|
|
141
|
-
export declare const SubagentSucceededPayloadSchema: z.ZodObject<{
|
|
142
|
-
transition: z.ZodLiteral<"succeeded">;
|
|
143
|
-
subagentId: z.ZodString;
|
|
144
|
-
durationMs: z.ZodNumber;
|
|
145
|
-
turnCount: z.ZodNumber;
|
|
146
|
-
totalCostUsd: z.ZodOptional<z.ZodNumber>;
|
|
147
|
-
outputBytes: z.ZodNumber;
|
|
148
|
-
stopReason: z.ZodOptional<z.ZodString>;
|
|
149
|
-
}, z.core.$strip>;
|
|
150
|
-
export declare const SubagentFailedPayloadSchema: z.ZodObject<{
|
|
151
|
-
transition: z.ZodLiteral<"failed">;
|
|
152
|
-
subagentId: z.ZodString;
|
|
153
|
-
errorClass: z.ZodString;
|
|
154
|
-
errorMessage: z.ZodString;
|
|
155
|
-
partialOutputBytes: z.ZodNumber;
|
|
156
|
-
failureClass: z.ZodOptional<z.ZodEnum<{
|
|
157
|
-
budget: "budget";
|
|
158
|
-
abort: "abort";
|
|
159
|
-
"policy-refusal": "policy-refusal";
|
|
160
|
-
timeout: "timeout";
|
|
161
|
-
"permission-denied": "permission-denied";
|
|
162
|
-
"hook-block": "hook-block";
|
|
163
|
-
"elicitation-declined": "elicitation-declined";
|
|
164
|
-
"denial-breaker": "denial-breaker";
|
|
165
|
-
"repeat-failure": "repeat-failure";
|
|
166
|
-
"no-such-target": "no-such-target";
|
|
167
|
-
}>>;
|
|
168
|
-
}, z.core.$strip>;
|
|
169
|
-
export declare const SubagentCancelledPayloadSchema: z.ZodObject<{
|
|
170
|
-
transition: z.ZodLiteral<"cancelled">;
|
|
171
|
-
subagentId: z.ZodString;
|
|
172
|
-
source: z.ZodEnum<{
|
|
173
|
-
explicit: "explicit";
|
|
174
|
-
cascade: "cascade";
|
|
175
|
-
}>;
|
|
176
|
-
timeout: z.ZodOptional<z.ZodBoolean>;
|
|
177
|
-
}, z.core.$strip>;
|
|
178
|
-
export declare const SubagentLifecyclePayloadSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
179
|
-
transition: z.ZodLiteral<"started">;
|
|
180
|
-
subagentId: z.ZodString;
|
|
181
|
-
parentId: z.ZodString;
|
|
182
|
-
model: z.ZodString;
|
|
183
|
-
allowedTools: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodString>>>;
|
|
184
|
-
systemPromptHash: z.ZodOptional<z.ZodString>;
|
|
185
|
-
promptHead: z.ZodOptional<z.ZodString>;
|
|
186
|
-
agentType: z.ZodOptional<z.ZodString>;
|
|
187
|
-
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
188
|
-
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
189
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
190
|
-
transition: z.ZodLiteral<"succeeded">;
|
|
191
|
-
subagentId: z.ZodString;
|
|
192
|
-
durationMs: z.ZodNumber;
|
|
193
|
-
turnCount: z.ZodNumber;
|
|
194
|
-
totalCostUsd: z.ZodOptional<z.ZodNumber>;
|
|
195
|
-
outputBytes: z.ZodNumber;
|
|
196
|
-
stopReason: z.ZodOptional<z.ZodString>;
|
|
197
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
198
|
-
transition: z.ZodLiteral<"failed">;
|
|
199
|
-
subagentId: z.ZodString;
|
|
200
|
-
errorClass: z.ZodString;
|
|
201
|
-
errorMessage: z.ZodString;
|
|
202
|
-
partialOutputBytes: z.ZodNumber;
|
|
203
|
-
failureClass: z.ZodOptional<z.ZodEnum<{
|
|
204
|
-
budget: "budget";
|
|
205
|
-
abort: "abort";
|
|
206
|
-
"policy-refusal": "policy-refusal";
|
|
207
|
-
timeout: "timeout";
|
|
208
|
-
"permission-denied": "permission-denied";
|
|
209
|
-
"hook-block": "hook-block";
|
|
210
|
-
"elicitation-declined": "elicitation-declined";
|
|
211
|
-
"denial-breaker": "denial-breaker";
|
|
212
|
-
"repeat-failure": "repeat-failure";
|
|
213
|
-
"no-such-target": "no-such-target";
|
|
214
|
-
}>>;
|
|
215
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
216
|
-
transition: z.ZodLiteral<"cancelled">;
|
|
217
|
-
subagentId: z.ZodString;
|
|
218
|
-
source: z.ZodEnum<{
|
|
219
|
-
explicit: "explicit";
|
|
220
|
-
cascade: "cascade";
|
|
221
|
-
}>;
|
|
222
|
-
timeout: z.ZodOptional<z.ZodBoolean>;
|
|
223
|
-
}, z.core.$strip>], "transition">;
|
|
224
|
-
export declare const BackgroundAgentStartedPayloadSchema: z.ZodObject<{
|
|
225
|
-
transition: z.ZodLiteral<"started">;
|
|
226
|
-
jobId: z.ZodString;
|
|
227
|
-
subagentId: z.ZodString;
|
|
228
|
-
label: z.ZodString;
|
|
229
|
-
model: z.ZodString;
|
|
230
|
-
}, z.core.$strip>;
|
|
231
|
-
export declare const BackgroundAgentCompletedPayloadSchema: z.ZodObject<{
|
|
232
|
-
transition: z.ZodLiteral<"completed">;
|
|
233
|
-
jobId: z.ZodString;
|
|
234
|
-
subagentId: z.ZodString;
|
|
235
|
-
durationMs: z.ZodNumber;
|
|
236
|
-
outputBytes: z.ZodNumber;
|
|
237
|
-
}, z.core.$strip>;
|
|
238
|
-
export declare const BackgroundAgentFailedPayloadSchema: z.ZodObject<{
|
|
239
|
-
transition: z.ZodLiteral<"failed">;
|
|
240
|
-
jobId: z.ZodString;
|
|
241
|
-
subagentId: z.ZodString;
|
|
242
|
-
durationMs: z.ZodNumber;
|
|
243
|
-
errorClass: z.ZodString;
|
|
244
|
-
errorMessage: z.ZodString;
|
|
245
|
-
}, z.core.$strip>;
|
|
246
|
-
export declare const BackgroundAgentJoinedPayloadSchema: z.ZodObject<{
|
|
247
|
-
transition: z.ZodLiteral<"joined">;
|
|
248
|
-
jobId: z.ZodString;
|
|
249
|
-
subagentId: z.ZodString;
|
|
250
|
-
jobStatus: z.ZodEnum<{
|
|
251
|
-
failed: "failed";
|
|
252
|
-
completed: "completed";
|
|
253
|
-
cancelled: "cancelled";
|
|
254
|
-
}>;
|
|
255
|
-
}, z.core.$strip>;
|
|
256
|
-
export declare const BackgroundAgentDeliveredPayloadSchema: z.ZodObject<{
|
|
257
|
-
transition: z.ZodLiteral<"delivered">;
|
|
258
|
-
jobId: z.ZodString;
|
|
259
|
-
subagentId: z.ZodString;
|
|
260
|
-
jobStatus: z.ZodEnum<{
|
|
261
|
-
failed: "failed";
|
|
262
|
-
completed: "completed";
|
|
263
|
-
cancelled: "cancelled";
|
|
264
|
-
}>;
|
|
265
|
-
}, z.core.$strip>;
|
|
266
130
|
export declare const BackgroundAgentPayloadSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
267
131
|
transition: z.ZodLiteral<"started">;
|
|
268
132
|
jobId: z.ZodString;
|
|
@@ -21,6 +21,7 @@ export declare const SubagentStartedPayloadSchema: z.ZodObject<{
|
|
|
21
21
|
promptHead: z.ZodOptional<z.ZodString>;
|
|
22
22
|
agentType: z.ZodOptional<z.ZodString>;
|
|
23
23
|
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
24
|
+
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
24
25
|
}, z.core.$strip>;
|
|
25
26
|
export declare const SubagentSucceededPayloadSchema: z.ZodObject<{
|
|
26
27
|
transition: z.ZodLiteral<"succeeded">;
|
|
@@ -69,6 +70,7 @@ export declare const SubagentLifecyclePayloadSchema: z.ZodDiscriminatedUnion<[z.
|
|
|
69
70
|
promptHead: z.ZodOptional<z.ZodString>;
|
|
70
71
|
agentType: z.ZodOptional<z.ZodString>;
|
|
71
72
|
resolvedAgentType: z.ZodOptional<z.ZodString>;
|
|
73
|
+
maxToolUseIterations: z.ZodOptional<z.ZodNumber>;
|
|
72
74
|
}, z.core.$strip>, z.ZodObject<{
|
|
73
75
|
transition: z.ZodLiteral<"succeeded">;
|
|
74
76
|
subagentId: z.ZodString;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: automate
|
|
3
|
-
description: "Set up a scheduled headless afk run that pushes a summary to Telegram.
|
|
3
|
+
description: "Set up a scheduled headless afk run that pushes a summary to Telegram. Use when the user wants to automate a recurring task via the afk daemon scheduler (cron) with push-notified results."
|
|
4
4
|
disable-model-invocation: true
|
|
5
5
|
context: load
|
|
6
6
|
failure_modes:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: shadow-verify
|
|
3
|
-
description: "Dispatch a parallel adversarial verifier wave after any high-stakes sub-agent investigation (code reviews, audits, findings reports, large refactors, gap analyses) — or whenever a sub-agent asserts a claim with high-confidence language
|
|
3
|
+
description: "Dispatch a parallel adversarial verifier wave after any high-stakes sub-agent investigation (code reviews, audits, findings reports, large refactors, gap analyses) — or whenever a sub-agent asserts a claim with high-confidence language, since confidence is a trigger, not a verdict. Use when sub-agent output will drive decisions, file changes, commits, or external side-effects."
|
|
4
4
|
argument-hint: "[--findings-list <file | inline-findings>] [--goal <session-goal>] [--action <planned-action>]"
|
|
5
5
|
context: load
|
|
6
6
|
---
|