agent-afk 5.212.12 → 5.213.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.
@@ -2,6 +2,7 @@ import type { Writer } from '../slash/types.js';
2
2
  import type { TerminalCompositor } from '../terminal-compositor.js';
3
3
  import type { OverlayComposer } from './overlay-composer.js';
4
4
  import type { ToolLane } from '../commands/interactive/tool-lane.js';
5
+ import type { ToolLaneFlash } from '../commands/interactive/tool-lane-flash.js';
5
6
  import type { CommitCoordinator } from './commit-coordinator.js';
6
7
  import type { StreamingMarkdownRenderer } from '../markdown-stream.js';
7
8
  export interface DisposeCtx {
@@ -15,6 +16,7 @@ export interface DisposeCtx {
15
16
  current: OverlayComposer | null;
16
17
  };
17
18
  toolLane: ToolLane;
19
+ toolLaneFlash: ToolLaneFlash | null;
18
20
  streamingMarkdownRef: {
19
21
  current: StreamingMarkdownRenderer | null;
20
22
  };
@@ -35,6 +35,7 @@ export declare class StreamRenderer {
35
35
  private childActivity;
36
36
  private inFlightTools;
37
37
  private disposed;
38
+ private toolLaneFlash;
38
39
  private pauseTickInterval;
39
40
  private resizeUnsub;
40
41
  private subagentTickInterval;
@@ -49,6 +50,7 @@ export declare class StreamRenderer {
49
50
  constructor(opts: StreamRendererOptions);
50
51
  arm(): Promise<void>;
51
52
  getCompositor(): TerminalCompositor | null;
53
+ private deferFlush;
52
54
  setInterrupting(active: boolean): void;
53
55
  setSoftStopping(active: boolean): void;
54
56
  stripPendingTerminalState(headingOffset: number): boolean;
@@ -0,0 +1,2 @@
1
+ import type { InteractiveCtx } from './shared.js';
2
+ export declare function runFirstTurnHookIfNeeded(ctx: InteractiveCtx, text: string): Promise<void>;
@@ -0,0 +1,13 @@
1
+ export declare class MomentumTicker {
2
+ private readonly onRepaint;
3
+ private running;
4
+ private smoothedRate;
5
+ private lastSampleMs;
6
+ private pendingChars;
7
+ private lastRepaintMs;
8
+ constructor(onRepaint?: (rate: number | null) => void);
9
+ start(): void;
10
+ update(charCount: number): void;
11
+ getCurrentRate(): number | null;
12
+ stop(): void;
13
+ }
@@ -121,6 +121,7 @@ export interface TurnHandles {
121
121
  bashTailSetter?: {
122
122
  current: ((toolUseId: string, tail: string | undefined) => void) | undefined;
123
123
  };
124
+ onTextDelta?(charCount: number): void;
124
125
  }
125
126
  export declare const REPL_SPINNER_OPTIONS: {
126
127
  readonly stream: NodeJS.WriteStream & {
@@ -0,0 +1,11 @@
1
+ export declare const FLASH_DURATION_MS = 150;
2
+ export declare class ToolLaneFlash {
3
+ private readonly onRepaint;
4
+ private readonly flashing;
5
+ private readonly timers;
6
+ private disposed;
7
+ constructor(onRepaint: () => void);
8
+ flashTool(toolUseId: string): void;
9
+ isFlashing(toolUseId: string): boolean;
10
+ dispose(): void;
11
+ }
@@ -51,3 +51,4 @@ export { assignConnectors, addOverflowSynthetic, addResultSummarySynthetic, type
51
51
  export { renderOverlayChildren, renderFlushChildren } from './tool-lane-render-children.js';
52
52
  export { formatAgentSummary, formatAgentHeader, formatAgentChildren, } from './tool-lane-render-agent.js';
53
53
  export { renderGroupedRootTools, formatGroupedToolResults, } from './tool-lane-render-grouped-root.js';
54
+ export declare function buildChildMap(entries: ReadonlyMap<string, Entry>, order: readonly string[]): Map<string, Entry[]>;
@@ -2,6 +2,7 @@ import type { ToolResultChunk } from '../../../agent/types/message-types.js';
2
2
  import { formatToolLine, formatToolResultLine } from './tool-lane-format.js';
3
3
  import type { DiffPayload } from '../../../utils/diff.js';
4
4
  import { type ToolEntry, type TextEntry, type Entry } from './tool-lane-render.js';
5
+ import type { ToolLaneFlash } from './tool-lane-flash.js';
5
6
  export type { ToolEntry, TextEntry, Entry };
6
7
  export declare const MAX_OVERLAY_ROOTS = 6;
7
8
  export declare class ToolLane {
@@ -10,6 +11,7 @@ export declare class ToolLane {
10
11
  private agentIdStack;
11
12
  private lastElapsedSecond;
12
13
  private activeTools;
14
+ flash: ToolLaneFlash | null;
13
15
  addStart(toolUseId: string, toolName: string, toolInput: string): void;
14
16
  addStartWithAgentContext(toolUseId: string, toolName: string, toolInput: string, agentContext: string | undefined, maxWidth?: number): void;
15
17
  mergeAgentLabel(parentToolUseId: string, label: string, maxWidth?: number): boolean;
@@ -33,6 +35,5 @@ export declare class ToolLane {
33
35
  flushSource(parentId: string, homeDir?: string): string[];
34
36
  flushCompletedRoots(homeDir?: string): string[];
35
37
  flush(homeDir?: string): string[];
36
- private buildChildMap;
37
38
  }
38
39
  export { formatToolLine, formatToolResultLine };
@@ -18,6 +18,7 @@ export interface StatusLineFields {
18
18
  budgetUsd?: number;
19
19
  maxBudgetUsd?: number;
20
20
  activeAgentCount?: number;
21
+ tokPerSec?: number;
21
22
  }
22
23
  interface StatusLineOpts {
23
24
  stream?: NodeJS.WriteStream;