Skip to content

Commit a70f641

Browse files
deyaaeldeenstainless-app[bot]
authored andcommitted
[Azure] Update Batch API (#871)
1 parent ed4219a commit a70f641

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

src/index.ts

-1
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,6 @@ const _deployments_endpoints = new Set([
492492
'/audio/translations',
493493
'/audio/speech',
494494
'/images/generations',
495-
'/batches',
496495
]);
497496

498497
const API_KEY_SENTINEL = '<Missing Key>';

tests/lib/azure.test.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -290,15 +290,15 @@ describe('azure request building', () => {
290290
fetch: testFetch,
291291
});
292292

293-
test('handles Batch', async () => {
293+
test('handles batch', async () => {
294294
expect(
295295
await client.batches.create({
296296
completion_window: '24h',
297297
endpoint: '/v1/chat/completions',
298298
input_file_id: 'file-id',
299299
}),
300300
).toStrictEqual({
301-
url: `https://example.com/openai/deployments/${deployment}/batches?api-version=${apiVersion}`,
301+
url: `https://example.com/openai/batches?api-version=${apiVersion}`,
302302
});
303303
});
304304

@@ -423,7 +423,7 @@ describe('azure request building', () => {
423423
fetch: testFetch,
424424
});
425425

426-
test('Batch is not handled', async () => {
426+
test('handles batch', async () => {
427427
expect(
428428
await client.batches.create({
429429
completion_window: '24h',

0 commit comments

Comments
 (0)