From cd18dc10c2a72352c2c96fe3f5d6f4db1c59fb66 Mon Sep 17 00:00:00 2001 From: stainless-bot Date: Wed, 30 Oct 2024 22:55:58 +0000 Subject: [PATCH] feat(api): manual updates --- .stats.yml | 2 +- src/resources/chat.ts | 4 ++-- tests/api-resources/chat.test.ts | 15 ++++++++++++--- 3 files changed, 15 insertions(+), 6 deletions(-) diff --git a/.stats.yml b/.stats.yml index 6641d6d9..fc7fd561 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,2 +1,2 @@ configured_endpoints: 21 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/writerai%2Fwriter-1cc5cdee043b0cdaf8a02e3f4e2799f17a4b88dd843cf31eea423843f5bbd4b8.yml +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/writerai%2Fwriter-8e1a6a7a707502c2d026f1201825d0ce91e7a8f71d74cf6eebc95991b48be760.yml diff --git a/src/resources/chat.ts b/src/resources/chat.ts index e70dbd87..3069dc6f 100644 --- a/src/resources/chat.ts +++ b/src/resources/chat.ts @@ -820,7 +820,7 @@ export namespace ChatChatParams { } export interface JsonObjectToolChoice { - value: unknown; + value: Record; } export interface FunctionTool { @@ -844,7 +844,7 @@ export namespace ChatChatParams { */ description?: string; - parameters?: unknown; + parameters?: Record; } } diff --git a/tests/api-resources/chat.test.ts b/tests/api-resources/chat.test.ts index ba7691dd..8ac3a9e4 100644 --- a/tests/api-resources/chat.test.ts +++ b/tests/api-resources/chat.test.ts @@ -81,9 +81,18 @@ describe('resource chat', () => { temperature: 0, tool_choice: { value: 'none' }, tools: [ - { function: { name: 'name', description: 'description', parameters: {} }, type: 'function' }, - { function: { name: 'name', description: 'description', parameters: {} }, type: 'function' }, - { function: { name: 'name', description: 'description', parameters: {} }, type: 'function' }, + { + function: { name: 'name', description: 'description', parameters: { foo: 'bar' } }, + type: 'function', + }, + { + function: { name: 'name', description: 'description', parameters: { foo: 'bar' } }, + type: 'function', + }, + { + function: { name: 'name', description: 'description', parameters: { foo: 'bar' } }, + type: 'function', + }, ], top_p: 0, });