orchestrated 0.1.18 → 0.1.19

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 (4) hide show
  1. package/index.d.ts +40 -2
  2. package/index.js +103483 -13866
  3. package/index.js.map +653 -21
  4. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -67,6 +67,7 @@ declare class BatchClient {
67
67
  private mode;
68
68
  private s3FileManager;
69
69
  private bedrockConfig;
70
+ private bedrockNativeConfig;
70
71
  private tempDir;
71
72
  requests: BatchRequest[];
72
73
  responses: BatchResult[];
@@ -123,6 +124,16 @@ declare class BatchClient {
123
124
  * @returns Batch object with ID and status
124
125
  */
125
126
  submitBatch(requests: BatchRequest[], completionWindow?: "24h"): Promise<Batch>;
127
+ /**
128
+ * Submit a batch using the native Bedrock CreateModelInvocationJob API
129
+ * with modelInvocationType "Converse".
130
+ */
131
+ private submitBedrockNativeBatch;
132
+ /**
133
+ * Encode eval name and checksum into a Bedrock jobName.
134
+ * Bedrock jobName must match: [a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}
135
+ */
136
+ private encodeJobName;
126
137
  /**
127
138
  * Retrieves the status of a batch
128
139
  *
@@ -130,6 +141,11 @@ declare class BatchClient {
130
141
  * @returns Batch object with current status
131
142
  */
132
143
  getBatchStatus(batchId: string): Promise<Batch>;
144
+ /**
145
+ * Get the status of a native Bedrock batch job.
146
+ * batchId is the Bedrock job ARN.
147
+ */
148
+ private getBedrockNativeBatchStatus;
133
149
  /**
134
150
  * Checks if a batch has completed (successfully or with errors)
135
151
  */
@@ -143,10 +159,20 @@ declare class BatchClient {
143
159
  * @returns Array of batch results
144
160
  */
145
161
  getBatchResults(batchId: string): Promise<BatchResult[]>;
162
+ /**
163
+ * Parse native Bedrock Converse output JSONL into BatchResult[].
164
+ * Bedrock writes output to {outputUri}/{jobId}/input.jsonl.out
165
+ * We list the S3 prefix and read the .out file.
166
+ */
167
+ private getBedrockNativeBatchResults;
146
168
  /**
147
169
  * Lists all batches with optional filtering
148
170
  */
149
171
  listBatches(limit?: number): Promise<Batch[]>;
172
+ /**
173
+ * List native Bedrock batch jobs, filtering by eval name encoded in jobName.
174
+ */
175
+ private listBedrockNativeBatches;
150
176
  /**
151
177
  * Cancels a batch that is in progress
152
178
  */
@@ -166,9 +192,10 @@ declare class BatchClient {
166
192
  * Options for constructing a BatchClient
167
193
  */
168
194
  declare interface BatchClientOptions {
169
- mode?: "OPENAI" | "BEDROCK_OPENAI";
195
+ mode?: "OPENAI" | "BEDROCK_OPENAI" | "BEDROCK";
170
196
  clientOptions?: ClientOptions;
171
197
  bedrock?: BedrockBatchConfig;
198
+ bedrockNative?: BedrockNativeBatchConfig;
172
199
  }
173
200
 
174
201
  /**
@@ -208,6 +235,17 @@ declare interface BedrockBatchConfig {
208
235
  s3Prefix?: string;
209
236
  }
210
237
 
238
+ /**
239
+ * Bedrock-specific configuration for native BEDROCK mode (Converse API)
240
+ */
241
+ declare interface BedrockNativeBatchConfig {
242
+ region: string;
243
+ serviceRoleArn: string;
244
+ modelId: string;
245
+ s3Bucket: string;
246
+ s3Prefix?: string;
247
+ }
248
+
211
249
  export declare const Behavioral: ((args: unknown) => Promise<Score>) & {
212
250
  definition?: SerializableScorerDefinition;
213
251
  };
@@ -490,7 +528,7 @@ export declare interface EvalOptions<EvalReport = boolean> {
490
528
  * - "OPENAI": Use OpenAI Batch API (default)
491
529
  * - "BEDROCK_OPENAI": Use AWS Bedrock OpenAI-compatible Batch API
492
530
  */
493
- batchProcessor?: "OPENAI" | "BEDROCK_OPENAI";
531
+ batchProcessor?: "OPENAI" | "BEDROCK_OPENAI" | "BEDROCK";
494
532
  __schedule?: string;
495
533
  }
496
534