Skip to content

Commit 50206a0

Browse files
committed
docs: use @deprecated decorator for deprecated params (#711)
1 parent 0825acf commit 50206a0

File tree

2 files changed

+22
-16
lines changed

2 files changed

+22
-16
lines changed

Diff for: src/resources/chat/completions.ts

+18-12
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,8 @@ export interface ChatCompletionAssistantMessageParam {
133133
content?: string | null;
134134

135135
/**
136-
* Deprecated and replaced by `tool_calls`. The name and arguments of a function
137-
* that should be called, as generated by the model.
136+
* @deprecated: Deprecated and replaced by `tool_calls`. The name and arguments of
137+
* a function that should be called, as generated by the model.
138138
*/
139139
function_call?: ChatCompletionAssistantMessageParam.FunctionCall;
140140

@@ -152,8 +152,8 @@ export interface ChatCompletionAssistantMessageParam {
152152

153153
export namespace ChatCompletionAssistantMessageParam {
154154
/**
155-
* Deprecated and replaced by `tool_calls`. The name and arguments of a function
156-
* that should be called, as generated by the model.
155+
* @deprecated: Deprecated and replaced by `tool_calls`. The name and arguments of
156+
* a function that should be called, as generated by the model.
157157
*/
158158
export interface FunctionCall {
159159
/**
@@ -250,8 +250,8 @@ export namespace ChatCompletionChunk {
250250
content?: string | null;
251251

252252
/**
253-
* Deprecated and replaced by `tool_calls`. The name and arguments of a function
254-
* that should be called, as generated by the model.
253+
* @deprecated: Deprecated and replaced by `tool_calls`. The name and arguments of
254+
* a function that should be called, as generated by the model.
255255
*/
256256
function_call?: Delta.FunctionCall;
257257

@@ -265,8 +265,8 @@ export namespace ChatCompletionChunk {
265265

266266
export namespace Delta {
267267
/**
268-
* Deprecated and replaced by `tool_calls`. The name and arguments of a function
269-
* that should be called, as generated by the model.
268+
* @deprecated: Deprecated and replaced by `tool_calls`. The name and arguments of
269+
* a function that should be called, as generated by the model.
270270
*/
271271
export interface FunctionCall {
272272
/**
@@ -378,6 +378,9 @@ export interface ChatCompletionFunctionCallOption {
378378
name: string;
379379
}
380380

381+
/**
382+
* @deprecated
383+
*/
381384
export interface ChatCompletionFunctionMessageParam {
382385
/**
383386
* The contents of the function message.
@@ -410,8 +413,8 @@ export interface ChatCompletionMessage {
410413
role: 'assistant';
411414

412415
/**
413-
* Deprecated and replaced by `tool_calls`. The name and arguments of a function
414-
* that should be called, as generated by the model.
416+
* @deprecated: Deprecated and replaced by `tool_calls`. The name and arguments of
417+
* a function that should be called, as generated by the model.
415418
*/
416419
function_call?: ChatCompletionMessage.FunctionCall;
417420

@@ -423,8 +426,8 @@ export interface ChatCompletionMessage {
423426

424427
export namespace ChatCompletionMessage {
425428
/**
426-
* Deprecated and replaced by `tool_calls`. The name and arguments of a function
427-
* that should be called, as generated by the model.
429+
* @deprecated: Deprecated and replaced by `tool_calls`. The name and arguments of
430+
* a function that should be called, as generated by the model.
428431
*/
429432
export interface FunctionCall {
430433
/**
@@ -855,6 +858,9 @@ export interface ChatCompletionCreateParamsBase {
855858
}
856859

857860
export namespace ChatCompletionCreateParams {
861+
/**
862+
* @deprecated
863+
*/
858864
export interface Function {
859865
/**
860866
* The name of the function to be called. Must be a-z, A-Z, 0-9, or contain

Diff for: src/resources/files.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -154,14 +154,14 @@ export interface FileObject {
154154
purpose: 'fine-tune' | 'fine-tune-results' | 'assistants' | 'assistants_output';
155155

156156
/**
157-
* Deprecated. The current status of the file, which can be either `uploaded`,
158-
* `processed`, or `error`.
157+
* @deprecated: Deprecated. The current status of the file, which can be either
158+
* `uploaded`, `processed`, or `error`.
159159
*/
160160
status: 'uploaded' | 'processed' | 'error';
161161

162162
/**
163-
* Deprecated. For details on why a fine-tuning training file failed validation,
164-
* see the `error` field on `fine_tuning.job`.
163+
* @deprecated: Deprecated. For details on why a fine-tuning training file failed
164+
* validation, see the `error` field on `fine_tuning.job`.
165165
*/
166166
status_details?: string;
167167
}

0 commit comments

Comments
 (0)