Skip to content

Commit

Permalink
spec 1.0.4 + build
Browse files Browse the repository at this point in the history
  • Loading branch information
jeevnayak committed Mar 15, 2022
1 parent a41d007 commit c0bd324
Show file tree
Hide file tree
Showing 15 changed files with 588 additions and 19 deletions.
260 changes: 257 additions & 3 deletions api.ts

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* OpenAI API
* APIs for sampling from and fine-tuning language models
*
* The version of the OpenAPI document: 1.0.3
* The version of the OpenAPI document: 1.0.4
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* OpenAI API
* APIs for sampling from and fine-tuning language models
*
* The version of the OpenAPI document: 1.0.3
* The version of the OpenAPI document: 1.0.4
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
2 changes: 1 addition & 1 deletion configuration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* OpenAI API
* APIs for sampling from and fine-tuning language models
*
* The version of the OpenAPI document: 1.0.3
* The version of the OpenAPI document: 1.0.4
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down
187 changes: 184 additions & 3 deletions dist/api.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* OpenAI API
* APIs for sampling from and fine-tuning language models
*
* The version of the OpenAPI document: 1.0.3
* The version of the OpenAPI document: 1.0.4
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
Expand Down Expand Up @@ -361,7 +361,13 @@ export interface CreateCompletionFromModelRequest {
*/
'prompt'?: string | Array<string> | Array<number> | Array<any> | null;
/**
* The maximum number of [tokens](/tokenizer) to generate in the completion. The token count of your prompt plus `max_tokens` cannot exceed the model\'s context length. Most models have a context length of 2048 tokens (except `code-davinci-001`, which supports 4096).
* The suffix that comes after a completion of inserted text, encoded as a string or array of strings.
* @type {string | Array<string>}
* @memberof CreateCompletionFromModelRequest
*/
'suffix'?: string | Array<string> | null;
/**
* The maximum number of [tokens](/tokenizer) to generate in the completion. The token count of your prompt plus `max_tokens` cannot exceed the model\'s context length. Most models have a context length of 2048 tokens (except for the newest models, which support 4096).
* @type {number}
* @memberof CreateCompletionFromModelRequest
*/
Expand Down Expand Up @@ -471,7 +477,13 @@ export interface CreateCompletionRequest {
*/
'prompt'?: string | Array<string> | Array<number> | Array<any> | null;
/**
* The maximum number of [tokens](/tokenizer) to generate in the completion. The token count of your prompt plus `max_tokens` cannot exceed the model\'s context length. Most models have a context length of 2048 tokens (except `code-davinci-001`, which supports 4096).
* The suffix that comes after a completion of inserted text, encoded as a string or array of strings.
* @type {string | Array<string>}
* @memberof CreateCompletionRequest
*/
'suffix'?: string | Array<string> | null;
/**
* The maximum number of [tokens](/tokenizer) to generate in the completion. The token count of your prompt plus `max_tokens` cannot exceed the model\'s context length. Most models have a context length of 2048 tokens (except for the newest models, which support 4096).
* @type {number}
* @memberof CreateCompletionRequest
*/
Expand Down Expand Up @@ -648,6 +660,74 @@ export interface CreateCompletionResponseLogprobs {
*/
'text_offset'?: Array<number>;
}
/**
*
* @export
* @interface CreateEditRequest
*/
export interface CreateEditRequest {
/**
* The input text to use as a starting point for the edit.
* @type {string}
* @memberof CreateEditRequest
*/
'input'?: string | null;
/**
* The instruction that tells the model how to edit the prompt.
* @type {string}
* @memberof CreateEditRequest
*/
'instruction': string;
/**
* What [sampling temperature](https://towardsdatascience.com/how-to-sample-from-language-models-682bceb97277) to use. Higher values means the model will take more risks. Try 0.9 for more creative applications, and 0 (argmax sampling) for ones with a well-defined answer. We generally recommend altering this or `top_p` but not both.
* @type {number}
* @memberof CreateEditRequest
*/
'temperature'?: number | 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.
* @type {number}
* @memberof CreateEditRequest
*/
'top_p'?: number | null;
}
/**
*
* @export
* @interface CreateEditResponse
*/
export interface CreateEditResponse {
/**
*
* @type {string}
* @memberof CreateEditResponse
*/
'id'?: string;
/**
*
* @type {string}
* @memberof CreateEditResponse
*/
'object'?: string;
/**
*
* @type {number}
* @memberof CreateEditResponse
*/
'created'?: number;
/**
*
* @type {string}
* @memberof CreateEditResponse
*/
'model'?: string;
/**
*
* @type {Array<CreateCompletionResponseChoices>}
* @memberof CreateEditResponse
*/
'choices'?: Array<CreateCompletionResponseChoices>;
}
/**
*
* @export
Expand Down Expand Up @@ -789,6 +869,12 @@ export interface CreateFineTuneRequest {
* @memberof CreateFineTuneRequest
*/
'classification_betas'?: Array<number> | null;
/**
* A string of up to 40 characters that will be added to your fine-tuned model name. For example, a `suffix` of \"custom-model-name\" would produce a model name like `ada:ft-your-org:custom-model-name-2022-02-15-04-21-04`.
* @type {string}
* @memberof CreateFineTuneRequest
*/
'suffix'?: string | null;
}
/**
*
Expand Down Expand Up @@ -908,6 +994,31 @@ export interface DeleteFileResponse {
*/
'deleted'?: boolean;
}
/**
*
* @export
* @interface DeleteModelResponse
*/
export interface DeleteModelResponse {
/**
*
* @type {string}
* @memberof DeleteModelResponse
*/
'id'?: string;
/**
*
* @type {string}
* @memberof DeleteModelResponse
*/
'object'?: string;
/**
*
* @type {boolean}
* @memberof DeleteModelResponse
*/
'deleted'?: boolean;
}
/**
*
* @export
Expand Down Expand Up @@ -1232,6 +1343,15 @@ export declare const OpenAIApiAxiosParamCreator: (configuration?: Configuration)
* @throws {RequiredError}
*/
createCompletionFromModel: (createCompletionFromModelRequest: CreateCompletionFromModelRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
/**
*
* @summary Creates a new edit for the provided input, instruction, and parameters
* @param {string} engineId The ID of the engine to use for this request
* @param {CreateEditRequest} createEditRequest
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
createEdit: (engineId: string, createEditRequest: CreateEditRequest, options?: AxiosRequestConfig) => Promise<RequestArgs>;
/**
*
* @summary Creates an embedding vector representing the input text.
Expand Down Expand Up @@ -1275,6 +1395,14 @@ export declare const OpenAIApiAxiosParamCreator: (configuration?: Configuration)
* @throws {RequiredError}
*/
deleteFile: (fileId: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
/**
*
* @summary Delete a fine-tuned model. You must have the Owner role in your organization.
* @param {string} model The model to delete
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
deleteModel: (model: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
/**
*
* @summary Returns the contents of the specified file
Expand Down Expand Up @@ -1384,6 +1512,15 @@ export declare const OpenAIApiFp: (configuration?: Configuration) => {
* @throws {RequiredError}
*/
createCompletionFromModel(createCompletionFromModelRequest: CreateCompletionFromModelRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateCompletionResponse>>;
/**
*
* @summary Creates a new edit for the provided input, instruction, and parameters
* @param {string} engineId The ID of the engine to use for this request
* @param {CreateEditRequest} createEditRequest
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
createEdit(engineId: string, createEditRequest: CreateEditRequest, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateEditResponse>>;
/**
*
* @summary Creates an embedding vector representing the input text.
Expand Down Expand Up @@ -1427,6 +1564,14 @@ export declare const OpenAIApiFp: (configuration?: Configuration) => {
* @throws {RequiredError}
*/
deleteFile(fileId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DeleteFileResponse>>;
/**
*
* @summary Delete a fine-tuned model. You must have the Owner role in your organization.
* @param {string} model The model to delete
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
deleteModel(model: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DeleteModelResponse>>;
/**
*
* @summary Returns the contents of the specified file
Expand Down Expand Up @@ -1536,6 +1681,15 @@ export declare const OpenAIApiFactory: (configuration?: Configuration, basePath?
* @throws {RequiredError}
*/
createCompletionFromModel(createCompletionFromModelRequest: CreateCompletionFromModelRequest, options?: any): AxiosPromise<CreateCompletionResponse>;
/**
*
* @summary Creates a new edit for the provided input, instruction, and parameters
* @param {string} engineId The ID of the engine to use for this request
* @param {CreateEditRequest} createEditRequest
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
createEdit(engineId: string, createEditRequest: CreateEditRequest, options?: any): AxiosPromise<CreateEditResponse>;
/**
*
* @summary Creates an embedding vector representing the input text.
Expand Down Expand Up @@ -1579,6 +1733,14 @@ export declare const OpenAIApiFactory: (configuration?: Configuration, basePath?
* @throws {RequiredError}
*/
deleteFile(fileId: string, options?: any): AxiosPromise<DeleteFileResponse>;
/**
*
* @summary Delete a fine-tuned model. You must have the Owner role in your organization.
* @param {string} model The model to delete
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
deleteModel(model: string, options?: any): AxiosPromise<DeleteModelResponse>;
/**
*
* @summary Returns the contents of the specified file
Expand Down Expand Up @@ -1695,6 +1857,16 @@ export declare class OpenAIApi extends BaseAPI {
* @memberof OpenAIApi
*/
createCompletionFromModel(createCompletionFromModelRequest: CreateCompletionFromModelRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateCompletionResponse, any>>;
/**
*
* @summary Creates a new edit for the provided input, instruction, and parameters
* @param {string} engineId The ID of the engine to use for this request
* @param {CreateEditRequest} createEditRequest
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof OpenAIApi
*/
createEdit(engineId: string, createEditRequest: CreateEditRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateEditResponse, any>>;
/**
*
* @summary Creates an embedding vector representing the input text.
Expand Down Expand Up @@ -1743,6 +1915,15 @@ export declare class OpenAIApi extends BaseAPI {
* @memberof OpenAIApi
*/
deleteFile(fileId: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<DeleteFileResponse, any>>;
/**
*
* @summary Delete a fine-tuned model. You must have the Owner role in your organization.
* @param {string} model The model to delete
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof OpenAIApi
*/
deleteModel(model: string, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<DeleteModelResponse, any>>;
/**
*
* @summary Returns the contents of the specified file
Expand Down
Loading

0 comments on commit c0bd324

Please sign in to comment.