@rkat/sdk 0.7.26 → 0.7.28

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
- export declare const CONTRACT_VERSION = "0.7.26";
1
+ export declare const CONTRACT_VERSION = "0.7.28";
2
2
  export type Value = unknown;
3
3
  export interface WireUsage {
4
4
  input_tokens: number;
@@ -614,18 +614,25 @@ export interface RuntimeHostInfo {
614
614
  realm: Record<string, unknown>;
615
615
  }
616
616
  export interface Schedule {
617
- config: Record<string, unknown>;
617
+ created_at_utc: string;
618
+ deleted_at_utc?: string;
619
+ description?: string;
620
+ labels?: Record<string, string>;
618
621
  misfire_policy: Record<string, unknown>;
619
622
  missing_target_policy: "skip" | "mark_misfired";
623
+ name?: string;
620
624
  next_occurrence_ordinal: number;
621
625
  overlap_policy: "allow_concurrent" | "skip_if_running";
622
626
  phase: "active" | "paused" | "deleted";
623
627
  planning_cursor_utc?: string;
628
+ planning_horizon_days: number;
629
+ planning_horizon_occurrences: number;
624
630
  revision: number;
625
631
  schedule_id: string;
626
- superseded_ack_ids: string[];
632
+ superseded_ack_ids?: string[];
627
633
  target: Record<string, unknown>;
628
634
  trigger: Record<string, unknown>;
635
+ updated_at_utc: string;
629
636
  }
630
637
  export interface ScheduleToolCallParams {
631
638
  arguments?: unknown;
@@ -1908,7 +1915,7 @@ export type WireRenderClass = "user_prompt" | "peer_message" | "peer_request" |
1908
1915
  export type WireRenderSalience = "background" | "normal" | "important" | "urgent";
1909
1916
  export type WireRuntimeState = "initializing" | "idle" | "attached" | "running" | "retired" | "stopped" | "destroyed";
1910
1917
  export type RealtimeTurningMode = "provider_managed" | "explicit_commit";
1911
- export type RealtimeInputKind = "text" | "audio" | "video";
1918
+ export type RealtimeInputKind = "text" | "audio" | "video" | "image";
1912
1919
  export type RealtimeOutputKind = "text" | "audio" | "video";
1913
1920
  export interface RealtimeInputChunkTextChunk {
1914
1921
  text: string;
@@ -1926,7 +1933,13 @@ export interface RealtimeInputChunkVideoChunk {
1926
1933
  mime_type: string;
1927
1934
  kind: "video_chunk";
1928
1935
  }
1929
- export type RealtimeInputChunk = RealtimeInputChunkTextChunk | RealtimeInputChunkAudioChunk | RealtimeInputChunkVideoChunk;
1936
+ export interface RealtimeInputChunkImageChunk {
1937
+ data: string;
1938
+ idempotency_key: string;
1939
+ mime_type: string;
1940
+ kind: "image_chunk";
1941
+ }
1942
+ export type RealtimeInputChunk = RealtimeInputChunkTextChunk | RealtimeInputChunkAudioChunk | RealtimeInputChunkVideoChunk | RealtimeInputChunkImageChunk;
1930
1943
  export type RuntimeAcceptOutcomeType = "accepted" | "deduplicated" | "rejected";
1931
1944
  export type WireInputLifecycleState = "accepted" | "queued" | "staged" | "applied" | "applied_pending_consumption" | "consumed" | "superseded" | "coalesced" | "abandoned";
1932
1945
  export type WireStopReason = "end_turn" | "tool_use" | "max_tokens" | "stop_sequence" | "content_filter" | "cancelled";
@@ -2063,7 +2076,14 @@ export interface BridgeCommandDeclareMemberOutboundTaint {
2063
2076
  supervisor: BridgePeerSpec;
2064
2077
  taint?: SenderContentTaint;
2065
2078
  }
2066
- export type BridgeCommand = BridgeCommandBindMember | BridgeCommandAuthorizeSupervisor | BridgeCommandRevokeSupervisor | BridgeCommandDeliverMemberInput | BridgeCommandObserveMember | BridgeCommandInterruptMember | BridgeCommandHardCancelMember | BridgeCommandRetireMember | BridgeCommandDestroyMember | BridgeCommandWireMember | BridgeCommandUnwireMember | BridgeCommandDeclareMemberOutboundTaint;
2079
+ export interface BridgeCommandObserveSupervisorRotation {
2080
+ command: "observe_supervisor_rotation";
2081
+ observer: BridgePeerSpec;
2082
+ observer_epoch: number;
2083
+ operation_id: unknown;
2084
+ protocol_version: BridgeProtocolVersion;
2085
+ }
2086
+ export type BridgeCommand = BridgeCommandBindMember | BridgeCommandAuthorizeSupervisor | BridgeCommandRevokeSupervisor | BridgeCommandDeliverMemberInput | BridgeCommandObserveMember | BridgeCommandInterruptMember | BridgeCommandHardCancelMember | BridgeCommandRetireMember | BridgeCommandDestroyMember | BridgeCommandWireMember | BridgeCommandUnwireMember | BridgeCommandDeclareMemberOutboundTaint | BridgeCommandObserveSupervisorRotation;
2067
2087
  export interface BridgeDeliveryOutcomeAccepted {
2068
2088
  outcome: "accepted";
2069
2089
  }
@@ -2132,12 +2152,15 @@ export interface BridgeReplyDestroy {
2132
2152
  inputs_abandoned: number;
2133
2153
  result: "destroy";
2134
2154
  }
2155
+ export interface BridgeReplySupervisorRotation {
2156
+ result: "supervisor_rotation";
2157
+ }
2135
2158
  export interface BridgeReplyRejected {
2136
2159
  cause: BridgeRejectionCause;
2137
2160
  reason: string;
2138
2161
  result: "rejected";
2139
2162
  }
2140
- export type BridgeReply = BridgeReplyBindMember | BridgeReplyAck | BridgeReplyObservation | BridgeReplyDelivery | BridgeReplyRetire | BridgeReplyDestroy | BridgeReplyRejected;
2163
+ export type BridgeReply = BridgeReplyBindMember | BridgeReplyAck | BridgeReplyObservation | BridgeReplyDelivery | BridgeReplyRetire | BridgeReplyDestroy | BridgeReplySupervisorRotation | BridgeReplyRejected;
2141
2164
  export interface ContentBlockText {
2142
2165
  text: string;
2143
2166
  type: "text";
@@ -2298,7 +2321,13 @@ export interface RealtimeVideoChunk {
2298
2321
  data: string;
2299
2322
  mime_type: string;
2300
2323
  }
2324
+ export interface RealtimeImageChunk {
2325
+ data: string;
2326
+ idempotency_key: string;
2327
+ mime_type: string;
2328
+ }
2301
2329
  export interface LiveOpenParams {
2330
+ seed_max_chars?: number;
2302
2331
  session_id: string;
2303
2332
  transport?: "websocket" | "webrtc";
2304
2333
  turning_mode?: RealtimeTurningMode;
@@ -2373,6 +2402,9 @@ export interface LiveSendInputParams {
2373
2402
  channel_id: string;
2374
2403
  chunk: LiveInputChunkWire;
2375
2404
  }
2405
+ export interface LiveSendInputErrorData {
2406
+ error_code: WireLiveAdapterErrorCode;
2407
+ }
2376
2408
  export interface LiveTruncateParams {
2377
2409
  audio_played_ms: number;
2378
2410
  channel_id: string;
@@ -2430,6 +2462,7 @@ export interface LiveInputChunkWireText {
2430
2462
  }
2431
2463
  export interface LiveInputChunkWireImage {
2432
2464
  data: string;
2465
+ idempotency_key: string;
2433
2466
  kind: "image";
2434
2467
  mime: string;
2435
2468
  }
@@ -2493,9 +2526,9 @@ export interface RealtimeTranscriptEventAssistantTranscriptFinalText {
2493
2526
  }
2494
2527
  export interface RealtimeTranscriptEventAssistantTurnCompleted {
2495
2528
  response_id: string;
2496
- stop_reason: unknown;
2529
+ stop_reason: "end_turn" | "tool_use" | "max_tokens" | "stop_sequence" | "content_filter" | "cancelled";
2497
2530
  type: "assistant_turn_completed";
2498
- usage: unknown;
2531
+ usage: Record<string, unknown>;
2499
2532
  }
2500
2533
  export interface RealtimeTranscriptEventAssistantTurnInterrupted {
2501
2534
  response_id: string;
@@ -2560,6 +2593,54 @@ export interface WireLiveConfigRejectionReasonNonRealtimeResolution {
2560
2593
  export interface WireLiveConfigRejectionReasonImageInputNotImplemented {
2561
2594
  kind: "image_input_not_implemented";
2562
2595
  }
2596
+ export interface WireLiveConfigRejectionReasonImageInputUnsupportedMime {
2597
+ kind: "image_input_unsupported_mime";
2598
+ mime_type: string;
2599
+ }
2600
+ export interface WireLiveConfigRejectionReasonImageInputContentMismatch {
2601
+ kind: "image_input_content_mismatch";
2602
+ mime_type: string;
2603
+ }
2604
+ export interface WireLiveConfigRejectionReasonImageInputInvalidBase64 {
2605
+ kind: "image_input_invalid_base64";
2606
+ }
2607
+ export interface WireLiveConfigRejectionReasonImageInputTooLarge {
2608
+ actual_bytes: number;
2609
+ kind: "image_input_too_large";
2610
+ max_bytes: number;
2611
+ }
2612
+ export interface WireLiveConfigRejectionReasonImageInputIdempotencyKeyInvalid {
2613
+ actual_bytes: number;
2614
+ kind: "image_input_idempotency_key_invalid";
2615
+ max_bytes: number;
2616
+ }
2617
+ export interface WireLiveConfigRejectionReasonImageInputIdempotencyConflict {
2618
+ kind: "image_input_idempotency_conflict";
2619
+ }
2620
+ export interface WireLiveConfigRejectionReasonImageInputHistoryBudgetExceeded {
2621
+ kind: "image_input_history_budget_exceeded";
2622
+ max_decoded_bytes: number;
2623
+ }
2624
+ export interface WireLiveConfigRejectionReasonImageInputRequiresCommit {
2625
+ kind: "image_input_requires_commit";
2626
+ }
2627
+ export interface WireLiveConfigRejectionReasonInputTooLarge {
2628
+ actual_bytes: number;
2629
+ kind: "input_too_large";
2630
+ max_bytes: number;
2631
+ }
2632
+ export interface WireLiveConfigRejectionReasonInputBackpressured {
2633
+ kind: "input_backpressured";
2634
+ max_pending_bytes: number;
2635
+ }
2636
+ export interface WireLiveConfigRejectionReasonImageInputBackpressured {
2637
+ kind: "image_input_backpressured";
2638
+ max_pending_bytes: number;
2639
+ }
2640
+ export interface WireLiveConfigRejectionReasonImageInputTransportUnsupported {
2641
+ kind: "image_input_transport_unsupported";
2642
+ transport: string;
2643
+ }
2563
2644
  export interface WireLiveConfigRejectionReasonVideoFrameInputNotImplemented {
2564
2645
  kind: "video_frame_input_not_implemented";
2565
2646
  }
@@ -2580,6 +2661,9 @@ export interface WireLiveConfigRejectionReasonRefreshAudioConfigMismatch {
2580
2661
  detail: string;
2581
2662
  kind: "refresh_audio_config_mismatch";
2582
2663
  }
2664
+ export interface WireLiveConfigRejectionReasonRefreshTranscriptRewriteRequiresReopen {
2665
+ kind: "refresh_transcript_rewrite_requires_reopen";
2666
+ }
2583
2667
  export interface WireLiveConfigRejectionReasonAudioInputFormatMismatch {
2584
2668
  actual_channels: number;
2585
2669
  actual_sample_rate_hz: number;
@@ -2595,7 +2679,7 @@ export interface WireLiveConfigRejectionReasonUnknown {
2595
2679
  debug: string;
2596
2680
  kind: "unknown";
2597
2681
  }
2598
- export type WireLiveConfigRejectionReason = WireLiveConfigRejectionReasonChannelIdentitySwap | WireLiveConfigRejectionReasonNonRealtimeResolution | WireLiveConfigRejectionReasonImageInputNotImplemented | WireLiveConfigRejectionReasonVideoFrameInputNotImplemented | WireLiveConfigRejectionReasonUnsupportedInputChunkVariant | WireLiveConfigRejectionReasonRefreshModelSwap | WireLiveConfigRejectionReasonRefreshProviderSwap | WireLiveConfigRejectionReasonRefreshAudioConfigMismatch | WireLiveConfigRejectionReasonAudioInputFormatMismatch | WireLiveConfigRejectionReasonOther | WireLiveConfigRejectionReasonUnknown;
2682
+ export type WireLiveConfigRejectionReason = WireLiveConfigRejectionReasonChannelIdentitySwap | WireLiveConfigRejectionReasonNonRealtimeResolution | WireLiveConfigRejectionReasonImageInputNotImplemented | WireLiveConfigRejectionReasonImageInputUnsupportedMime | WireLiveConfigRejectionReasonImageInputContentMismatch | WireLiveConfigRejectionReasonImageInputInvalidBase64 | WireLiveConfigRejectionReasonImageInputTooLarge | WireLiveConfigRejectionReasonImageInputIdempotencyKeyInvalid | WireLiveConfigRejectionReasonImageInputIdempotencyConflict | WireLiveConfigRejectionReasonImageInputHistoryBudgetExceeded | WireLiveConfigRejectionReasonImageInputRequiresCommit | WireLiveConfigRejectionReasonInputTooLarge | WireLiveConfigRejectionReasonInputBackpressured | WireLiveConfigRejectionReasonImageInputBackpressured | WireLiveConfigRejectionReasonImageInputTransportUnsupported | WireLiveConfigRejectionReasonVideoFrameInputNotImplemented | WireLiveConfigRejectionReasonUnsupportedInputChunkVariant | WireLiveConfigRejectionReasonRefreshModelSwap | WireLiveConfigRejectionReasonRefreshProviderSwap | WireLiveConfigRejectionReasonRefreshAudioConfigMismatch | WireLiveConfigRejectionReasonRefreshTranscriptRewriteRequiresReopen | WireLiveConfigRejectionReasonAudioInputFormatMismatch | WireLiveConfigRejectionReasonOther | WireLiveConfigRejectionReasonUnknown;
2599
2683
  export interface WireLiveAdapterErrorCodeConnectionFailed {
2600
2684
  code: "connection_failed";
2601
2685
  }
@@ -2683,6 +2767,14 @@ export interface WireLiveAdapterObservationRealtimeTranscript {
2683
2767
  event: RealtimeTranscriptEvent;
2684
2768
  observation: "realtime_transcript";
2685
2769
  }
2770
+ export interface WireLiveAdapterObservationUserContentCommitted {
2771
+ content_index: number;
2772
+ idempotency_key: string;
2773
+ item_id: string;
2774
+ media_type: string;
2775
+ observation: "user_content_committed";
2776
+ previous_item_id?: string;
2777
+ }
2686
2778
  export interface WireLiveAdapterObservationToolCallRequested {
2687
2779
  arguments: unknown;
2688
2780
  observation: "tool_call_requested";
@@ -2717,7 +2809,7 @@ export interface WireLiveAdapterObservationUnknown {
2717
2809
  debug: string;
2718
2810
  observation: "unknown";
2719
2811
  }
2720
- export type WireLiveAdapterObservation = WireLiveAdapterObservationReady | WireLiveAdapterObservationUserTranscriptFinal | WireLiveAdapterObservationAssistantTextDelta | WireLiveAdapterObservationAssistantTranscriptDelta | WireLiveAdapterObservationAssistantAudioChunk | WireLiveAdapterObservationAssistantTranscriptFinal | WireLiveAdapterObservationAssistantTranscriptTruncated | WireLiveAdapterObservationRealtimeTranscript | WireLiveAdapterObservationToolCallRequested | WireLiveAdapterObservationTurnInterrupted | WireLiveAdapterObservationTurnCompleted | WireLiveAdapterObservationStatusChanged | WireLiveAdapterObservationError | WireLiveAdapterObservationCommandRejected | WireLiveAdapterObservationUnknown;
2812
+ export type WireLiveAdapterObservation = WireLiveAdapterObservationReady | WireLiveAdapterObservationUserTranscriptFinal | WireLiveAdapterObservationAssistantTextDelta | WireLiveAdapterObservationAssistantTranscriptDelta | WireLiveAdapterObservationAssistantAudioChunk | WireLiveAdapterObservationAssistantTranscriptFinal | WireLiveAdapterObservationAssistantTranscriptTruncated | WireLiveAdapterObservationRealtimeTranscript | WireLiveAdapterObservationUserContentCommitted | WireLiveAdapterObservationToolCallRequested | WireLiveAdapterObservationTurnInterrupted | WireLiveAdapterObservationTurnCompleted | WireLiveAdapterObservationStatusChanged | WireLiveAdapterObservationError | WireLiveAdapterObservationCommandRejected | WireLiveAdapterObservationUnknown;
2721
2813
  export interface RuntimeAcceptResult {
2722
2814
  existing_id?: string;
2723
2815
  input_id?: string;