agent-afk 5.337.0 → 5.339.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/background-registry.mark-terminal.d.ts +1 -1
- package/dist/agent/background-registry.types.d.ts +1 -1
- package/dist/agent/file-checkpoint/bash-checkpoint.d.ts +5 -0
- package/dist/agent/file-checkpoint/file-checkpoint.d.ts +6 -0
- package/dist/agent/file-checkpoint/git-snapshot.attrs.d.ts +9 -0
- package/dist/agent/file-checkpoint/git-snapshot.d.ts +49 -0
- package/dist/agent/file-checkpoint/git-snapshot.diff.d.ts +27 -0
- package/dist/agent/file-checkpoint/git-snapshot.exec.d.ts +34 -0
- package/dist/agent/file-checkpoint/git-snapshot.index.d.ts +6 -0
- package/dist/agent/file-checkpoint/rewind-plan.d.ts +1 -0
- package/dist/agent/file-checkpoint/turn-log.d.ts +9 -1
- package/dist/agent/hooks.d.ts +1 -0
- package/dist/agent/provider.d.ts +1 -0
- package/dist/agent/providers/anthropic-direct/query-options.d.ts +1 -0
- package/dist/agent/providers/anthropic-direct/query-runtime.d.ts +1 -0
- package/dist/agent/providers/anthropic-direct/query-turn-driver.d.ts +1 -0
- package/dist/agent/providers/anthropic-direct/request-types.d.ts +1 -0
- package/dist/agent/providers/openai-compatible/query/turn-driver.d.ts +1 -0
- package/dist/agent/providers/openai-compatible/system-prompt-wiring.d.ts +10 -0
- package/dist/agent/providers/shared/prompt-fragment-tokens.d.ts +23 -0
- package/dist/agent/risk-classifier.d.ts +1 -1
- package/dist/agent/session/model-slots.d.ts +2 -0
- package/dist/agent/session/session-meta.d.ts +14 -0
- package/dist/agent/session/slot-credentials.d.ts +1 -0
- package/dist/agent/trace/events.d.ts +5 -0
- package/dist/agent/trace/events.session-phase.d.ts +2 -0
- package/dist/agent/trace/receipt.d.ts +5 -1
- package/dist/agent/trace/receipt.journal.d.ts +10 -0
- package/dist/agent/trace/types.session-phase.d.ts +1 -1
- package/dist/agent/types/config-types.d.ts +1 -0
- package/dist/agent/types/session-types.d.ts +1 -0
- package/dist/cli/commands/interactive/mascot-bar.d.ts +1 -0
- package/dist/cli/session-store.d.ts +1 -0
- package/dist/cli/terminal-compositor.frame.lines.d.ts +1 -1
- package/dist/cli/terminal-compositor.types.d.ts +1 -0
- package/dist/cli.mjs +589 -582
- package/dist/config/endpoint-semaphore.d.ts +9 -0
- package/dist/config/env.d.ts +56 -0
- package/dist/config/env.debug.d.ts +7 -0
- package/dist/config/env.file-checkpoint.d.ts +21 -0
- package/dist/config/env.model-slot-concurrency.d.ts +29 -0
- package/dist/config/env.session-storage.d.ts +21 -0
- package/dist/improve/propose/template-engine.templates-density.d.ts +2 -0
- package/dist/index.mjs +443 -434
- package/dist/paths.checkpoint.d.ts +2 -0
- package/dist/paths.d.ts +1 -1
- package/dist/paths.journal.d.ts +1 -0
- package/dist/telegram.mjs +471 -466
- package/dist/utils/errors.d.ts +2 -0
- package/dist/web-server/fork-ledger.d.ts +1 -0
- package/package.json +2 -1
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export interface EndpointSemaphore {
|
|
2
|
+
acquire(signal?: AbortSignal): Promise<void>;
|
|
3
|
+
release(): void;
|
|
4
|
+
readonly activeCount: number;
|
|
5
|
+
readonly limit: number;
|
|
6
|
+
}
|
|
7
|
+
export declare function getEndpointSemaphore(baseUrl: string | undefined, limit: number | undefined): EndpointSemaphore | null;
|
|
8
|
+
export declare function withEndpointSemaphore<T>(sem: EndpointSemaphore | null, fn: () => Promise<T>, signal?: AbortSignal): Promise<T>;
|
|
9
|
+
export declare function _resetEndpointSemaphores(): void;
|
package/dist/config/env.d.ts
CHANGED
|
@@ -474,6 +474,34 @@ export declare const ENV_REGISTRY: readonly [{
|
|
|
474
474
|
readonly required: false;
|
|
475
475
|
readonly example: "sonnet";
|
|
476
476
|
readonly category: "model";
|
|
477
|
+
}, {
|
|
478
|
+
readonly name: "AFK_MODEL_LOCAL_MAX_CONCURRENCY";
|
|
479
|
+
readonly description: string;
|
|
480
|
+
readonly type: "number";
|
|
481
|
+
readonly required: false;
|
|
482
|
+
readonly example: "1";
|
|
483
|
+
readonly category: "model";
|
|
484
|
+
}, {
|
|
485
|
+
readonly name: "AFK_MODEL_LARGE_MAX_CONCURRENCY";
|
|
486
|
+
readonly description: string;
|
|
487
|
+
readonly type: "number";
|
|
488
|
+
readonly required: false;
|
|
489
|
+
readonly example: "1";
|
|
490
|
+
readonly category: "model";
|
|
491
|
+
}, {
|
|
492
|
+
readonly name: "AFK_MODEL_MEDIUM_MAX_CONCURRENCY";
|
|
493
|
+
readonly description: string;
|
|
494
|
+
readonly type: "number";
|
|
495
|
+
readonly required: false;
|
|
496
|
+
readonly example: "1";
|
|
497
|
+
readonly category: "model";
|
|
498
|
+
}, {
|
|
499
|
+
readonly name: "AFK_MODEL_SMALL_MAX_CONCURRENCY";
|
|
500
|
+
readonly description: string;
|
|
501
|
+
readonly type: "number";
|
|
502
|
+
readonly required: false;
|
|
503
|
+
readonly example: "1";
|
|
504
|
+
readonly category: "model";
|
|
477
505
|
}, {
|
|
478
506
|
readonly name: "AFK_SUGGEST_ENABLED";
|
|
479
507
|
readonly description: "Enable the LLM-backed ghost-text suggestion tier in the interactive REPL. On by default. Set to 0/false/no/off to disable.";
|
|
@@ -1356,6 +1384,13 @@ export declare const ENV_REGISTRY: readonly [{
|
|
|
1356
1384
|
readonly required: false;
|
|
1357
1385
|
readonly example: "1";
|
|
1358
1386
|
readonly category: "debug";
|
|
1387
|
+
}, {
|
|
1388
|
+
readonly name: "AFK_RUN_RECEIPT_TEXT_DISABLED";
|
|
1389
|
+
readonly description: string;
|
|
1390
|
+
readonly type: "boolean";
|
|
1391
|
+
readonly required: false;
|
|
1392
|
+
readonly example: "1";
|
|
1393
|
+
readonly category: "debug";
|
|
1359
1394
|
}, {
|
|
1360
1395
|
readonly name: "AFK_SUBAGENT_RESULT_CAP_BYTES";
|
|
1361
1396
|
readonly description: string;
|
|
@@ -1439,6 +1474,27 @@ export declare const ENV_REGISTRY: readonly [{
|
|
|
1439
1474
|
readonly required: false;
|
|
1440
1475
|
readonly example: "1";
|
|
1441
1476
|
readonly category: "process";
|
|
1477
|
+
}, {
|
|
1478
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_DISABLE";
|
|
1479
|
+
readonly description: "Disable best-effort git-backed capture of foreground bash file changes for /rewind.";
|
|
1480
|
+
readonly type: "boolean";
|
|
1481
|
+
readonly required: false;
|
|
1482
|
+
readonly example: "1";
|
|
1483
|
+
readonly category: "debug";
|
|
1484
|
+
}, {
|
|
1485
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_TIMEOUT_MS";
|
|
1486
|
+
readonly description: "Maximum milliseconds per bash checkpoint capture or diff. Default 5000.";
|
|
1487
|
+
readonly type: "number";
|
|
1488
|
+
readonly required: false;
|
|
1489
|
+
readonly default: "5000";
|
|
1490
|
+
readonly category: "debug";
|
|
1491
|
+
}, {
|
|
1492
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_MAX_FILES";
|
|
1493
|
+
readonly description: "Maximum changed files captured per bash call; larger diffs are reported as partial. Default 1000.";
|
|
1494
|
+
readonly type: "number";
|
|
1495
|
+
readonly required: false;
|
|
1496
|
+
readonly default: "1000";
|
|
1497
|
+
readonly category: "debug";
|
|
1442
1498
|
}, {
|
|
1443
1499
|
readonly name: "AFK_FILE_CHECKPOINT_RETENTION_DISABLE";
|
|
1444
1500
|
readonly description: string;
|
|
@@ -97,6 +97,13 @@ export declare const DEBUG_ENV_REGISTRY: readonly [{
|
|
|
97
97
|
readonly required: false;
|
|
98
98
|
readonly example: "1";
|
|
99
99
|
readonly category: "debug";
|
|
100
|
+
}, {
|
|
101
|
+
readonly name: "AFK_RUN_RECEIPT_TEXT_DISABLED";
|
|
102
|
+
readonly description: string;
|
|
103
|
+
readonly type: "boolean";
|
|
104
|
+
readonly required: false;
|
|
105
|
+
readonly example: "1";
|
|
106
|
+
readonly category: "debug";
|
|
100
107
|
}, {
|
|
101
108
|
readonly name: "AFK_SUBAGENT_RESULT_CAP_BYTES";
|
|
102
109
|
readonly description: string;
|
|
@@ -1,4 +1,25 @@
|
|
|
1
1
|
export declare const FILE_CHECKPOINT_ENV_REGISTRY: readonly [{
|
|
2
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_DISABLE";
|
|
3
|
+
readonly description: "Disable best-effort git-backed capture of foreground bash file changes for /rewind.";
|
|
4
|
+
readonly type: "boolean";
|
|
5
|
+
readonly required: false;
|
|
6
|
+
readonly example: "1";
|
|
7
|
+
readonly category: "debug";
|
|
8
|
+
}, {
|
|
9
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_TIMEOUT_MS";
|
|
10
|
+
readonly description: "Maximum milliseconds per bash checkpoint capture or diff. Default 5000.";
|
|
11
|
+
readonly type: "number";
|
|
12
|
+
readonly required: false;
|
|
13
|
+
readonly default: "5000";
|
|
14
|
+
readonly category: "debug";
|
|
15
|
+
}, {
|
|
16
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_MAX_FILES";
|
|
17
|
+
readonly description: "Maximum changed files captured per bash call; larger diffs are reported as partial. Default 1000.";
|
|
18
|
+
readonly type: "number";
|
|
19
|
+
readonly required: false;
|
|
20
|
+
readonly default: "1000";
|
|
21
|
+
readonly category: "debug";
|
|
22
|
+
}, {
|
|
2
23
|
readonly name: "AFK_FILE_CHECKPOINT_RETENTION_DISABLE";
|
|
3
24
|
readonly description: string;
|
|
4
25
|
readonly type: "boolean";
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
export declare const MODEL_SLOT_CONCURRENCY_ENV_REGISTRY: readonly [{
|
|
2
|
+
readonly name: "AFK_MODEL_LOCAL_MAX_CONCURRENCY";
|
|
3
|
+
readonly description: string;
|
|
4
|
+
readonly type: "number";
|
|
5
|
+
readonly required: false;
|
|
6
|
+
readonly example: "1";
|
|
7
|
+
readonly category: "model";
|
|
8
|
+
}, {
|
|
9
|
+
readonly name: "AFK_MODEL_LARGE_MAX_CONCURRENCY";
|
|
10
|
+
readonly description: string;
|
|
11
|
+
readonly type: "number";
|
|
12
|
+
readonly required: false;
|
|
13
|
+
readonly example: "1";
|
|
14
|
+
readonly category: "model";
|
|
15
|
+
}, {
|
|
16
|
+
readonly name: "AFK_MODEL_MEDIUM_MAX_CONCURRENCY";
|
|
17
|
+
readonly description: string;
|
|
18
|
+
readonly type: "number";
|
|
19
|
+
readonly required: false;
|
|
20
|
+
readonly example: "1";
|
|
21
|
+
readonly category: "model";
|
|
22
|
+
}, {
|
|
23
|
+
readonly name: "AFK_MODEL_SMALL_MAX_CONCURRENCY";
|
|
24
|
+
readonly description: string;
|
|
25
|
+
readonly type: "number";
|
|
26
|
+
readonly required: false;
|
|
27
|
+
readonly example: "1";
|
|
28
|
+
readonly category: "model";
|
|
29
|
+
}];
|
|
@@ -19,6 +19,27 @@ export declare const SESSION_STORAGE_ENV_REGISTRY: readonly [{
|
|
|
19
19
|
readonly required: false;
|
|
20
20
|
readonly example: "1";
|
|
21
21
|
readonly category: "process";
|
|
22
|
+
}, {
|
|
23
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_DISABLE";
|
|
24
|
+
readonly description: "Disable best-effort git-backed capture of foreground bash file changes for /rewind.";
|
|
25
|
+
readonly type: "boolean";
|
|
26
|
+
readonly required: false;
|
|
27
|
+
readonly example: "1";
|
|
28
|
+
readonly category: "debug";
|
|
29
|
+
}, {
|
|
30
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_TIMEOUT_MS";
|
|
31
|
+
readonly description: "Maximum milliseconds per bash checkpoint capture or diff. Default 5000.";
|
|
32
|
+
readonly type: "number";
|
|
33
|
+
readonly required: false;
|
|
34
|
+
readonly default: "5000";
|
|
35
|
+
readonly category: "debug";
|
|
36
|
+
}, {
|
|
37
|
+
readonly name: "AFK_FILE_CHECKPOINT_BASH_MAX_FILES";
|
|
38
|
+
readonly description: "Maximum changed files captured per bash call; larger diffs are reported as partial. Default 1000.";
|
|
39
|
+
readonly type: "number";
|
|
40
|
+
readonly required: false;
|
|
41
|
+
readonly default: "1000";
|
|
42
|
+
readonly category: "debug";
|
|
22
43
|
}, {
|
|
23
44
|
readonly name: "AFK_FILE_CHECKPOINT_RETENTION_DISABLE";
|
|
24
45
|
readonly description: string;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { FailureCard, LikelyFile, ValidationPlan } from '../schemas.js';
|
|
2
2
|
import type { RootCauseClass, Severity } from '../schemas.js';
|
|
3
|
+
export declare function rootCauseFromClusterKey(key: string): RootCauseClass;
|
|
4
|
+
export declare function likelyFilesForTool(toolName: string): readonly LikelyFile[];
|
|
3
5
|
interface PatternTemplate {
|
|
4
6
|
rootCauseClass: RootCauseClass;
|
|
5
7
|
hypothesis(card: FailureCard): string;
|