@broberg/ai-sdk 0.57.0 → 0.58.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.ts CHANGED
@@ -1,8 +1,74 @@
1
+ import { C as CostSink, T as Tier, U as Usage, a as ChatResult, b as ChatStreamEvent, c as TranslateResult, I as ImageResult, A as AnimateResult, d as TrainStyleResult, E as EmbeddingResult, e as TranscribeResult, O as OcrResult, M as ModerationResult, J as JudgeResult, P as PodcastResult, B as BatchRequestItem, f as TierSpec, g as BatchJob, h as BatchResultItem, i as ProviderAdapter, j as ToolCall, k as Tool, l as Transport, m as Capability, R as Region, n as BudgetConfig, o as BudgetStore } from './registry-VqJrONWk.js';
2
+ export { p as AlignedWordTimings, q as AvailabilitySource, r as AvailabilityStatus, s as AzureWordBoundary, t as CallOptions, u as ChatRequest, v as ContentPart, D as DialogueRequest, w as DialogueTurn, x as EmbeddingRequest, y as ImageRequest, z as JudgeAnswer, F as JudgeChoiceAnswer, G as JudgeNoulAnswer, H as JudgeQuestion, K as JudgeScoreAnswer, L as LoraWeight, N as Message, Q as ModelStatus, S as ModelUnavailableError, V as ModerationItem, W as ModerationRequest, X as OcrPage, Y as OcrRequest, Z as ResolveOptions, _ as ResolveResult, $ as Role, a0 as TierDescription, a1 as TrainStyleRequest, a2 as TranscribeRequest, a3 as TtsRequest, a4 as WordTiming, a5 as alignWordTimings, a6 as classifyRegionName, a7 as describeTier, a8 as listModels, a9 as regionOfHost, aa as regionOfProvider, ab as resolveModel } from './registry-VqJrONWk.js';
1
3
  import { z } from 'zod';
2
- import { T as Tier, U as Usage, C as ChatResult, a as ChatStreamEvent, b as TranslateResult, I as ImageResult, A as AnimateResult, c as TrainStyleResult, E as EmbeddingResult, d as TranscribeResult, O as OcrResult, M as ModerationResult, J as JudgeResult, P as PodcastResult, B as BatchRequestItem, e as TierSpec, f as BatchJob, g as BatchResultItem, h as ProviderAdapter, i as CostSink, j as ToolCall, k as Tool, l as Transport, m as Capability, R as Region, n as BudgetConfig, o as BudgetStore } from './registry-U66vzTm0.js';
3
- export { p as AlignedWordTimings, q as AvailabilitySource, r as AvailabilityStatus, s as AzureWordBoundary, t as CallOptions, u as ChatRequest, v as ContentPart, D as DialogueRequest, w as DialogueTurn, x as EmbeddingRequest, y as ImageRequest, z as JudgeAnswer, F as JudgeChoiceAnswer, G as JudgeNoulAnswer, H as JudgeQuestion, K as JudgeScoreAnswer, L as LoraWeight, N as Message, Q as ModelStatus, S as ModelUnavailableError, V as ModerationItem, W as ModerationRequest, X as OcrPage, Y as OcrRequest, Z as ResolveOptions, _ as ResolveResult, $ as Role, a0 as TierDescription, a1 as TrainStyleRequest, a2 as TranscribeRequest, a3 as TtsRequest, a4 as WordTiming, a5 as alignWordTimings, a6 as classifyRegionName, a7 as describeTier, a8 as listModels, a9 as regionOfHost, aa as regionOfProvider, ab as resolveModel } from './registry-U66vzTm0.js';
4
4
  export { DEFAULT_CLIP_SEC, MEDIA_PRICING_CHECKED_AT, MediaPrice, MediaUnit, PRICING_STALE_AFTER_DAYS, PricingFreshness, UnitFreshness, getMediaPrice, listMediaPrices, pricingFreshness, pricingGeneratedAt } from './pricing.js';
5
5
 
6
+ type SearchProviderId = "brave" | "cloudflare:ceramic" | "cloudflare:linkup" | "cloudflare:exa";
7
+ /** Why the search runs — picks the route and the cache lifetime (F078.2). */
8
+ type SearchPurpose = "agent" | "grounding" | "discovery" | "monitor";
9
+ interface SearchRequest {
10
+ query: string;
11
+ /** BCP-47-ish language of the query ("da", "en"). Routing input (F078.2); Brave also filters on it. */
12
+ lang?: string;
13
+ /** Country hint for providers that filter on it (Brave: "DK"). */
14
+ country?: string;
15
+ /** Max results. Cloudflare caps at 10. */
16
+ limit?: number;
17
+ /** Omit to let the router choose (F078.2). Set to force one provider — the only way to reach Exa. */
18
+ provider?: SearchProviderId;
19
+ purpose?: SearchPurpose;
20
+ /** Results must be recent / news-like — routes to Brave, the only provider with freshness filters. */
21
+ fresh?: boolean;
22
+ /** Only Zero-Data-Retention providers (customer data in the query). Excludes Exa and Brave. */
23
+ zdr?: boolean;
24
+ /** Attribution on the cost-sink row, e.g. { tenantId }. */
25
+ labels?: Record<string, string>;
26
+ }
27
+ interface SearchItem {
28
+ title: string;
29
+ url: string;
30
+ description: string;
31
+ provider: SearchProviderId;
32
+ lang?: string;
33
+ /** ISO timestamp when the provider reports one (Brave does; Cloudflare's providers do not). */
34
+ publishedAt?: string;
35
+ }
36
+ interface SearchResult {
37
+ items: SearchItem[];
38
+ meta: {
39
+ provider: SearchProviderId;
40
+ latencyMs: number;
41
+ cached: boolean;
42
+ costUsd: number;
43
+ requestId?: string;
44
+ };
45
+ }
46
+ interface SearchCredentials {
47
+ braveApiKey?: string;
48
+ cloudflareAccountId?: string;
49
+ cloudflareApiToken?: string;
50
+ }
51
+ interface SearchCache {
52
+ get(key: string): SearchResult | undefined;
53
+ set(key: string, value: SearchResult, ttlMs: number): void;
54
+ }
55
+ interface SearchOptions {
56
+ /** false = no cache. Default: one in-process memory cache shared by all calls. */
57
+ cache?: SearchCache | false;
58
+ /** Where each call (and each failed attempt) is recorded. ai.search() passes the client's sink. */
59
+ costSink?: CostSink;
60
+ /** Explicit keys (BYOK); missing fields fall back to env. */
61
+ credentials?: SearchCredentials;
62
+ /** Injectable fetch (tests, proxies) — same contract as the model adapters (F073). */
63
+ fetch?: typeof fetch;
64
+ }
65
+ /** Thrown before any request when the provider's key is absent — names the env var to set. */
66
+ declare class SearchKeyMissingError extends Error {
67
+ readonly provider: SearchProviderId;
68
+ readonly envVar: string;
69
+ constructor(provider: SearchProviderId, envVar: string);
70
+ }
71
+
6
72
  interface MockupInput {
7
73
  description: string;
8
74
  constraints?: string;
@@ -422,6 +488,8 @@ declare const chatInputSchema: z.ZodObject<{
422
488
  responseFormat: z.ZodOptional<z.ZodEnum<["json", "text"]>>;
423
489
  }, "strip", z.ZodTypeAny, {
424
490
  system?: string | undefined;
491
+ purpose?: string | undefined;
492
+ labels?: Record<string, string> | undefined;
425
493
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
426
494
  prompt?: string | undefined;
427
495
  messages?: {
@@ -449,7 +517,6 @@ declare const chatInputSchema: z.ZodObject<{
449
517
  description: string;
450
518
  }[] | undefined;
451
519
  temperature?: number | undefined;
452
- purpose?: string | undefined;
453
520
  promptCacheKey?: string | undefined;
454
521
  promptCache?: boolean | undefined;
455
522
  maxTokens?: number | undefined;
@@ -466,9 +533,10 @@ declare const chatInputSchema: z.ZodObject<{
466
533
  transport: "http" | "subprocess";
467
534
  })[] | undefined;
468
535
  allowFloating?: boolean | undefined;
469
- labels?: Record<string, string> | undefined;
470
536
  }, {
471
537
  system?: string | undefined;
538
+ purpose?: string | undefined;
539
+ labels?: Record<string, string> | undefined;
472
540
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
473
541
  prompt?: string | undefined;
474
542
  messages?: {
@@ -496,7 +564,6 @@ declare const chatInputSchema: z.ZodObject<{
496
564
  description: string;
497
565
  }[] | undefined;
498
566
  temperature?: number | undefined;
499
- purpose?: string | undefined;
500
567
  promptCacheKey?: string | undefined;
501
568
  promptCache?: boolean | undefined;
502
569
  maxTokens?: number | undefined;
@@ -513,7 +580,6 @@ declare const chatInputSchema: z.ZodObject<{
513
580
  transport: "http" | "subprocess";
514
581
  })[] | undefined;
515
582
  allowFloating?: boolean | undefined;
516
- labels?: Record<string, string> | undefined;
517
583
  }>;
518
584
  declare const visionInputSchema: z.ZodObject<{
519
585
  tier: z.ZodOptional<z.ZodEnum<["fast", "smart", "powerful", "cheap", "vision", "video", "embedding"]>>;
@@ -556,9 +622,10 @@ declare const visionInputSchema: z.ZodObject<{
556
622
  image: string | Uint8Array<ArrayBuffer>;
557
623
  prompt: string;
558
624
  system?: string | undefined;
625
+ purpose?: string | undefined;
626
+ labels?: Record<string, string> | undefined;
559
627
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
560
628
  mimeType?: string | undefined;
561
- purpose?: string | undefined;
562
629
  override?: {
563
630
  provider?: string | undefined;
564
631
  model?: string | undefined;
@@ -570,14 +637,14 @@ declare const visionInputSchema: z.ZodObject<{
570
637
  transport: "http" | "subprocess";
571
638
  })[] | undefined;
572
639
  allowFloating?: boolean | undefined;
573
- labels?: Record<string, string> | undefined;
574
640
  }, {
575
641
  image: string | Uint8Array<ArrayBuffer>;
576
642
  prompt: string;
577
643
  system?: string | undefined;
644
+ purpose?: string | undefined;
645
+ labels?: Record<string, string> | undefined;
578
646
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
579
647
  mimeType?: string | undefined;
580
- purpose?: string | undefined;
581
648
  override?: {
582
649
  provider?: string | undefined;
583
650
  model?: string | undefined;
@@ -589,7 +656,6 @@ declare const visionInputSchema: z.ZodObject<{
589
656
  transport: "http" | "subprocess";
590
657
  })[] | undefined;
591
658
  allowFloating?: boolean | undefined;
592
- labels?: Record<string, string> | undefined;
593
659
  }>;
594
660
  declare const videoInputSchema: z.ZodObject<{
595
661
  tier: z.ZodOptional<z.ZodEnum<["fast", "smart", "powerful", "cheap", "vision", "video", "embedding"]>>;
@@ -631,9 +697,10 @@ declare const videoInputSchema: z.ZodObject<{
631
697
  video: string | Uint8Array<ArrayBuffer>;
632
698
  prompt: string;
633
699
  system?: string | undefined;
700
+ purpose?: string | undefined;
701
+ labels?: Record<string, string> | undefined;
634
702
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
635
703
  mimeType?: string | undefined;
636
- purpose?: string | undefined;
637
704
  override?: {
638
705
  provider?: string | undefined;
639
706
  model?: string | undefined;
@@ -645,14 +712,14 @@ declare const videoInputSchema: z.ZodObject<{
645
712
  transport: "http" | "subprocess";
646
713
  })[] | undefined;
647
714
  allowFloating?: boolean | undefined;
648
- labels?: Record<string, string> | undefined;
649
715
  }, {
650
716
  video: string | Uint8Array<ArrayBuffer>;
651
717
  prompt: string;
652
718
  system?: string | undefined;
719
+ purpose?: string | undefined;
720
+ labels?: Record<string, string> | undefined;
653
721
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
654
722
  mimeType?: string | undefined;
655
- purpose?: string | undefined;
656
723
  override?: {
657
724
  provider?: string | undefined;
658
725
  model?: string | undefined;
@@ -664,7 +731,6 @@ declare const videoInputSchema: z.ZodObject<{
664
731
  transport: "http" | "subprocess";
665
732
  })[] | undefined;
666
733
  allowFloating?: boolean | undefined;
667
- labels?: Record<string, string> | undefined;
668
734
  }>;
669
735
  declare const translateInputSchema: z.ZodObject<{
670
736
  tier: z.ZodOptional<z.ZodEnum<["fast", "smart", "powerful", "cheap", "vision", "video", "embedding"]>>;
@@ -703,8 +769,9 @@ declare const translateInputSchema: z.ZodObject<{
703
769
  }, "strip", z.ZodTypeAny, {
704
770
  text: string;
705
771
  to: string;
706
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
707
772
  purpose?: string | undefined;
773
+ labels?: Record<string, string> | undefined;
774
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
708
775
  override?: {
709
776
  provider?: string | undefined;
710
777
  model?: string | undefined;
@@ -716,13 +783,13 @@ declare const translateInputSchema: z.ZodObject<{
716
783
  transport: "http" | "subprocess";
717
784
  })[] | undefined;
718
785
  allowFloating?: boolean | undefined;
719
- labels?: Record<string, string> | undefined;
720
786
  from?: string | undefined;
721
787
  }, {
722
788
  text: string;
723
789
  to: string;
724
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
725
790
  purpose?: string | undefined;
791
+ labels?: Record<string, string> | undefined;
792
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
726
793
  override?: {
727
794
  provider?: string | undefined;
728
795
  model?: string | undefined;
@@ -734,7 +801,6 @@ declare const translateInputSchema: z.ZodObject<{
734
801
  transport: "http" | "subprocess";
735
802
  })[] | undefined;
736
803
  allowFloating?: boolean | undefined;
737
- labels?: Record<string, string> | undefined;
738
804
  from?: string | undefined;
739
805
  }>;
740
806
  declare const imageInputSchema: z.ZodObject<{
@@ -802,9 +868,10 @@ declare const imageInputSchema: z.ZodObject<{
802
868
  retryOnBlack: z.ZodOptional<z.ZodBoolean>;
803
869
  }, "strip", z.ZodTypeAny, {
804
870
  prompt: string;
871
+ purpose?: string | undefined;
872
+ labels?: Record<string, string> | undefined;
805
873
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
806
874
  seed?: number | undefined;
807
- purpose?: string | undefined;
808
875
  outputFormat?: "jpeg" | "png" | "webp" | undefined;
809
876
  loras?: {
810
877
  path: string;
@@ -824,7 +891,6 @@ declare const imageInputSchema: z.ZodObject<{
824
891
  transport: "http" | "subprocess";
825
892
  })[] | undefined;
826
893
  allowFloating?: boolean | undefined;
827
- labels?: Record<string, string> | undefined;
828
894
  finetune?: string | undefined;
829
895
  finetuneStrength?: number | undefined;
830
896
  referenceImages?: (string | Uint8Array<ArrayBuffer>)[] | undefined;
@@ -832,9 +898,10 @@ declare const imageInputSchema: z.ZodObject<{
832
898
  retryOnBlack?: boolean | undefined;
833
899
  }, {
834
900
  prompt: string;
901
+ purpose?: string | undefined;
902
+ labels?: Record<string, string> | undefined;
835
903
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
836
904
  seed?: number | undefined;
837
- purpose?: string | undefined;
838
905
  outputFormat?: "jpeg" | "png" | "webp" | undefined;
839
906
  loras?: {
840
907
  path: string;
@@ -854,7 +921,6 @@ declare const imageInputSchema: z.ZodObject<{
854
921
  transport: "http" | "subprocess";
855
922
  })[] | undefined;
856
923
  allowFloating?: boolean | undefined;
857
- labels?: Record<string, string> | undefined;
858
924
  finetune?: string | undefined;
859
925
  finetuneStrength?: number | undefined;
860
926
  referenceImages?: (string | Uint8Array<ArrayBuffer>)[] | undefined;
@@ -903,10 +969,11 @@ declare const animateInputSchema: z.ZodObject<{
903
969
  resolution: z.ZodOptional<z.ZodString>;
904
970
  }, "strip", z.ZodTypeAny, {
905
971
  image: string | Uint8Array<ArrayBuffer>;
972
+ purpose?: string | undefined;
973
+ labels?: Record<string, string> | undefined;
906
974
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
907
975
  prompt?: string | undefined;
908
976
  resolution?: string | undefined;
909
- purpose?: string | undefined;
910
977
  override?: {
911
978
  provider?: string | undefined;
912
979
  model?: string | undefined;
@@ -918,14 +985,14 @@ declare const animateInputSchema: z.ZodObject<{
918
985
  transport: "http" | "subprocess";
919
986
  })[] | undefined;
920
987
  allowFloating?: boolean | undefined;
921
- labels?: Record<string, string> | undefined;
922
988
  durationSec?: number | undefined;
923
989
  }, {
924
990
  image: string | Uint8Array<ArrayBuffer>;
991
+ purpose?: string | undefined;
992
+ labels?: Record<string, string> | undefined;
925
993
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
926
994
  prompt?: string | undefined;
927
995
  resolution?: string | undefined;
928
- purpose?: string | undefined;
929
996
  override?: {
930
997
  provider?: string | undefined;
931
998
  model?: string | undefined;
@@ -937,7 +1004,6 @@ declare const animateInputSchema: z.ZodObject<{
937
1004
  transport: "http" | "subprocess";
938
1005
  })[] | undefined;
939
1006
  allowFloating?: boolean | undefined;
940
- labels?: Record<string, string> | undefined;
941
1007
  durationSec?: number | undefined;
942
1008
  }>;
943
1009
  declare const trainStyleInputSchema: z.ZodObject<{
@@ -980,8 +1046,9 @@ declare const trainStyleInputSchema: z.ZodObject<{
980
1046
  createMasks: z.ZodOptional<z.ZodBoolean>;
981
1047
  }, "strip", z.ZodTypeAny, {
982
1048
  images: string | string[];
983
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
984
1049
  purpose?: string | undefined;
1050
+ labels?: Record<string, string> | undefined;
1051
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
985
1052
  steps?: number | undefined;
986
1053
  override?: {
987
1054
  provider?: string | undefined;
@@ -994,14 +1061,14 @@ declare const trainStyleInputSchema: z.ZodObject<{
994
1061
  transport: "http" | "subprocess";
995
1062
  })[] | undefined;
996
1063
  allowFloating?: boolean | undefined;
997
- labels?: Record<string, string> | undefined;
998
1064
  isStyle?: boolean | undefined;
999
1065
  triggerWord?: string | undefined;
1000
1066
  createMasks?: boolean | undefined;
1001
1067
  }, {
1002
1068
  images: string | string[];
1003
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1004
1069
  purpose?: string | undefined;
1070
+ labels?: Record<string, string> | undefined;
1071
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1005
1072
  steps?: number | undefined;
1006
1073
  override?: {
1007
1074
  provider?: string | undefined;
@@ -1014,7 +1081,6 @@ declare const trainStyleInputSchema: z.ZodObject<{
1014
1081
  transport: "http" | "subprocess";
1015
1082
  })[] | undefined;
1016
1083
  allowFloating?: boolean | undefined;
1017
- labels?: Record<string, string> | undefined;
1018
1084
  isStyle?: boolean | undefined;
1019
1085
  triggerWord?: string | undefined;
1020
1086
  createMasks?: boolean | undefined;
@@ -1053,8 +1119,9 @@ declare const embeddingInputSchema: z.ZodObject<{
1053
1119
  text: z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>;
1054
1120
  }, "strip", z.ZodTypeAny, {
1055
1121
  text: string | string[];
1056
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1057
1122
  purpose?: string | undefined;
1123
+ labels?: Record<string, string> | undefined;
1124
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1058
1125
  override?: {
1059
1126
  provider?: string | undefined;
1060
1127
  model?: string | undefined;
@@ -1066,11 +1133,11 @@ declare const embeddingInputSchema: z.ZodObject<{
1066
1133
  transport: "http" | "subprocess";
1067
1134
  })[] | undefined;
1068
1135
  allowFloating?: boolean | undefined;
1069
- labels?: Record<string, string> | undefined;
1070
1136
  }, {
1071
1137
  text: string | string[];
1072
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1073
1138
  purpose?: string | undefined;
1139
+ labels?: Record<string, string> | undefined;
1140
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1074
1141
  override?: {
1075
1142
  provider?: string | undefined;
1076
1143
  model?: string | undefined;
@@ -1082,7 +1149,6 @@ declare const embeddingInputSchema: z.ZodObject<{
1082
1149
  transport: "http" | "subprocess";
1083
1150
  })[] | undefined;
1084
1151
  allowFloating?: boolean | undefined;
1085
- labels?: Record<string, string> | undefined;
1086
1152
  }>;
1087
1153
  declare const transcribeInputSchema: z.ZodObject<{
1088
1154
  tier: z.ZodOptional<z.ZodEnum<["fast", "smart", "powerful", "cheap", "vision", "video", "embedding"]>>;
@@ -1129,9 +1195,10 @@ declare const transcribeInputSchema: z.ZodObject<{
1129
1195
  timestamps: z.ZodOptional<z.ZodUnion<[z.ZodEnum<["word", "segment"]>, z.ZodArray<z.ZodEnum<["word", "segment"]>, "many">]>>;
1130
1196
  }, "strip", z.ZodTypeAny, {
1131
1197
  audio: string | Uint8Array<ArrayBuffer>;
1198
+ purpose?: string | undefined;
1199
+ labels?: Record<string, string> | undefined;
1132
1200
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1133
1201
  language?: string | undefined;
1134
- purpose?: string | undefined;
1135
1202
  override?: {
1136
1203
  provider?: string | undefined;
1137
1204
  model?: string | undefined;
@@ -1143,15 +1210,15 @@ declare const transcribeInputSchema: z.ZodObject<{
1143
1210
  transport: "http" | "subprocess";
1144
1211
  })[] | undefined;
1145
1212
  allowFloating?: boolean | undefined;
1146
- labels?: Record<string, string> | undefined;
1147
1213
  durationSec?: number | undefined;
1148
1214
  phrases?: string[] | undefined;
1149
1215
  timestamps?: "word" | "segment" | ("word" | "segment")[] | undefined;
1150
1216
  }, {
1151
1217
  audio: string | Uint8Array<ArrayBuffer>;
1218
+ purpose?: string | undefined;
1219
+ labels?: Record<string, string> | undefined;
1152
1220
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1153
1221
  language?: string | undefined;
1154
- purpose?: string | undefined;
1155
1222
  override?: {
1156
1223
  provider?: string | undefined;
1157
1224
  model?: string | undefined;
@@ -1163,7 +1230,6 @@ declare const transcribeInputSchema: z.ZodObject<{
1163
1230
  transport: "http" | "subprocess";
1164
1231
  })[] | undefined;
1165
1232
  allowFloating?: boolean | undefined;
1166
- labels?: Record<string, string> | undefined;
1167
1233
  durationSec?: number | undefined;
1168
1234
  phrases?: string[] | undefined;
1169
1235
  timestamps?: "word" | "segment" | ("word" | "segment")[] | undefined;
@@ -1205,9 +1271,10 @@ declare const ocrInputSchema: z.ZodObject<{
1205
1271
  mimeType: z.ZodOptional<z.ZodString>;
1206
1272
  }, "strip", z.ZodTypeAny, {
1207
1273
  document: string | Uint8Array<ArrayBuffer>;
1274
+ purpose?: string | undefined;
1275
+ labels?: Record<string, string> | undefined;
1208
1276
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1209
1277
  mimeType?: string | undefined;
1210
- purpose?: string | undefined;
1211
1278
  override?: {
1212
1279
  provider?: string | undefined;
1213
1280
  model?: string | undefined;
@@ -1219,12 +1286,12 @@ declare const ocrInputSchema: z.ZodObject<{
1219
1286
  transport: "http" | "subprocess";
1220
1287
  })[] | undefined;
1221
1288
  allowFloating?: boolean | undefined;
1222
- labels?: Record<string, string> | undefined;
1223
1289
  }, {
1224
1290
  document: string | Uint8Array<ArrayBuffer>;
1291
+ purpose?: string | undefined;
1292
+ labels?: Record<string, string> | undefined;
1225
1293
  tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1226
1294
  mimeType?: string | undefined;
1227
- purpose?: string | undefined;
1228
1295
  override?: {
1229
1296
  provider?: string | undefined;
1230
1297
  model?: string | undefined;
@@ -1236,7 +1303,6 @@ declare const ocrInputSchema: z.ZodObject<{
1236
1303
  transport: "http" | "subprocess";
1237
1304
  })[] | undefined;
1238
1305
  allowFloating?: boolean | undefined;
1239
- labels?: Record<string, string> | undefined;
1240
1306
  }>;
1241
1307
  declare const moderationInputSchema: z.ZodObject<{
1242
1308
  tier: z.ZodOptional<z.ZodEnum<["fast", "smart", "powerful", "cheap", "vision", "video", "embedding"]>>;
@@ -1272,8 +1338,9 @@ declare const moderationInputSchema: z.ZodObject<{
1272
1338
  input: z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>;
1273
1339
  }, "strip", z.ZodTypeAny, {
1274
1340
  input: string | string[];
1275
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1276
1341
  purpose?: string | undefined;
1342
+ labels?: Record<string, string> | undefined;
1343
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1277
1344
  override?: {
1278
1345
  provider?: string | undefined;
1279
1346
  model?: string | undefined;
@@ -1285,11 +1352,11 @@ declare const moderationInputSchema: z.ZodObject<{
1285
1352
  transport: "http" | "subprocess";
1286
1353
  })[] | undefined;
1287
1354
  allowFloating?: boolean | undefined;
1288
- labels?: Record<string, string> | undefined;
1289
1355
  }, {
1290
1356
  input: string | string[];
1291
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1292
1357
  purpose?: string | undefined;
1358
+ labels?: Record<string, string> | undefined;
1359
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1293
1360
  override?: {
1294
1361
  provider?: string | undefined;
1295
1362
  model?: string | undefined;
@@ -1301,7 +1368,6 @@ declare const moderationInputSchema: z.ZodObject<{
1301
1368
  transport: "http" | "subprocess";
1302
1369
  })[] | undefined;
1303
1370
  allowFloating?: boolean | undefined;
1304
- labels?: Record<string, string> | undefined;
1305
1371
  }>;
1306
1372
  declare const judgeInputSchema: z.ZodObject<{
1307
1373
  tier: z.ZodOptional<z.ZodEnum<["fast", "smart", "powerful", "cheap", "vision", "video", "embedding"]>>;
@@ -1435,8 +1501,9 @@ declare const judgeInputSchema: z.ZodObject<{
1435
1501
  instructions: string | unknown[] | Record<string, unknown> | null;
1436
1502
  criteria: (string | unknown[] | Record<string, unknown> | null)[];
1437
1503
  }>;
1438
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1439
1504
  purpose?: string | undefined;
1505
+ labels?: Record<string, string> | undefined;
1506
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1440
1507
  override?: {
1441
1508
  provider?: string | undefined;
1442
1509
  model?: string | undefined;
@@ -1448,7 +1515,6 @@ declare const judgeInputSchema: z.ZodObject<{
1448
1515
  transport: "http" | "subprocess";
1449
1516
  })[] | undefined;
1450
1517
  allowFloating?: boolean | undefined;
1451
- labels?: Record<string, string> | undefined;
1452
1518
  }, {
1453
1519
  state: string | string[] | Record<string, unknown>;
1454
1520
  questions: Record<string, {
@@ -1467,8 +1533,9 @@ declare const judgeInputSchema: z.ZodObject<{
1467
1533
  instructions: string | unknown[] | Record<string, unknown> | null;
1468
1534
  criteria: (string | unknown[] | Record<string, unknown> | null)[];
1469
1535
  }>;
1470
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1471
1536
  purpose?: string | undefined;
1537
+ labels?: Record<string, string> | undefined;
1538
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1472
1539
  override?: {
1473
1540
  provider?: string | undefined;
1474
1541
  model?: string | undefined;
@@ -1480,7 +1547,6 @@ declare const judgeInputSchema: z.ZodObject<{
1480
1547
  transport: "http" | "subprocess";
1481
1548
  })[] | undefined;
1482
1549
  allowFloating?: boolean | undefined;
1483
- labels?: Record<string, string> | undefined;
1484
1550
  }>;
1485
1551
  declare const podcastInputSchema: z.ZodObject<{
1486
1552
  tier: z.ZodOptional<z.ZodEnum<["fast", "smart", "powerful", "cheap", "vision", "video", "embedding"]>>;
@@ -1538,15 +1604,15 @@ declare const podcastInputSchema: z.ZodObject<{
1538
1604
  }, "strip", z.ZodTypeAny, {
1539
1605
  word: string;
1540
1606
  matchInCompounds?: boolean | undefined;
1607
+ lang?: string | undefined;
1541
1608
  alias?: string | undefined;
1542
1609
  ipa?: string | undefined;
1543
- lang?: string | undefined;
1544
1610
  }, {
1545
1611
  word: string;
1546
1612
  matchInCompounds?: boolean | undefined;
1613
+ lang?: string | undefined;
1547
1614
  alias?: string | undefined;
1548
1615
  ipa?: string | undefined;
1549
- lang?: string | undefined;
1550
1616
  }>, "many">>;
1551
1617
  }, "strip", z.ZodTypeAny, {
1552
1618
  script: {
@@ -1554,14 +1620,15 @@ declare const podcastInputSchema: z.ZodObject<{
1554
1620
  speaker: string;
1555
1621
  }[];
1556
1622
  voices: Record<string, string>;
1557
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1558
1623
  purpose?: string | undefined;
1624
+ labels?: Record<string, string> | undefined;
1625
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1559
1626
  pronunciations?: {
1560
1627
  word: string;
1561
1628
  matchInCompounds?: boolean | undefined;
1629
+ lang?: string | undefined;
1562
1630
  alias?: string | undefined;
1563
1631
  ipa?: string | undefined;
1564
- lang?: string | undefined;
1565
1632
  }[] | undefined;
1566
1633
  override?: {
1567
1634
  provider?: string | undefined;
@@ -1574,7 +1641,6 @@ declare const podcastInputSchema: z.ZodObject<{
1574
1641
  transport: "http" | "subprocess";
1575
1642
  })[] | undefined;
1576
1643
  allowFloating?: boolean | undefined;
1577
- labels?: Record<string, string> | undefined;
1578
1644
  format?: string | undefined;
1579
1645
  }, {
1580
1646
  script: {
@@ -1582,14 +1648,15 @@ declare const podcastInputSchema: z.ZodObject<{
1582
1648
  speaker: string;
1583
1649
  }[];
1584
1650
  voices: Record<string, string>;
1585
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1586
1651
  purpose?: string | undefined;
1652
+ labels?: Record<string, string> | undefined;
1653
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1587
1654
  pronunciations?: {
1588
1655
  word: string;
1589
1656
  matchInCompounds?: boolean | undefined;
1657
+ lang?: string | undefined;
1590
1658
  alias?: string | undefined;
1591
1659
  ipa?: string | undefined;
1592
- lang?: string | undefined;
1593
1660
  }[] | undefined;
1594
1661
  override?: {
1595
1662
  provider?: string | undefined;
@@ -1602,7 +1669,6 @@ declare const podcastInputSchema: z.ZodObject<{
1602
1669
  transport: "http" | "subprocess";
1603
1670
  })[] | undefined;
1604
1671
  allowFloating?: boolean | undefined;
1605
- labels?: Record<string, string> | undefined;
1606
1672
  format?: string | undefined;
1607
1673
  }>;
1608
1674
  declare const ttsInputSchema: z.ZodObject<{
@@ -1650,15 +1716,15 @@ declare const ttsInputSchema: z.ZodObject<{
1650
1716
  }, "strip", z.ZodTypeAny, {
1651
1717
  word: string;
1652
1718
  matchInCompounds?: boolean | undefined;
1719
+ lang?: string | undefined;
1653
1720
  alias?: string | undefined;
1654
1721
  ipa?: string | undefined;
1655
- lang?: string | undefined;
1656
1722
  }, {
1657
1723
  word: string;
1658
1724
  matchInCompounds?: boolean | undefined;
1725
+ lang?: string | undefined;
1659
1726
  alias?: string | undefined;
1660
1727
  ipa?: string | undefined;
1661
- lang?: string | undefined;
1662
1728
  }>, "many">>;
1663
1729
  /** F055 — per-word timings (Azure only). Changes the route to batch synthesis. */
1664
1730
  wordTimings: z.ZodOptional<z.ZodBoolean>;
@@ -1679,15 +1745,17 @@ declare const ttsInputSchema: z.ZodObject<{
1679
1745
  }, "strip", z.ZodTypeAny, {
1680
1746
  text: string;
1681
1747
  voice: string;
1682
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1748
+ lang?: string | undefined;
1683
1749
  purpose?: string | undefined;
1750
+ labels?: Record<string, string> | undefined;
1751
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1684
1752
  wordTimings?: boolean | undefined;
1685
1753
  pronunciations?: {
1686
1754
  word: string;
1687
1755
  matchInCompounds?: boolean | undefined;
1756
+ lang?: string | undefined;
1688
1757
  alias?: string | undefined;
1689
1758
  ipa?: string | undefined;
1690
- lang?: string | undefined;
1691
1759
  }[] | undefined;
1692
1760
  override?: {
1693
1761
  provider?: string | undefined;
@@ -1700,23 +1768,23 @@ declare const ttsInputSchema: z.ZodObject<{
1700
1768
  transport: "http" | "subprocess";
1701
1769
  })[] | undefined;
1702
1770
  allowFloating?: boolean | undefined;
1703
- labels?: Record<string, string> | undefined;
1704
- lang?: string | undefined;
1705
1771
  format?: string | undefined;
1706
1772
  voiceFallback?: string | undefined;
1707
1773
  rate?: number | undefined;
1708
1774
  }, {
1709
1775
  text: string;
1710
1776
  voice: string;
1711
- tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1777
+ lang?: string | undefined;
1712
1778
  purpose?: string | undefined;
1779
+ labels?: Record<string, string> | undefined;
1780
+ tier?: "vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap" | undefined;
1713
1781
  wordTimings?: boolean | undefined;
1714
1782
  pronunciations?: {
1715
1783
  word: string;
1716
1784
  matchInCompounds?: boolean | undefined;
1785
+ lang?: string | undefined;
1717
1786
  alias?: string | undefined;
1718
1787
  ipa?: string | undefined;
1719
- lang?: string | undefined;
1720
1788
  }[] | undefined;
1721
1789
  override?: {
1722
1790
  provider?: string | undefined;
@@ -1729,8 +1797,6 @@ declare const ttsInputSchema: z.ZodObject<{
1729
1797
  transport: "http" | "subprocess";
1730
1798
  })[] | undefined;
1731
1799
  allowFloating?: boolean | undefined;
1732
- labels?: Record<string, string> | undefined;
1733
- lang?: string | undefined;
1734
1800
  format?: string | undefined;
1735
1801
  voiceFallback?: string | undefined;
1736
1802
  rate?: number | undefined;
@@ -1786,8 +1852,8 @@ declare const aiConfigSchema: z.ZodObject<{
1786
1852
  autoResolve?: boolean | undefined;
1787
1853
  }>>;
1788
1854
  }, "strip", z.ZodTypeAny, {
1789
- promptCache?: boolean | undefined;
1790
1855
  labels?: Record<string, string> | undefined;
1856
+ promptCache?: boolean | undefined;
1791
1857
  byok?: boolean | undefined;
1792
1858
  strictPinning?: boolean | undefined;
1793
1859
  defaults?: Partial<Record<"vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap", {
@@ -1806,8 +1872,8 @@ declare const aiConfigSchema: z.ZodObject<{
1806
1872
  autoResolve?: boolean | undefined;
1807
1873
  } | undefined;
1808
1874
  }, {
1809
- promptCache?: boolean | undefined;
1810
1875
  labels?: Record<string, string> | undefined;
1876
+ promptCache?: boolean | undefined;
1811
1877
  byok?: boolean | undefined;
1812
1878
  strictPinning?: boolean | undefined;
1813
1879
  defaults?: Partial<Record<"vision" | "video" | "embedding" | "fast" | "smart" | "powerful" | "cheap", {
@@ -1871,6 +1937,9 @@ interface AiClient {
1871
1937
  /** Judge (F066) — typed yes/no, choice and score decisions with calibrated
1872
1938
  * probabilities. TypeSafe Jev. US-hosted: NOT for personal data. */
1873
1939
  judge(input: JudgeInput): Promise<JudgeResult>;
1940
+ /** F078 — web search through ai-sdk; reports every call to this client's cost sink
1941
+ * with the client's labels. Same request/result as the standalone `search()`. */
1942
+ search(req: SearchRequest, opts?: Omit<SearchOptions, "costSink">): Promise<SearchResult>;
1874
1943
  /** Podcast (F020) — a finished manuscript → one multi-voice audio episode. ElevenLabs. */
1875
1944
  podcast(input: PodcastInput): Promise<PodcastResult>;
1876
1945
  /** Single-voice TTS (F020.4) — text → audio. `voice` = curated name or voiceId. ElevenLabs. */
@@ -2232,8 +2301,8 @@ declare const falStubAdapter: ProviderAdapter;
2232
2301
  * wires the live adapters. */
2233
2302
  declare const stubProviders: Record<string, ProviderAdapter>;
2234
2303
 
2235
- declare const VERSION: "0.57.0";
2236
- declare const SDK_TAG: "@broberg/ai-sdk@0.57.0";
2304
+ declare const VERSION: "0.58.0";
2305
+ declare const SDK_TAG: "@broberg/ai-sdk@0.58.0";
2237
2306
 
2238
2307
  /** Built-in defaults. Every entry is overridable via AiConfig.defaults or a
2239
2308
  * per-call override.
@@ -2758,57 +2827,26 @@ interface StreamTransportRequest extends TransportRequest {
2758
2827
  */
2759
2828
  declare function streamTransport(req: StreamTransportRequest): AsyncIterable<string>;
2760
2829
 
2761
- type SearchProviderId = "brave" | "cloudflare:ceramic" | "cloudflare:linkup" | "cloudflare:exa";
2762
- interface SearchRequest {
2763
- query: string;
2764
- /** BCP-47-ish language of the query ("da", "en"). Routing input (F078.2); Brave also filters on it. */
2765
- lang?: string;
2766
- /** Country hint for providers that filter on it (Brave: "DK"). */
2767
- country?: string;
2768
- /** Max results. Cloudflare caps at 10. */
2769
- limit?: number;
2770
- /** F078.1: required until the router (F078.2) can choose. */
2771
- provider: SearchProviderId;
2772
- }
2773
- interface SearchItem {
2774
- title: string;
2775
- url: string;
2776
- description: string;
2777
- provider: SearchProviderId;
2778
- lang?: string;
2779
- /** ISO timestamp when the provider reports one (Brave does; Cloudflare's providers do not). */
2780
- publishedAt?: string;
2781
- }
2782
- interface SearchResult {
2783
- items: SearchItem[];
2784
- meta: {
2785
- provider: SearchProviderId;
2786
- latencyMs: number;
2787
- cached: boolean;
2788
- costUsd: number;
2789
- requestId?: string;
2830
+ declare const SEARCH_PRICE_USD: Record<SearchProviderId, number>;
2831
+
2832
+ interface SearchRoute {
2833
+ /** Readable name — shows up in tests and in the reason a provider was picked. */
2834
+ name: string;
2835
+ when: {
2836
+ fresh?: boolean;
2837
+ english?: boolean;
2838
+ purpose?: SearchRequest["purpose"][];
2790
2839
  };
2840
+ chain: SearchProviderId[];
2791
2841
  }
2792
- interface SearchCredentials {
2793
- braveApiKey?: string;
2794
- cloudflareAccountId?: string;
2795
- cloudflareApiToken?: string;
2796
- }
2797
- interface SearchOptions {
2798
- /** Explicit keys (BYOK); missing fields fall back to env. */
2799
- credentials?: SearchCredentials;
2800
- /** Injectable fetch (tests, proxies) — same contract as the model adapters (F073). */
2801
- fetch?: typeof fetch;
2802
- }
2803
- /** Thrown before any request when the provider's key is absent — names the env var to set. */
2804
- declare class SearchKeyMissingError extends Error {
2805
- readonly provider: SearchProviderId;
2806
- readonly envVar: string;
2807
- constructor(provider: SearchProviderId, envVar: string);
2808
- }
2842
+ declare const DEFAULT_SEARCH_ROUTES: SearchRoute[];
2843
+ /** Providers that keep no data (Cloudflare docs, 2026-10-09). Brave's standard plan logs 90 days. */
2844
+ declare const ZDR_PROVIDERS: Set<SearchProviderId>;
2845
+ declare function routeSearch(req: SearchRequest, routes?: SearchRoute[]): SearchProviderId[];
2809
2846
 
2810
- declare const SEARCH_PRICE_USD: Record<SearchProviderId, number>;
2847
+ declare const SEARCH_CACHE_TTL_MS: Record<NonNullable<SearchRequest["purpose"]>, number>;
2848
+ declare function memorySearchCache(max?: number): SearchCache;
2811
2849
 
2812
2850
  declare function search(req: SearchRequest, opts?: SearchOptions): Promise<SearchResult>;
2813
2851
 
2814
- export { AZURE_DANISH_VOICES, AZURE_DANISH_VOICE_LIST, type AiClient, type AiConfig, type AzureVoiceInfo, BatchJob, BatchRequestItem, BatchResultItem, type BflAdapterConfig, type BflCredits, BudgetConfig, BudgetExceededError, BudgetGuard, BudgetStore, CONFIG_DERIVED_HOSTS, Capability, type ChatInput, ChatResult, ChatStreamEvent, type CheckVoiceOptions, type ClassifyInput, type ClassifyResult, type Contracts, type CostQuery, CostSink, type CostSummary, type CostSummaryQuery, type CostTimeseriesQuery, DEFAULT_BASE_URLS, DEFAULT_TIER_MAP, type DesignInput, type DesignResult, type DiscordSinkConfig, ELEVENLABS_DANISH_VOICES, type EmbeddingInput, EmbeddingResult, type ExtractInput, type ExtractResult, type FalAdapterConfig, type FixedHostProvider, type HttpResponse, type ImageInput, ImageResult, type JudgeInput, JudgeResult, LOCALLY_PINNED_HOSTS, type MockupInput, type MockupResult, type ModerationInput, ModerationResult, type OcrInput, OcrResult, type OpenAICompatibleConfig, type PodcastInput, PodcastResult, type PriceDriftResult, type PriceDriftRow, type PricingEntry, ProviderAdapter, type RefreshOptions, type RefreshResult, Region, type RerankInput, type RerankResult, type RouteForecast, SDK_TAG, SEARCH_PRICE_USD, type SearchCredentials, type SearchItem, SearchKeyMissingError, type SearchOptions, type SearchProviderId, type SearchRequest, type SearchResult, type SqliteBudgetStoreConfig, type SqliteSinkConfig, StreamHttpError, type SubprocessResponse, Tier, TierSpec, Tool, ToolCall, type TrainStyleInput, TrainStyleResult, type TranscribeInput, TranscribeResult, type TranslateInput, TranslateResult, Transport, type TransportRequest, type TransportResponse, type TtsInput, type UpmetricsCostClientConfig, UpmetricsCostError, type UpmetricsCostRow, type UpmetricsCostSummary, type UpmetricsCostTimeseries, type UpmetricsSink, type UpmetricsSinkConfig, type UpmetricsSinkStats, Usage, VERSION, type VideoInput, type VisionInput, type VoiceInfo, type VoiceProvider, type VoiceResolveResult, type VoiceStatus, VoiceUnavailableError, aiConfigSchema, anthropicAdapter, anthropicApiAdapter, anthropicSubprocessAdapter, azureAdapter, bflAdapter, bflCredits, byokAdapter, chatInputSchema, checkPriceDrift, checkVoice, computeCost, createAI, deepinfraAdapter, deeplAdapter, deepseekAdapter, defaultBaseUrl, defaultProviders, discordSink, elevenlabsAdapter, embeddingInputSchema, falAdapter, falStubAdapter, freshUsage, fromProviderToolCall, geminiAdapter, getCostSummary, getPrice, httpTransport, imageInputSchema, isByokKeyed, listAzureDanishVoices, listVoices, makeContracts, makeOpenAICompatibleAdapter, matchLabel, messageSchema, mistralAdapter, mistralStubAdapter, multiSink, noopSink, openaiAdapter, openaiStubAdapter, openrouterAdapter, parseClaudeCliJson, parseJsonLoose, refreshAvailability, requestyAdapter, resetRefreshState, resetRegistry, resolveAzureVoice, resolveTier, resolveVoice, search, sqliteBudgetStore, sqliteSink, streamTransport, stubProviders, subprocessTransport, tierSpecSchema, toProviderTools, toolSchema, translateInputSchema, typesafeAdapter, upmetricsCostClient, upmetricsSink, usdFromMicro, vertexAdapter, visionInputSchema, wouldProviderRouteTo, wouldRouteTo };
2852
+ export { AZURE_DANISH_VOICES, AZURE_DANISH_VOICE_LIST, type AiClient, type AiConfig, type AzureVoiceInfo, BatchJob, BatchRequestItem, BatchResultItem, type BflAdapterConfig, type BflCredits, BudgetConfig, BudgetExceededError, BudgetGuard, BudgetStore, CONFIG_DERIVED_HOSTS, Capability, type ChatInput, ChatResult, ChatStreamEvent, type CheckVoiceOptions, type ClassifyInput, type ClassifyResult, type Contracts, type CostQuery, CostSink, type CostSummary, type CostSummaryQuery, type CostTimeseriesQuery, DEFAULT_BASE_URLS, DEFAULT_SEARCH_ROUTES, DEFAULT_TIER_MAP, type DesignInput, type DesignResult, type DiscordSinkConfig, ELEVENLABS_DANISH_VOICES, type EmbeddingInput, EmbeddingResult, type ExtractInput, type ExtractResult, type FalAdapterConfig, type FixedHostProvider, type HttpResponse, type ImageInput, ImageResult, type JudgeInput, JudgeResult, LOCALLY_PINNED_HOSTS, type MockupInput, type MockupResult, type ModerationInput, ModerationResult, type OcrInput, OcrResult, type OpenAICompatibleConfig, type PodcastInput, PodcastResult, type PriceDriftResult, type PriceDriftRow, type PricingEntry, ProviderAdapter, type RefreshOptions, type RefreshResult, Region, type RerankInput, type RerankResult, type RouteForecast, SDK_TAG, SEARCH_CACHE_TTL_MS, SEARCH_PRICE_USD, type SearchCache, type SearchCredentials, type SearchItem, SearchKeyMissingError, type SearchOptions, type SearchProviderId, type SearchPurpose, type SearchRequest, type SearchResult, type SearchRoute, type SqliteBudgetStoreConfig, type SqliteSinkConfig, StreamHttpError, type SubprocessResponse, Tier, TierSpec, Tool, ToolCall, type TrainStyleInput, TrainStyleResult, type TranscribeInput, TranscribeResult, type TranslateInput, TranslateResult, Transport, type TransportRequest, type TransportResponse, type TtsInput, type UpmetricsCostClientConfig, UpmetricsCostError, type UpmetricsCostRow, type UpmetricsCostSummary, type UpmetricsCostTimeseries, type UpmetricsSink, type UpmetricsSinkConfig, type UpmetricsSinkStats, Usage, VERSION, type VideoInput, type VisionInput, type VoiceInfo, type VoiceProvider, type VoiceResolveResult, type VoiceStatus, VoiceUnavailableError, ZDR_PROVIDERS, aiConfigSchema, anthropicAdapter, anthropicApiAdapter, anthropicSubprocessAdapter, azureAdapter, bflAdapter, bflCredits, byokAdapter, chatInputSchema, checkPriceDrift, checkVoice, computeCost, createAI, deepinfraAdapter, deeplAdapter, deepseekAdapter, defaultBaseUrl, defaultProviders, discordSink, elevenlabsAdapter, embeddingInputSchema, falAdapter, falStubAdapter, freshUsage, fromProviderToolCall, geminiAdapter, getCostSummary, getPrice, httpTransport, imageInputSchema, isByokKeyed, listAzureDanishVoices, listVoices, makeContracts, makeOpenAICompatibleAdapter, matchLabel, memorySearchCache, messageSchema, mistralAdapter, mistralStubAdapter, multiSink, noopSink, openaiAdapter, openaiStubAdapter, openrouterAdapter, parseClaudeCliJson, parseJsonLoose, refreshAvailability, requestyAdapter, resetRefreshState, resetRegistry, resolveAzureVoice, resolveTier, resolveVoice, routeSearch, search, sqliteBudgetStore, sqliteSink, streamTransport, stubProviders, subprocessTransport, tierSpecSchema, toProviderTools, toolSchema, translateInputSchema, typesafeAdapter, upmetricsCostClient, upmetricsSink, usdFromMicro, vertexAdapter, visionInputSchema, wouldProviderRouteTo, wouldRouteTo };