@ellipsis-dev/sdk 0.25.0 → 0.28.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.
@@ -1,4 +1,4 @@
1
- import { W as SessionRecord, a7 as CodexFileChangeItem, a as CodexEvent, a8 as CodexMcpToolCallItem, w as SdkRecord, J as Session, Q as SessionMessage, a4 as StreamFrame } from '../types-DJzmFABi.js';
1
+ import { cp as SessionRecord, L as CodexFileChangeItem, J as CodexEvent, Y as CodexMcpToolCallItem, bK as SdkRecord, bW as Session, cj as SessionMessage, cO as StreamFrame } from '../types-B-jIFh4_.js';
2
2
 
3
3
  interface ChatToolNode {
4
4
  key: string;
@@ -55,6 +55,7 @@ type RecordSlice = {
55
55
  };
56
56
  declare function recordSlice(records: readonly SessionRecord[]): readonly RecordSlice[];
57
57
  declare function humanDuration(seconds: number): string;
58
+ declare const SESSION_WAKING = "Session waking";
58
59
  declare function sessionLogText(recordType: string, payload: Record<string, unknown>): string | null;
59
60
  declare function awaitingAgentPhase(records: readonly RecordSlice[]): 'boot' | 'turn' | null;
60
61
  declare function deliveredUnechoedSends(records: readonly RecordSlice[]): {
@@ -67,6 +68,7 @@ type SandboxLogLine = {
67
68
  key: string;
68
69
  kind: SandboxLogKind;
69
70
  text: string;
71
+ loading?: boolean;
70
72
  };
71
73
  type SandboxState = {
72
74
  headline: string;
@@ -79,6 +81,8 @@ type SandboxState = {
79
81
  };
80
82
  declare function hookPhrase(step: string): string;
81
83
  declare function deriveSandboxState(records: readonly RecordSlice[], minFeedSeq: number): SandboxState | null;
84
+ declare function startupSettled(sandbox: SandboxState | null, status: string): boolean;
85
+ declare function startupHeadline(sandbox: SandboxState | null, status: string): string;
82
86
  declare function sandboxSummary(sandbox: SandboxState | null): string;
83
87
  declare function lastLines(log: readonly SandboxLogLine[], max: number): SandboxLogLine[];
84
88
 
@@ -95,6 +99,8 @@ interface TranscriptItem {
95
99
  name: string;
96
100
  input?: Record<string, unknown>;
97
101
  };
102
+ loading?: boolean;
103
+ summary?: boolean;
98
104
  }
99
105
  declare function oneLine(text: string, max: number): string;
100
106
  declare function summarizeToolInput(name: string, input: unknown): string;
@@ -110,7 +116,11 @@ declare function codexMcpToolName(item: CodexMcpToolCallItem): string;
110
116
  declare function recordToItems(record: SessionRecord, keyBase: string, options?: EventToItemsOptions): TranscriptItem[];
111
117
  declare function isConnectVisibleRecord(record: SessionRecord): boolean;
112
118
  declare function pendingToolCalls(items: TranscriptItem[]): TranscriptItem[];
113
- declare function collapseToolRuns(items: TranscriptItem[]): TranscriptItem[];
119
+ declare function isFoldable(item: TranscriptItem): boolean;
120
+ declare function foldRun(group: TranscriptItem[], loading: boolean): TranscriptItem;
121
+ declare function collapseToolRuns(items: TranscriptItem[], { working }?: {
122
+ working?: boolean;
123
+ }): TranscriptItem[];
114
124
  declare function clampLines(text: string, maxLines: number): {
115
125
  body: string;
116
126
  more: number;
@@ -129,7 +139,6 @@ declare function gutterFor(item: TranscriptItem): string;
129
139
  declare function chatTurnsToItems(turns: readonly ChatTurn[]): TranscriptItem[];
130
140
  declare function isToolFold(item: TranscriptItem): boolean;
131
141
  declare function isToolActivity(item: TranscriptItem): boolean;
132
- declare function isAgentSpeech(item: TranscriptItem): boolean;
133
142
  type PlacedItem = {
134
143
  item: TranscriptItem;
135
144
  nested: boolean;
@@ -143,6 +152,27 @@ declare function tailLines(text: string, maxLines: number): {
143
152
  };
144
153
  declare function toolRunMembers(items: readonly TranscriptItem[]): Map<string, TranscriptItem[]>;
145
154
 
155
+ interface LedgerEntry {
156
+ key: string;
157
+ prompt: string;
158
+ cancelled: boolean;
159
+ turns: ChatTurn[];
160
+ }
161
+ declare function splitLedger(turns: readonly ChatTurn[]): {
162
+ preamble: ChatTurn[];
163
+ entries: LedgerEntry[];
164
+ };
165
+ declare function entrySeconds(entry: LedgerEntry, now: number): number;
166
+ type EntryBody = {
167
+ items: TranscriptItem[];
168
+ members: Map<string, TranscriptItem[]>;
169
+ };
170
+ declare function entryBody(entry: LedgerEntry, { live, now, liveText, }: {
171
+ live: boolean;
172
+ now: number;
173
+ liveText?: string;
174
+ }): EntryBody;
175
+
146
176
  declare function sandboxOutputStep(payload: Record<string, unknown>): string;
147
177
  declare function sandboxOutputLines(payload: Record<string, unknown>): string[];
148
178
  declare function sandboxOutputLine(payload: Record<string, unknown>): string | null;
@@ -150,6 +180,8 @@ declare function cacheTierLabel(tier: unknown): string | null;
150
180
  declare function sandboxPhaseLabel(phase: unknown): string;
151
181
  declare function lifecycleText(recordType: string, payload: Record<string, unknown>): string | null;
152
182
 
183
+ declare function claudePayload(record: SessionRecord): SdkRecord | null;
184
+
153
185
  declare function isConversationOver(session: Session): boolean;
154
186
  interface SessionTranscriptSnapshot {
155
187
  session: Session | null;
@@ -186,4 +218,4 @@ declare class SessionTranscriptStore {
186
218
  ingest: (rawFrame: StreamFrame) => void;
187
219
  }
188
220
 
189
- export { BRANCH_GLYPH, type ChatNode, type ChatToolNode, type ChatTurn, type EventToItemsOptions, type ItemKind, LIVE_GLYPH, type PlacedItem, type RecordSlice, type SandboxLogKind, type SandboxLogLine, type SandboxState, type SessionTranscriptSnapshot, SessionTranscriptStore, StreamFrame, type TranscriptItem, USER_BAR, awaitingAgentPhase, cacheTierLabel, chatTurnsToItems, clampLines, codexChangedPaths, codexEventToItems, codexMcpToolName, collapseToolRuns, deliveredUnechoedSends, deriveSandboxState, emptySessionTranscriptSnapshot, eventToItems, foldCosts, foldGutter, formatDuration, groupRecordsToChatTurns, gutterFor, hookPhrase, humanDuration, isAgentSpeech, isConnectVisibleRecord, isConversationOver, isToolActivity, isToolFold, lastLines, layOutItems, lifecycleText, oneLine, pendingToolCalls, recordSlice, recordToItems, resultCostUsd, sandboxOutputLine, sandboxOutputLines, sandboxOutputStep, sandboxPhaseLabel, sandboxSummary, seedTranscriptStore, sessionLogText, statusActivityText, summarizeToolInput, tailLines, toolResultText, toolRunMembers };
221
+ export { BRANCH_GLYPH, type ChatNode, type ChatToolNode, type ChatTurn, type EntryBody, type EventToItemsOptions, type ItemKind, LIVE_GLYPH, type LedgerEntry, type PlacedItem, type RecordSlice, SESSION_WAKING, type SandboxLogKind, type SandboxLogLine, type SandboxState, type SessionTranscriptSnapshot, SessionTranscriptStore, StreamFrame, type TranscriptItem, USER_BAR, awaitingAgentPhase, cacheTierLabel, chatTurnsToItems, clampLines, claudePayload, codexChangedPaths, codexEventToItems, codexMcpToolName, collapseToolRuns, deliveredUnechoedSends, deriveSandboxState, emptySessionTranscriptSnapshot, entryBody, entrySeconds, eventToItems, foldCosts, foldGutter, foldRun, formatDuration, groupRecordsToChatTurns, gutterFor, hookPhrase, humanDuration, isConnectVisibleRecord, isConversationOver, isFoldable, isToolActivity, isToolFold, lastLines, layOutItems, lifecycleText, oneLine, pendingToolCalls, recordSlice, recordToItems, resultCostUsd, sandboxOutputLine, sandboxOutputLines, sandboxOutputStep, sandboxPhaseLabel, sandboxSummary, seedTranscriptStore, sessionLogText, splitLedger, startupHeadline, startupSettled, statusActivityText, summarizeToolInput, tailLines, toolResultText, toolRunMembers };