agent-afk 5.15.12 → 5.16.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/session/agent-session.d.ts +4 -1
- package/dist/agent/types/permission-types.d.ts +1 -0
- package/dist/agent/types/session-types.d.ts +1 -1
- package/dist/agent/worktree-sweep.d.ts +3 -21
- package/dist/cli/commands/interactive/tool-lane.d.ts +1 -0
- package/dist/cli/errors/classifier.d.ts +2 -1
- package/dist/cli/errors/index.d.ts +1 -1
- package/dist/cli/formatter.d.ts +0 -21
- package/dist/cli/palette.d.ts +0 -1
- package/dist/cli/slash/index.d.ts +0 -1
- package/dist/cli.mjs +404 -407
- package/dist/index.mjs +8 -4
- package/dist/skills/_lib/emit-card.d.ts +0 -1
- package/dist/telegram.mjs +114 -110
- package/dist/utils/errors.d.ts +0 -13
- package/package.json +1 -1
- package/dist/cli/slash/registry-exports.d.ts +0 -2
- package/dist/skills/example-template/index.d.ts +0 -1
- package/dist/telegram/example.d.ts +0 -1
- package/dist/telemetry/schemas.d.ts +0 -10
- package/dist/utils/CircularBuffer.d.ts +0 -13
- package/dist/utils/envUtils.d.ts +0 -2
- package/dist/utils/json.d.ts +0 -1
- package/dist/utils/memoize.d.ts +0 -9
|
@@ -13,6 +13,7 @@ export declare class AgentSession implements IAgentSession {
|
|
|
13
13
|
private providerIterator;
|
|
14
14
|
private conversationHistory;
|
|
15
15
|
private turnCount;
|
|
16
|
+
private pendingFrameworkContext;
|
|
16
17
|
private lastResponseMetadata;
|
|
17
18
|
private initPromise;
|
|
18
19
|
private inputStream;
|
|
@@ -78,7 +79,9 @@ export declare class AgentSession implements IAgentSession {
|
|
|
78
79
|
compact(): Promise<ProviderCompactResult>;
|
|
79
80
|
getLastResponseMetadata(): ResponseMetadata | null;
|
|
80
81
|
getOutputStream(): AsyncIterable<OutputEvent>;
|
|
81
|
-
|
|
82
|
+
queueFrameworkContext(text: string): void;
|
|
83
|
+
private withPendingFrameworkContext;
|
|
84
|
+
getInputStreamRef(): Pick<InputStreamRef, 'pushUserMessage' | 'queueFrameworkContext'>;
|
|
82
85
|
getHistory(): readonly Message[];
|
|
83
86
|
getTurnCount(): number;
|
|
84
87
|
close(): Promise<void>;
|
|
@@ -119,7 +119,7 @@ export interface IAgentSession {
|
|
|
119
119
|
getQuery(): ProviderQuery;
|
|
120
120
|
getLastResponseMetadata(): ResponseMetadata | null;
|
|
121
121
|
getOutputStream(): AsyncIterable<OutputEvent>;
|
|
122
|
-
getInputStreamRef(): Pick<InputStreamRef, 'pushUserMessage'>;
|
|
122
|
+
getInputStreamRef(): Pick<InputStreamRef, 'pushUserMessage' | 'queueFrameworkContext'>;
|
|
123
123
|
supportedCommands(): Promise<SlashCommand[]>;
|
|
124
124
|
supportedModels(): Promise<ModelInfo[]>;
|
|
125
125
|
supportedAgents(): Promise<AgentInfo[]>;
|
|
@@ -5,26 +5,7 @@ export type ExecFileFn = (file: string, args: string[], opts?: {
|
|
|
5
5
|
stdout: string;
|
|
6
6
|
stderr: string;
|
|
7
7
|
}>;
|
|
8
|
-
|
|
9
|
-
owner: 'interactive' | 'diagnose' | string;
|
|
10
|
-
pid?: number;
|
|
11
|
-
createdAt: string;
|
|
12
|
-
baseSha?: string;
|
|
13
|
-
baseBranch?: string;
|
|
14
|
-
}
|
|
15
|
-
export interface WorktreeCandidate {
|
|
16
|
-
path: string;
|
|
17
|
-
head?: string;
|
|
18
|
-
branch?: string;
|
|
19
|
-
locked: boolean;
|
|
20
|
-
prunable: boolean;
|
|
21
|
-
meta?: WorktreeMeta;
|
|
22
|
-
ageMs: number;
|
|
23
|
-
isDirty: boolean;
|
|
24
|
-
commitsAhead: number;
|
|
25
|
-
ownerLiveness: 'alive' | 'dead' | 'unknown';
|
|
26
|
-
}
|
|
27
|
-
export type WorktreeVerdict = 'empty' | 'stale-clean' | 'stale-dirty' | 'locked' | 'active' | 'orphaned-dir' | 'orphaned-registration' | 'dead-owner';
|
|
8
|
+
type WorktreeVerdict = 'empty' | 'stale-clean' | 'stale-dirty' | 'locked' | 'active' | 'orphaned-dir' | 'orphaned-registration' | 'dead-owner';
|
|
28
9
|
export interface SweepOptions {
|
|
29
10
|
execFile: ExecFileFn;
|
|
30
11
|
repoRoot: string;
|
|
@@ -37,7 +18,7 @@ export interface SweepOptions {
|
|
|
37
18
|
bypassSoftLaunch?: boolean;
|
|
38
19
|
readPresence?: () => Promise<PresenceRecord[]>;
|
|
39
20
|
}
|
|
40
|
-
|
|
21
|
+
interface SweepCandidateSummary {
|
|
41
22
|
path: string;
|
|
42
23
|
verdict: WorktreeVerdict;
|
|
43
24
|
owner: 'interactive' | 'diagnose' | 'unknown';
|
|
@@ -50,3 +31,4 @@ export interface SweepResult {
|
|
|
50
31
|
candidates: SweepCandidateSummary[];
|
|
51
32
|
}
|
|
52
33
|
export declare function runSweep(options: SweepOptions): Promise<SweepResult>;
|
|
34
|
+
export {};
|
|
@@ -21,6 +21,7 @@ export declare class ToolLane {
|
|
|
21
21
|
hasPending(): boolean;
|
|
22
22
|
hasEntry(id: string): boolean;
|
|
23
23
|
findLastSkillEntryId(): string | undefined;
|
|
24
|
+
peekTrailingCompletedRootToolName(): string | undefined;
|
|
24
25
|
getOverlay(): string;
|
|
25
26
|
private ancestorDepthOf;
|
|
26
27
|
flushSource(parentId: string, homeDir?: string): string[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
type ErrorKind = 'auth' | 'rate_limit' | 'overloaded' | 'budget_exceeded' | 'unsupported_config' | 'hook_blocked' | 'timeout' | 'network' | 'not_git_repo' | 'unknown';
|
|
2
2
|
export interface ClassifiedError {
|
|
3
3
|
kind: ErrorKind;
|
|
4
4
|
userMessage: string;
|
|
@@ -7,3 +7,4 @@ export interface ClassifiedError {
|
|
|
7
7
|
raw: unknown;
|
|
8
8
|
}
|
|
9
9
|
export declare function classifyError(err: unknown): ClassifiedError;
|
|
10
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export declare function handleCommandError(err: unknown): never;
|
|
2
2
|
export { classifyError } from './classifier.js';
|
|
3
3
|
export { presentError } from './presenter.js';
|
|
4
|
-
export type { ClassifiedError
|
|
4
|
+
export type { ClassifiedError } from './classifier.js';
|
package/dist/cli/formatter.d.ts
CHANGED
|
@@ -3,25 +3,4 @@ interface RenderMarkdownOptions {
|
|
|
3
3
|
}
|
|
4
4
|
export declare function renderCardLine(text: string): string;
|
|
5
5
|
export declare function renderMarkdownToTerminal(text: string, opts?: RenderMarkdownOptions): string;
|
|
6
|
-
export declare class OutputFormatter {
|
|
7
|
-
private useColors;
|
|
8
|
-
constructor(useColors?: boolean);
|
|
9
|
-
formatMarkdown(text: string): string;
|
|
10
|
-
formatError(message: string, error?: Error): string;
|
|
11
|
-
formatSuccess(message: string): string;
|
|
12
|
-
formatInfo(message: string): string;
|
|
13
|
-
formatWarning(message: string): string;
|
|
14
|
-
formatCommand(command: string): string;
|
|
15
|
-
formatPrompt(modelName: string): string;
|
|
16
|
-
formatModelInfo(model: string, maxTokens: number, temp: number): string;
|
|
17
|
-
separator(char?: string, width?: number): string;
|
|
18
|
-
formatHelp(sections: {
|
|
19
|
-
title: string;
|
|
20
|
-
items: string[];
|
|
21
|
-
}[]): string;
|
|
22
|
-
formatStreaming(text: string): string;
|
|
23
|
-
}
|
|
24
|
-
export declare const formatter: OutputFormatter;
|
|
25
|
-
export declare function truncate(text: string, maxLength: number): string;
|
|
26
|
-
export declare function wordWrap(text: string, width: number): string;
|
|
27
6
|
export {};
|
package/dist/cli/palette.d.ts
CHANGED