@astralform/js 9.0.0 → 9.2.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/index.d.cts CHANGED
@@ -902,8 +902,10 @@ interface ThinkingDescriptor {
902
902
  }
903
903
  /**
904
904
  * The per-request model choice (client-side model selection). `provider` and
905
- * `model` are paired — send both or neither; when omitted, the server reuses the
906
- * conversation's last model or a connected-provider default.
905
+ * `model` are paired — send both or neither. Pass them on the first message of
906
+ * a new conversation: newer servers reject a new conversation that names no
907
+ * model, and every server accepts one that does. Omitted later, the server
908
+ * reuses the conversation's last model.
907
909
  */
908
910
  interface ModelChoiceOptions {
909
911
  provider?: string;
@@ -943,7 +945,9 @@ interface ChatStreamRequest {
943
945
  goal?: string;
944
946
  /**
945
947
  * Per-request model choice (client-side model selection), wire shape.
946
- * `provider` and `model` are paired; omit to reuse the thread's last model.
948
+ * `provider` and `model` are paired. Pass them on a new conversation (newer
949
+ * servers reject one without); omit them mid-thread to reuse the thread's
950
+ * last model.
947
951
  */
948
952
  provider?: string;
949
953
  model?: string;
@@ -1082,7 +1086,11 @@ interface VoiceConfig {
1082
1086
  defaultMode: VoicePolishMode;
1083
1087
  /** In tap-to-talk mode, the pause that ends a recording. */
1084
1088
  silenceAutoStopSeconds: number;
1085
- /** Send the message as soon as the result is ready. */
1089
+ /**
1090
+ * @deprecated Always `false`. Auto-send was removed from the platform
1091
+ * (2026-09-14); a dictation only fills the composer and the user sends it.
1092
+ * Kept so existing code compiles; slated for removal in the next major.
1093
+ */
1086
1094
  autoSend: boolean;
1087
1095
  maxRecordingSeconds: number;
1088
1096
  /**
@@ -1356,6 +1364,69 @@ interface ConversationJob {
1356
1364
  status: string;
1357
1365
  message_id?: string | null;
1358
1366
  metrics?: Record<string, unknown>;
1367
+ /**
1368
+ * The per-turn state a consumer rehydrates a restored transcript from —
1369
+ * attachment chips, composer modes, goal linkage, the model the turn ran on.
1370
+ *
1371
+ * Every field below was ALREADY in this response and already fetched by the
1372
+ * restore's own paged read. They were simply not TYPED, and a field the SDK
1373
+ * does not surface is one a consumer cannot reach without re-requesting the
1374
+ * endpoint itself — which is exactly what happened: the chat issued a second,
1375
+ * UNBOUNDED `GET /jobs` on `restoreSettled`, a payload that grows with the
1376
+ * transcript, landing before first paint (measured 409-959 ms on the #1052
1377
+ * reference conversation). Widening the type is what lets that request be
1378
+ * deleted rather than merely bounded, which keeps ONE page size and ONE
1379
+ * cursor in the SDK instead of a second copy of both in every consumer.
1380
+ *
1381
+ * Optional throughout, because "the backend cannot say" is a real answer for
1382
+ * most of them: a job older than the field, or a server that does not project
1383
+ * it yet. `plan_mode`/`image_mode`/`video_mode` are three-valued for that
1384
+ * reason — absent/null is NOT false. `llm_provider`/`llm_model` come as a
1385
+ * pair or not at all.
1386
+ */
1387
+ created_at?: string | null;
1388
+ completed_at?: string | null;
1389
+ goal_id?: string | null;
1390
+ goal_objective?: string | null;
1391
+ plan_mode?: boolean | null;
1392
+ image_mode?: boolean | null;
1393
+ video_mode?: boolean | null;
1394
+ llm_provider?: string | null;
1395
+ llm_model?: string | null;
1396
+ /**
1397
+ * Files that rode along with this turn's user message, as display metadata.
1398
+ *
1399
+ * Present for every job that carried uploads WHATEVER its status — the files
1400
+ * are stored at attach time, before the turn starts, so a stopped or failed
1401
+ * turn still carried them and its bubble should still show them.
1402
+ */
1403
+ attachments?: ConversationJobAttachment[] | null;
1404
+ }
1405
+ /**
1406
+ * One file that rode along with a turn's user message.
1407
+ *
1408
+ * Named rather than inlined into `ConversationJob.attachments`: a consumer
1409
+ * rebuilding attachment chips writes a function over ONE of these, and an
1410
+ * inline literal is nameable only by indexing back out of the parent
1411
+ * (`NonNullable<ConversationJob["attachments"]>[number]`). Handing the rows
1412
+ * over is pointless if the row's element type cannot be spelled.
1413
+ *
1414
+ * `asset_id` and `filename` are required while the rest of `ConversationJob`
1415
+ * is optional, and that is not an oversight: the others are optional because
1416
+ * the BACKEND may not project them (a job older than the field, a server that
1417
+ * does not send it yet), whereas this whole object is built in one place and
1418
+ * both fields are unconditionally populated from the asset row whenever an
1419
+ * entry exists at all.
1420
+ */
1421
+ interface ConversationJobAttachment {
1422
+ asset_id: string;
1423
+ filename: string;
1424
+ media_type?: string | null;
1425
+ size_bytes?: number | null;
1426
+ /** Signed and expiring — the restored thumbnail. */
1427
+ url?: string | null;
1428
+ /** Permanent address, for keeping or linking. */
1429
+ content_url?: string | null;
1359
1430
  }
1360
1431
  /** One page of turns, plus where the next older page starts. */
1361
1432
  interface JobsPage {
@@ -2138,6 +2209,20 @@ declare function streamJobSSE(options: StreamJobSSEOptions): AsyncGenerator<Chat
2138
2209
 
2139
2210
  type StreamState = "idle" | "streaming" | "restoring" | "detached";
2140
2211
  interface SendOptions extends ModelChoiceOptions {
2212
+ /**
2213
+ * Client tools to enable for THIS turn, overriding `session.enabledClientTools`
2214
+ * for it alone. Omit to use that Set, which is the persistent default.
2215
+ *
2216
+ * Present here while `conversationId` — the session's other extra field — is
2217
+ * deliberately absent, and the difference is worth stating so neither gets
2218
+ * "tidied" to match the other. `send` overwrites `conversationId` on its
2219
+ * forward below, because the manager owns the pointer, so accepting one would
2220
+ * silently discard the caller's value. Nothing overwrites this: the spread
2221
+ * carries it and `ChatSession.send` reads it as the override. It was missing
2222
+ * only because it was never added — #55 fixed the same loss for `repository`
2223
+ * in the forward direction and recorded that this one had gone the other way.
2224
+ */
2225
+ enabledClientTools?: string[];
2141
2226
  agentName?: string;
2142
2227
  uploadIds?: string[];
2143
2228
  planMode?: boolean;
@@ -2196,6 +2281,20 @@ type StreamManagerEvent = {
2196
2281
  position: "prepend";
2197
2282
  /** Whether anything older still remains after this page. */
2198
2283
  hasMore: boolean;
2284
+ /**
2285
+ * This page's turns, as the job list describes them — the rows this
2286
+ * page was replayed FROM, handed over rather than re-fetched.
2287
+ *
2288
+ * A consumer rehydrating per-turn state (attachment chips, composer
2289
+ * modes, goal runs, the turn's model) needs these for a prepended page
2290
+ * exactly as it does for the first render, and has no cursor of its own
2291
+ * to ask for them with. Empty when the page replayed nothing.
2292
+ *
2293
+ * Read this only when `complete` is `true`, for the same reason the
2294
+ * buffered blocks are discarded otherwise: an incomplete page's cursor
2295
+ * did not advance and the same turns replay again next request.
2296
+ */
2297
+ jobs: ConversationJob[];
2199
2298
  /**
2200
2299
  * Did the whole page replay?
2201
2300
  *
@@ -2240,6 +2339,18 @@ type StreamManagerEvent = {
2240
2339
  */
2241
2340
  type: "restoreSettled";
2242
2341
  conversationId: string;
2342
+ /**
2343
+ * The newest page's turns, as the job list describes them.
2344
+ *
2345
+ * The restore ALREADY fetched these — `jobList` asks for
2346
+ * `RESTORE_TURN_PAGE_SIZE` of them, and gets that many from any server
2347
+ * that honours the cursor (an older one ignores `limit` and answers with
2348
+ * the whole list, the documented degrade). Handing them over is what lets
2349
+ * a consumer rehydrate without issuing its OWN unbounded `GET /jobs`,
2350
+ * which is unbounded against every server, not just an old one, and lands
2351
+ * before first paint.
2352
+ */
2353
+ jobs: ConversationJob[];
2243
2354
  };
2244
2355
  type EventHandler = (event: StreamManagerEvent) => void;
2245
2356
  declare class StreamManager {
@@ -2573,4 +2684,4 @@ declare function isEmbeddedResource(value: unknown): value is {
2573
2684
  */
2574
2685
  declare function parseEmbeddedResource(value: unknown): EmbeddedResource | null;
2575
2686
 
2576
- export { type ActiveJob, type AgentCapability, type AgentIdentity, type AgentInfo, type AgentStatus, type AssetCreatedPayload, type AstralformApiKeyConfig, AstralformClient, type AstralformConfig, AstralformError, type AstralformUserTokenConfig, type AttachmentStagedPayload, AuthenticationError, type AvailableRepositories, type AvailableRepository, type BlockDeltaPayload, CONVERSATION_PAGE_SIZE, type ChatEvent, ChatEventType, type ChatEventTypeValue, ChatSession, type ChatStorage, type ChatStreamEvent, type ChatStreamRequest, type CodeProject, ConnectionError, type ContextUpdatePayload, type ContextWarningPayload, type Conversation, type ConversationAsset, type ConversationEvent, type DesktopStreamPayload, type EffortRung, type EmbeddedResource, type FeedbackRequest, type FeedbackResponse, InMemoryStorage, type JobCreateResponse, type JobStatus, type JobSummary, LLMNotConfiguredError, type MemoryProviderErrorPayload, type MemoryRecallPayload, type MemoryRecord, type MemoryUpdatePayload, type Message, type ModelChoiceOptions, type ModelOption, type MyToolGrantsPage, type NestedLlmUsagePayload, type NoteUpdatePayload, type PlanUpdatePayload, type PromptSuggestionPayload, type ProtocolAdapter, ProtocolRegistry, RateLimitError, type RateLimitErrorDetails, type RawSseEvent, type ReasoningEffort, type SendOptions, ServerError, type SkillInfo, type SlashCommand, type SlashCommandSurface, StreamAbortedError, type StreamJobSSEOptions, StreamManager, type StreamManagerEvent, type StreamState, type SubagentStartPayload, type SubagentStopPayload, type TaskStatus, type TeamAgentSummary, type TeamSummary, type ThinkingDescriptor, type ThinkingRungOption, type TitleGeneratedPayload, type TodoItem, type TodoUpdatePayload, type ToolApprovalDecision, type ToolApprovalGrantedPayload, type ToolApprovalRequest, type ToolApprovalRequestedPayload, type ToolApprovalScope, type ToolCallRequest, type ToolDefinition, type ToolGrant, type ToolHandler, type ToolHarnessWarningPayload, type ToolOutputMode, type ToolOutputStub, type ToolProgressPayload, ToolRegistry, type ToolResult, type ToolResultRequest, type ToolSource, type TurnUsage, type UIComponentsConfig, type UserUnavailablePayload, VOICE_POLISH_MODES, type VoiceConfig, type VoiceLLMMode, type VoicePolishEvent, type VoicePolishMode, type VoicePolishRequest, type VoiceTranscribeOptions, type VoiceTranscript, type WireBlockDelta, type WireBlockDeltaPayload, type WireBlockKind, type WireBlockStart, type WireBlockStatus, type WireBlockStop, type WireCustomEvent, type WireErrorEvent, type WireEvent, type WireInputArgDelta, type WireInputDelta, type WireKeepalive, type WireMessageStart, type WireMessageStop, type WireOutputDelta, type WireRetryEvent, type WireSignatureDelta, type WireStallWarning, type WireStatusDelta, type WireStopReason, type WireTextDelta, type WireThinkingDelta, type WorkspaceReadyPayload, generateId, isEmbeddedResource, isToolOutputStub, isVoiceLLMMode, isVoicePolishMode, mapSseToChat, parseEmbeddedResource, parseVoicePolishFrame, replayEvents, streamJobSSE, translateDelta };
2687
+ export { type ActiveJob, type AgentCapability, type AgentIdentity, type AgentInfo, type AgentStatus, type AssetCreatedPayload, type AstralformApiKeyConfig, AstralformClient, type AstralformConfig, AstralformError, type AstralformUserTokenConfig, type AttachmentStagedPayload, AuthenticationError, type AvailableRepositories, type AvailableRepository, type BlockDeltaPayload, CONVERSATION_PAGE_SIZE, type ChatEvent, ChatEventType, type ChatEventTypeValue, ChatSession, type ChatStorage, type ChatStreamEvent, type ChatStreamRequest, type CodeProject, ConnectionError, type ContextUpdatePayload, type ContextWarningPayload, type Conversation, type ConversationAsset, type ConversationEvent, type ConversationJob, type ConversationJobAttachment, type DesktopStreamPayload, type EffortRung, type EmbeddedResource, type FeedbackRequest, type FeedbackResponse, InMemoryStorage, type JobCreateResponse, type JobStatus, type JobSummary, type JobsPage, LLMNotConfiguredError, type MemoryProviderErrorPayload, type MemoryRecallPayload, type MemoryRecord, type MemoryUpdatePayload, type Message, type MessagesPage, type ModelChoiceOptions, type ModelOption, type MyToolGrantsPage, type NestedLlmUsagePayload, type NoteUpdatePayload, type PlanUpdatePayload, type PromptSuggestionPayload, type ProtocolAdapter, ProtocolRegistry, RateLimitError, type RateLimitErrorDetails, type RawSseEvent, type ReasoningEffort, type SendOptions, ServerError, type SendOptions$1 as SessionSendOptions, type SkillInfo, type SlashCommand, type SlashCommandSurface, StreamAbortedError, type StreamJobSSEOptions, StreamManager, type StreamManagerEvent, type StreamState, type SubagentStartPayload, type SubagentStopPayload, type TaskStatus, type TeamAgentSummary, type TeamSummary, type ThinkingDescriptor, type ThinkingRungOption, type TitleGeneratedPayload, type TodoItem, type TodoUpdatePayload, type ToolApprovalDecision, type ToolApprovalGrantedPayload, type ToolApprovalRequest, type ToolApprovalRequestedPayload, type ToolApprovalScope, type ToolCallRequest, type ToolDefinition, type ToolGrant, type ToolHandler, type ToolHarnessWarningPayload, type ToolOutputMode, type ToolOutputStub, type ToolProgressPayload, ToolRegistry, type ToolResult, type ToolResultRequest, type ToolSource, type TurnUsage, type UIComponentsConfig, type UserUnavailablePayload, VOICE_POLISH_MODES, type VoiceConfig, type VoiceLLMMode, type VoicePolishEvent, type VoicePolishMode, type VoicePolishRequest, type VoiceTranscribeOptions, type VoiceTranscript, type WireBlockDelta, type WireBlockDeltaPayload, type WireBlockKind, type WireBlockStart, type WireBlockStatus, type WireBlockStop, type WireCustomEvent, type WireErrorEvent, type WireEvent, type WireInputArgDelta, type WireInputDelta, type WireKeepalive, type WireMessageStart, type WireMessageStop, type WireOutputDelta, type WireRetryEvent, type WireSignatureDelta, type WireStallWarning, type WireStatusDelta, type WireStopReason, type WireTextDelta, type WireThinkingDelta, type WorkspaceReadyPayload, generateId, isEmbeddedResource, isToolOutputStub, isVoiceLLMMode, isVoicePolishMode, mapSseToChat, parseEmbeddedResource, parseVoicePolishFrame, replayEvents, streamJobSSE, translateDelta };
package/dist/index.d.ts CHANGED
@@ -902,8 +902,10 @@ interface ThinkingDescriptor {
902
902
  }
903
903
  /**
904
904
  * The per-request model choice (client-side model selection). `provider` and
905
- * `model` are paired — send both or neither; when omitted, the server reuses the
906
- * conversation's last model or a connected-provider default.
905
+ * `model` are paired — send both or neither. Pass them on the first message of
906
+ * a new conversation: newer servers reject a new conversation that names no
907
+ * model, and every server accepts one that does. Omitted later, the server
908
+ * reuses the conversation's last model.
907
909
  */
908
910
  interface ModelChoiceOptions {
909
911
  provider?: string;
@@ -943,7 +945,9 @@ interface ChatStreamRequest {
943
945
  goal?: string;
944
946
  /**
945
947
  * Per-request model choice (client-side model selection), wire shape.
946
- * `provider` and `model` are paired; omit to reuse the thread's last model.
948
+ * `provider` and `model` are paired. Pass them on a new conversation (newer
949
+ * servers reject one without); omit them mid-thread to reuse the thread's
950
+ * last model.
947
951
  */
948
952
  provider?: string;
949
953
  model?: string;
@@ -1082,7 +1086,11 @@ interface VoiceConfig {
1082
1086
  defaultMode: VoicePolishMode;
1083
1087
  /** In tap-to-talk mode, the pause that ends a recording. */
1084
1088
  silenceAutoStopSeconds: number;
1085
- /** Send the message as soon as the result is ready. */
1089
+ /**
1090
+ * @deprecated Always `false`. Auto-send was removed from the platform
1091
+ * (2026-09-14); a dictation only fills the composer and the user sends it.
1092
+ * Kept so existing code compiles; slated for removal in the next major.
1093
+ */
1086
1094
  autoSend: boolean;
1087
1095
  maxRecordingSeconds: number;
1088
1096
  /**
@@ -1356,6 +1364,69 @@ interface ConversationJob {
1356
1364
  status: string;
1357
1365
  message_id?: string | null;
1358
1366
  metrics?: Record<string, unknown>;
1367
+ /**
1368
+ * The per-turn state a consumer rehydrates a restored transcript from —
1369
+ * attachment chips, composer modes, goal linkage, the model the turn ran on.
1370
+ *
1371
+ * Every field below was ALREADY in this response and already fetched by the
1372
+ * restore's own paged read. They were simply not TYPED, and a field the SDK
1373
+ * does not surface is one a consumer cannot reach without re-requesting the
1374
+ * endpoint itself — which is exactly what happened: the chat issued a second,
1375
+ * UNBOUNDED `GET /jobs` on `restoreSettled`, a payload that grows with the
1376
+ * transcript, landing before first paint (measured 409-959 ms on the #1052
1377
+ * reference conversation). Widening the type is what lets that request be
1378
+ * deleted rather than merely bounded, which keeps ONE page size and ONE
1379
+ * cursor in the SDK instead of a second copy of both in every consumer.
1380
+ *
1381
+ * Optional throughout, because "the backend cannot say" is a real answer for
1382
+ * most of them: a job older than the field, or a server that does not project
1383
+ * it yet. `plan_mode`/`image_mode`/`video_mode` are three-valued for that
1384
+ * reason — absent/null is NOT false. `llm_provider`/`llm_model` come as a
1385
+ * pair or not at all.
1386
+ */
1387
+ created_at?: string | null;
1388
+ completed_at?: string | null;
1389
+ goal_id?: string | null;
1390
+ goal_objective?: string | null;
1391
+ plan_mode?: boolean | null;
1392
+ image_mode?: boolean | null;
1393
+ video_mode?: boolean | null;
1394
+ llm_provider?: string | null;
1395
+ llm_model?: string | null;
1396
+ /**
1397
+ * Files that rode along with this turn's user message, as display metadata.
1398
+ *
1399
+ * Present for every job that carried uploads WHATEVER its status — the files
1400
+ * are stored at attach time, before the turn starts, so a stopped or failed
1401
+ * turn still carried them and its bubble should still show them.
1402
+ */
1403
+ attachments?: ConversationJobAttachment[] | null;
1404
+ }
1405
+ /**
1406
+ * One file that rode along with a turn's user message.
1407
+ *
1408
+ * Named rather than inlined into `ConversationJob.attachments`: a consumer
1409
+ * rebuilding attachment chips writes a function over ONE of these, and an
1410
+ * inline literal is nameable only by indexing back out of the parent
1411
+ * (`NonNullable<ConversationJob["attachments"]>[number]`). Handing the rows
1412
+ * over is pointless if the row's element type cannot be spelled.
1413
+ *
1414
+ * `asset_id` and `filename` are required while the rest of `ConversationJob`
1415
+ * is optional, and that is not an oversight: the others are optional because
1416
+ * the BACKEND may not project them (a job older than the field, a server that
1417
+ * does not send it yet), whereas this whole object is built in one place and
1418
+ * both fields are unconditionally populated from the asset row whenever an
1419
+ * entry exists at all.
1420
+ */
1421
+ interface ConversationJobAttachment {
1422
+ asset_id: string;
1423
+ filename: string;
1424
+ media_type?: string | null;
1425
+ size_bytes?: number | null;
1426
+ /** Signed and expiring — the restored thumbnail. */
1427
+ url?: string | null;
1428
+ /** Permanent address, for keeping or linking. */
1429
+ content_url?: string | null;
1359
1430
  }
1360
1431
  /** One page of turns, plus where the next older page starts. */
1361
1432
  interface JobsPage {
@@ -2138,6 +2209,20 @@ declare function streamJobSSE(options: StreamJobSSEOptions): AsyncGenerator<Chat
2138
2209
 
2139
2210
  type StreamState = "idle" | "streaming" | "restoring" | "detached";
2140
2211
  interface SendOptions extends ModelChoiceOptions {
2212
+ /**
2213
+ * Client tools to enable for THIS turn, overriding `session.enabledClientTools`
2214
+ * for it alone. Omit to use that Set, which is the persistent default.
2215
+ *
2216
+ * Present here while `conversationId` — the session's other extra field — is
2217
+ * deliberately absent, and the difference is worth stating so neither gets
2218
+ * "tidied" to match the other. `send` overwrites `conversationId` on its
2219
+ * forward below, because the manager owns the pointer, so accepting one would
2220
+ * silently discard the caller's value. Nothing overwrites this: the spread
2221
+ * carries it and `ChatSession.send` reads it as the override. It was missing
2222
+ * only because it was never added — #55 fixed the same loss for `repository`
2223
+ * in the forward direction and recorded that this one had gone the other way.
2224
+ */
2225
+ enabledClientTools?: string[];
2141
2226
  agentName?: string;
2142
2227
  uploadIds?: string[];
2143
2228
  planMode?: boolean;
@@ -2196,6 +2281,20 @@ type StreamManagerEvent = {
2196
2281
  position: "prepend";
2197
2282
  /** Whether anything older still remains after this page. */
2198
2283
  hasMore: boolean;
2284
+ /**
2285
+ * This page's turns, as the job list describes them — the rows this
2286
+ * page was replayed FROM, handed over rather than re-fetched.
2287
+ *
2288
+ * A consumer rehydrating per-turn state (attachment chips, composer
2289
+ * modes, goal runs, the turn's model) needs these for a prepended page
2290
+ * exactly as it does for the first render, and has no cursor of its own
2291
+ * to ask for them with. Empty when the page replayed nothing.
2292
+ *
2293
+ * Read this only when `complete` is `true`, for the same reason the
2294
+ * buffered blocks are discarded otherwise: an incomplete page's cursor
2295
+ * did not advance and the same turns replay again next request.
2296
+ */
2297
+ jobs: ConversationJob[];
2199
2298
  /**
2200
2299
  * Did the whole page replay?
2201
2300
  *
@@ -2240,6 +2339,18 @@ type StreamManagerEvent = {
2240
2339
  */
2241
2340
  type: "restoreSettled";
2242
2341
  conversationId: string;
2342
+ /**
2343
+ * The newest page's turns, as the job list describes them.
2344
+ *
2345
+ * The restore ALREADY fetched these — `jobList` asks for
2346
+ * `RESTORE_TURN_PAGE_SIZE` of them, and gets that many from any server
2347
+ * that honours the cursor (an older one ignores `limit` and answers with
2348
+ * the whole list, the documented degrade). Handing them over is what lets
2349
+ * a consumer rehydrate without issuing its OWN unbounded `GET /jobs`,
2350
+ * which is unbounded against every server, not just an old one, and lands
2351
+ * before first paint.
2352
+ */
2353
+ jobs: ConversationJob[];
2243
2354
  };
2244
2355
  type EventHandler = (event: StreamManagerEvent) => void;
2245
2356
  declare class StreamManager {
@@ -2573,4 +2684,4 @@ declare function isEmbeddedResource(value: unknown): value is {
2573
2684
  */
2574
2685
  declare function parseEmbeddedResource(value: unknown): EmbeddedResource | null;
2575
2686
 
2576
- export { type ActiveJob, type AgentCapability, type AgentIdentity, type AgentInfo, type AgentStatus, type AssetCreatedPayload, type AstralformApiKeyConfig, AstralformClient, type AstralformConfig, AstralformError, type AstralformUserTokenConfig, type AttachmentStagedPayload, AuthenticationError, type AvailableRepositories, type AvailableRepository, type BlockDeltaPayload, CONVERSATION_PAGE_SIZE, type ChatEvent, ChatEventType, type ChatEventTypeValue, ChatSession, type ChatStorage, type ChatStreamEvent, type ChatStreamRequest, type CodeProject, ConnectionError, type ContextUpdatePayload, type ContextWarningPayload, type Conversation, type ConversationAsset, type ConversationEvent, type DesktopStreamPayload, type EffortRung, type EmbeddedResource, type FeedbackRequest, type FeedbackResponse, InMemoryStorage, type JobCreateResponse, type JobStatus, type JobSummary, LLMNotConfiguredError, type MemoryProviderErrorPayload, type MemoryRecallPayload, type MemoryRecord, type MemoryUpdatePayload, type Message, type ModelChoiceOptions, type ModelOption, type MyToolGrantsPage, type NestedLlmUsagePayload, type NoteUpdatePayload, type PlanUpdatePayload, type PromptSuggestionPayload, type ProtocolAdapter, ProtocolRegistry, RateLimitError, type RateLimitErrorDetails, type RawSseEvent, type ReasoningEffort, type SendOptions, ServerError, type SkillInfo, type SlashCommand, type SlashCommandSurface, StreamAbortedError, type StreamJobSSEOptions, StreamManager, type StreamManagerEvent, type StreamState, type SubagentStartPayload, type SubagentStopPayload, type TaskStatus, type TeamAgentSummary, type TeamSummary, type ThinkingDescriptor, type ThinkingRungOption, type TitleGeneratedPayload, type TodoItem, type TodoUpdatePayload, type ToolApprovalDecision, type ToolApprovalGrantedPayload, type ToolApprovalRequest, type ToolApprovalRequestedPayload, type ToolApprovalScope, type ToolCallRequest, type ToolDefinition, type ToolGrant, type ToolHandler, type ToolHarnessWarningPayload, type ToolOutputMode, type ToolOutputStub, type ToolProgressPayload, ToolRegistry, type ToolResult, type ToolResultRequest, type ToolSource, type TurnUsage, type UIComponentsConfig, type UserUnavailablePayload, VOICE_POLISH_MODES, type VoiceConfig, type VoiceLLMMode, type VoicePolishEvent, type VoicePolishMode, type VoicePolishRequest, type VoiceTranscribeOptions, type VoiceTranscript, type WireBlockDelta, type WireBlockDeltaPayload, type WireBlockKind, type WireBlockStart, type WireBlockStatus, type WireBlockStop, type WireCustomEvent, type WireErrorEvent, type WireEvent, type WireInputArgDelta, type WireInputDelta, type WireKeepalive, type WireMessageStart, type WireMessageStop, type WireOutputDelta, type WireRetryEvent, type WireSignatureDelta, type WireStallWarning, type WireStatusDelta, type WireStopReason, type WireTextDelta, type WireThinkingDelta, type WorkspaceReadyPayload, generateId, isEmbeddedResource, isToolOutputStub, isVoiceLLMMode, isVoicePolishMode, mapSseToChat, parseEmbeddedResource, parseVoicePolishFrame, replayEvents, streamJobSSE, translateDelta };
2687
+ export { type ActiveJob, type AgentCapability, type AgentIdentity, type AgentInfo, type AgentStatus, type AssetCreatedPayload, type AstralformApiKeyConfig, AstralformClient, type AstralformConfig, AstralformError, type AstralformUserTokenConfig, type AttachmentStagedPayload, AuthenticationError, type AvailableRepositories, type AvailableRepository, type BlockDeltaPayload, CONVERSATION_PAGE_SIZE, type ChatEvent, ChatEventType, type ChatEventTypeValue, ChatSession, type ChatStorage, type ChatStreamEvent, type ChatStreamRequest, type CodeProject, ConnectionError, type ContextUpdatePayload, type ContextWarningPayload, type Conversation, type ConversationAsset, type ConversationEvent, type ConversationJob, type ConversationJobAttachment, type DesktopStreamPayload, type EffortRung, type EmbeddedResource, type FeedbackRequest, type FeedbackResponse, InMemoryStorage, type JobCreateResponse, type JobStatus, type JobSummary, type JobsPage, LLMNotConfiguredError, type MemoryProviderErrorPayload, type MemoryRecallPayload, type MemoryRecord, type MemoryUpdatePayload, type Message, type MessagesPage, type ModelChoiceOptions, type ModelOption, type MyToolGrantsPage, type NestedLlmUsagePayload, type NoteUpdatePayload, type PlanUpdatePayload, type PromptSuggestionPayload, type ProtocolAdapter, ProtocolRegistry, RateLimitError, type RateLimitErrorDetails, type RawSseEvent, type ReasoningEffort, type SendOptions, ServerError, type SendOptions$1 as SessionSendOptions, type SkillInfo, type SlashCommand, type SlashCommandSurface, StreamAbortedError, type StreamJobSSEOptions, StreamManager, type StreamManagerEvent, type StreamState, type SubagentStartPayload, type SubagentStopPayload, type TaskStatus, type TeamAgentSummary, type TeamSummary, type ThinkingDescriptor, type ThinkingRungOption, type TitleGeneratedPayload, type TodoItem, type TodoUpdatePayload, type ToolApprovalDecision, type ToolApprovalGrantedPayload, type ToolApprovalRequest, type ToolApprovalRequestedPayload, type ToolApprovalScope, type ToolCallRequest, type ToolDefinition, type ToolGrant, type ToolHandler, type ToolHarnessWarningPayload, type ToolOutputMode, type ToolOutputStub, type ToolProgressPayload, ToolRegistry, type ToolResult, type ToolResultRequest, type ToolSource, type TurnUsage, type UIComponentsConfig, type UserUnavailablePayload, VOICE_POLISH_MODES, type VoiceConfig, type VoiceLLMMode, type VoicePolishEvent, type VoicePolishMode, type VoicePolishRequest, type VoiceTranscribeOptions, type VoiceTranscript, type WireBlockDelta, type WireBlockDeltaPayload, type WireBlockKind, type WireBlockStart, type WireBlockStatus, type WireBlockStop, type WireCustomEvent, type WireErrorEvent, type WireEvent, type WireInputArgDelta, type WireInputDelta, type WireKeepalive, type WireMessageStart, type WireMessageStop, type WireOutputDelta, type WireRetryEvent, type WireSignatureDelta, type WireStallWarning, type WireStatusDelta, type WireStopReason, type WireTextDelta, type WireThinkingDelta, type WorkspaceReadyPayload, generateId, isEmbeddedResource, isToolOutputStub, isVoiceLLMMode, isVoicePolishMode, mapSseToChat, parseEmbeddedResource, parseVoicePolishFrame, replayEvents, streamJobSSE, translateDelta };
package/dist/index.js CHANGED
@@ -977,7 +977,11 @@ var AstralformClient = class {
977
977
  // `VoicePolishMode`; `structured` is the server's own default.
978
978
  defaultMode: isVoicePolishMode(raw.default_mode) ? raw.default_mode : "structured",
979
979
  silenceAutoStopSeconds: raw.silence_auto_stop_seconds ?? 2,
980
- autoSend: raw.auto_send ?? true,
980
+ // Deliberately not read from the wire. Auto-send was removed from the
981
+ // platform (2026-09-14) and the server pins `auto_send` to false; an
982
+ // older server still sending `true` must not make a client auto-send, so
983
+ // an absent field and an explicit `true` both read as false.
984
+ autoSend: false,
981
985
  maxRecordingSeconds: raw.max_recording_seconds ?? 300,
982
986
  supportsStreaming: Boolean(raw.supports_streaming),
983
987
  hotwords: raw.hotwords ?? []
@@ -3362,7 +3366,13 @@ var StreamManager = class _StreamManager {
3362
3366
  conversationId,
3363
3367
  position: "prepend",
3364
3368
  hasMore: completed ? page.hasMore : true,
3365
- complete: completed
3369
+ complete: completed,
3370
+ // Empty on the incomplete path, matching the blocks a consumer is
3371
+ // required to discard there: that page's cursor did not advance, so
3372
+ // these same turns replay from the start on the next request and
3373
+ // rehydrating from them now would key state to turns about to be
3374
+ // re-emitted.
3375
+ jobs: completed ? page.jobs : []
3366
3376
  });
3367
3377
  return emitted;
3368
3378
  } finally {
@@ -3451,7 +3461,7 @@ var StreamManager = class _StreamManager {
3451
3461
  this.oldestDrawnMessageId = plan[0]?.messageId ?? null;
3452
3462
  complete = true;
3453
3463
  if (stopReplay()) return false;
3454
- this.emit({ type: "restoreSettled", conversationId });
3464
+ this.emit({ type: "restoreSettled", conversationId, jobs });
3455
3465
  const versionCount = replayableJobs.filter(
3456
3466
  (j) => j.status === "completed"
3457
3467
  ).length;