diff --git a/tests/api-resources/beta/assistants.test.ts b/tests/api-resources/beta/assistants.test.ts index 13fec377d..fdc325254 100644 --- a/tests/api-resources/beta/assistants.test.ts +++ b/tests/api-resources/beta/assistants.test.ts @@ -34,7 +34,7 @@ describe('resource assistants', () => { file_search: { vector_store_ids: ['string'], vector_stores: [ - { file_ids: ['string', 'string', 'string'], chunking_strategy: { type: 'auto' }, metadata: {} }, + { chunking_strategy: { type: 'auto' }, file_ids: ['string', 'string', 'string'], metadata: {} }, ], }, }, diff --git a/tests/api-resources/beta/threads/runs/runs.test.ts b/tests/api-resources/beta/threads/runs/runs.test.ts index f6a7dead6..a2fda7757 100644 --- a/tests/api-resources/beta/threads/runs/runs.test.ts +++ b/tests/api-resources/beta/threads/runs/runs.test.ts @@ -26,8 +26,8 @@ describe('resource runs', () => { additional_instructions: 'additional_instructions', additional_messages: [ { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -57,8 +57,8 @@ describe('resource runs', () => { metadata: {}, }, { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -88,8 +88,8 @@ describe('resource runs', () => { metadata: {}, }, { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -227,9 +227,9 @@ describe('resource runs', () => { test('submitToolOutputs: required and optional params', async () => { const response = await client.beta.threads.runs.submitToolOutputs('thread_id', 'run_id', { tool_outputs: [ - { tool_call_id: 'tool_call_id', output: 'output' }, - { tool_call_id: 'tool_call_id', output: 'output' }, - { tool_call_id: 'tool_call_id', output: 'output' }, + { output: 'output', tool_call_id: 'tool_call_id' }, + { output: 'output', tool_call_id: 'tool_call_id' }, + { output: 'output', tool_call_id: 'tool_call_id' }, ], stream: false, }); diff --git a/tests/api-resources/beta/threads/threads.test.ts b/tests/api-resources/beta/threads/threads.test.ts index abf631adb..dc0a94a7d 100644 --- a/tests/api-resources/beta/threads/threads.test.ts +++ b/tests/api-resources/beta/threads/threads.test.ts @@ -34,8 +34,8 @@ describe('resource threads', () => { { messages: [ { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -65,8 +65,8 @@ describe('resource threads', () => { metadata: {}, }, { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -96,8 +96,8 @@ describe('resource threads', () => { metadata: {}, }, { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -134,8 +134,8 @@ describe('resource threads', () => { vector_store_ids: ['string'], vector_stores: [ { - file_ids: ['string', 'string', 'string'], chunking_strategy: { type: 'auto' }, + file_ids: ['string', 'string', 'string'], metadata: {}, }, ], @@ -220,8 +220,8 @@ describe('resource threads', () => { thread: { messages: [ { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -251,8 +251,8 @@ describe('resource threads', () => { metadata: {}, }, { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -282,8 +282,8 @@ describe('resource threads', () => { metadata: {}, }, { - role: 'user', content: 'string', + role: 'user', attachments: [ { file_id: 'file_id', @@ -313,16 +313,16 @@ describe('resource threads', () => { metadata: {}, }, ], + metadata: {}, tool_resources: { code_interpreter: { file_ids: ['string', 'string', 'string'] }, file_search: { vector_store_ids: ['string'], vector_stores: [ - { file_ids: ['string', 'string', 'string'], chunking_strategy: { type: 'auto' }, metadata: {} }, + { chunking_strategy: { type: 'auto' }, file_ids: ['string', 'string', 'string'], metadata: {} }, ], }, }, - metadata: {}, }, tool_choice: 'none', tool_resources: { diff --git a/tests/api-resources/chat/completions.test.ts b/tests/api-resources/chat/completions.test.ts index 5cdd1e670..2179c52c3 100644 --- a/tests/api-resources/chat/completions.test.ts +++ b/tests/api-resources/chat/completions.test.ts @@ -29,7 +29,7 @@ describe('resource completions', () => { model: 'gpt-4o', frequency_penalty: -2, function_call: 'none', - functions: [{ description: 'description', name: 'name', parameters: { foo: 'bar' } }], + functions: [{ name: 'name', description: 'description', parameters: { foo: 'bar' } }], logit_bias: { foo: 0 }, logprobs: true, max_tokens: 0, @@ -46,16 +46,16 @@ describe('resource completions', () => { tool_choice: 'none', tools: [ { + function: { name: 'name', description: 'description', parameters: { foo: 'bar' }, strict: true }, type: 'function', - function: { description: 'description', name: 'name', parameters: { foo: 'bar' }, strict: true }, }, { + function: { name: 'name', description: 'description', parameters: { foo: 'bar' }, strict: true }, type: 'function', - function: { description: 'description', name: 'name', parameters: { foo: 'bar' }, strict: true }, }, { + function: { name: 'name', description: 'description', parameters: { foo: 'bar' }, strict: true }, type: 'function', - function: { description: 'description', name: 'name', parameters: { foo: 'bar' }, strict: true }, }, ], top_logprobs: 0, diff --git a/tests/api-resources/fine-tuning/jobs/jobs.test.ts b/tests/api-resources/fine-tuning/jobs/jobs.test.ts index e683dfe3e..646c2f5cf 100644 --- a/tests/api-resources/fine-tuning/jobs/jobs.test.ts +++ b/tests/api-resources/fine-tuning/jobs/jobs.test.ts @@ -33,8 +33,8 @@ describe('resource jobs', () => { type: 'wandb', wandb: { project: 'my-wandb-project', - name: 'name', entity: 'entity', + name: 'name', tags: ['custom-tag', 'custom-tag', 'custom-tag'], }, }, @@ -42,8 +42,8 @@ describe('resource jobs', () => { type: 'wandb', wandb: { project: 'my-wandb-project', - name: 'name', entity: 'entity', + name: 'name', tags: ['custom-tag', 'custom-tag', 'custom-tag'], }, }, @@ -51,8 +51,8 @@ describe('resource jobs', () => { type: 'wandb', wandb: { project: 'my-wandb-project', - name: 'name', entity: 'entity', + name: 'name', tags: ['custom-tag', 'custom-tag', 'custom-tag'], }, }, diff --git a/tests/api-resources/images.test.ts b/tests/api-resources/images.test.ts index 43e67b030..88eb97a93 100644 --- a/tests/api-resources/images.test.ts +++ b/tests/api-resources/images.test.ts @@ -28,7 +28,7 @@ describe('resource images', () => { model: 'dall-e-2', n: 1, response_format: 'url', - size: '1024x1024', + size: '256x256', user: 'user-1234', }); }); @@ -55,7 +55,7 @@ describe('resource images', () => { model: 'dall-e-2', n: 1, response_format: 'url', - size: '1024x1024', + size: '256x256', user: 'user-1234', }); }); @@ -78,7 +78,7 @@ describe('resource images', () => { n: 1, quality: 'standard', response_format: 'url', - size: '1024x1024', + size: '256x256', style: 'vivid', user: 'user-1234', });