Skip to content

Commit

Permalink
Merge pull request #779 from openai/release-please--branches--master-…
Browse files Browse the repository at this point in the history
…-changes--next--components--openai

release: 4.37.1
  • Loading branch information
nknj authored Apr 17, 2024
2 parents c2c998d + f3a5360 commit 9c31244
Show file tree
Hide file tree
Showing 9 changed files with 153 additions and 33 deletions.
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "4.37.0"
".": "4.37.1"
}
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 4.37.1 (2024-04-17)

Full Changelog: [v4.37.0...v4.37.1](https://github.com/openai/openai-node/compare/v4.37.0...v4.37.1)

### Chores

* **api:** docs and response_format response property ([#778](https://github.com/openai/openai-node/issues/778)) ([78f5c35](https://github.com/openai/openai-node/commit/78f5c3568d95d8e854c04049dc7d5643aa49e93f))

## 4.37.0 (2024-04-17)

Full Changelog: [v4.36.0...v4.37.0](https://github.com/openai/openai-node/compare/v4.36.0...v4.37.0)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ You can import in Deno via:
<!-- x-release-please-start-version -->

```ts
import OpenAI from 'https://deno.land/x/[email protected].0/mod.ts';
import OpenAI from 'https://deno.land/x/[email protected].1/mod.ts';
```

<!-- x-release-please-end -->
Expand Down
2 changes: 1 addition & 1 deletion build-deno
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ This is a build produced from https://github.com/openai/openai-node – please g
Usage:
\`\`\`ts
import OpenAI from "https://deno.land/x/[email protected].0/mod.ts";
import OpenAI from "https://deno.land/x/[email protected].1/mod.ts";
const client = new OpenAI();
\`\`\`
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "openai",
"version": "4.37.0",
"version": "4.37.1",
"description": "The official TypeScript library for the OpenAI API",
"author": "OpenAI <[email protected]>",
"types": "dist/index.d.ts",
Expand Down
38 changes: 36 additions & 2 deletions src/resources/beta/assistants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,13 +142,47 @@ export interface Assistant {
*/
tools: Array<AssistantTool>;

/**
* Specifies the format that the model must output. Compatible with
* [GPT-4 Turbo](https://platform.openai.com/docs/models/gpt-4-and-gpt-4-turbo) and
* all GPT-3.5 Turbo models since `gpt-3.5-turbo-1106`.
*
* Setting to `{ "type": "json_object" }` enables JSON mode, which guarantees the
* message the model generates is valid JSON.
*
* **Important:** when using JSON mode, you **must** also instruct the model to
* produce JSON yourself via a system or user message. Without this, the model may
* generate an unending stream of whitespace until the generation reaches the token
* limit, resulting in a long-running and seemingly "stuck" request. Also note that
* the message content may be partially cut off if `finish_reason="length"`, which
* indicates the generation exceeded `max_tokens` or the conversation exceeded the
* max context length.
*/
response_format?: ThreadsAPI.AssistantResponseFormatOption | null;

/**
* What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
* make the output more random, while lower values like 0.2 will make it more
* focused and deterministic.
*/
temperature?: number | null;

/**
* A set of resources that are used by the assistant's tools. The resources are
* specific to the type of tool. For example, the `code_interpreter` tool requires
* a list of file IDs, while the `file_search` tool requires a list of vector store
* IDs.
*/
tool_resources?: Assistant.ToolResources | null;

/**
* An alternative to sampling with temperature, called nucleus sampling, where the
* model considers the results of the tokens with top_p probability mass. So 0.1
* means only the tokens comprising the top 10% probability mass are considered.
*
* We generally recommend altering this or temperature but not both.
*/
top_p?: number | null;
}

export namespace Assistant {
Expand Down Expand Up @@ -1012,7 +1046,7 @@ export interface AssistantCreateParams {
/**
* Specifies the format that the model must output. Compatible with
* [GPT-4 Turbo](https://platform.openai.com/docs/models/gpt-4-and-gpt-4-turbo) and
* all GPT-3.5 Turbo models newer than `gpt-3.5-turbo-1106`.
* all GPT-3.5 Turbo models since `gpt-3.5-turbo-1106`.
*
* Setting to `{ "type": "json_object" }` enables JSON mode, which guarantees the
* message the model generates is valid JSON.
Expand Down Expand Up @@ -1158,7 +1192,7 @@ export interface AssistantUpdateParams {
/**
* Specifies the format that the model must output. Compatible with
* [GPT-4 Turbo](https://platform.openai.com/docs/models/gpt-4-and-gpt-4-turbo) and
* all GPT-3.5 Turbo models newer than `gpt-3.5-turbo-1106`.
* all GPT-3.5 Turbo models since `gpt-3.5-turbo-1106`.
*
* Setting to `{ "type": "json_object" }` enables JSON mode, which guarantees the
* message the model generates is valid JSON.
Expand Down
Loading

0 comments on commit 9c31244

Please sign in to comment.