@effect/ai-amazon-bedrock 0.1.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.
Files changed (59) hide show
  1. package/AmazonBedrockClient/package.json +6 -0
  2. package/AmazonBedrockConfig/package.json +6 -0
  3. package/AmazonBedrockLanguageModel/package.json +6 -0
  4. package/AmazonBedrockSchema/package.json +6 -0
  5. package/EventStreamEncoding/package.json +6 -0
  6. package/LICENSE +21 -0
  7. package/README.md +5 -0
  8. package/dist/cjs/AmazonBedrockClient.js +255 -0
  9. package/dist/cjs/AmazonBedrockClient.js.map +1 -0
  10. package/dist/cjs/AmazonBedrockConfig.js +30 -0
  11. package/dist/cjs/AmazonBedrockConfig.js.map +1 -0
  12. package/dist/cjs/AmazonBedrockLanguageModel.js +507 -0
  13. package/dist/cjs/AmazonBedrockLanguageModel.js.map +1 -0
  14. package/dist/cjs/AmazonBedrockSchema.js +745 -0
  15. package/dist/cjs/AmazonBedrockSchema.js.map +1 -0
  16. package/dist/cjs/EventStreamEncoding.js +85 -0
  17. package/dist/cjs/EventStreamEncoding.js.map +1 -0
  18. package/dist/cjs/index.js +18 -0
  19. package/dist/cjs/index.js.map +1 -0
  20. package/dist/cjs/internal/utilities.js +25 -0
  21. package/dist/cjs/internal/utilities.js.map +1 -0
  22. package/dist/dts/AmazonBedrockClient.d.ts +95 -0
  23. package/dist/dts/AmazonBedrockClient.d.ts.map +1 -0
  24. package/dist/dts/AmazonBedrockConfig.d.ts +47 -0
  25. package/dist/dts/AmazonBedrockConfig.d.ts.map +1 -0
  26. package/dist/dts/AmazonBedrockLanguageModel.d.ts +95 -0
  27. package/dist/dts/AmazonBedrockLanguageModel.d.ts.map +1 -0
  28. package/dist/dts/AmazonBedrockSchema.d.ts +1434 -0
  29. package/dist/dts/AmazonBedrockSchema.d.ts.map +1 -0
  30. package/dist/dts/EventStreamEncoding.d.ts +16 -0
  31. package/dist/dts/EventStreamEncoding.d.ts.map +1 -0
  32. package/dist/dts/index.d.ts +21 -0
  33. package/dist/dts/index.d.ts.map +1 -0
  34. package/dist/dts/internal/utilities.d.ts +2 -0
  35. package/dist/dts/internal/utilities.d.ts.map +1 -0
  36. package/dist/esm/AmazonBedrockClient.js +242 -0
  37. package/dist/esm/AmazonBedrockClient.js.map +1 -0
  38. package/dist/esm/AmazonBedrockConfig.js +22 -0
  39. package/dist/esm/AmazonBedrockConfig.js.map +1 -0
  40. package/dist/esm/AmazonBedrockLanguageModel.js +495 -0
  41. package/dist/esm/AmazonBedrockLanguageModel.js.map +1 -0
  42. package/dist/esm/AmazonBedrockSchema.js +675 -0
  43. package/dist/esm/AmazonBedrockSchema.js.map +1 -0
  44. package/dist/esm/EventStreamEncoding.js +76 -0
  45. package/dist/esm/EventStreamEncoding.js.map +1 -0
  46. package/dist/esm/index.js +21 -0
  47. package/dist/esm/index.js.map +1 -0
  48. package/dist/esm/internal/utilities.js +17 -0
  49. package/dist/esm/internal/utilities.js.map +1 -0
  50. package/dist/esm/package.json +4 -0
  51. package/index/package.json +6 -0
  52. package/package.json +91 -0
  53. package/src/AmazonBedrockClient.ts +409 -0
  54. package/src/AmazonBedrockConfig.ts +78 -0
  55. package/src/AmazonBedrockLanguageModel.ts +623 -0
  56. package/src/AmazonBedrockSchema.ts +1038 -0
  57. package/src/EventStreamEncoding.ts +111 -0
  58. package/src/index.ts +24 -0
  59. package/src/internal/utilities.ts +21 -0
@@ -0,0 +1,1434 @@
1
+ /**
2
+ * @since 1.0.0
3
+ */
4
+ import * as Schema from "effect/Schema";
5
+ declare const BedrockFoundationModelId_base: Schema.Literal<["amazon.titan-tg1-large", "amazon.titan-image-generator-v1:0", "amazon.titan-image-generator-v1", "amazon.titan-image-generator-v2:0", "amazon.nova-premier-v1:0:8k", "amazon.nova-premier-v1:0:20k", "amazon.nova-premier-v1:0:1000k", "amazon.nova-premier-v1:0:mm", "amazon.nova-premier-v1:0", "amazon.titan-text-premier-v1:0", "amazon.nova-pro-v1:0:24k", "amazon.nova-pro-v1:0:300k", "amazon.nova-pro-v1:0", "amazon.nova-lite-v1:0:24k", "amazon.nova-lite-v1:0:300k", "amazon.nova-lite-v1:0", "amazon.nova-canvas-v1:0", "amazon.nova-reel-v1:0", "amazon.nova-reel-v1:1", "amazon.nova-micro-v1:0:24k", "amazon.nova-micro-v1:0:128k", "amazon.nova-micro-v1:0", "amazon.nova-sonic-v1:0", "amazon.titan-embed-g1-text-02", "amazon.titan-text-lite-v1:0:4k", "amazon.titan-text-lite-v1", "amazon.titan-text-express-v1:0:8k", "amazon.titan-text-express-v1", "amazon.titan-embed-text-v1:2:8k", "amazon.titan-embed-text-v1", "amazon.titan-embed-text-v2:0:8k", "amazon.titan-embed-text-v2:0", "amazon.titan-embed-image-v1:0", "amazon.titan-embed-image-v1", "stability.stable-diffusion-xl-v1:0", "stability.stable-diffusion-xl-v1", "ai21.jamba-instruct-v1:0", "ai21.jamba-1-5-large-v1:0", "ai21.jamba-1-5-mini-v1:0", "anthropic.claude-instant-v1:2:100k", "anthropic.claude-instant-v1", "anthropic.claude-v2:0:18k", "anthropic.claude-v2:0:100k", "anthropic.claude-v2:1:18k", "anthropic.claude-v2:1:200k", "anthropic.claude-v2:1", "anthropic.claude-v2", "anthropic.claude-3-sonnet-20240229-v1:0:28k", "anthropic.claude-3-sonnet-20240229-v1:0:200k", "anthropic.claude-3-sonnet-20240229-v1:0", "anthropic.claude-3-haiku-20240307-v1:0:48k", "anthropic.claude-3-haiku-20240307-v1:0:200k", "anthropic.claude-3-haiku-20240307-v1:0", "anthropic.claude-3-opus-20240229-v1:0:12k", "anthropic.claude-3-opus-20240229-v1:0:28k", "anthropic.claude-3-opus-20240229-v1:0:200k", "anthropic.claude-3-opus-20240229-v1:0", "anthropic.claude-3-5-sonnet-20240620-v1:0", "anthropic.claude-3-5-sonnet-20241022-v2:0", "anthropic.claude-3-7-sonnet-20250219-v1:0", "anthropic.claude-3-5-haiku-20241022-v1:0", "anthropic.claude-opus-4-20250514-v1:0", "anthropic.claude-sonnet-4-20250514-v1:0", "cohere.command-text-v14:7:4k", "cohere.command-text-v14", "cohere.command-r-v1:0", "cohere.command-r-plus-v1:0", "cohere.command-light-text-v14:7:4k", "cohere.command-light-text-v14", "cohere.embed-english-v3:0:512", "cohere.embed-english-v3", "cohere.embed-multilingual-v3:0:512", "cohere.embed-multilingual-v3", "deepseek.r1-v1:0", "meta.llama3-8b-instruct-v1:0", "meta.llama3-70b-instruct-v1:0", "meta.llama3-1-8b-instruct-v1:0", "meta.llama3-1-70b-instruct-v1:0", "meta.llama3-2-11b-instruct-v1:0", "meta.llama3-2-90b-instruct-v1:0", "meta.llama3-2-1b-instruct-v1:0", "meta.llama3-2-3b-instruct-v1:0", "meta.llama3-3-70b-instruct-v1:0", "meta.llama4-scout-17b-instruct-v1:0", "meta.llama4-maverick-17b-instruct-v1:0", "mistral.mistral-7b-instruct-v0:2", "mistral.mixtral-8x7b-instruct-v0:1", "mistral.mistral-large-2402-v1:0", "mistral.mistral-small-2402-v1:0", "mistral.pixtral-large-2502-v1:0"]>;
6
+ /**
7
+ * The foundation models supported by Amazon Bedrock.
8
+ *
9
+ * An up-to-date list can be generated with the following command:
10
+ *
11
+ * ```sh
12
+ * aws bedrock list-foundation-models --output json | jq '[.modelSummaries[].modelId]'
13
+ * ```
14
+ *
15
+ * @since 1.0.0
16
+ * @category Schemas
17
+ */
18
+ export declare class BedrockFoundationModelId extends BedrockFoundationModelId_base {
19
+ }
20
+ declare const CachePointBlock_base: Schema.Class<CachePointBlock, {
21
+ type: Schema.Literal<["default"]>;
22
+ }, Schema.Struct.Encoded<{
23
+ type: Schema.Literal<["default"]>;
24
+ }>, never, {
25
+ readonly type: "default";
26
+ }, {}, {}>;
27
+ /**
28
+ * @since 1.0.0
29
+ * @category Schemas
30
+ */
31
+ export declare class CachePointBlock extends CachePointBlock_base {
32
+ }
33
+ /**
34
+ * @since 1.0.0
35
+ * @category Schemas
36
+ */
37
+ export declare const DocumentFormat: Schema.Literal<["csv", "doc", "docx", "html", "md", "pdf", "txt", "xls", "xlsx"]>;
38
+ /**
39
+ * @since 1.0.0
40
+ * @category Schemas
41
+ */
42
+ export type DocumentFormat = typeof DocumentFormat.Type;
43
+ declare const DocumentBlock_base: Schema.Class<DocumentBlock, {
44
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
45
+ format: Schema.Literal<["csv", "doc", "docx", "html", "md", "pdf", "txt", "xls", "xlsx"]>;
46
+ source: Schema.Struct<{
47
+ bytes: typeof Schema.NonEmptyString;
48
+ }>;
49
+ }, Schema.Struct.Encoded<{
50
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
51
+ format: Schema.Literal<["csv", "doc", "docx", "html", "md", "pdf", "txt", "xls", "xlsx"]>;
52
+ source: Schema.Struct<{
53
+ bytes: typeof Schema.NonEmptyString;
54
+ }>;
55
+ }>, never, {
56
+ readonly format: "csv" | "doc" | "docx" | "html" | "md" | "pdf" | "txt" | "xls" | "xlsx";
57
+ } & {
58
+ readonly name: string;
59
+ } & {
60
+ readonly source: {
61
+ readonly bytes: string;
62
+ };
63
+ }, {}, {}>;
64
+ /**
65
+ * @since 1.0.0
66
+ * @category Schemas
67
+ */
68
+ export declare class DocumentBlock extends DocumentBlock_base {
69
+ }
70
+ declare const GuardrailConverseImageBlock_base: Schema.Class<GuardrailConverseImageBlock, {
71
+ format: Schema.Literal<["png", "jpg"]>;
72
+ source: Schema.Struct<{
73
+ bytes: typeof Schema.NonEmptyString;
74
+ }>;
75
+ }, Schema.Struct.Encoded<{
76
+ format: Schema.Literal<["png", "jpg"]>;
77
+ source: Schema.Struct<{
78
+ bytes: typeof Schema.NonEmptyString;
79
+ }>;
80
+ }>, never, {
81
+ readonly format: "png" | "jpg";
82
+ } & {
83
+ readonly source: {
84
+ readonly bytes: string;
85
+ };
86
+ }, {}, {}>;
87
+ /**
88
+ * @since 1.0.0
89
+ * @category Schemas
90
+ */
91
+ export declare class GuardrailConverseImageBlock extends GuardrailConverseImageBlock_base {
92
+ }
93
+ declare const GuardrailConverseTextBlock_base: Schema.Class<GuardrailConverseTextBlock, {
94
+ text: typeof Schema.String;
95
+ qualifiers: Schema.optional<Schema.Array$<Schema.Literal<["guard_content", "grounding_source", "query"]>>>;
96
+ }, Schema.Struct.Encoded<{
97
+ text: typeof Schema.String;
98
+ qualifiers: Schema.optional<Schema.Array$<Schema.Literal<["guard_content", "grounding_source", "query"]>>>;
99
+ }>, never, {
100
+ readonly text: string;
101
+ } & {
102
+ readonly qualifiers?: readonly ("guard_content" | "grounding_source" | "query")[] | undefined;
103
+ }, {}, {}>;
104
+ /**
105
+ * @since 1.0.0
106
+ * @category Schemas
107
+ */
108
+ export declare class GuardrailConverseTextBlock extends GuardrailConverseTextBlock_base {
109
+ }
110
+ declare const GuardrailConverseContentBlock_base: Schema.Union<[typeof GuardrailConverseImageBlock, typeof GuardrailConverseTextBlock]>;
111
+ /**
112
+ * @since 1.0.0
113
+ * @category Schemas
114
+ */
115
+ export declare class GuardrailConverseContentBlock extends GuardrailConverseContentBlock_base {
116
+ }
117
+ /**
118
+ * @since 1.0.0
119
+ * @category Schemas
120
+ */
121
+ export declare const ImageFormat: Schema.Literal<["gif", "jpeg", "png", "webp"]>;
122
+ /**
123
+ * @since 1.0.0
124
+ * @category Schemas
125
+ */
126
+ export type ImageFormat = typeof ImageFormat.Type;
127
+ declare const ImageBlock_base: Schema.Class<ImageBlock, {
128
+ format: Schema.Literal<["gif", "jpeg", "png", "webp"]>;
129
+ source: Schema.Struct<{
130
+ bytes: typeof Schema.NonEmptyString;
131
+ }>;
132
+ }, Schema.Struct.Encoded<{
133
+ format: Schema.Literal<["gif", "jpeg", "png", "webp"]>;
134
+ source: Schema.Struct<{
135
+ bytes: typeof Schema.NonEmptyString;
136
+ }>;
137
+ }>, never, {
138
+ readonly format: "png" | "gif" | "jpeg" | "webp";
139
+ } & {
140
+ readonly source: {
141
+ readonly bytes: string;
142
+ };
143
+ }, {}, {}>;
144
+ /**
145
+ * @since 1.0.0
146
+ * @category Schemas
147
+ */
148
+ export declare class ImageBlock extends ImageBlock_base {
149
+ }
150
+ declare const JsonBlock_base: Schema.Class<JsonBlock, {
151
+ json: typeof Schema.Unknown;
152
+ }, Schema.Struct.Encoded<{
153
+ json: typeof Schema.Unknown;
154
+ }>, never, {
155
+ readonly json: unknown;
156
+ }, {}, {}>;
157
+ /**
158
+ * @since 1.0.0
159
+ * @category Schemas
160
+ */
161
+ export declare class JsonBlock extends JsonBlock_base {
162
+ }
163
+ declare const ReasoningContentBlock_base: Schema.Union<[Schema.Struct<{
164
+ reasoningText: Schema.Struct<{
165
+ text: typeof Schema.String;
166
+ signature: Schema.optional<typeof Schema.String>;
167
+ }>;
168
+ }>, Schema.Struct<{
169
+ redactedContent: Schema.Schema<Uint8Array<ArrayBufferLike>, string, never>;
170
+ }>]>;
171
+ /**
172
+ * @since 1.0.0
173
+ * @category Schemas
174
+ */
175
+ export declare class ReasoningContentBlock extends ReasoningContentBlock_base {
176
+ }
177
+ declare const VideoBlock_base: Schema.Class<VideoBlock, {
178
+ format: Schema.Literal<["flv", "mkv", "mov", "mp4", "mpg", "mpeg", "three_gp", "webm"]>;
179
+ source: Schema.Union<[Schema.Struct<{
180
+ bytes: typeof Schema.NonEmptyString;
181
+ }>, Schema.Struct<{
182
+ s3Location: Schema.Struct<{
183
+ uri: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
184
+ bucketOwner: Schema.optional<Schema.filter<typeof Schema.String>>;
185
+ }>;
186
+ }>]>;
187
+ }, Schema.Struct.Encoded<{
188
+ format: Schema.Literal<["flv", "mkv", "mov", "mp4", "mpg", "mpeg", "three_gp", "webm"]>;
189
+ source: Schema.Union<[Schema.Struct<{
190
+ bytes: typeof Schema.NonEmptyString;
191
+ }>, Schema.Struct<{
192
+ s3Location: Schema.Struct<{
193
+ uri: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
194
+ bucketOwner: Schema.optional<Schema.filter<typeof Schema.String>>;
195
+ }>;
196
+ }>]>;
197
+ }>, never, {
198
+ readonly format: "flv" | "mkv" | "mov" | "mp4" | "mpg" | "mpeg" | "three_gp" | "webm";
199
+ } & {
200
+ readonly source: {
201
+ readonly bytes: string;
202
+ } | {
203
+ readonly s3Location: {
204
+ readonly uri: string;
205
+ readonly bucketOwner?: string | undefined;
206
+ };
207
+ };
208
+ }, {}, {}>;
209
+ /**
210
+ * @since 1.0.0
211
+ * @category Schemas
212
+ */
213
+ export declare class VideoBlock extends VideoBlock_base {
214
+ }
215
+ declare const ToolResultBlock_base: Schema.Class<ToolResultBlock, {
216
+ content: Schema.Array$<Schema.Union<[Schema.Struct<{
217
+ document: typeof DocumentBlock;
218
+ }>, Schema.Struct<{
219
+ image: typeof ImageBlock;
220
+ }>, Schema.Struct<{
221
+ text: typeof Schema.String;
222
+ }>, Schema.Struct<{
223
+ json: typeof JsonBlock;
224
+ }>, Schema.Struct<{
225
+ video: typeof VideoBlock;
226
+ }>]>>;
227
+ toolUseId: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
228
+ status: Schema.optional<Schema.Literal<["success", "error"]>>;
229
+ }, Schema.Struct.Encoded<{
230
+ content: Schema.Array$<Schema.Union<[Schema.Struct<{
231
+ document: typeof DocumentBlock;
232
+ }>, Schema.Struct<{
233
+ image: typeof ImageBlock;
234
+ }>, Schema.Struct<{
235
+ text: typeof Schema.String;
236
+ }>, Schema.Struct<{
237
+ json: typeof JsonBlock;
238
+ }>, Schema.Struct<{
239
+ video: typeof VideoBlock;
240
+ }>]>>;
241
+ toolUseId: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
242
+ status: Schema.optional<Schema.Literal<["success", "error"]>>;
243
+ }>, never, {
244
+ readonly content: readonly ({
245
+ readonly document: DocumentBlock;
246
+ } | {
247
+ readonly image: ImageBlock;
248
+ } | {
249
+ readonly text: string;
250
+ } | {
251
+ readonly json: JsonBlock;
252
+ } | {
253
+ readonly video: VideoBlock;
254
+ })[];
255
+ } & {
256
+ readonly toolUseId: string;
257
+ } & {
258
+ readonly status?: "success" | "error" | undefined;
259
+ }, {}, {}>;
260
+ /**
261
+ * @since 1.0.0
262
+ * @category Schemas
263
+ */
264
+ export declare class ToolResultBlock extends ToolResultBlock_base {
265
+ }
266
+ declare const ToolUseBlock_base: Schema.Class<ToolUseBlock, {
267
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
268
+ input: typeof Schema.Unknown;
269
+ toolUseId: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
270
+ }, Schema.Struct.Encoded<{
271
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
272
+ input: typeof Schema.Unknown;
273
+ toolUseId: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
274
+ }>, never, {
275
+ readonly name: string;
276
+ } & {
277
+ readonly toolUseId: string;
278
+ } & {
279
+ readonly input: unknown;
280
+ }, {}, {}>;
281
+ /**
282
+ * @since 1.0.0
283
+ * @category Schemas
284
+ */
285
+ export declare class ToolUseBlock extends ToolUseBlock_base {
286
+ }
287
+ declare const ContentBlock_base: Schema.Union<[Schema.Struct<{
288
+ cachePoint: typeof CachePointBlock;
289
+ }>, Schema.Struct<{
290
+ document: typeof DocumentBlock;
291
+ }>, Schema.Struct<{
292
+ guardContent: typeof GuardrailConverseContentBlock;
293
+ }>, Schema.Struct<{
294
+ image: typeof ImageBlock;
295
+ }>, Schema.Struct<{
296
+ reasoningContent: typeof ReasoningContentBlock;
297
+ }>, Schema.Struct<{
298
+ text: typeof Schema.String;
299
+ }>, Schema.Struct<{
300
+ toolResult: typeof ToolResultBlock;
301
+ }>, Schema.Struct<{
302
+ toolUse: typeof ToolUseBlock;
303
+ }>, Schema.Struct<{
304
+ video: typeof VideoBlock;
305
+ }>]>;
306
+ /**
307
+ * @since 1.0.0
308
+ * @category Schemas
309
+ */
310
+ export declare class ContentBlock extends ContentBlock_base {
311
+ }
312
+ declare const Message_base: Schema.Class<Message, {
313
+ role: Schema.Literal<["user", "assistant"]>;
314
+ content: Schema.Array$<typeof ContentBlock>;
315
+ }, Schema.Struct.Encoded<{
316
+ role: Schema.Literal<["user", "assistant"]>;
317
+ content: Schema.Array$<typeof ContentBlock>;
318
+ }>, never, {
319
+ readonly content: readonly ({
320
+ readonly cachePoint: CachePointBlock;
321
+ } | {
322
+ readonly document: DocumentBlock;
323
+ } | {
324
+ readonly guardContent: GuardrailConverseImageBlock | GuardrailConverseTextBlock;
325
+ } | {
326
+ readonly image: ImageBlock;
327
+ } | {
328
+ readonly reasoningContent: {
329
+ readonly reasoningText: {
330
+ readonly text: string;
331
+ readonly signature?: string | undefined;
332
+ };
333
+ } | {
334
+ readonly redactedContent: Uint8Array<ArrayBufferLike>;
335
+ };
336
+ } | {
337
+ readonly text: string;
338
+ } | {
339
+ readonly toolResult: ToolResultBlock;
340
+ } | {
341
+ readonly toolUse: ToolUseBlock;
342
+ } | {
343
+ readonly video: VideoBlock;
344
+ })[];
345
+ } & {
346
+ readonly role: "user" | "assistant";
347
+ }, {}, {}>;
348
+ /**
349
+ * @since 1.0.0
350
+ * @category Schemas
351
+ */
352
+ export declare class Message extends Message_base {
353
+ }
354
+ declare const ConverseOutput_base: Schema.Class<ConverseOutput, {
355
+ message: typeof Message;
356
+ }, Schema.Struct.Encoded<{
357
+ message: typeof Message;
358
+ }>, never, {
359
+ readonly message: Message;
360
+ }, {}, {}>;
361
+ /**
362
+ * @since 1.0.0
363
+ * @category Schemas
364
+ */
365
+ export declare class ConverseOutput extends ConverseOutput_base {
366
+ }
367
+ declare const ConverseMetrics_base: Schema.Class<ConverseMetrics, {
368
+ latencyMs: typeof Schema.DurationFromMillis;
369
+ }, Schema.Struct.Encoded<{
370
+ latencyMs: typeof Schema.DurationFromMillis;
371
+ }>, never, {
372
+ readonly latencyMs: import("effect/Duration").Duration;
373
+ }, {}, {}>;
374
+ /**
375
+ * @since 1.0.0
376
+ * @category Schemas
377
+ */
378
+ export declare class ConverseMetrics extends ConverseMetrics_base {
379
+ }
380
+ declare const GuardrailContentFilter_base: Schema.Class<GuardrailContentFilter, {
381
+ type: Schema.Literal<["HATE", "INSULTS", "MISCONDUCT", "PROMPT_ATTACK", "SEXUAL", "VIOLENCE"]>;
382
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
383
+ confidence: Schema.Literal<["NONE", "LOW", "MEDIUM", "HIGH"]>;
384
+ detected: Schema.optional<typeof Schema.Boolean>;
385
+ filterStrength: Schema.optional<Schema.Literal<["NONE", "LOW", "MEDIUM", "HIGH"]>>;
386
+ }, Schema.Struct.Encoded<{
387
+ type: Schema.Literal<["HATE", "INSULTS", "MISCONDUCT", "PROMPT_ATTACK", "SEXUAL", "VIOLENCE"]>;
388
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
389
+ confidence: Schema.Literal<["NONE", "LOW", "MEDIUM", "HIGH"]>;
390
+ detected: Schema.optional<typeof Schema.Boolean>;
391
+ filterStrength: Schema.optional<Schema.Literal<["NONE", "LOW", "MEDIUM", "HIGH"]>>;
392
+ }>, never, {
393
+ readonly type: "HATE" | "INSULTS" | "MISCONDUCT" | "PROMPT_ATTACK" | "SEXUAL" | "VIOLENCE";
394
+ } & {
395
+ readonly action: "BLOCKED" | "NONE";
396
+ } & {
397
+ readonly confidence: "NONE" | "LOW" | "MEDIUM" | "HIGH";
398
+ } & {
399
+ readonly detected?: boolean | undefined;
400
+ } & {
401
+ readonly filterStrength?: "NONE" | "LOW" | "MEDIUM" | "HIGH" | undefined;
402
+ }, {}, {}>;
403
+ /**
404
+ * @since 1.0.0
405
+ * @category Schemas
406
+ */
407
+ export declare class GuardrailContentFilter extends GuardrailContentFilter_base {
408
+ }
409
+ declare const GuardrailContentPolicyAssessment_base: Schema.Class<GuardrailContentPolicyAssessment, {
410
+ filters: Schema.Array$<typeof GuardrailContentFilter>;
411
+ }, Schema.Struct.Encoded<{
412
+ filters: Schema.Array$<typeof GuardrailContentFilter>;
413
+ }>, never, {
414
+ readonly filters: readonly GuardrailContentFilter[];
415
+ }, {}, {}>;
416
+ /**
417
+ * @since 1.0.0
418
+ * @category Schemas
419
+ */
420
+ export declare class GuardrailContentPolicyAssessment extends GuardrailContentPolicyAssessment_base {
421
+ }
422
+ declare const GuardrailContextualGroundingFilter_base: Schema.Class<GuardrailContextualGroundingFilter, {
423
+ type: Schema.Literal<["GROUNDING", "RELEVANCE"]>;
424
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
425
+ score: Schema.filter<typeof Schema.Number>;
426
+ threshold: Schema.filter<typeof Schema.Number>;
427
+ detected: Schema.optional<typeof Schema.Boolean>;
428
+ }, Schema.Struct.Encoded<{
429
+ type: Schema.Literal<["GROUNDING", "RELEVANCE"]>;
430
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
431
+ score: Schema.filter<typeof Schema.Number>;
432
+ threshold: Schema.filter<typeof Schema.Number>;
433
+ detected: Schema.optional<typeof Schema.Boolean>;
434
+ }>, never, {
435
+ readonly type: "GROUNDING" | "RELEVANCE";
436
+ } & {
437
+ readonly action: "BLOCKED" | "NONE";
438
+ } & {
439
+ readonly detected?: boolean | undefined;
440
+ } & {
441
+ readonly score: number;
442
+ } & {
443
+ readonly threshold: number;
444
+ }, {}, {}>;
445
+ /**
446
+ * @since 1.0.0
447
+ * @category Schemas
448
+ */
449
+ export declare class GuardrailContextualGroundingFilter extends GuardrailContextualGroundingFilter_base {
450
+ }
451
+ declare const GuardrailContextualGroundingPolicyAssessment_base: Schema.Class<GuardrailContextualGroundingPolicyAssessment, {
452
+ filters: Schema.optional<Schema.Array$<typeof GuardrailContextualGroundingFilter>>;
453
+ }, Schema.Struct.Encoded<{
454
+ filters: Schema.optional<Schema.Array$<typeof GuardrailContextualGroundingFilter>>;
455
+ }>, never, {
456
+ readonly filters?: readonly GuardrailContextualGroundingFilter[] | undefined;
457
+ }, {}, {}>;
458
+ /**
459
+ * @since 1.0.0
460
+ * @category Schemas
461
+ */
462
+ export declare class GuardrailContextualGroundingPolicyAssessment extends GuardrailContextualGroundingPolicyAssessment_base {
463
+ }
464
+ declare const GuardrailImageCoverage_base: Schema.Class<GuardrailImageCoverage, {
465
+ guarded: Schema.optional<typeof Schema.Int>;
466
+ total: Schema.optional<typeof Schema.Int>;
467
+ }, Schema.Struct.Encoded<{
468
+ guarded: Schema.optional<typeof Schema.Int>;
469
+ total: Schema.optional<typeof Schema.Int>;
470
+ }>, never, {
471
+ readonly guarded?: number | undefined;
472
+ } & {
473
+ readonly total?: number | undefined;
474
+ }, {}, {}>;
475
+ /**
476
+ * @since 1.0.0
477
+ * @category Schemas
478
+ */
479
+ export declare class GuardrailImageCoverage extends GuardrailImageCoverage_base {
480
+ }
481
+ declare const GuardrailTextCharactersCoverage_base: Schema.Class<GuardrailTextCharactersCoverage, {
482
+ guarded: Schema.optional<typeof Schema.Int>;
483
+ total: Schema.optional<typeof Schema.Int>;
484
+ }, Schema.Struct.Encoded<{
485
+ guarded: Schema.optional<typeof Schema.Int>;
486
+ total: Schema.optional<typeof Schema.Int>;
487
+ }>, never, {
488
+ readonly guarded?: number | undefined;
489
+ } & {
490
+ readonly total?: number | undefined;
491
+ }, {}, {}>;
492
+ /**
493
+ * @since 1.0.0
494
+ * @category Schemas
495
+ */
496
+ export declare class GuardrailTextCharactersCoverage extends GuardrailTextCharactersCoverage_base {
497
+ }
498
+ declare const GuardrailCoverage_base: Schema.Class<GuardrailCoverage, {
499
+ images: Schema.optional<typeof GuardrailImageCoverage>;
500
+ textCharacters: Schema.optional<typeof GuardrailTextCharactersCoverage>;
501
+ }, Schema.Struct.Encoded<{
502
+ images: Schema.optional<typeof GuardrailImageCoverage>;
503
+ textCharacters: Schema.optional<typeof GuardrailTextCharactersCoverage>;
504
+ }>, never, {
505
+ readonly images?: GuardrailImageCoverage | undefined;
506
+ } & {
507
+ readonly textCharacters?: GuardrailTextCharactersCoverage | undefined;
508
+ }, {}, {}>;
509
+ /**
510
+ * @since 1.0.0
511
+ * @category Schemas
512
+ */
513
+ export declare class GuardrailCoverage extends GuardrailCoverage_base {
514
+ }
515
+ declare const GuardrailUsage_base: Schema.Class<GuardrailUsage, {
516
+ contentPolicyUnits: typeof Schema.Int;
517
+ contextualGroundingPolicyUnits: typeof Schema.Int;
518
+ sensitiveInformationPolicyFreeUnits: typeof Schema.Int;
519
+ sensitiveInformationPolicyUnits: typeof Schema.Int;
520
+ topicPolicyUnits: typeof Schema.Int;
521
+ wordPolicyUnits: typeof Schema.Int;
522
+ contentPolicyImageUnits: Schema.optional<typeof Schema.Int>;
523
+ }, Schema.Struct.Encoded<{
524
+ contentPolicyUnits: typeof Schema.Int;
525
+ contextualGroundingPolicyUnits: typeof Schema.Int;
526
+ sensitiveInformationPolicyFreeUnits: typeof Schema.Int;
527
+ sensitiveInformationPolicyUnits: typeof Schema.Int;
528
+ topicPolicyUnits: typeof Schema.Int;
529
+ wordPolicyUnits: typeof Schema.Int;
530
+ contentPolicyImageUnits: Schema.optional<typeof Schema.Int>;
531
+ }>, never, {
532
+ readonly contentPolicyUnits: number;
533
+ } & {
534
+ readonly contextualGroundingPolicyUnits: number;
535
+ } & {
536
+ readonly sensitiveInformationPolicyFreeUnits: number;
537
+ } & {
538
+ readonly sensitiveInformationPolicyUnits: number;
539
+ } & {
540
+ readonly topicPolicyUnits: number;
541
+ } & {
542
+ readonly wordPolicyUnits: number;
543
+ } & {
544
+ readonly contentPolicyImageUnits?: number | undefined;
545
+ }, {}, {}>;
546
+ /**
547
+ * @since 1.0.0
548
+ * @category Schemas
549
+ */
550
+ export declare class GuardrailUsage extends GuardrailUsage_base {
551
+ }
552
+ declare const GuardrailInvocationMetrics_base: Schema.Class<GuardrailInvocationMetrics, {
553
+ guardrailCoverage: Schema.optional<typeof GuardrailCoverage>;
554
+ guardrailProcessingLatency: Schema.optional<typeof Schema.Number>;
555
+ usage: Schema.optional<typeof GuardrailUsage>;
556
+ }, Schema.Struct.Encoded<{
557
+ guardrailCoverage: Schema.optional<typeof GuardrailCoverage>;
558
+ guardrailProcessingLatency: Schema.optional<typeof Schema.Number>;
559
+ usage: Schema.optional<typeof GuardrailUsage>;
560
+ }>, never, {
561
+ readonly guardrailCoverage?: GuardrailCoverage | undefined;
562
+ } & {
563
+ readonly guardrailProcessingLatency?: number | undefined;
564
+ } & {
565
+ readonly usage?: GuardrailUsage | undefined;
566
+ }, {}, {}>;
567
+ /**
568
+ * @since 1.0.0
569
+ * @category Schemas
570
+ */
571
+ export declare class GuardrailInvocationMetrics extends GuardrailInvocationMetrics_base {
572
+ }
573
+ declare const GuardrailPiiEntityFilter_base: Schema.Class<GuardrailPiiEntityFilter, {
574
+ type: Schema.Literal<["ADDRESS", "AGE", "AWS_ACCESS_KEY", "AWS_SECRET_KEY", "CA_HEALTH_NUMBER", "CA_SOCIAL_INSURANCE_NUMBER", "CREDIT_DEBIT_CARD_CVV", "CREDIT_DEBIT_CARD_EXPIRY", "CREDIT_DEBIT_CARD_NUMBER", "DRIVER_ID", "EMAIL", "INTERNATIONAL_BANK_ACCOUNT_NUMBER", "IP_ADDRESS", "LICENSE_PLATE", "MAC_ADDRESS", "NAME", "PASSWORD", "PHONE", "PIN", "SWIFT_CODE", "UK_NATIONAL_HEALTH_SERVICE_NUMBER", "UK_NATIONAL_INSURANCE_NUMBER", "UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER", "URL", "USERNAME", "US_BANK_ACCOUNT_NUMBER", "US_BANK_ROUTING_NUMBER", "US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER", "US_PASSPORT_NUMBER", "US_SOCIAL_SECURITY_NUMBER", "VEHICLE_IDENTIFICATION_NUMBER"]>;
575
+ action: Schema.Literal<["ANONYMIZED", "BLOCKED", "NONE"]>;
576
+ match: typeof Schema.String;
577
+ detected: Schema.optional<typeof Schema.Boolean>;
578
+ }, Schema.Struct.Encoded<{
579
+ type: Schema.Literal<["ADDRESS", "AGE", "AWS_ACCESS_KEY", "AWS_SECRET_KEY", "CA_HEALTH_NUMBER", "CA_SOCIAL_INSURANCE_NUMBER", "CREDIT_DEBIT_CARD_CVV", "CREDIT_DEBIT_CARD_EXPIRY", "CREDIT_DEBIT_CARD_NUMBER", "DRIVER_ID", "EMAIL", "INTERNATIONAL_BANK_ACCOUNT_NUMBER", "IP_ADDRESS", "LICENSE_PLATE", "MAC_ADDRESS", "NAME", "PASSWORD", "PHONE", "PIN", "SWIFT_CODE", "UK_NATIONAL_HEALTH_SERVICE_NUMBER", "UK_NATIONAL_INSURANCE_NUMBER", "UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER", "URL", "USERNAME", "US_BANK_ACCOUNT_NUMBER", "US_BANK_ROUTING_NUMBER", "US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER", "US_PASSPORT_NUMBER", "US_SOCIAL_SECURITY_NUMBER", "VEHICLE_IDENTIFICATION_NUMBER"]>;
580
+ action: Schema.Literal<["ANONYMIZED", "BLOCKED", "NONE"]>;
581
+ match: typeof Schema.String;
582
+ detected: Schema.optional<typeof Schema.Boolean>;
583
+ }>, never, {
584
+ readonly type: "ADDRESS" | "AGE" | "AWS_ACCESS_KEY" | "AWS_SECRET_KEY" | "CA_HEALTH_NUMBER" | "CA_SOCIAL_INSURANCE_NUMBER" | "CREDIT_DEBIT_CARD_CVV" | "CREDIT_DEBIT_CARD_EXPIRY" | "CREDIT_DEBIT_CARD_NUMBER" | "DRIVER_ID" | "EMAIL" | "INTERNATIONAL_BANK_ACCOUNT_NUMBER" | "IP_ADDRESS" | "LICENSE_PLATE" | "MAC_ADDRESS" | "NAME" | "PASSWORD" | "PHONE" | "PIN" | "SWIFT_CODE" | "UK_NATIONAL_HEALTH_SERVICE_NUMBER" | "UK_NATIONAL_INSURANCE_NUMBER" | "UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER" | "URL" | "USERNAME" | "US_BANK_ACCOUNT_NUMBER" | "US_BANK_ROUTING_NUMBER" | "US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER" | "US_PASSPORT_NUMBER" | "US_SOCIAL_SECURITY_NUMBER" | "VEHICLE_IDENTIFICATION_NUMBER";
585
+ } & {
586
+ readonly action: "BLOCKED" | "NONE" | "ANONYMIZED";
587
+ } & {
588
+ readonly detected?: boolean | undefined;
589
+ } & {
590
+ readonly match: string;
591
+ }, {}, {}>;
592
+ /**
593
+ * @since 1.0.0
594
+ * @category Schemas
595
+ */
596
+ export declare class GuardrailPiiEntityFilter extends GuardrailPiiEntityFilter_base {
597
+ }
598
+ declare const GuardrailRegexFilter_base: Schema.Class<GuardrailRegexFilter, {
599
+ action: Schema.Literal<["ANONYMIZED", "BLOCKED", "NONE"]>;
600
+ name: Schema.optional<typeof Schema.String>;
601
+ match: Schema.optional<typeof Schema.String>;
602
+ regex: Schema.optional<typeof Schema.String>;
603
+ detected: Schema.optional<typeof Schema.Boolean>;
604
+ }, Schema.Struct.Encoded<{
605
+ action: Schema.Literal<["ANONYMIZED", "BLOCKED", "NONE"]>;
606
+ name: Schema.optional<typeof Schema.String>;
607
+ match: Schema.optional<typeof Schema.String>;
608
+ regex: Schema.optional<typeof Schema.String>;
609
+ detected: Schema.optional<typeof Schema.Boolean>;
610
+ }>, never, {
611
+ readonly name?: string | undefined;
612
+ } & {
613
+ readonly action: "BLOCKED" | "NONE" | "ANONYMIZED";
614
+ } & {
615
+ readonly detected?: boolean | undefined;
616
+ } & {
617
+ readonly match?: string | undefined;
618
+ } & {
619
+ readonly regex?: string | undefined;
620
+ }, {}, {}>;
621
+ /**
622
+ * @since 1.0.0
623
+ * @category Schemas
624
+ */
625
+ export declare class GuardrailRegexFilter extends GuardrailRegexFilter_base {
626
+ }
627
+ declare const GuardrailSensitiveInformationPolicyAssessment_base: Schema.Class<GuardrailSensitiveInformationPolicyAssessment, {
628
+ piiEntities: Schema.Array$<typeof GuardrailPiiEntityFilter>;
629
+ regexes: Schema.Array$<typeof GuardrailRegexFilter>;
630
+ }, Schema.Struct.Encoded<{
631
+ piiEntities: Schema.Array$<typeof GuardrailPiiEntityFilter>;
632
+ regexes: Schema.Array$<typeof GuardrailRegexFilter>;
633
+ }>, never, {
634
+ readonly piiEntities: readonly GuardrailPiiEntityFilter[];
635
+ } & {
636
+ readonly regexes: readonly GuardrailRegexFilter[];
637
+ }, {}, {}>;
638
+ /**
639
+ * @since 1.0.0
640
+ * @category Schemas
641
+ */
642
+ export declare class GuardrailSensitiveInformationPolicyAssessment extends GuardrailSensitiveInformationPolicyAssessment_base {
643
+ }
644
+ declare const GuardrailTopic_base: Schema.Class<GuardrailTopic, {
645
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
646
+ name: typeof Schema.String;
647
+ type: Schema.Literal<["DENY"]>;
648
+ detected: Schema.optional<typeof Schema.Boolean>;
649
+ }, Schema.Struct.Encoded<{
650
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
651
+ name: typeof Schema.String;
652
+ type: Schema.Literal<["DENY"]>;
653
+ detected: Schema.optional<typeof Schema.Boolean>;
654
+ }>, never, {
655
+ readonly type: "DENY";
656
+ } & {
657
+ readonly name: string;
658
+ } & {
659
+ readonly action: "BLOCKED" | "NONE";
660
+ } & {
661
+ readonly detected?: boolean | undefined;
662
+ }, {}, {}>;
663
+ /**
664
+ * @since 1.0.0
665
+ * @category Schemas
666
+ */
667
+ export declare class GuardrailTopic extends GuardrailTopic_base {
668
+ }
669
+ declare const GuardrailTopicPolicyAssessment_base: Schema.Class<GuardrailTopicPolicyAssessment, {
670
+ topics: Schema.Array$<typeof GuardrailTopic>;
671
+ }, Schema.Struct.Encoded<{
672
+ topics: Schema.Array$<typeof GuardrailTopic>;
673
+ }>, never, {
674
+ readonly topics: readonly GuardrailTopic[];
675
+ }, {}, {}>;
676
+ /**
677
+ * @since 1.0.0
678
+ * @category Schemas
679
+ */
680
+ export declare class GuardrailTopicPolicyAssessment extends GuardrailTopicPolicyAssessment_base {
681
+ }
682
+ declare const GuardrailCustomWord_base: Schema.Class<GuardrailCustomWord, {
683
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
684
+ match: typeof Schema.String;
685
+ detected: Schema.optional<typeof Schema.Boolean>;
686
+ }, Schema.Struct.Encoded<{
687
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
688
+ match: typeof Schema.String;
689
+ detected: Schema.optional<typeof Schema.Boolean>;
690
+ }>, never, {
691
+ readonly action: "BLOCKED" | "NONE";
692
+ } & {
693
+ readonly detected?: boolean | undefined;
694
+ } & {
695
+ readonly match: string;
696
+ }, {}, {}>;
697
+ /**
698
+ * @since 1.0.0
699
+ * @category Schemas
700
+ */
701
+ export declare class GuardrailCustomWord extends GuardrailCustomWord_base {
702
+ }
703
+ declare const GuardrailManagedWord_base: Schema.Class<GuardrailManagedWord, {
704
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
705
+ match: typeof Schema.String;
706
+ type: Schema.Literal<["PROFANITY"]>;
707
+ detected: Schema.optional<typeof Schema.Boolean>;
708
+ }, Schema.Struct.Encoded<{
709
+ action: Schema.Literal<["BLOCKED", "NONE"]>;
710
+ match: typeof Schema.String;
711
+ type: Schema.Literal<["PROFANITY"]>;
712
+ detected: Schema.optional<typeof Schema.Boolean>;
713
+ }>, never, {
714
+ readonly type: "PROFANITY";
715
+ } & {
716
+ readonly action: "BLOCKED" | "NONE";
717
+ } & {
718
+ readonly detected?: boolean | undefined;
719
+ } & {
720
+ readonly match: string;
721
+ }, {}, {}>;
722
+ /**
723
+ * @since 1.0.0
724
+ * @category Schemas
725
+ */
726
+ export declare class GuardrailManagedWord extends GuardrailManagedWord_base {
727
+ }
728
+ declare const GuardrailWordPolicyAssessment_base: Schema.Class<GuardrailWordPolicyAssessment, {
729
+ customWords: typeof GuardrailCustomWord;
730
+ managedWordLists: typeof GuardrailManagedWord;
731
+ }, Schema.Struct.Encoded<{
732
+ customWords: typeof GuardrailCustomWord;
733
+ managedWordLists: typeof GuardrailManagedWord;
734
+ }>, never, {
735
+ readonly customWords: GuardrailCustomWord;
736
+ } & {
737
+ readonly managedWordLists: GuardrailManagedWord;
738
+ }, {}, {}>;
739
+ /**
740
+ * @since 1.0.0
741
+ * @category Schemas
742
+ */
743
+ export declare class GuardrailWordPolicyAssessment extends GuardrailWordPolicyAssessment_base {
744
+ }
745
+ declare const GuardrailAssessment_base: Schema.Class<GuardrailAssessment, {
746
+ contentPolicy: Schema.optional<typeof GuardrailContentPolicyAssessment>;
747
+ contextualGroundingPolicy: Schema.optional<typeof GuardrailContextualGroundingPolicyAssessment>;
748
+ invocationMetrics: Schema.optional<typeof GuardrailInvocationMetrics>;
749
+ sensitiveInformationPolicy: Schema.optional<typeof GuardrailSensitiveInformationPolicyAssessment>;
750
+ topicPolicy: Schema.optional<typeof GuardrailTopicPolicyAssessment>;
751
+ wordPolicy: Schema.optional<typeof GuardrailWordPolicyAssessment>;
752
+ }, Schema.Struct.Encoded<{
753
+ contentPolicy: Schema.optional<typeof GuardrailContentPolicyAssessment>;
754
+ contextualGroundingPolicy: Schema.optional<typeof GuardrailContextualGroundingPolicyAssessment>;
755
+ invocationMetrics: Schema.optional<typeof GuardrailInvocationMetrics>;
756
+ sensitiveInformationPolicy: Schema.optional<typeof GuardrailSensitiveInformationPolicyAssessment>;
757
+ topicPolicy: Schema.optional<typeof GuardrailTopicPolicyAssessment>;
758
+ wordPolicy: Schema.optional<typeof GuardrailWordPolicyAssessment>;
759
+ }>, never, {
760
+ readonly contentPolicy?: GuardrailContentPolicyAssessment | undefined;
761
+ } & {
762
+ readonly contextualGroundingPolicy?: GuardrailContextualGroundingPolicyAssessment | undefined;
763
+ } & {
764
+ readonly invocationMetrics?: GuardrailInvocationMetrics | undefined;
765
+ } & {
766
+ readonly sensitiveInformationPolicy?: GuardrailSensitiveInformationPolicyAssessment | undefined;
767
+ } & {
768
+ readonly topicPolicy?: GuardrailTopicPolicyAssessment | undefined;
769
+ } & {
770
+ readonly wordPolicy?: GuardrailWordPolicyAssessment | undefined;
771
+ }, {}, {}>;
772
+ /**
773
+ * @since 1.0.0
774
+ * @category Schemas
775
+ */
776
+ export declare class GuardrailAssessment extends GuardrailAssessment_base {
777
+ }
778
+ declare const GuardrailTraceAssessment_base: Schema.Class<GuardrailTraceAssessment, {
779
+ actionReason: Schema.optional<typeof Schema.String>;
780
+ inputAssessment: Schema.optional<Schema.Record$<typeof Schema.String, typeof GuardrailAssessment>>;
781
+ modelOutput: Schema.optional<Schema.Array$<typeof Schema.String>>;
782
+ outputAssessments: Schema.optional<Schema.Record$<typeof Schema.String, typeof GuardrailAssessment>>;
783
+ }, Schema.Struct.Encoded<{
784
+ actionReason: Schema.optional<typeof Schema.String>;
785
+ inputAssessment: Schema.optional<Schema.Record$<typeof Schema.String, typeof GuardrailAssessment>>;
786
+ modelOutput: Schema.optional<Schema.Array$<typeof Schema.String>>;
787
+ outputAssessments: Schema.optional<Schema.Record$<typeof Schema.String, typeof GuardrailAssessment>>;
788
+ }>, never, {
789
+ readonly actionReason?: string | undefined;
790
+ } & {
791
+ readonly inputAssessment?: {
792
+ readonly [x: string]: GuardrailAssessment;
793
+ } | undefined;
794
+ } & {
795
+ readonly modelOutput?: readonly string[] | undefined;
796
+ } & {
797
+ readonly outputAssessments?: {
798
+ readonly [x: string]: GuardrailAssessment;
799
+ } | undefined;
800
+ }, {}, {}>;
801
+ /**
802
+ * @since 1.0.0
803
+ * @category Schemas
804
+ */
805
+ export declare class GuardrailTraceAssessment extends GuardrailTraceAssessment_base {
806
+ }
807
+ declare const PromptRouterTrace_base: Schema.Class<PromptRouterTrace, {
808
+ invokedModelId: Schema.optional<Schema.filter<typeof Schema.String>>;
809
+ }, Schema.Struct.Encoded<{
810
+ invokedModelId: Schema.optional<Schema.filter<typeof Schema.String>>;
811
+ }>, never, {
812
+ readonly invokedModelId?: string | undefined;
813
+ }, {}, {}>;
814
+ /**
815
+ * @since 1.0.0
816
+ * @category Schemas
817
+ */
818
+ export declare class PromptRouterTrace extends PromptRouterTrace_base {
819
+ }
820
+ declare const ConverseTrace_base: Schema.Class<ConverseTrace, {
821
+ guardrail: Schema.optional<typeof GuardrailTraceAssessment>;
822
+ promptRouter: Schema.optional<typeof PromptRouterTrace>;
823
+ }, Schema.Struct.Encoded<{
824
+ guardrail: Schema.optional<typeof GuardrailTraceAssessment>;
825
+ promptRouter: Schema.optional<typeof PromptRouterTrace>;
826
+ }>, never, {
827
+ readonly guardrail?: GuardrailTraceAssessment | undefined;
828
+ } & {
829
+ readonly promptRouter?: PromptRouterTrace | undefined;
830
+ }, {}, {}>;
831
+ /**
832
+ * @since 1.0.0
833
+ * @category Schemas
834
+ */
835
+ export declare class ConverseTrace extends ConverseTrace_base {
836
+ }
837
+ /**
838
+ * @since 1.0.0
839
+ * @category Schemas
840
+ */
841
+ export declare const IntZeroOrGreater: Schema.filter<typeof Schema.Int>;
842
+ declare const TokenUsage_base: Schema.Class<TokenUsage, {
843
+ inputTokens: Schema.filter<typeof Schema.Int>;
844
+ outputTokens: Schema.filter<typeof Schema.Int>;
845
+ totalTokens: Schema.filter<typeof Schema.Int>;
846
+ cacheReadInputTokens: Schema.optional<Schema.filter<typeof Schema.Int>>;
847
+ cacheWriteInputTokens: Schema.optional<Schema.filter<typeof Schema.Int>>;
848
+ }, Schema.Struct.Encoded<{
849
+ inputTokens: Schema.filter<typeof Schema.Int>;
850
+ outputTokens: Schema.filter<typeof Schema.Int>;
851
+ totalTokens: Schema.filter<typeof Schema.Int>;
852
+ cacheReadInputTokens: Schema.optional<Schema.filter<typeof Schema.Int>>;
853
+ cacheWriteInputTokens: Schema.optional<Schema.filter<typeof Schema.Int>>;
854
+ }>, never, {
855
+ readonly inputTokens: number;
856
+ } & {
857
+ readonly outputTokens: number;
858
+ } & {
859
+ readonly totalTokens: number;
860
+ } & {
861
+ readonly cacheReadInputTokens?: number | undefined;
862
+ } & {
863
+ readonly cacheWriteInputTokens?: number | undefined;
864
+ }, {}, {}>;
865
+ /**
866
+ * @since 1.0.0
867
+ * @category Schemas
868
+ */
869
+ export declare class TokenUsage extends TokenUsage_base {
870
+ }
871
+ declare const SystemContentBlock_base: Schema.Union<[Schema.Struct<{
872
+ cachePoint: typeof CachePointBlock;
873
+ }>, Schema.Struct<{
874
+ guardContent: typeof GuardrailConverseContentBlock;
875
+ }>, Schema.Struct<{
876
+ text: Schema.filter<typeof Schema.String>;
877
+ }>]>;
878
+ /**
879
+ * @since 1.0.0
880
+ * @category Schemas
881
+ */
882
+ export declare class SystemContentBlock extends SystemContentBlock_base {
883
+ }
884
+ declare const GuardrailConfiguration_base: Schema.Class<GuardrailConfiguration, {
885
+ guardrailIdentifier: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
886
+ guardrailVersion: Schema.filter<typeof Schema.String>;
887
+ trace: Schema.optional<Schema.Literal<["enabled", "disabled", "enabled_full"]>>;
888
+ }, Schema.Struct.Encoded<{
889
+ guardrailIdentifier: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
890
+ guardrailVersion: Schema.filter<typeof Schema.String>;
891
+ trace: Schema.optional<Schema.Literal<["enabled", "disabled", "enabled_full"]>>;
892
+ }>, never, {
893
+ readonly guardrailIdentifier: string;
894
+ } & {
895
+ readonly guardrailVersion: string;
896
+ } & {
897
+ readonly trace?: "enabled" | "disabled" | "enabled_full" | undefined;
898
+ }, {}, {}>;
899
+ /**
900
+ * @since 1.0.0
901
+ * @category Schemas
902
+ */
903
+ export declare class GuardrailConfiguration extends GuardrailConfiguration_base {
904
+ }
905
+ declare const InferenceConfiguration_base: Schema.Class<InferenceConfiguration, {
906
+ maxTokens: Schema.optional<Schema.filter<typeof Schema.Int>>;
907
+ stopSequences: Schema.optional<Schema.filter<Schema.Array$<Schema.filter<typeof Schema.String>>>>;
908
+ temperature: Schema.filter<typeof Schema.Number>;
909
+ topP: Schema.filter<typeof Schema.Number>;
910
+ }, Schema.Struct.Encoded<{
911
+ maxTokens: Schema.optional<Schema.filter<typeof Schema.Int>>;
912
+ stopSequences: Schema.optional<Schema.filter<Schema.Array$<Schema.filter<typeof Schema.String>>>>;
913
+ temperature: Schema.filter<typeof Schema.Number>;
914
+ topP: Schema.filter<typeof Schema.Number>;
915
+ }>, never, {
916
+ readonly maxTokens?: number | undefined;
917
+ } & {
918
+ readonly stopSequences?: readonly string[] | undefined;
919
+ } & {
920
+ readonly temperature: number;
921
+ } & {
922
+ readonly topP: number;
923
+ }, {}, {}>;
924
+ /**
925
+ * @since 1.0.0
926
+ * @category Schemas
927
+ */
928
+ export declare class InferenceConfiguration extends InferenceConfiguration_base {
929
+ }
930
+ declare const PerformanceConfiguration_base: Schema.Class<PerformanceConfiguration, {
931
+ latency: Schema.optional<Schema.Literal<["standard", "optimized"]>>;
932
+ }, Schema.Struct.Encoded<{
933
+ latency: Schema.optional<Schema.Literal<["standard", "optimized"]>>;
934
+ }>, never, {
935
+ readonly latency?: "standard" | "optimized" | undefined;
936
+ }, {}, {}>;
937
+ /**
938
+ * @since 1.0.0
939
+ * @category Schemas
940
+ */
941
+ export declare class PerformanceConfiguration extends PerformanceConfiguration_base {
942
+ }
943
+ declare const ToolSpecification_base: Schema.Class<ToolSpecification, {
944
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
945
+ inputSchema: Schema.Struct<{
946
+ json: Schema.Record$<typeof Schema.String, typeof Schema.Unknown>;
947
+ }>;
948
+ description: Schema.optional<Schema.filter<typeof Schema.String>>;
949
+ }, Schema.Struct.Encoded<{
950
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
951
+ inputSchema: Schema.Struct<{
952
+ json: Schema.Record$<typeof Schema.String, typeof Schema.Unknown>;
953
+ }>;
954
+ description: Schema.optional<Schema.filter<typeof Schema.String>>;
955
+ }>, never, {
956
+ readonly name: string;
957
+ } & {
958
+ readonly inputSchema: {
959
+ readonly json: {
960
+ readonly [x: string]: unknown;
961
+ };
962
+ };
963
+ } & {
964
+ readonly description?: string | undefined;
965
+ }, {}, {}>;
966
+ /**
967
+ * @since 1.0.0
968
+ * @category Schemas
969
+ */
970
+ export declare class ToolSpecification extends ToolSpecification_base {
971
+ }
972
+ declare const Tool_base: Schema.Class<Tool, {
973
+ cachePoint: Schema.optional<typeof CachePointBlock>;
974
+ toolSpec: Schema.optional<typeof ToolSpecification>;
975
+ }, Schema.Struct.Encoded<{
976
+ cachePoint: Schema.optional<typeof CachePointBlock>;
977
+ toolSpec: Schema.optional<typeof ToolSpecification>;
978
+ }>, never, {
979
+ readonly cachePoint?: CachePointBlock | undefined;
980
+ } & {
981
+ readonly toolSpec?: ToolSpecification | undefined;
982
+ }, {}, {}>;
983
+ /**
984
+ * @since 1.0.0
985
+ * @category Schemas
986
+ */
987
+ export declare class Tool extends Tool_base {
988
+ }
989
+ declare const ToolChoice_base: Schema.Union<[Schema.Struct<{
990
+ any: Schema.Struct<{}>;
991
+ }>, Schema.Struct<{
992
+ auto: Schema.Struct<{}>;
993
+ }>, Schema.Struct<{
994
+ tool: Schema.Struct<{
995
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
996
+ }>;
997
+ }>]>;
998
+ /**
999
+ * @since 1.0.0
1000
+ * @category Schemas
1001
+ */
1002
+ export declare class ToolChoice extends ToolChoice_base {
1003
+ }
1004
+ declare const ToolConfiguration_base: Schema.Class<ToolConfiguration, {
1005
+ tools: Schema.filter<Schema.Array$<typeof Tool>>;
1006
+ toolChoice: Schema.optional<typeof ToolChoice>;
1007
+ }, Schema.Struct.Encoded<{
1008
+ tools: Schema.filter<Schema.Array$<typeof Tool>>;
1009
+ toolChoice: Schema.optional<typeof ToolChoice>;
1010
+ }>, never, {
1011
+ readonly tools: readonly Tool[];
1012
+ } & {
1013
+ readonly toolChoice?: {
1014
+ readonly any: {};
1015
+ } | {
1016
+ readonly auto: {};
1017
+ } | {
1018
+ readonly tool: {
1019
+ readonly name: string;
1020
+ };
1021
+ } | undefined;
1022
+ }, {}, {}>;
1023
+ /**
1024
+ * @since 1.0.0
1025
+ * @category Schemas
1026
+ */
1027
+ export declare class ToolConfiguration extends ToolConfiguration_base {
1028
+ }
1029
+ declare const ConverseRequest_base: Schema.Class<ConverseRequest, {
1030
+ modelId: typeof Schema.String;
1031
+ messages: Schema.Array$<typeof Message>;
1032
+ system: Schema.optional<Schema.Array$<typeof SystemContentBlock>>;
1033
+ toolConfig: Schema.optional<typeof ToolConfiguration>;
1034
+ guardrailConfig: Schema.optional<typeof GuardrailConfiguration>;
1035
+ inferenceConfig: Schema.optional<typeof InferenceConfiguration>;
1036
+ performanceConfig: Schema.optional<typeof PerformanceConfiguration>;
1037
+ promptVariables: Schema.optional<Schema.Record$<typeof Schema.String, Schema.Struct<{
1038
+ text: typeof Schema.String;
1039
+ }>>>;
1040
+ requestMetadata: Schema.optional<Schema.Record$<Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>, Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>>>;
1041
+ additionalModelRequestFields: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1042
+ additionalModelResponseFieldPaths: Schema.optional<Schema.filter<Schema.Array$<Schema.filter<Schema.filter<typeof Schema.String>>>>>;
1043
+ }, Schema.Struct.Encoded<{
1044
+ modelId: typeof Schema.String;
1045
+ messages: Schema.Array$<typeof Message>;
1046
+ system: Schema.optional<Schema.Array$<typeof SystemContentBlock>>;
1047
+ toolConfig: Schema.optional<typeof ToolConfiguration>;
1048
+ guardrailConfig: Schema.optional<typeof GuardrailConfiguration>;
1049
+ inferenceConfig: Schema.optional<typeof InferenceConfiguration>;
1050
+ performanceConfig: Schema.optional<typeof PerformanceConfiguration>;
1051
+ promptVariables: Schema.optional<Schema.Record$<typeof Schema.String, Schema.Struct<{
1052
+ text: typeof Schema.String;
1053
+ }>>>;
1054
+ requestMetadata: Schema.optional<Schema.Record$<Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>, Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>>>;
1055
+ additionalModelRequestFields: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1056
+ additionalModelResponseFieldPaths: Schema.optional<Schema.filter<Schema.Array$<Schema.filter<Schema.filter<typeof Schema.String>>>>>;
1057
+ }>, never, {
1058
+ readonly modelId: string;
1059
+ } & {
1060
+ readonly messages: readonly Message[];
1061
+ } & {
1062
+ readonly system?: readonly ({
1063
+ readonly cachePoint: CachePointBlock;
1064
+ } | {
1065
+ readonly guardContent: GuardrailConverseImageBlock | GuardrailConverseTextBlock;
1066
+ } | {
1067
+ readonly text: string;
1068
+ })[] | undefined;
1069
+ } & {
1070
+ readonly toolConfig?: ToolConfiguration | undefined;
1071
+ } & {
1072
+ readonly guardrailConfig?: GuardrailConfiguration | undefined;
1073
+ } & {
1074
+ readonly inferenceConfig?: InferenceConfiguration | undefined;
1075
+ } & {
1076
+ readonly performanceConfig?: PerformanceConfiguration | undefined;
1077
+ } & {
1078
+ readonly promptVariables?: {
1079
+ readonly [x: string]: {
1080
+ readonly text: string;
1081
+ };
1082
+ } | undefined;
1083
+ } & {
1084
+ readonly requestMetadata?: {
1085
+ readonly [x: string]: string;
1086
+ } | undefined;
1087
+ } & {
1088
+ readonly additionalModelRequestFields?: {
1089
+ readonly [x: string]: unknown;
1090
+ } | undefined;
1091
+ } & {
1092
+ readonly additionalModelResponseFieldPaths?: readonly string[] | undefined;
1093
+ }, {}, {}>;
1094
+ /**
1095
+ * @since 1.0.0
1096
+ * @category Schemas
1097
+ */
1098
+ export declare class ConverseRequest extends ConverseRequest_base {
1099
+ }
1100
+ declare const ConverseResponse_base: Schema.Class<ConverseResponse, {
1101
+ output: typeof ConverseOutput;
1102
+ metrics: typeof ConverseMetrics;
1103
+ usage: typeof TokenUsage;
1104
+ stopReason: Schema.Literal<["content_filtered", "end_turn", "tool_use", "max_tokens", "stop_sequence", "guardrail_intervened"]>;
1105
+ trace: Schema.optional<typeof ConverseTrace>;
1106
+ performanceConfig: Schema.optional<Schema.Struct<{
1107
+ latency: Schema.Literal<["standard", "optimized"]>;
1108
+ }>>;
1109
+ additionalModelResponseFields: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1110
+ }, Schema.Struct.Encoded<{
1111
+ output: typeof ConverseOutput;
1112
+ metrics: typeof ConverseMetrics;
1113
+ usage: typeof TokenUsage;
1114
+ stopReason: Schema.Literal<["content_filtered", "end_turn", "tool_use", "max_tokens", "stop_sequence", "guardrail_intervened"]>;
1115
+ trace: Schema.optional<typeof ConverseTrace>;
1116
+ performanceConfig: Schema.optional<Schema.Struct<{
1117
+ latency: Schema.Literal<["standard", "optimized"]>;
1118
+ }>>;
1119
+ additionalModelResponseFields: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1120
+ }>, never, {
1121
+ readonly usage: TokenUsage;
1122
+ } & {
1123
+ readonly trace?: ConverseTrace | undefined;
1124
+ } & {
1125
+ readonly performanceConfig?: {
1126
+ readonly latency: "standard" | "optimized";
1127
+ } | undefined;
1128
+ } & {
1129
+ readonly output: ConverseOutput;
1130
+ } & {
1131
+ readonly metrics: ConverseMetrics;
1132
+ } & {
1133
+ readonly stopReason: "content_filtered" | "end_turn" | "tool_use" | "max_tokens" | "stop_sequence" | "guardrail_intervened";
1134
+ } & {
1135
+ readonly additionalModelResponseFields?: {
1136
+ readonly [x: string]: unknown;
1137
+ } | undefined;
1138
+ }, {}, {}>;
1139
+ /**
1140
+ * @since 1.0.0
1141
+ * @category Schemas
1142
+ */
1143
+ export declare class ConverseResponse extends ConverseResponse_base {
1144
+ }
1145
+ declare const ReasoningContentBlockDelta_base: Schema.Union<[Schema.Struct<{
1146
+ redactedContent: Schema.Schema<Uint8Array<ArrayBufferLike>, string, never>;
1147
+ }>, Schema.Struct<{
1148
+ signature: typeof Schema.String;
1149
+ }>, Schema.Struct<{
1150
+ text: typeof Schema.String;
1151
+ }>]>;
1152
+ /**
1153
+ * @since 1.0.0
1154
+ * @category Schemas
1155
+ */
1156
+ export declare class ReasoningContentBlockDelta extends ReasoningContentBlockDelta_base {
1157
+ }
1158
+ declare const ToolUseBlockStart_base: Schema.Class<ToolUseBlockStart, {
1159
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
1160
+ toolUseId: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
1161
+ }, Schema.Struct.Encoded<{
1162
+ name: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
1163
+ toolUseId: Schema.filter<Schema.filter<Schema.filter<typeof Schema.String>>>;
1164
+ }>, never, {
1165
+ readonly name: string;
1166
+ } & {
1167
+ readonly toolUseId: string;
1168
+ }, {}, {}>;
1169
+ /**
1170
+ * @since 1.0.0
1171
+ * @category Schemas
1172
+ */
1173
+ export declare class ToolUseBlockStart extends ToolUseBlockStart_base {
1174
+ }
1175
+ declare const ContentBlockStart_base: Schema.Class<ContentBlockStart, {
1176
+ toolUse: typeof ToolUseBlockStart;
1177
+ }, Schema.Struct.Encoded<{
1178
+ toolUse: typeof ToolUseBlockStart;
1179
+ }>, never, {
1180
+ readonly toolUse: ToolUseBlockStart;
1181
+ }, {}, {}>;
1182
+ /**
1183
+ * @since 1.0.0
1184
+ * @category Schemas
1185
+ */
1186
+ export declare class ContentBlockStart extends ContentBlockStart_base {
1187
+ }
1188
+ declare const ContentBlockStartEvent_base: Schema.Class<ContentBlockStartEvent, {
1189
+ contentBlockIndex: Schema.filter<typeof Schema.Int>;
1190
+ start: typeof ContentBlockStart;
1191
+ }, Schema.Struct.Encoded<{
1192
+ contentBlockIndex: Schema.filter<typeof Schema.Int>;
1193
+ start: typeof ContentBlockStart;
1194
+ }>, never, {
1195
+ readonly start: ContentBlockStart;
1196
+ } & {
1197
+ readonly contentBlockIndex: number;
1198
+ }, {}, {}>;
1199
+ /**
1200
+ * @since 1.0.0
1201
+ * @category Schemas
1202
+ */
1203
+ export declare class ContentBlockStartEvent extends ContentBlockStartEvent_base {
1204
+ }
1205
+ declare const ContentBlockStopEvent_base: Schema.Class<ContentBlockStopEvent, {
1206
+ contentBlockIndex: Schema.filter<typeof Schema.Int>;
1207
+ }, Schema.Struct.Encoded<{
1208
+ contentBlockIndex: Schema.filter<typeof Schema.Int>;
1209
+ }>, never, {
1210
+ readonly contentBlockIndex: number;
1211
+ }, {}, {}>;
1212
+ /**
1213
+ * @since 1.0.0
1214
+ * @category Schemas
1215
+ */
1216
+ export declare class ContentBlockStopEvent extends ContentBlockStopEvent_base {
1217
+ }
1218
+ declare const ToolUseBlockDelta_base: Schema.Class<ToolUseBlockDelta, {
1219
+ input: typeof Schema.String;
1220
+ }, Schema.Struct.Encoded<{
1221
+ input: typeof Schema.String;
1222
+ }>, never, {
1223
+ readonly input: string;
1224
+ }, {}, {}>;
1225
+ /**
1226
+ * @since 1.0.0
1227
+ * @category Schemas
1228
+ */
1229
+ export declare class ToolUseBlockDelta extends ToolUseBlockDelta_base {
1230
+ }
1231
+ declare const ContentBlockDelta_base: Schema.Union<[Schema.Struct<{
1232
+ reasoningContent: typeof ReasoningContentBlockDelta;
1233
+ }>, Schema.Struct<{
1234
+ text: typeof Schema.String;
1235
+ }>, Schema.Struct<{
1236
+ toolUse: typeof ToolUseBlockDelta;
1237
+ }>]>;
1238
+ /**
1239
+ * @since 1.0.0
1240
+ * @category Schemas
1241
+ */
1242
+ export declare class ContentBlockDelta extends ContentBlockDelta_base {
1243
+ }
1244
+ declare const ContentBlockDeltaEvent_base: Schema.Class<ContentBlockDeltaEvent, {
1245
+ contentBlockIndex: Schema.filter<typeof Schema.Int>;
1246
+ delta: typeof ContentBlockDelta;
1247
+ }, Schema.Struct.Encoded<{
1248
+ contentBlockIndex: Schema.filter<typeof Schema.Int>;
1249
+ delta: typeof ContentBlockDelta;
1250
+ }>, never, {
1251
+ readonly contentBlockIndex: number;
1252
+ } & {
1253
+ readonly delta: {
1254
+ readonly reasoningContent: {
1255
+ readonly redactedContent: Uint8Array<ArrayBufferLike>;
1256
+ } | {
1257
+ readonly signature: string;
1258
+ } | {
1259
+ readonly text: string;
1260
+ };
1261
+ } | {
1262
+ readonly text: string;
1263
+ } | {
1264
+ readonly toolUse: ToolUseBlockDelta;
1265
+ };
1266
+ }, {}, {}>;
1267
+ /**
1268
+ * @since 1.0.0
1269
+ * @category Schemas
1270
+ */
1271
+ export declare class ContentBlockDeltaEvent extends ContentBlockDeltaEvent_base {
1272
+ }
1273
+ declare const MessageStartEvent_base: Schema.Class<MessageStartEvent, {
1274
+ role: Schema.Literal<["user", "assistant"]>;
1275
+ }, Schema.Struct.Encoded<{
1276
+ role: Schema.Literal<["user", "assistant"]>;
1277
+ }>, never, {
1278
+ readonly role: "user" | "assistant";
1279
+ }, {}, {}>;
1280
+ /**
1281
+ * @since 1.0.0
1282
+ * @category Schemas
1283
+ */
1284
+ export declare class MessageStartEvent extends MessageStartEvent_base {
1285
+ }
1286
+ /**
1287
+ * @since 1.0.0
1288
+ * @category Schemas
1289
+ */
1290
+ export declare const StopReason: Schema.Literal<["end_turn", "tool_use", "max_tokens", "stop_sequence", "guardrail_intervened", "content_filtered"]>;
1291
+ /**
1292
+ * @since 1.0.0
1293
+ * @category Schemas
1294
+ */
1295
+ export type StopReason = typeof StopReason.Type;
1296
+ declare const MessageStopEvent_base: Schema.Class<MessageStopEvent, {
1297
+ stopReason: Schema.Literal<["end_turn", "tool_use", "max_tokens", "stop_sequence", "guardrail_intervened", "content_filtered"]>;
1298
+ additionalModelResponseFields: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1299
+ }, Schema.Struct.Encoded<{
1300
+ stopReason: Schema.Literal<["end_turn", "tool_use", "max_tokens", "stop_sequence", "guardrail_intervened", "content_filtered"]>;
1301
+ additionalModelResponseFields: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1302
+ }>, never, {
1303
+ readonly stopReason: "content_filtered" | "end_turn" | "tool_use" | "max_tokens" | "stop_sequence" | "guardrail_intervened";
1304
+ } & {
1305
+ readonly additionalModelResponseFields?: {
1306
+ readonly [x: string]: unknown;
1307
+ } | undefined;
1308
+ }, {}, {}>;
1309
+ /**
1310
+ * @since 1.0.0
1311
+ * @category Schemas
1312
+ */
1313
+ export declare class MessageStopEvent extends MessageStopEvent_base {
1314
+ }
1315
+ declare const ConverseStreamMetrics_base: Schema.Class<ConverseStreamMetrics, {
1316
+ latencyMs: typeof Schema.DurationFromMillis;
1317
+ }, Schema.Struct.Encoded<{
1318
+ latencyMs: typeof Schema.DurationFromMillis;
1319
+ }>, never, {
1320
+ readonly latencyMs: import("effect/Duration").Duration;
1321
+ }, {}, {}>;
1322
+ /**
1323
+ * @since 1.0.0
1324
+ * @category Schemas
1325
+ */
1326
+ export declare class ConverseStreamMetrics extends ConverseStreamMetrics_base {
1327
+ }
1328
+ declare const ConverseStreamTrace_base: Schema.Class<ConverseStreamTrace, {
1329
+ guardrail: Schema.optional<typeof GuardrailTraceAssessment>;
1330
+ promptRouter: Schema.optional<typeof PromptRouterTrace>;
1331
+ }, Schema.Struct.Encoded<{
1332
+ guardrail: Schema.optional<typeof GuardrailTraceAssessment>;
1333
+ promptRouter: Schema.optional<typeof PromptRouterTrace>;
1334
+ }>, never, {
1335
+ readonly guardrail?: GuardrailTraceAssessment | undefined;
1336
+ } & {
1337
+ readonly promptRouter?: PromptRouterTrace | undefined;
1338
+ }, {}, {}>;
1339
+ /**
1340
+ * @since 1.0.0
1341
+ * @category Schemas
1342
+ */
1343
+ export declare class ConverseStreamTrace extends ConverseStreamTrace_base {
1344
+ }
1345
+ declare const ConverseStreamMetadataEvent_base: Schema.Class<ConverseStreamMetadataEvent, {
1346
+ metrics: typeof ConverseStreamMetrics;
1347
+ usage: typeof TokenUsage;
1348
+ performanceConfig: Schema.optional<typeof PerformanceConfiguration>;
1349
+ trace: Schema.optional<typeof ConverseStreamTrace>;
1350
+ }, Schema.Struct.Encoded<{
1351
+ metrics: typeof ConverseStreamMetrics;
1352
+ usage: typeof TokenUsage;
1353
+ performanceConfig: Schema.optional<typeof PerformanceConfiguration>;
1354
+ trace: Schema.optional<typeof ConverseStreamTrace>;
1355
+ }>, never, {
1356
+ readonly usage: TokenUsage;
1357
+ } & {
1358
+ readonly trace?: ConverseStreamTrace | undefined;
1359
+ } & {
1360
+ readonly performanceConfig?: PerformanceConfiguration | undefined;
1361
+ } & {
1362
+ readonly metrics: ConverseStreamMetrics;
1363
+ }, {}, {}>;
1364
+ /**
1365
+ * @since 1.0.0
1366
+ * @category Schemas
1367
+ */
1368
+ export declare class ConverseStreamMetadataEvent extends ConverseStreamMetadataEvent_base {
1369
+ }
1370
+ declare const ConverseStreamResponse_base: Schema.Class<ConverseStreamResponse, {
1371
+ contentBlockStart: Schema.optional<typeof ContentBlockStartEvent>;
1372
+ contentBlockStop: Schema.optional<typeof ContentBlockStopEvent>;
1373
+ contentBlockDelta: Schema.optional<typeof ContentBlockDeltaEvent>;
1374
+ messageStart: Schema.optional<typeof MessageStartEvent>;
1375
+ messageStop: Schema.optional<typeof MessageStopEvent>;
1376
+ metadata: Schema.optional<typeof ConverseStreamMetadataEvent>;
1377
+ internalServerException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1378
+ modelStreamErrorException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1379
+ serviceUnavailableException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1380
+ throttlingException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1381
+ validationException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1382
+ }, Schema.Struct.Encoded<{
1383
+ contentBlockStart: Schema.optional<typeof ContentBlockStartEvent>;
1384
+ contentBlockStop: Schema.optional<typeof ContentBlockStopEvent>;
1385
+ contentBlockDelta: Schema.optional<typeof ContentBlockDeltaEvent>;
1386
+ messageStart: Schema.optional<typeof MessageStartEvent>;
1387
+ messageStop: Schema.optional<typeof MessageStopEvent>;
1388
+ metadata: Schema.optional<typeof ConverseStreamMetadataEvent>;
1389
+ internalServerException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1390
+ modelStreamErrorException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1391
+ serviceUnavailableException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1392
+ throttlingException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1393
+ validationException: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.Unknown>>;
1394
+ }>, never, {
1395
+ readonly contentBlockStart?: ContentBlockStartEvent | undefined;
1396
+ } & {
1397
+ readonly contentBlockStop?: ContentBlockStopEvent | undefined;
1398
+ } & {
1399
+ readonly contentBlockDelta?: ContentBlockDeltaEvent | undefined;
1400
+ } & {
1401
+ readonly messageStart?: MessageStartEvent | undefined;
1402
+ } & {
1403
+ readonly messageStop?: MessageStopEvent | undefined;
1404
+ } & {
1405
+ readonly metadata?: ConverseStreamMetadataEvent | undefined;
1406
+ } & {
1407
+ readonly internalServerException?: {
1408
+ readonly [x: string]: unknown;
1409
+ } | undefined;
1410
+ } & {
1411
+ readonly modelStreamErrorException?: {
1412
+ readonly [x: string]: unknown;
1413
+ } | undefined;
1414
+ } & {
1415
+ readonly serviceUnavailableException?: {
1416
+ readonly [x: string]: unknown;
1417
+ } | undefined;
1418
+ } & {
1419
+ readonly throttlingException?: {
1420
+ readonly [x: string]: unknown;
1421
+ } | undefined;
1422
+ } & {
1423
+ readonly validationException?: {
1424
+ readonly [x: string]: unknown;
1425
+ } | undefined;
1426
+ }, {}, {}>;
1427
+ /**
1428
+ * @since 1.0.0
1429
+ * @category Schemas
1430
+ */
1431
+ export declare class ConverseStreamResponse extends ConverseStreamResponse_base {
1432
+ }
1433
+ export {};
1434
+ //# sourceMappingURL=AmazonBedrockSchema.d.ts.map