diff --git a/client-sdks/stainless/openapi.yml b/client-sdks/stainless/openapi.yml index 4ffe1de17..e3d8c9fd1 100644 --- a/client-sdks/stainless/openapi.yml +++ b/client-sdks/stainless/openapi.yml @@ -5200,6 +5200,37 @@ components: type: object title: ChatCompletionInputType description: Parameter type for chat completion input. + Checkpoint: + properties: + identifier: + type: string + title: Identifier + created_at: + type: string + format: date-time + title: Created At + epoch: + type: integer + title: Epoch + post_training_job_id: + type: string + title: Post Training Job Id + path: + type: string + title: Path + training_metrics: + anyOf: + - $ref: '#/components/schemas/PostTrainingMetric' + - type: 'null' + type: object + required: + - identifier + - created_at + - epoch + - post_training_job_id + - path + title: Checkpoint + description: Checkpoint created during training runs. Chunk-Input: properties: content: @@ -5855,6 +5886,166 @@ components: - judge_model title: LLMAsJudgeScoringFnParams description: Parameters for LLM-as-judge scoring function configuration. + ListBatchesResponse: + properties: + object: + type: string + const: list + title: Object + default: list + data: + items: + $ref: '#/components/schemas/Batch' + type: array + title: Data + description: List of batch objects + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + description: ID of the first batch in the list + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + description: ID of the last batch in the list + has_more: + type: boolean + title: Has More + description: Whether there are more batches available + default: false + type: object + required: + - data + title: ListBatchesResponse + description: Response containing a list of batch objects. + ListOpenAIChatCompletionResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAICompletionWithInputMessages' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIChatCompletionResponse + description: Response from listing OpenAI-compatible chat completions. + ListOpenAIFileResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIFileObject' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIFileResponse + description: Response for listing files in OpenAI Files API. + ListOpenAIResponseInputItem: + properties: + data: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Data + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + title: ListOpenAIResponseInputItem + description: List container for OpenAI response input items. + ListOpenAIResponseObject: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIResponseObjectWithInput-Output' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIResponseObject + description: Paginated list of OpenAI response objects with navigation metadata. ListPostTrainingJobsResponse: properties: data: @@ -5890,6 +6081,30 @@ components: - data title: ListProvidersResponse description: Response containing a list of all available providers. + ListRoutesResponse: + properties: + data: + items: + $ref: '#/components/schemas/RouteInfo' + type: array + title: Data + type: object + required: + - data + title: ListRoutesResponse + description: Response containing a list of all available API routes. + ListToolDefsResponse: + properties: + data: + items: + $ref: '#/components/schemas/ToolDef' + type: array + title: Data + type: object + required: + - data + title: ListToolDefsResponse + description: Response containing a list of tool definitions. LoraFinetuningConfig: properties: type: @@ -7835,6 +8050,155 @@ components: - status title: OpenAIResponseObject description: Complete OpenAI response object containing generation results and metadata. + OpenAIResponseObjectWithInput-Output: + properties: + created_at: + type: integer + title: Created At + error: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseError' + - type: 'null' + id: + type: string + title: Id + model: + type: string + title: Model + object: + type: string + const: response + title: Object + default: response + output: + items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + type: array + title: Output + parallel_tool_calls: + type: boolean + title: Parallel Tool Calls + default: false + previous_response_id: + anyOf: + - type: string + - type: 'null' + title: Previous Response Id + prompt: + anyOf: + - $ref: '#/components/schemas/OpenAIResponsePrompt' + - type: 'null' + status: + type: string + title: Status + temperature: + anyOf: + - type: number + - type: 'null' + title: Temperature + text: + $ref: '#/components/schemas/OpenAIResponseText' + default: + format: + type: text + top_p: + anyOf: + - type: number + - type: 'null' + title: Top P + tools: + anyOf: + - items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseInputToolWebSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFileSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFunction' + - $ref: '#/components/schemas/OpenAIResponseToolMCP' + discriminator: + propertyName: type + mapping: + file_search: '#/components/schemas/OpenAIResponseInputToolFileSearch' + function: '#/components/schemas/OpenAIResponseInputToolFunction' + mcp: '#/components/schemas/OpenAIResponseToolMCP' + web_search: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_2025_08_26: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview_2025_03_11: '#/components/schemas/OpenAIResponseInputToolWebSearch' + type: array + - type: 'null' + title: Tools + truncation: + anyOf: + - type: string + - type: 'null' + title: Truncation + usage: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseUsage' + - type: 'null' + instructions: + anyOf: + - type: string + - type: 'null' + title: Instructions + max_tool_calls: + anyOf: + - type: integer + - type: 'null' + title: Max Tool Calls + input: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Input + type: object + required: + - created_at + - id + - model + - output + - status + - input + title: OpenAIResponseObjectWithInput + description: OpenAI response object extended with input context information. OpenAIResponseOutputMessageContentOutputText: properties: text: @@ -8400,6 +8764,28 @@ components: required: - reasoning_tokens title: OutputTokensDetails + PaginatedResponse: + properties: + data: + items: + additionalProperties: true + type: object + type: array + title: Data + has_more: + type: boolean + title: Has More + url: + anyOf: + - type: string + - type: 'null' + title: Url + type: object + required: + - data + - has_more + title: PaginatedResponse + description: A generic paginated response that follows a simple format. PostTrainingJob: properties: job_uuid: @@ -8409,6 +8795,85 @@ components: required: - job_uuid title: PostTrainingJob + PostTrainingJobArtifactsResponse: + properties: + job_uuid: + type: string + title: Job Uuid + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + title: PostTrainingJobArtifactsResponse + description: Artifacts of a finetuning job. + PostTrainingJobStatusResponse: + properties: + job_uuid: + type: string + title: Job Uuid + status: + $ref: '#/components/schemas/JobStatus' + scheduled_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Scheduled At + started_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Started At + completed_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Completed At + resources_allocated: + anyOf: + - additionalProperties: true + type: object + - type: 'null' + title: Resources Allocated + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + - status + title: PostTrainingJobStatusResponse + description: Status of a finetuning job. + PostTrainingMetric: + properties: + epoch: + type: integer + title: Epoch + train_loss: + type: number + title: Train Loss + validation_loss: + type: number + title: Validation Loss + perplexity: + type: number + title: Perplexity + type: object + required: + - epoch + - train_loss + - validation_loss + - perplexity + title: PostTrainingMetric + description: Training metrics captured during post-training jobs. Prompt: properties: prompt: @@ -8556,6 +9021,26 @@ components: - data title: RerankResponse description: Response from a reranking request. + RouteInfo: + properties: + route: + type: string + title: Route + method: + type: string + title: Method + provider_types: + items: + type: string + type: array + title: Provider Types + type: object + required: + - route + - method + - provider_types + title: RouteInfo + description: Information about an API route including its path, method, and implementing providers. RowsDataSource: properties: type: @@ -9359,6 +9844,96 @@ components: - vector_store_id title: VectorStoreFileObject description: OpenAI Vector Store File object. + VectorStoreFilesListInBatchResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreFilesListInBatchResponse + description: Response from listing files in a vector store file batch. + VectorStoreListFilesResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListFilesResponse + description: Response from listing files in a vector store. + VectorStoreListResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListResponse + description: Response from listing vector stores. VectorStoreObject: properties: id: @@ -13472,43 +14047,15 @@ components: - $ref: '#/components/schemas/UnstructuredLogEvent' - $ref: '#/components/schemas/MetricEvent' - $ref: '#/components/schemas/StructuredLogEvent' - ListOpenAIResponseInputItem: - description: List container for OpenAI response input items. + ResponseGuardrailSpec: + description: Specification for a guardrail to apply during response generation. properties: - data: - items: - anyOf: - - discriminator: - mapping: - file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - message: '#/components/schemas/OpenAIResponseMessage' - web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - propertyName: type - oneOf: - - $ref: '#/components/schemas/OpenAIResponseMessage' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' - - $ref: '#/components/schemas/OpenAIResponseMessage' - title: Data - type: array - object: - const: list - default: list - title: Object + type: + title: Type type: string required: - - data - title: ListOpenAIResponseInputItem + - type + title: ResponseGuardrailSpec type: object OpenAIResponseObjectWithInput: description: OpenAI response object extended with input context information. @@ -13669,82 +14216,6 @@ components: - input title: OpenAIResponseObjectWithInput type: object - ListOpenAIResponseObject: - description: Paginated list of OpenAI response objects with navigation metadata. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIResponseObjectWithInput' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIResponseObject - type: object - ResponseGuardrailSpec: - description: Specification for a guardrail to apply during response generation. - properties: - type: - title: Type - type: string - required: - - type - title: ResponseGuardrailSpec - type: object - ListBatchesResponse: - description: Response containing a list of batch objects. - properties: - object: - const: list - default: list - title: Object - type: string - data: - description: List of batch objects - items: - $ref: '#/components/schemas/Batch' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - description: ID of the first batch in the list - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - description: ID of the last batch in the list - title: Last Id - nullable: true - has_more: - default: false - description: Whether there are more batches available - title: Has More - type: boolean - required: - - data - title: ListBatchesResponse - type: object MetricInResponse: description: A metric value included in API responses. properties: @@ -13767,83 +14238,6 @@ components: - value title: MetricInResponse type: object - PaginatedResponse: - description: A generic paginated response that follows a simple format. - properties: - data: - items: - additionalProperties: true - type: object - title: Data - type: array - has_more: - title: Has More - type: boolean - url: - anyOf: - - type: string - - type: 'null' - title: Url - nullable: true - required: - - data - - has_more - title: PaginatedResponse - type: object - PostTrainingMetric: - description: Training metrics captured during post-training jobs. - properties: - epoch: - title: Epoch - type: integer - train_loss: - title: Train Loss - type: number - validation_loss: - title: Validation Loss - type: number - perplexity: - title: Perplexity - type: number - required: - - epoch - - train_loss - - validation_loss - - perplexity - title: PostTrainingMetric - type: object - Checkpoint: - description: Checkpoint created during training runs. - properties: - identifier: - title: Identifier - type: string - created_at: - format: date-time - title: Created At - type: string - epoch: - title: Epoch - type: integer - post_training_job_id: - title: Post Training Job Id - type: string - path: - title: Path - type: string - training_metrics: - anyOf: - - $ref: '#/components/schemas/PostTrainingMetric' - - type: 'null' - nullable: true - required: - - identifier - - created_at - - epoch - - post_training_job_id - - path - title: Checkpoint - type: object DialogType: description: Parameter type for dialog data with semantic output labels. properties: @@ -13928,35 +14322,6 @@ components: - status title: ConversationMessage type: object - ListOpenAIFileResponse: - description: Response for listing files in OpenAI Files API. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIFileObject' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIFileResponse - type: object Bf16QuantizationConfig: description: Configuration for BFloat16 precision (typically no quantization). properties: @@ -14007,92 +14372,6 @@ components: title: Scheme title: Int4QuantizationConfig type: object - OpenAIChoice: - description: A choice from an OpenAI-compatible chat completion response. - properties: - message: - discriminator: - mapping: - assistant: '#/components/schemas/OpenAIAssistantMessageParam' - developer: '#/components/schemas/OpenAIDeveloperMessageParam' - system: '#/components/schemas/OpenAISystemMessageParam' - tool: '#/components/schemas/OpenAIToolMessageParam' - user: '#/components/schemas/OpenAIUserMessageParam' - propertyName: role - oneOf: - - $ref: '#/components/schemas/OpenAIUserMessageParam' - - $ref: '#/components/schemas/OpenAISystemMessageParam' - - $ref: '#/components/schemas/OpenAIAssistantMessageParam' - - $ref: '#/components/schemas/OpenAIToolMessageParam' - - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' - title: Message - finish_reason: - title: Finish Reason - type: string - index: - title: Index - type: integer - logprobs: - anyOf: - - $ref: '#/components/schemas/OpenAIChoiceLogprobs' - - type: 'null' - nullable: true - required: - - message - - finish_reason - - index - title: OpenAIChoice - type: object - OpenAIChoiceLogprobs: - description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. - properties: - content: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Content - nullable: true - refusal: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Refusal - nullable: true - title: OpenAIChoiceLogprobs - type: object - ListOpenAIChatCompletionResponse: - description: Response from listing OpenAI-compatible chat completions. - properties: - data: - items: - $ref: '#/components/schemas/OpenAICompletionWithInputMessages' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIChatCompletionResponse - type: object OpenAIChoiceDelta: description: A delta from an OpenAI-compatible chat completion streaming response. properties: @@ -14130,6 +14409,27 @@ components: nullable: true title: OpenAIChoiceDelta type: object + OpenAIChoiceLogprobs: + description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. + properties: + content: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Content + nullable: true + refusal: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Refusal + nullable: true + title: OpenAIChoiceLogprobs + type: object OpenAIChunkChoice: description: A chunk choice from an OpenAI-compatible chat completion streaming response. properties: @@ -14186,6 +14486,42 @@ components: - model title: OpenAIChatCompletionChunk type: object + OpenAIChoice: + description: A choice from an OpenAI-compatible chat completion response. + properties: + message: + discriminator: + mapping: + assistant: '#/components/schemas/OpenAIAssistantMessageParam' + developer: '#/components/schemas/OpenAIDeveloperMessageParam' + system: '#/components/schemas/OpenAISystemMessageParam' + tool: '#/components/schemas/OpenAIToolMessageParam' + user: '#/components/schemas/OpenAIUserMessageParam' + propertyName: role + oneOf: + - $ref: '#/components/schemas/OpenAIUserMessageParam' + - $ref: '#/components/schemas/OpenAISystemMessageParam' + - $ref: '#/components/schemas/OpenAIAssistantMessageParam' + - $ref: '#/components/schemas/OpenAIToolMessageParam' + - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' + title: Message + finish_reason: + title: Finish Reason + type: string + index: + title: Index + type: integer + logprobs: + anyOf: + - $ref: '#/components/schemas/OpenAIChoiceLogprobs' + - type: 'null' + nullable: true + required: + - message + - finish_reason + - index + title: OpenAIChoice + type: object OpenAICompletionChoice: description: |- A choice from an OpenAI-compatible completion response. @@ -14368,53 +14704,6 @@ components: - content title: UserMessage type: object - RouteInfo: - description: Information about an API route including its path, method, and implementing providers. - properties: - route: - title: Route - type: string - method: - title: Method - type: string - provider_types: - items: - type: string - title: Provider Types - type: array - required: - - route - - method - - provider_types - title: RouteInfo - type: object - ListRoutesResponse: - description: Response containing a list of all available API routes. - properties: - data: - items: - $ref: '#/components/schemas/RouteInfo' - title: Data - type: array - required: - - data - title: ListRoutesResponse - type: object - PostTrainingJobArtifactsResponse: - description: Artifacts of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - title: PostTrainingJobArtifactsResponse - type: object PostTrainingJobLogStream: description: Stream of logs from a finetuning job. properties: @@ -14431,52 +14720,6 @@ components: - log_lines title: PostTrainingJobLogStream type: object - PostTrainingJobStatusResponse: - description: Status of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - status: - $ref: '#/components/schemas/JobStatus' - scheduled_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Scheduled At - nullable: true - started_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Started At - nullable: true - completed_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Completed At - nullable: true - resources_allocated: - anyOf: - - additionalProperties: true - type: object - - type: 'null' - title: Resources Allocated - nullable: true - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - - status - title: PostTrainingJobStatusResponse - type: object RLHFAlgorithm: description: Available reinforcement learning from human feedback algorithms. enum: @@ -14690,18 +14933,6 @@ components: title: PostTrainingRLHFRequest >>>>>>> ceca36b91 (chore: regen scehma with main) type: object - ListToolDefsResponse: - description: Response containing a list of tool definitions. - properties: - data: - items: - $ref: '#/components/schemas/ToolDef' - title: Data - type: array - required: - - data - title: ListToolDefsResponse - type: object ToolGroupInput: description: Input data for registering a tool group. properties: @@ -14812,102 +15043,6 @@ components: type: object title: VectorStoreCreateRequest type: object - VectorStoreFilesListInBatchResponse: - description: Response from listing files in a vector store file batch. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreFilesListInBatchResponse - type: object - VectorStoreListFilesResponse: - description: Response from listing files in a vector store. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListFilesResponse - type: object - VectorStoreListResponse: - description: Response from listing vector stores. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListResponse - type: object VectorStoreModifyRequest: description: Request to modify a vector store. properties: diff --git a/docs/static/deprecated-llama-stack-spec.yaml b/docs/static/deprecated-llama-stack-spec.yaml index e1256e922..eb041b243 100644 --- a/docs/static/deprecated-llama-stack-spec.yaml +++ b/docs/static/deprecated-llama-stack-spec.yaml @@ -1182,6 +1182,37 @@ components: type: object title: ChatCompletionInputType description: Parameter type for chat completion input. + Checkpoint: + properties: + identifier: + type: string + title: Identifier + created_at: + type: string + format: date-time + title: Created At + epoch: + type: integer + title: Epoch + post_training_job_id: + type: string + title: Post Training Job Id + path: + type: string + title: Path + training_metrics: + anyOf: + - $ref: '#/components/schemas/PostTrainingMetric' + - type: 'null' + type: object + required: + - identifier + - created_at + - epoch + - post_training_job_id + - path + title: Checkpoint + description: Checkpoint created during training runs. Chunk-Input: properties: content: @@ -1837,6 +1868,41 @@ components: - judge_model title: LLMAsJudgeScoringFnParams description: Parameters for LLM-as-judge scoring function configuration. + ListBatchesResponse: + properties: + object: + type: string + const: list + title: Object + default: list + data: + items: + $ref: '#/components/schemas/Batch' + type: array + title: Data + description: List of batch objects + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + description: ID of the first batch in the list + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + description: ID of the last batch in the list + has_more: + type: boolean + title: Has More + description: Whether there are more batches available + default: false + type: object + required: + - data + title: ListBatchesResponse + description: Response containing a list of batch objects. ListBenchmarksResponse: properties: data: @@ -1860,6 +1926,131 @@ components: - data title: ListDatasetsResponse description: Response from listing datasets. + ListOpenAIChatCompletionResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAICompletionWithInputMessages' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIChatCompletionResponse + description: Response from listing OpenAI-compatible chat completions. + ListOpenAIFileResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIFileObject' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIFileResponse + description: Response for listing files in OpenAI Files API. + ListOpenAIResponseInputItem: + properties: + data: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Data + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + title: ListOpenAIResponseInputItem + description: List container for OpenAI response input items. + ListOpenAIResponseObject: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIResponseObjectWithInput-Output' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIResponseObject + description: Paginated list of OpenAI response objects with navigation metadata. ListPostTrainingJobsResponse: properties: data: @@ -1895,6 +2086,18 @@ components: - data title: ListProvidersResponse description: Response containing a list of all available providers. + ListRoutesResponse: + properties: + data: + items: + $ref: '#/components/schemas/RouteInfo' + type: array + title: Data + type: object + required: + - data + title: ListRoutesResponse + description: Response containing a list of all available API routes. ListScoringFunctionsResponse: properties: data: @@ -1917,6 +2120,18 @@ components: required: - data title: ListShieldsResponse + ListToolDefsResponse: + properties: + data: + items: + $ref: '#/components/schemas/ToolDef' + type: array + title: Data + type: object + required: + - data + title: ListToolDefsResponse + description: Response containing a list of tool definitions. ListToolGroupsResponse: properties: data: @@ -3967,6 +4182,304 @@ components: - status title: OpenAIResponseObject description: Complete OpenAI response object containing generation results and metadata. + OpenAIResponseObjectWithInput-Input: + properties: + created_at: + type: integer + title: Created At + error: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseError' + - type: 'null' + id: + type: string + title: Id + model: + type: string + title: Model + object: + type: string + const: response + title: Object + default: response + output: + items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Input' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Input' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + type: array + title: Output + parallel_tool_calls: + type: boolean + title: Parallel Tool Calls + default: false + previous_response_id: + anyOf: + - type: string + - type: 'null' + title: Previous Response Id + prompt: + anyOf: + - $ref: '#/components/schemas/OpenAIResponsePrompt' + - type: 'null' + status: + type: string + title: Status + temperature: + anyOf: + - type: number + - type: 'null' + title: Temperature + text: + $ref: '#/components/schemas/OpenAIResponseText' + default: + format: + type: text + top_p: + anyOf: + - type: number + - type: 'null' + title: Top P + tools: + anyOf: + - items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseInputToolWebSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFileSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFunction' + - $ref: '#/components/schemas/OpenAIResponseToolMCP' + discriminator: + propertyName: type + mapping: + file_search: '#/components/schemas/OpenAIResponseInputToolFileSearch' + function: '#/components/schemas/OpenAIResponseInputToolFunction' + mcp: '#/components/schemas/OpenAIResponseToolMCP' + web_search: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_2025_08_26: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview_2025_03_11: '#/components/schemas/OpenAIResponseInputToolWebSearch' + type: array + - type: 'null' + title: Tools + truncation: + anyOf: + - type: string + - type: 'null' + title: Truncation + usage: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseUsage' + - type: 'null' + instructions: + anyOf: + - type: string + - type: 'null' + title: Instructions + max_tool_calls: + anyOf: + - type: integer + - type: 'null' + title: Max Tool Calls + input: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Input' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Input' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Input' + type: array + title: Input + type: object + required: + - created_at + - id + - model + - output + - status + - input + title: OpenAIResponseObjectWithInput + description: OpenAI response object extended with input context information. + OpenAIResponseObjectWithInput-Output: + properties: + created_at: + type: integer + title: Created At + error: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseError' + - type: 'null' + id: + type: string + title: Id + model: + type: string + title: Model + object: + type: string + const: response + title: Object + default: response + output: + items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + type: array + title: Output + parallel_tool_calls: + type: boolean + title: Parallel Tool Calls + default: false + previous_response_id: + anyOf: + - type: string + - type: 'null' + title: Previous Response Id + prompt: + anyOf: + - $ref: '#/components/schemas/OpenAIResponsePrompt' + - type: 'null' + status: + type: string + title: Status + temperature: + anyOf: + - type: number + - type: 'null' + title: Temperature + text: + $ref: '#/components/schemas/OpenAIResponseText' + default: + format: + type: text + top_p: + anyOf: + - type: number + - type: 'null' + title: Top P + tools: + anyOf: + - items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseInputToolWebSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFileSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFunction' + - $ref: '#/components/schemas/OpenAIResponseToolMCP' + discriminator: + propertyName: type + mapping: + file_search: '#/components/schemas/OpenAIResponseInputToolFileSearch' + function: '#/components/schemas/OpenAIResponseInputToolFunction' + mcp: '#/components/schemas/OpenAIResponseToolMCP' + web_search: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_2025_08_26: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview_2025_03_11: '#/components/schemas/OpenAIResponseInputToolWebSearch' + type: array + - type: 'null' + title: Tools + truncation: + anyOf: + - type: string + - type: 'null' + title: Truncation + usage: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseUsage' + - type: 'null' + instructions: + anyOf: + - type: string + - type: 'null' + title: Instructions + max_tool_calls: + anyOf: + - type: integer + - type: 'null' + title: Max Tool Calls + input: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Input + type: object + required: + - created_at + - id + - model + - output + - status + - input + title: OpenAIResponseObjectWithInput + description: OpenAI response object extended with input context information. OpenAIResponseOutputMessageContentOutputText: properties: text: @@ -4532,6 +5045,28 @@ components: required: - reasoning_tokens title: OutputTokensDetails + PaginatedResponse: + properties: + data: + items: + additionalProperties: true + type: object + type: array + title: Data + has_more: + type: boolean + title: Has More + url: + anyOf: + - type: string + - type: 'null' + title: Url + type: object + required: + - data + - has_more + title: PaginatedResponse + description: A generic paginated response that follows a simple format. PostTrainingJob: properties: job_uuid: @@ -4541,6 +5076,85 @@ components: required: - job_uuid title: PostTrainingJob + PostTrainingJobArtifactsResponse: + properties: + job_uuid: + type: string + title: Job Uuid + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + title: PostTrainingJobArtifactsResponse + description: Artifacts of a finetuning job. + PostTrainingJobStatusResponse: + properties: + job_uuid: + type: string + title: Job Uuid + status: + $ref: '#/components/schemas/JobStatus' + scheduled_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Scheduled At + started_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Started At + completed_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Completed At + resources_allocated: + anyOf: + - additionalProperties: true + type: object + - type: 'null' + title: Resources Allocated + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + - status + title: PostTrainingJobStatusResponse + description: Status of a finetuning job. + PostTrainingMetric: + properties: + epoch: + type: integer + title: Epoch + train_loss: + type: number + title: Train Loss + validation_loss: + type: number + title: Validation Loss + perplexity: + type: number + title: Perplexity + type: object + required: + - epoch + - train_loss + - validation_loss + - perplexity + title: PostTrainingMetric + description: Training metrics captured during post-training jobs. Prompt: properties: prompt: @@ -4688,6 +5302,26 @@ components: - data title: RerankResponse description: Response from a reranking request. + RouteInfo: + properties: + route: + type: string + title: Route + method: + type: string + title: Method + provider_types: + items: + type: string + type: array + title: Provider Types + type: object + required: + - route + - method + - provider_types + title: RouteInfo + description: Information about an API route including its path, method, and implementing providers. RowsDataSource: properties: type: @@ -5491,6 +6125,96 @@ components: - vector_store_id title: VectorStoreFileObject description: OpenAI Vector Store File object. + VectorStoreFilesListInBatchResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreFilesListInBatchResponse + description: Response from listing files in a vector store file batch. + VectorStoreListFilesResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListFilesResponse + description: Response from listing files in a vector store. + VectorStoreListResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListResponse + description: Response from listing vector stores. VectorStoreObject: properties: id: @@ -8253,43 +8977,15 @@ components: - $ref: '#/components/schemas/UnstructuredLogEvent' - $ref: '#/components/schemas/MetricEvent' - $ref: '#/components/schemas/StructuredLogEvent' - ListOpenAIResponseInputItem: - description: List container for OpenAI response input items. + ResponseGuardrailSpec: + description: Specification for a guardrail to apply during response generation. properties: - data: - items: - anyOf: - - discriminator: - mapping: - file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - message: '#/components/schemas/OpenAIResponseMessage' - web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - propertyName: type - oneOf: - - $ref: '#/components/schemas/OpenAIResponseMessage' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' - - $ref: '#/components/schemas/OpenAIResponseMessage' - title: Data - type: array - object: - const: list - default: list - title: Object + type: + title: Type type: string required: - - data - title: ListOpenAIResponseInputItem + - type + title: ResponseGuardrailSpec type: object OpenAIResponseObjectWithInput: description: OpenAI response object extended with input context information. @@ -8450,82 +9146,6 @@ components: - input title: OpenAIResponseObjectWithInput type: object - ListOpenAIResponseObject: - description: Paginated list of OpenAI response objects with navigation metadata. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIResponseObjectWithInput' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIResponseObject - type: object - ResponseGuardrailSpec: - description: Specification for a guardrail to apply during response generation. - properties: - type: - title: Type - type: string - required: - - type - title: ResponseGuardrailSpec - type: object - ListBatchesResponse: - description: Response containing a list of batch objects. - properties: - object: - const: list - default: list - title: Object - type: string - data: - description: List of batch objects - items: - $ref: '#/components/schemas/Batch' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - description: ID of the first batch in the list - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - description: ID of the last batch in the list - title: Last Id - nullable: true - has_more: - default: false - description: Whether there are more batches available - title: Has More - type: boolean - required: - - data - title: ListBatchesResponse - type: object MetricInResponse: description: A metric value included in API responses. properties: @@ -8548,83 +9168,6 @@ components: - value title: MetricInResponse type: object - PaginatedResponse: - description: A generic paginated response that follows a simple format. - properties: - data: - items: - additionalProperties: true - type: object - title: Data - type: array - has_more: - title: Has More - type: boolean - url: - anyOf: - - type: string - - type: 'null' - title: Url - nullable: true - required: - - data - - has_more - title: PaginatedResponse - type: object - PostTrainingMetric: - description: Training metrics captured during post-training jobs. - properties: - epoch: - title: Epoch - type: integer - train_loss: - title: Train Loss - type: number - validation_loss: - title: Validation Loss - type: number - perplexity: - title: Perplexity - type: number - required: - - epoch - - train_loss - - validation_loss - - perplexity - title: PostTrainingMetric - type: object - Checkpoint: - description: Checkpoint created during training runs. - properties: - identifier: - title: Identifier - type: string - created_at: - format: date-time - title: Created At - type: string - epoch: - title: Epoch - type: integer - post_training_job_id: - title: Post Training Job Id - type: string - path: - title: Path - type: string - training_metrics: - anyOf: - - $ref: '#/components/schemas/PostTrainingMetric' - - type: 'null' - nullable: true - required: - - identifier - - created_at - - epoch - - post_training_job_id - - path - title: Checkpoint - type: object DialogType: description: Parameter type for dialog data with semantic output labels. properties: @@ -8709,35 +9252,6 @@ components: - status title: ConversationMessage type: object - ListOpenAIFileResponse: - description: Response for listing files in OpenAI Files API. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIFileObject' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIFileResponse - type: object Bf16QuantizationConfig: description: Configuration for BFloat16 precision (typically no quantization). properties: @@ -8788,92 +9302,6 @@ components: title: Scheme title: Int4QuantizationConfig type: object - OpenAIChoice: - description: A choice from an OpenAI-compatible chat completion response. - properties: - message: - discriminator: - mapping: - assistant: '#/components/schemas/OpenAIAssistantMessageParam' - developer: '#/components/schemas/OpenAIDeveloperMessageParam' - system: '#/components/schemas/OpenAISystemMessageParam' - tool: '#/components/schemas/OpenAIToolMessageParam' - user: '#/components/schemas/OpenAIUserMessageParam' - propertyName: role - oneOf: - - $ref: '#/components/schemas/OpenAIUserMessageParam' - - $ref: '#/components/schemas/OpenAISystemMessageParam' - - $ref: '#/components/schemas/OpenAIAssistantMessageParam' - - $ref: '#/components/schemas/OpenAIToolMessageParam' - - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' - title: Message - finish_reason: - title: Finish Reason - type: string - index: - title: Index - type: integer - logprobs: - anyOf: - - $ref: '#/components/schemas/OpenAIChoiceLogprobs' - - type: 'null' - nullable: true - required: - - message - - finish_reason - - index - title: OpenAIChoice - type: object - OpenAIChoiceLogprobs: - description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. - properties: - content: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Content - nullable: true - refusal: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Refusal - nullable: true - title: OpenAIChoiceLogprobs - type: object - ListOpenAIChatCompletionResponse: - description: Response from listing OpenAI-compatible chat completions. - properties: - data: - items: - $ref: '#/components/schemas/OpenAICompletionWithInputMessages' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIChatCompletionResponse - type: object OpenAIChoiceDelta: description: A delta from an OpenAI-compatible chat completion streaming response. properties: @@ -8911,6 +9339,27 @@ components: nullable: true title: OpenAIChoiceDelta type: object + OpenAIChoiceLogprobs: + description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. + properties: + content: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Content + nullable: true + refusal: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Refusal + nullable: true + title: OpenAIChoiceLogprobs + type: object OpenAIChunkChoice: description: A chunk choice from an OpenAI-compatible chat completion streaming response. properties: @@ -8967,6 +9416,42 @@ components: - model title: OpenAIChatCompletionChunk type: object + OpenAIChoice: + description: A choice from an OpenAI-compatible chat completion response. + properties: + message: + discriminator: + mapping: + assistant: '#/components/schemas/OpenAIAssistantMessageParam' + developer: '#/components/schemas/OpenAIDeveloperMessageParam' + system: '#/components/schemas/OpenAISystemMessageParam' + tool: '#/components/schemas/OpenAIToolMessageParam' + user: '#/components/schemas/OpenAIUserMessageParam' + propertyName: role + oneOf: + - $ref: '#/components/schemas/OpenAIUserMessageParam' + - $ref: '#/components/schemas/OpenAISystemMessageParam' + - $ref: '#/components/schemas/OpenAIAssistantMessageParam' + - $ref: '#/components/schemas/OpenAIToolMessageParam' + - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' + title: Message + finish_reason: + title: Finish Reason + type: string + index: + title: Index + type: integer + logprobs: + anyOf: + - $ref: '#/components/schemas/OpenAIChoiceLogprobs' + - type: 'null' + nullable: true + required: + - message + - finish_reason + - index + title: OpenAIChoice + type: object OpenAICompletionChoice: description: |- A choice from an OpenAI-compatible completion response. @@ -9149,53 +9634,6 @@ components: - content title: UserMessage type: object - RouteInfo: - description: Information about an API route including its path, method, and implementing providers. - properties: - route: - title: Route - type: string - method: - title: Method - type: string - provider_types: - items: - type: string - title: Provider Types - type: array - required: - - route - - method - - provider_types - title: RouteInfo - type: object - ListRoutesResponse: - description: Response containing a list of all available API routes. - properties: - data: - items: - $ref: '#/components/schemas/RouteInfo' - title: Data - type: array - required: - - data - title: ListRoutesResponse - type: object - PostTrainingJobArtifactsResponse: - description: Artifacts of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - title: PostTrainingJobArtifactsResponse - type: object PostTrainingJobLogStream: description: Stream of logs from a finetuning job. properties: @@ -9212,52 +9650,6 @@ components: - log_lines title: PostTrainingJobLogStream type: object - PostTrainingJobStatusResponse: - description: Status of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - status: - $ref: '#/components/schemas/JobStatus' - scheduled_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Scheduled At - nullable: true - started_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Started At - nullable: true - completed_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Completed At - nullable: true - resources_allocated: - anyOf: - - additionalProperties: true - type: object - - type: 'null' - title: Resources Allocated - nullable: true - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - - status - title: PostTrainingJobStatusResponse - type: object RLHFAlgorithm: description: Available reinforcement learning from human feedback algorithms. enum: @@ -9307,18 +9699,6 @@ components: - logger_config title: PostTrainingRLHFRequest type: object - ListToolDefsResponse: - description: Response containing a list of tool definitions. - properties: - data: - items: - $ref: '#/components/schemas/ToolDef' - title: Data - type: array - required: - - data - title: ListToolDefsResponse - type: object ToolGroupInput: description: Input data for registering a tool group. properties: @@ -9429,102 +9809,6 @@ components: type: object title: VectorStoreCreateRequest type: object - VectorStoreFilesListInBatchResponse: - description: Response from listing files in a vector store file batch. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreFilesListInBatchResponse - type: object - VectorStoreListFilesResponse: - description: Response from listing files in a vector store. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListFilesResponse - type: object - VectorStoreListResponse: - description: Response from listing vector stores. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListResponse - type: object VectorStoreModifyRequest: description: Request to modify a vector store. properties: diff --git a/docs/static/experimental-llama-stack-spec.yaml b/docs/static/experimental-llama-stack-spec.yaml index 0ae55f135..30bd2a5ad 100644 --- a/docs/static/experimental-llama-stack-spec.yaml +++ b/docs/static/experimental-llama-stack-spec.yaml @@ -145,6 +145,65 @@ paths: default: $ref: '#/components/responses/DefaultError' description: Default Response + /v1beta/datasets/{dataset_id}: + get: + tags: + - Datasets + summary: Get Dataset + description: Get a dataset by its ID. + operationId: get_dataset_v1beta_datasets__dataset_id__get + responses: + '200': + description: A Dataset. + content: + application/json: + schema: + $ref: '#/components/schemas/Dataset' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' + parameters: + - name: dataset_id + in: path + required: true + schema: + type: string + description: 'Path parameter: dataset_id' + /v1beta/datasets: + get: + tags: + - Datasets + summary: List Datasets + description: List all datasets. + operationId: list_datasets_v1beta_datasets_get + responses: + '200': + description: A ListDatasetsResponse. + content: + application/json: + schema: + $ref: '#/components/schemas/ListDatasetsResponse' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' /v1alpha/eval/benchmarks/{benchmark_id}/evaluations: post: tags: @@ -338,6 +397,65 @@ paths: schema: type: string description: 'Path parameter: benchmark_id' + /v1alpha/eval/benchmarks/{benchmark_id}: + get: + tags: + - Benchmarks + summary: Get Benchmark + description: Get a benchmark by its ID. + operationId: get_benchmark_v1alpha_eval_benchmarks__benchmark_id__get + responses: + '200': + description: A Benchmark. + content: + application/json: + schema: + $ref: '#/components/schemas/Benchmark' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' + parameters: + - name: benchmark_id + in: path + required: true + schema: + type: string + description: 'Path parameter: benchmark_id' + /v1alpha/eval/benchmarks: + get: + tags: + - Benchmarks + summary: List Benchmarks + description: List all benchmarks. + operationId: list_benchmarks_v1alpha_eval_benchmarks_get + responses: + '200': + description: A ListBenchmarksResponse. + content: + application/json: + schema: + $ref: '#/components/schemas/ListBenchmarksResponse' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response /v1alpha/post-training/job/cancel: post: tags: @@ -872,6 +990,37 @@ components: type: object title: ChatCompletionInputType description: Parameter type for chat completion input. + Checkpoint: + properties: + identifier: + type: string + title: Identifier + created_at: + type: string + format: date-time + title: Created At + epoch: + type: integer + title: Epoch + post_training_job_id: + type: string + title: Post Training Job Id + path: + type: string + title: Path + training_metrics: + anyOf: + - $ref: '#/components/schemas/PostTrainingMetric' + - type: 'null' + type: object + required: + - identifier + - created_at + - epoch + - post_training_job_id + - path + title: Checkpoint + description: Checkpoint created during training runs. Chunk-Output: properties: content: @@ -1467,6 +1616,189 @@ components: - judge_model title: LLMAsJudgeScoringFnParams description: Parameters for LLM-as-judge scoring function configuration. + ListBatchesResponse: + properties: + object: + type: string + const: list + title: Object + default: list + data: + items: + $ref: '#/components/schemas/Batch' + type: array + title: Data + description: List of batch objects + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + description: ID of the first batch in the list + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + description: ID of the last batch in the list + has_more: + type: boolean + title: Has More + description: Whether there are more batches available + default: false + type: object + required: + - data + title: ListBatchesResponse + description: Response containing a list of batch objects. + ListBenchmarksResponse: + properties: + data: + items: + $ref: '#/components/schemas/Benchmark' + type: array + title: Data + type: object + required: + - data + title: ListBenchmarksResponse + ListDatasetsResponse: + properties: + data: + items: + $ref: '#/components/schemas/Dataset' + type: array + title: Data + type: object + required: + - data + title: ListDatasetsResponse + description: Response from listing datasets. + ListOpenAIChatCompletionResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAICompletionWithInputMessages' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIChatCompletionResponse + description: Response from listing OpenAI-compatible chat completions. + ListOpenAIFileResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIFileObject' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIFileResponse + description: Response for listing files in OpenAI Files API. + ListOpenAIResponseInputItem: + properties: + data: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Data + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + title: ListOpenAIResponseInputItem + description: List container for OpenAI response input items. + ListOpenAIResponseObject: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIResponseObjectWithInput-Output' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIResponseObject + description: Paginated list of OpenAI response objects with navigation metadata. ListPostTrainingJobsResponse: properties: data: @@ -1478,6 +1810,30 @@ components: required: - data title: ListPostTrainingJobsResponse + ListRoutesResponse: + properties: + data: + items: + $ref: '#/components/schemas/RouteInfo' + type: array + title: Data + type: object + required: + - data + title: ListRoutesResponse + description: Response containing a list of all available API routes. + ListToolDefsResponse: + properties: + data: + items: + $ref: '#/components/schemas/ToolDef' + type: array + title: Data + type: object + required: + - data + title: ListToolDefsResponse + description: Response containing a list of tool definitions. LoraFinetuningConfig: properties: type: @@ -3359,6 +3715,155 @@ components: - status title: OpenAIResponseObject description: Complete OpenAI response object containing generation results and metadata. + OpenAIResponseObjectWithInput-Output: + properties: + created_at: + type: integer + title: Created At + error: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseError' + - type: 'null' + id: + type: string + title: Id + model: + type: string + title: Model + object: + type: string + const: response + title: Object + default: response + output: + items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + type: array + title: Output + parallel_tool_calls: + type: boolean + title: Parallel Tool Calls + default: false + previous_response_id: + anyOf: + - type: string + - type: 'null' + title: Previous Response Id + prompt: + anyOf: + - $ref: '#/components/schemas/OpenAIResponsePrompt' + - type: 'null' + status: + type: string + title: Status + temperature: + anyOf: + - type: number + - type: 'null' + title: Temperature + text: + $ref: '#/components/schemas/OpenAIResponseText' + default: + format: + type: text + top_p: + anyOf: + - type: number + - type: 'null' + title: Top P + tools: + anyOf: + - items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseInputToolWebSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFileSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFunction' + - $ref: '#/components/schemas/OpenAIResponseToolMCP' + discriminator: + propertyName: type + mapping: + file_search: '#/components/schemas/OpenAIResponseInputToolFileSearch' + function: '#/components/schemas/OpenAIResponseInputToolFunction' + mcp: '#/components/schemas/OpenAIResponseToolMCP' + web_search: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_2025_08_26: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview_2025_03_11: '#/components/schemas/OpenAIResponseInputToolWebSearch' + type: array + - type: 'null' + title: Tools + truncation: + anyOf: + - type: string + - type: 'null' + title: Truncation + usage: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseUsage' + - type: 'null' + instructions: + anyOf: + - type: string + - type: 'null' + title: Instructions + max_tool_calls: + anyOf: + - type: integer + - type: 'null' + title: Max Tool Calls + input: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Input + type: object + required: + - created_at + - id + - model + - output + - status + - input + title: OpenAIResponseObjectWithInput + description: OpenAI response object extended with input context information. OpenAIResponseOutputMessageContentOutputText: properties: text: @@ -3917,6 +4422,28 @@ components: required: - reasoning_tokens title: OutputTokensDetails + PaginatedResponse: + properties: + data: + items: + additionalProperties: true + type: object + type: array + title: Data + has_more: + type: boolean + title: Has More + url: + anyOf: + - type: string + - type: 'null' + title: Url + type: object + required: + - data + - has_more + title: PaginatedResponse + description: A generic paginated response that follows a simple format. PostTrainingJob: properties: job_uuid: @@ -3926,6 +4453,85 @@ components: required: - job_uuid title: PostTrainingJob + PostTrainingJobArtifactsResponse: + properties: + job_uuid: + type: string + title: Job Uuid + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + title: PostTrainingJobArtifactsResponse + description: Artifacts of a finetuning job. + PostTrainingJobStatusResponse: + properties: + job_uuid: + type: string + title: Job Uuid + status: + $ref: '#/components/schemas/JobStatus' + scheduled_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Scheduled At + started_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Started At + completed_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Completed At + resources_allocated: + anyOf: + - additionalProperties: true + type: object + - type: 'null' + title: Resources Allocated + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + - status + title: PostTrainingJobStatusResponse + description: Status of a finetuning job. + PostTrainingMetric: + properties: + epoch: + type: integer + title: Epoch + train_loss: + type: number + title: Train Loss + validation_loss: + type: number + title: Validation Loss + perplexity: + type: number + title: Perplexity + type: object + required: + - epoch + - train_loss + - validation_loss + - perplexity + title: PostTrainingMetric + description: Training metrics captured during post-training jobs. Prompt: properties: prompt: @@ -4073,6 +4679,26 @@ components: - data title: RerankResponse description: Response from a reranking request. + RouteInfo: + properties: + route: + type: string + title: Route + method: + type: string + title: Method + provider_types: + items: + type: string + type: array + title: Provider Types + type: object + required: + - route + - method + - provider_types + title: RouteInfo + description: Information about an API route including its path, method, and implementing providers. RowsDataSource: properties: type: @@ -4876,6 +5502,96 @@ components: - vector_store_id title: VectorStoreFileObject description: OpenAI Vector Store File object. + VectorStoreFilesListInBatchResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreFilesListInBatchResponse + description: Response from listing files in a vector store file batch. + VectorStoreListFilesResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListFilesResponse + description: Response from listing files in a vector store. + VectorStoreListResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListResponse + description: Response from listing vector stores. VectorStoreObject: properties: id: @@ -7063,43 +7779,15 @@ components: - $ref: '#/components/schemas/UnstructuredLogEvent' - $ref: '#/components/schemas/MetricEvent' - $ref: '#/components/schemas/StructuredLogEvent' - ListOpenAIResponseInputItem: - description: List container for OpenAI response input items. + ResponseGuardrailSpec: + description: Specification for a guardrail to apply during response generation. properties: - data: - items: - anyOf: - - discriminator: - mapping: - file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - message: '#/components/schemas/OpenAIResponseMessage' - web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - propertyName: type - oneOf: - - $ref: '#/components/schemas/OpenAIResponseMessage' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' - - $ref: '#/components/schemas/OpenAIResponseMessage' - title: Data - type: array - object: - const: list - default: list - title: Object + type: + title: Type type: string required: - - data - title: ListOpenAIResponseInputItem + - type + title: ResponseGuardrailSpec type: object OpenAIResponseObjectWithInput: description: OpenAI response object extended with input context information. @@ -7260,82 +7948,6 @@ components: - input title: OpenAIResponseObjectWithInput type: object - ListOpenAIResponseObject: - description: Paginated list of OpenAI response objects with navigation metadata. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIResponseObjectWithInput' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIResponseObject - type: object - ResponseGuardrailSpec: - description: Specification for a guardrail to apply during response generation. - properties: - type: - title: Type - type: string - required: - - type - title: ResponseGuardrailSpec - type: object - ListBatchesResponse: - description: Response containing a list of batch objects. - properties: - object: - const: list - default: list - title: Object - type: string - data: - description: List of batch objects - items: - $ref: '#/components/schemas/Batch' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - description: ID of the first batch in the list - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - description: ID of the last batch in the list - title: Last Id - nullable: true - has_more: - default: false - description: Whether there are more batches available - title: Has More - type: boolean - required: - - data - title: ListBatchesResponse - type: object MetricInResponse: description: A metric value included in API responses. properties: @@ -7358,83 +7970,6 @@ components: - value title: MetricInResponse type: object - PaginatedResponse: - description: A generic paginated response that follows a simple format. - properties: - data: - items: - additionalProperties: true - type: object - title: Data - type: array - has_more: - title: Has More - type: boolean - url: - anyOf: - - type: string - - type: 'null' - title: Url - nullable: true - required: - - data - - has_more - title: PaginatedResponse - type: object - PostTrainingMetric: - description: Training metrics captured during post-training jobs. - properties: - epoch: - title: Epoch - type: integer - train_loss: - title: Train Loss - type: number - validation_loss: - title: Validation Loss - type: number - perplexity: - title: Perplexity - type: number - required: - - epoch - - train_loss - - validation_loss - - perplexity - title: PostTrainingMetric - type: object - Checkpoint: - description: Checkpoint created during training runs. - properties: - identifier: - title: Identifier - type: string - created_at: - format: date-time - title: Created At - type: string - epoch: - title: Epoch - type: integer - post_training_job_id: - title: Post Training Job Id - type: string - path: - title: Path - type: string - training_metrics: - anyOf: - - $ref: '#/components/schemas/PostTrainingMetric' - - type: 'null' - nullable: true - required: - - identifier - - created_at - - epoch - - post_training_job_id - - path - title: Checkpoint - type: object DialogType: description: Parameter type for dialog data with semantic output labels. properties: @@ -7519,35 +8054,6 @@ components: - status title: ConversationMessage type: object - ListOpenAIFileResponse: - description: Response for listing files in OpenAI Files API. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIFileObject' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIFileResponse - type: object Bf16QuantizationConfig: description: Configuration for BFloat16 precision (typically no quantization). properties: @@ -7598,92 +8104,6 @@ components: title: Scheme title: Int4QuantizationConfig type: object - OpenAIChoice: - description: A choice from an OpenAI-compatible chat completion response. - properties: - message: - discriminator: - mapping: - assistant: '#/components/schemas/OpenAIAssistantMessageParam' - developer: '#/components/schemas/OpenAIDeveloperMessageParam' - system: '#/components/schemas/OpenAISystemMessageParam' - tool: '#/components/schemas/OpenAIToolMessageParam' - user: '#/components/schemas/OpenAIUserMessageParam' - propertyName: role - oneOf: - - $ref: '#/components/schemas/OpenAIUserMessageParam' - - $ref: '#/components/schemas/OpenAISystemMessageParam' - - $ref: '#/components/schemas/OpenAIAssistantMessageParam' - - $ref: '#/components/schemas/OpenAIToolMessageParam' - - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' - title: Message - finish_reason: - title: Finish Reason - type: string - index: - title: Index - type: integer - logprobs: - anyOf: - - $ref: '#/components/schemas/OpenAIChoiceLogprobs' - - type: 'null' - nullable: true - required: - - message - - finish_reason - - index - title: OpenAIChoice - type: object - OpenAIChoiceLogprobs: - description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. - properties: - content: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Content - nullable: true - refusal: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Refusal - nullable: true - title: OpenAIChoiceLogprobs - type: object - ListOpenAIChatCompletionResponse: - description: Response from listing OpenAI-compatible chat completions. - properties: - data: - items: - $ref: '#/components/schemas/OpenAICompletionWithInputMessages' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIChatCompletionResponse - type: object OpenAIChoiceDelta: description: A delta from an OpenAI-compatible chat completion streaming response. properties: @@ -7721,6 +8141,27 @@ components: nullable: true title: OpenAIChoiceDelta type: object + OpenAIChoiceLogprobs: + description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. + properties: + content: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Content + nullable: true + refusal: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Refusal + nullable: true + title: OpenAIChoiceLogprobs + type: object OpenAIChunkChoice: description: A chunk choice from an OpenAI-compatible chat completion streaming response. properties: @@ -7777,6 +8218,42 @@ components: - model title: OpenAIChatCompletionChunk type: object + OpenAIChoice: + description: A choice from an OpenAI-compatible chat completion response. + properties: + message: + discriminator: + mapping: + assistant: '#/components/schemas/OpenAIAssistantMessageParam' + developer: '#/components/schemas/OpenAIDeveloperMessageParam' + system: '#/components/schemas/OpenAISystemMessageParam' + tool: '#/components/schemas/OpenAIToolMessageParam' + user: '#/components/schemas/OpenAIUserMessageParam' + propertyName: role + oneOf: + - $ref: '#/components/schemas/OpenAIUserMessageParam' + - $ref: '#/components/schemas/OpenAISystemMessageParam' + - $ref: '#/components/schemas/OpenAIAssistantMessageParam' + - $ref: '#/components/schemas/OpenAIToolMessageParam' + - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' + title: Message + finish_reason: + title: Finish Reason + type: string + index: + title: Index + type: integer + logprobs: + anyOf: + - $ref: '#/components/schemas/OpenAIChoiceLogprobs' + - type: 'null' + nullable: true + required: + - message + - finish_reason + - index + title: OpenAIChoice + type: object OpenAICompletionChoice: description: |- A choice from an OpenAI-compatible completion response. @@ -7959,53 +8436,6 @@ components: - content title: UserMessage type: object - RouteInfo: - description: Information about an API route including its path, method, and implementing providers. - properties: - route: - title: Route - type: string - method: - title: Method - type: string - provider_types: - items: - type: string - title: Provider Types - type: array - required: - - route - - method - - provider_types - title: RouteInfo - type: object - ListRoutesResponse: - description: Response containing a list of all available API routes. - properties: - data: - items: - $ref: '#/components/schemas/RouteInfo' - title: Data - type: array - required: - - data - title: ListRoutesResponse - type: object - PostTrainingJobArtifactsResponse: - description: Artifacts of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - title: PostTrainingJobArtifactsResponse - type: object PostTrainingJobLogStream: description: Stream of logs from a finetuning job. properties: @@ -8022,52 +8452,6 @@ components: - log_lines title: PostTrainingJobLogStream type: object - PostTrainingJobStatusResponse: - description: Status of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - status: - $ref: '#/components/schemas/JobStatus' - scheduled_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Scheduled At - nullable: true - started_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Started At - nullable: true - completed_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Completed At - nullable: true - resources_allocated: - anyOf: - - additionalProperties: true - type: object - - type: 'null' - title: Resources Allocated - nullable: true - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - - status - title: PostTrainingJobStatusResponse - type: object RLHFAlgorithm: description: Available reinforcement learning from human feedback algorithms. enum: @@ -8117,18 +8501,6 @@ components: - logger_config title: PostTrainingRLHFRequest type: object - ListToolDefsResponse: - description: Response containing a list of tool definitions. - properties: - data: - items: - $ref: '#/components/schemas/ToolDef' - title: Data - type: array - required: - - data - title: ListToolDefsResponse - type: object ToolGroupInput: description: Input data for registering a tool group. properties: @@ -8239,102 +8611,6 @@ components: type: object title: VectorStoreCreateRequest type: object - VectorStoreFilesListInBatchResponse: - description: Response from listing files in a vector store file batch. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreFilesListInBatchResponse - type: object - VectorStoreListFilesResponse: - description: Response from listing files in a vector store. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListFilesResponse - type: object - VectorStoreListResponse: - description: Response from listing vector stores. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListResponse - type: object VectorStoreModifyRequest: description: Request to modify a vector store. properties: diff --git a/docs/static/llama-stack-spec.yaml b/docs/static/llama-stack-spec.yaml index df61decd9..172e426d2 100644 --- a/docs/static/llama-stack-spec.yaml +++ b/docs/static/llama-stack-spec.yaml @@ -78,64 +78,6 @@ paths: description: Default Response $ref: '#/components/responses/DefaultError' /v1/responses: - post: - tags: - - Agents - summary: Create Openai Response - description: Create a model response. - operationId: create_openai_response_v1_responses_post - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/_responses_Request' - x-llama-stack-extra-body-params: - guardrails: - $defs: - ResponseGuardrailSpec: - description: |- - Specification for a guardrail to apply during response generation. - - :param type: The type/identifier of the guardrail. - properties: - type: - title: Type - type: string - required: - - type - title: ResponseGuardrailSpec - type: object - anyOf: - - items: - anyOf: - - type: string - - $ref: '#/components/schemas/ResponseGuardrailSpec' - type: array - - type: 'null' - description: List of guardrails to apply during response generation. Guardrails provide safety and content moderation. - responses: - '200': - description: An OpenAIResponseObject. - content: - application/json: - schema: - $ref: '#/components/schemas/OpenAIResponseObject' - text/event-stream: - schema: - $ref: '#/components/schemas/OpenAIResponseObjectStream' - '400': - $ref: '#/components/responses/BadRequest400' - description: Bad Request - '429': - $ref: '#/components/responses/TooManyRequests429' - description: Too Many Requests - '500': - $ref: '#/components/responses/InternalServerError500' - description: Internal Server Error - default: - $ref: '#/components/responses/DefaultError' - description: Default Response get: tags: - Agents @@ -196,6 +138,64 @@ paths: default: $ref: '#/components/responses/DefaultError' description: Default Response + post: + tags: + - Agents + summary: Create Openai Response + description: Create a model response. + operationId: create_openai_response_v1_responses_post + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/_responses_Request' + x-llama-stack-extra-body-params: + guardrails: + $defs: + ResponseGuardrailSpec: + description: |- + Specification for a guardrail to apply during response generation. + + :param type: The type/identifier of the guardrail. + properties: + type: + title: Type + type: string + required: + - type + title: ResponseGuardrailSpec + type: object + anyOf: + - items: + anyOf: + - type: string + - $ref: '#/components/schemas/ResponseGuardrailSpec' + type: array + - type: 'null' + description: List of guardrails to apply during response generation. Guardrails provide safety and content moderation. + responses: + '200': + description: An OpenAIResponseObject. + content: + application/json: + schema: + $ref: '#/components/schemas/OpenAIResponseObject' + text/event-stream: + schema: + $ref: '#/components/schemas/OpenAIResponseObjectStream' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response /v1/responses/{response_id}: get: tags: @@ -677,37 +677,6 @@ paths: type: string description: 'Path parameter: batch_id' /v1/batches: - post: - tags: - - Batches - summary: Create Batch - description: Create a new batch for processing multiple API requests. - operationId: create_batch_v1_batches_post - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/_batches_Request' - responses: - '200': - description: The created batch object. - content: - application/json: - schema: - $ref: '#/components/schemas/Batch' - '400': - $ref: '#/components/responses/BadRequest400' - description: Bad Request - '429': - $ref: '#/components/responses/TooManyRequests429' - description: Too Many Requests - '500': - $ref: '#/components/responses/InternalServerError500' - description: Internal Server Error - default: - $ref: '#/components/responses/DefaultError' - description: Default Response get: tags: - Batches @@ -749,6 +718,37 @@ paths: default: $ref: '#/components/responses/DefaultError' description: Default Response + post: + tags: + - Batches + summary: Create Batch + description: Create a new batch for processing multiple API requests. + operationId: create_batch_v1_batches_post + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/_batches_Request' + responses: + '200': + description: The created batch object. + content: + application/json: + schema: + $ref: '#/components/schemas/Batch' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response /v1/batches/{batch_id}: get: tags: @@ -817,44 +817,6 @@ paths: $ref: '#/components/responses/DefaultError' description: Default Response /v1/vector_stores/{vector_store_id}/files: - post: - tags: - - Vector Io - summary: Openai Attach File To Vector Store - description: Attach a file to a vector store. - operationId: openai_attach_file_to_vector_store_v1_vector_stores__vector_store_id__files_post - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/_vector_stores_vector_store_id_files_Request' - responses: - '200': - description: A VectorStoreFileObject representing the attached file. - content: - application/json: - schema: - $ref: '#/components/schemas/VectorStoreFileObject' - '400': - $ref: '#/components/responses/BadRequest400' - description: Bad Request - '429': - $ref: '#/components/responses/TooManyRequests429' - description: Too Many Requests - '500': - $ref: '#/components/responses/InternalServerError500' - description: Internal Server Error - default: - $ref: '#/components/responses/DefaultError' - description: Default Response - parameters: - - name: vector_store_id - in: path - required: true - schema: - type: string - description: 'Path parameter: vector_store_id' get: tags: - Vector Io @@ -936,6 +898,44 @@ paths: default: $ref: '#/components/responses/DefaultError' description: Default Response + post: + tags: + - Vector Io + summary: Openai Attach File To Vector Store + description: Attach a file to a vector store. + operationId: openai_attach_file_to_vector_store_v1_vector_stores__vector_store_id__files_post + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/_vector_stores_vector_store_id_files_Request' + responses: + '200': + description: A VectorStoreFileObject representing the attached file. + content: + application/json: + schema: + $ref: '#/components/schemas/VectorStoreFileObject' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response + parameters: + - name: vector_store_id + in: path + required: true + schema: + type: string + description: 'Path parameter: vector_store_id' /v1/vector_stores/{vector_store_id}/file_batches/{batch_id}/cancel: post: tags: @@ -976,40 +976,6 @@ paths: type: string description: 'Path parameter: batch_id' /v1/vector_stores: - post: - tags: - - Vector Io - summary: Openai Create Vector Store - description: |- - Creates a vector store. - - Generate an OpenAI-compatible vector store with the given parameters. - operationId: openai_create_vector_store_v1_vector_stores_post - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/OpenAICreateVectorStoreRequestWithExtraBody' - responses: - '200': - description: A VectorStoreObject representing the created vector store. - content: - application/json: - schema: - $ref: '#/components/schemas/VectorStoreObject' - '400': - $ref: '#/components/responses/BadRequest400' - description: Bad Request - '429': - $ref: '#/components/responses/TooManyRequests429' - description: Too Many Requests - '500': - $ref: '#/components/responses/InternalServerError500' - description: Internal Server Error - default: - $ref: '#/components/responses/DefaultError' - description: Default Response get: tags: - Vector Io @@ -1070,6 +1036,40 @@ paths: default: $ref: '#/components/responses/DefaultError' description: Default Response + post: + tags: + - Vector Io + summary: Openai Create Vector Store + description: |- + Creates a vector store. + + Generate an OpenAI-compatible vector store with the given parameters. + operationId: openai_create_vector_store_v1_vector_stores_post + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/OpenAICreateVectorStoreRequestWithExtraBody' + responses: + '200': + description: A VectorStoreObject representing the created vector store. + content: + application/json: + schema: + $ref: '#/components/schemas/VectorStoreObject' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response /v1/vector_stores/{vector_store_id}/file_batches: post: tags: @@ -1569,6 +1569,68 @@ paths: default: description: Default Response $ref: '#/components/responses/DefaultError' + /v1/models/{model_id}: + get: + tags: + - Models + summary: Get Model + description: |- + Get model. + + Get a model by its identifier. + operationId: get_model_v1_models__model_id__get + responses: + '200': + description: A Model. + content: + application/json: + schema: + $ref: '#/components/schemas/Model' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' + parameters: + - name: model_id + in: path + required: true + schema: + type: string + description: 'Path parameter: model_id' + /v1/models: + get: + tags: + - Models + summary: Openai List Models + description: List models using the OpenAI API. + operationId: openai_list_models_v1_models_get + responses: + '200': + description: A OpenAIListModelsResponse. + content: + application/json: + schema: + $ref: '#/components/schemas/OpenAIListModelsResponse' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' /v1/moderations: post: tags: @@ -1639,6 +1701,65 @@ paths: default: description: Default Response $ref: '#/components/responses/DefaultError' + /v1/shields/{identifier}: + get: + tags: + - Shields + summary: Get Shield + description: Get a shield by its identifier. + operationId: get_shield_v1_shields__identifier__get + responses: + '200': + description: A Shield. + content: + application/json: + schema: + $ref: '#/components/schemas/Shield' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' + parameters: + - name: identifier + in: path + required: true + schema: + type: string + description: 'Path parameter: identifier' + /v1/shields: + get: + tags: + - Shields + summary: List Shields + description: List all shields. + operationId: list_shields_v1_shields_get + responses: + '200': + description: A ListShieldsResponse. + content: + application/json: + schema: + $ref: '#/components/schemas/ListShieldsResponse' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' /v1/scoring/score: post: tags: @@ -1703,6 +1824,65 @@ paths: default: description: Default Response $ref: '#/components/responses/DefaultError' + /v1/scoring-functions/{scoring_fn_id}: + get: + tags: + - Scoring Functions + summary: Get Scoring Function + description: Get a scoring function by its ID. + operationId: get_scoring_function_v1_scoring_functions__scoring_fn_id__get + responses: + '200': + description: A ScoringFn. + content: + application/json: + schema: + $ref: '#/components/schemas/ScoringFn' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' + parameters: + - name: scoring_fn_id + in: path + required: true + schema: + type: string + description: 'Path parameter: scoring_fn_id' + /v1/scoring-functions: + get: + tags: + - Scoring Functions + summary: List Scoring Functions + description: List all scoring functions. + operationId: list_scoring_functions_v1_scoring_functions_get + responses: + '200': + description: A ListScoringFunctionsResponse. + content: + application/json: + schema: + $ref: '#/components/schemas/ListScoringFunctionsResponse' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response /v1/tools/{tool_name}: get: tags: @@ -1736,6 +1916,65 @@ paths: schema: type: string description: 'Path parameter: tool_name' + /v1/toolgroups/{toolgroup_id}: + get: + tags: + - Tool Groups + summary: Get Tool Group + description: Get a tool group by its ID. + operationId: get_tool_group_v1_toolgroups__toolgroup_id__get + responses: + '200': + description: A ToolGroup. + content: + application/json: + schema: + $ref: '#/components/schemas/ToolGroup' + '400': + description: Bad Request + $ref: '#/components/responses/BadRequest400' + '429': + description: Too Many Requests + $ref: '#/components/responses/TooManyRequests429' + '500': + description: Internal Server Error + $ref: '#/components/responses/InternalServerError500' + default: + description: Default Response + $ref: '#/components/responses/DefaultError' + parameters: + - name: toolgroup_id + in: path + required: true + schema: + type: string + description: 'Path parameter: toolgroup_id' + /v1/toolgroups: + get: + tags: + - Tool Groups + summary: List Tool Groups + description: List tool groups with optional provider. + operationId: list_tool_groups_v1_toolgroups_get + responses: + '200': + description: A ListToolGroupsResponse. + content: + application/json: + schema: + $ref: '#/components/schemas/ListToolGroupsResponse' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response /v1/tools: get: tags: @@ -2326,6 +2565,40 @@ paths: schema: type: string description: 'Path parameter: prompt_id' + delete: + tags: + - Prompts + summary: Delete Prompt + description: |- + Delete prompt. + + Delete a prompt. + operationId: delete_prompt_v1_prompts__prompt_id__delete + responses: + '200': + description: Successful Response + content: + application/json: + schema: {} + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response + parameters: + - name: prompt_id + in: path + required: true + schema: + type: string + description: 'Path parameter: prompt_id' /v1/prompts/{prompt_id}/versions: get: tags: @@ -2405,47 +2678,6 @@ paths: type: string description: 'Path parameter: prompt_id' /v1/conversations/{conversation_id}/items: - post: - tags: - - Conversations - summary: Add Items - description: |- - Create items. - - Create items in the conversation. - operationId: add_items_v1_conversations__conversation_id__items_post - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/_conversations_conversation_id_items_Request' - responses: - '200': - description: List of created items. - content: - application/json: - schema: - $ref: '#/components/schemas/ConversationItemList' - '400': - $ref: '#/components/responses/BadRequest400' - description: Bad Request - '429': - $ref: '#/components/responses/TooManyRequests429' - description: Too Many Requests - '500': - $ref: '#/components/responses/InternalServerError500' - description: Internal Server Error - default: - $ref: '#/components/responses/DefaultError' - description: Default Response - parameters: - - name: conversation_id - in: path - required: true - schema: - type: string - description: 'Path parameter: conversation_id' get: tags: - Conversations @@ -2518,6 +2750,47 @@ paths: default: $ref: '#/components/responses/DefaultError' description: Default Response + post: + tags: + - Conversations + summary: Add Items + description: |- + Create items. + + Create items in the conversation. + operationId: add_items_v1_conversations__conversation_id__items_post + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/_conversations_conversation_id_items_Request' + responses: + '200': + description: List of created items. + content: + application/json: + schema: + $ref: '#/components/schemas/ConversationItemList' + '400': + $ref: '#/components/responses/BadRequest400' + description: Bad Request + '429': + $ref: '#/components/responses/TooManyRequests429' + description: Too Many Requests + '500': + $ref: '#/components/responses/InternalServerError500' + description: Internal Server Error + default: + $ref: '#/components/responses/DefaultError' + description: Default Response + parameters: + - name: conversation_id + in: path + required: true + schema: + type: string + description: 'Path parameter: conversation_id' /v1/conversations: post: tags: @@ -3111,6 +3384,37 @@ components: type: object title: ChatCompletionInputType description: Parameter type for chat completion input. + Checkpoint: + properties: + identifier: + type: string + title: Identifier + created_at: + type: string + format: date-time + title: Created At + epoch: + type: integer + title: Epoch + post_training_job_id: + type: string + title: Post Training Job Id + path: + type: string + title: Path + training_metrics: + anyOf: + - $ref: '#/components/schemas/PostTrainingMetric' + - type: 'null' + type: object + required: + - identifier + - created_at + - epoch + - post_training_job_id + - path + title: Checkpoint + description: Checkpoint created during training runs. Chunk-Input: properties: content: @@ -3766,6 +4070,166 @@ components: - judge_model title: LLMAsJudgeScoringFnParams description: Parameters for LLM-as-judge scoring function configuration. + ListBatchesResponse: + properties: + object: + type: string + const: list + title: Object + default: list + data: + items: + $ref: '#/components/schemas/Batch' + type: array + title: Data + description: List of batch objects + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + description: ID of the first batch in the list + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + description: ID of the last batch in the list + has_more: + type: boolean + title: Has More + description: Whether there are more batches available + default: false + type: object + required: + - data + title: ListBatchesResponse + description: Response containing a list of batch objects. + ListOpenAIChatCompletionResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAICompletionWithInputMessages' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIChatCompletionResponse + description: Response from listing OpenAI-compatible chat completions. + ListOpenAIFileResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIFileObject' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIFileResponse + description: Response for listing files in OpenAI Files API. + ListOpenAIResponseInputItem: + properties: + data: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Data + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + title: ListOpenAIResponseInputItem + description: List container for OpenAI response input items. + ListOpenAIResponseObject: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIResponseObjectWithInput-Output' + type: array + title: Data + has_more: + type: boolean + title: Has More + first_id: + type: string + title: First Id + last_id: + type: string + title: Last Id + object: + type: string + const: list + title: Object + default: list + type: object + required: + - data + - has_more + - first_id + - last_id + title: ListOpenAIResponseObject + description: Paginated list of OpenAI response objects with navigation metadata. ListPromptsResponse: properties: data: @@ -3790,6 +4254,64 @@ components: - data title: ListProvidersResponse description: Response containing a list of all available providers. + ListRoutesResponse: + properties: + data: + items: + $ref: '#/components/schemas/RouteInfo' + type: array + title: Data + type: object + required: + - data + title: ListRoutesResponse + description: Response containing a list of all available API routes. + ListScoringFunctionsResponse: + properties: + data: + items: + $ref: '#/components/schemas/ScoringFn' + type: array + title: Data + type: object + required: + - data + title: ListScoringFunctionsResponse + ListShieldsResponse: + properties: + data: + items: + $ref: '#/components/schemas/Shield' + type: array + title: Data + type: object + required: + - data + title: ListShieldsResponse + ListToolDefsResponse: + properties: + data: + items: + $ref: '#/components/schemas/ToolDef' + type: array + title: Data + type: object + required: + - data + title: ListToolDefsResponse + description: Response containing a list of tool definitions. + ListToolGroupsResponse: + properties: + data: + items: + $ref: '#/components/schemas/ToolGroup' + type: array + title: Data + type: object + required: + - data + title: ListToolGroupsResponse + description: Response containing a list of tool groups. LoraFinetuningConfig: properties: type: @@ -4995,6 +5517,17 @@ components: type: object title: OpenAIJSONSchema description: JSON schema specification for OpenAI-compatible structured response format. + OpenAIListModelsResponse: + properties: + data: + items: + $ref: '#/components/schemas/OpenAIModel' + type: array + title: Data + type: object + required: + - data + title: OpenAIListModelsResponse OpenAIModel: properties: id: @@ -5735,6 +6268,155 @@ components: - status title: OpenAIResponseObject description: Complete OpenAI response object containing generation results and metadata. + OpenAIResponseObjectWithInput-Output: + properties: + created_at: + type: integer + title: Created At + error: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseError' + - type: 'null' + id: + type: string + title: Id + model: + type: string + title: Model + object: + type: string + const: response + title: Object + default: response + output: + items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + type: array + title: Output + parallel_tool_calls: + type: boolean + title: Parallel Tool Calls + default: false + previous_response_id: + anyOf: + - type: string + - type: 'null' + title: Previous Response Id + prompt: + anyOf: + - $ref: '#/components/schemas/OpenAIResponsePrompt' + - type: 'null' + status: + type: string + title: Status + temperature: + anyOf: + - type: number + - type: 'null' + title: Temperature + text: + $ref: '#/components/schemas/OpenAIResponseText' + default: + format: + type: text + top_p: + anyOf: + - type: number + - type: 'null' + title: Top P + tools: + anyOf: + - items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseInputToolWebSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFileSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFunction' + - $ref: '#/components/schemas/OpenAIResponseToolMCP' + discriminator: + propertyName: type + mapping: + file_search: '#/components/schemas/OpenAIResponseInputToolFileSearch' + function: '#/components/schemas/OpenAIResponseInputToolFunction' + mcp: '#/components/schemas/OpenAIResponseToolMCP' + web_search: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_2025_08_26: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview_2025_03_11: '#/components/schemas/OpenAIResponseInputToolWebSearch' + type: array + - type: 'null' + title: Tools + truncation: + anyOf: + - type: string + - type: 'null' + title: Truncation + usage: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseUsage' + - type: 'null' + instructions: + anyOf: + - type: string + - type: 'null' + title: Instructions + max_tool_calls: + anyOf: + - type: integer + - type: 'null' + title: Max Tool Calls + input: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Input + type: object + required: + - created_at + - id + - model + - output + - status + - input + title: OpenAIResponseObjectWithInput + description: OpenAI response object extended with input context information. OpenAIResponseOutputMessageContentOutputText: properties: text: @@ -6300,6 +6982,107 @@ components: required: - reasoning_tokens title: OutputTokensDetails + PaginatedResponse: + properties: + data: + items: + additionalProperties: true + type: object + type: array + title: Data + has_more: + type: boolean + title: Has More + url: + anyOf: + - type: string + - type: 'null' + title: Url + type: object + required: + - data + - has_more + title: PaginatedResponse + description: A generic paginated response that follows a simple format. + PostTrainingJobArtifactsResponse: + properties: + job_uuid: + type: string + title: Job Uuid + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + title: PostTrainingJobArtifactsResponse + description: Artifacts of a finetuning job. + PostTrainingJobStatusResponse: + properties: + job_uuid: + type: string + title: Job Uuid + status: + $ref: '#/components/schemas/JobStatus' + scheduled_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Scheduled At + started_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Started At + completed_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Completed At + resources_allocated: + anyOf: + - additionalProperties: true + type: object + - type: 'null' + title: Resources Allocated + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + - status + title: PostTrainingJobStatusResponse + description: Status of a finetuning job. + PostTrainingMetric: + properties: + epoch: + type: integer + title: Epoch + train_loss: + type: number + title: Train Loss + validation_loss: + type: number + title: Validation Loss + perplexity: + type: number + title: Perplexity + type: object + required: + - epoch + - train_loss + - validation_loss + - perplexity + title: PostTrainingMetric + description: Training metrics captured during post-training jobs. Prompt: properties: prompt: @@ -6447,6 +7230,26 @@ components: - data title: RerankResponse description: Response from a reranking request. + RouteInfo: + properties: + route: + type: string + title: Route + method: + type: string + title: Method + provider_types: + items: + type: string + type: array + title: Provider Types + type: object + required: + - route + - method + - provider_types + title: RouteInfo + description: Information about an API route including its path, method, and implementing providers. RowsDataSource: properties: type: @@ -7250,6 +8053,96 @@ components: - vector_store_id title: VectorStoreFileObject description: OpenAI Vector Store File object. + VectorStoreFilesListInBatchResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreFilesListInBatchResponse + description: Response from listing files in a vector store file batch. + VectorStoreListFilesResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListFilesResponse + description: Response from listing files in a vector store. + VectorStoreListResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListResponse + description: Response from listing vector stores. VectorStoreObject: properties: id: @@ -9818,43 +10711,15 @@ components: - $ref: '#/components/schemas/UnstructuredLogEvent' - $ref: '#/components/schemas/MetricEvent' - $ref: '#/components/schemas/StructuredLogEvent' - ListOpenAIResponseInputItem: - description: List container for OpenAI response input items. + ResponseGuardrailSpec: + description: Specification for a guardrail to apply during response generation. properties: - data: - items: - anyOf: - - discriminator: - mapping: - file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - message: '#/components/schemas/OpenAIResponseMessage' - web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - propertyName: type - oneOf: - - $ref: '#/components/schemas/OpenAIResponseMessage' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' - - $ref: '#/components/schemas/OpenAIResponseMessage' - title: Data - type: array - object: - const: list - default: list - title: Object + type: + title: Type type: string required: - - data - title: ListOpenAIResponseInputItem + - type + title: ResponseGuardrailSpec type: object OpenAIResponseObjectWithInput: description: OpenAI response object extended with input context information. @@ -10015,82 +10880,6 @@ components: - input title: OpenAIResponseObjectWithInput type: object - ListOpenAIResponseObject: - description: Paginated list of OpenAI response objects with navigation metadata. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIResponseObjectWithInput' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIResponseObject - type: object - ResponseGuardrailSpec: - description: Specification for a guardrail to apply during response generation. - properties: - type: - title: Type - type: string - required: - - type - title: ResponseGuardrailSpec - type: object - ListBatchesResponse: - description: Response containing a list of batch objects. - properties: - object: - const: list - default: list - title: Object - type: string - data: - description: List of batch objects - items: - $ref: '#/components/schemas/Batch' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - description: ID of the first batch in the list - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - description: ID of the last batch in the list - title: Last Id - nullable: true - has_more: - default: false - description: Whether there are more batches available - title: Has More - type: boolean - required: - - data - title: ListBatchesResponse - type: object MetricInResponse: description: A metric value included in API responses. properties: @@ -10113,83 +10902,6 @@ components: - value title: MetricInResponse type: object - PaginatedResponse: - description: A generic paginated response that follows a simple format. - properties: - data: - items: - additionalProperties: true - type: object - title: Data - type: array - has_more: - title: Has More - type: boolean - url: - anyOf: - - type: string - - type: 'null' - title: Url - nullable: true - required: - - data - - has_more - title: PaginatedResponse - type: object - PostTrainingMetric: - description: Training metrics captured during post-training jobs. - properties: - epoch: - title: Epoch - type: integer - train_loss: - title: Train Loss - type: number - validation_loss: - title: Validation Loss - type: number - perplexity: - title: Perplexity - type: number - required: - - epoch - - train_loss - - validation_loss - - perplexity - title: PostTrainingMetric - type: object - Checkpoint: - description: Checkpoint created during training runs. - properties: - identifier: - title: Identifier - type: string - created_at: - format: date-time - title: Created At - type: string - epoch: - title: Epoch - type: integer - post_training_job_id: - title: Post Training Job Id - type: string - path: - title: Path - type: string - training_metrics: - anyOf: - - $ref: '#/components/schemas/PostTrainingMetric' - - type: 'null' - nullable: true - required: - - identifier - - created_at - - epoch - - post_training_job_id - - path - title: Checkpoint - type: object DialogType: description: Parameter type for dialog data with semantic output labels. properties: @@ -10274,35 +10986,6 @@ components: - status title: ConversationMessage type: object - ListOpenAIFileResponse: - description: Response for listing files in OpenAI Files API. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIFileObject' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIFileResponse - type: object Bf16QuantizationConfig: description: Configuration for BFloat16 precision (typically no quantization). properties: @@ -10353,92 +11036,6 @@ components: title: Scheme title: Int4QuantizationConfig type: object - OpenAIChoice: - description: A choice from an OpenAI-compatible chat completion response. - properties: - message: - discriminator: - mapping: - assistant: '#/components/schemas/OpenAIAssistantMessageParam' - developer: '#/components/schemas/OpenAIDeveloperMessageParam' - system: '#/components/schemas/OpenAISystemMessageParam' - tool: '#/components/schemas/OpenAIToolMessageParam' - user: '#/components/schemas/OpenAIUserMessageParam' - propertyName: role - oneOf: - - $ref: '#/components/schemas/OpenAIUserMessageParam' - - $ref: '#/components/schemas/OpenAISystemMessageParam' - - $ref: '#/components/schemas/OpenAIAssistantMessageParam' - - $ref: '#/components/schemas/OpenAIToolMessageParam' - - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' - title: Message - finish_reason: - title: Finish Reason - type: string - index: - title: Index - type: integer - logprobs: - anyOf: - - $ref: '#/components/schemas/OpenAIChoiceLogprobs' - - type: 'null' - nullable: true - required: - - message - - finish_reason - - index - title: OpenAIChoice - type: object - OpenAIChoiceLogprobs: - description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. - properties: - content: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Content - nullable: true - refusal: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Refusal - nullable: true - title: OpenAIChoiceLogprobs - type: object - ListOpenAIChatCompletionResponse: - description: Response from listing OpenAI-compatible chat completions. - properties: - data: - items: - $ref: '#/components/schemas/OpenAICompletionWithInputMessages' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIChatCompletionResponse - type: object OpenAIChoiceDelta: description: A delta from an OpenAI-compatible chat completion streaming response. properties: @@ -10476,6 +11073,27 @@ components: nullable: true title: OpenAIChoiceDelta type: object + OpenAIChoiceLogprobs: + description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. + properties: + content: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Content + nullable: true + refusal: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Refusal + nullable: true + title: OpenAIChoiceLogprobs + type: object OpenAIChunkChoice: description: A chunk choice from an OpenAI-compatible chat completion streaming response. properties: @@ -10532,6 +11150,42 @@ components: - model title: OpenAIChatCompletionChunk type: object + OpenAIChoice: + description: A choice from an OpenAI-compatible chat completion response. + properties: + message: + discriminator: + mapping: + assistant: '#/components/schemas/OpenAIAssistantMessageParam' + developer: '#/components/schemas/OpenAIDeveloperMessageParam' + system: '#/components/schemas/OpenAISystemMessageParam' + tool: '#/components/schemas/OpenAIToolMessageParam' + user: '#/components/schemas/OpenAIUserMessageParam' + propertyName: role + oneOf: + - $ref: '#/components/schemas/OpenAIUserMessageParam' + - $ref: '#/components/schemas/OpenAISystemMessageParam' + - $ref: '#/components/schemas/OpenAIAssistantMessageParam' + - $ref: '#/components/schemas/OpenAIToolMessageParam' + - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' + title: Message + finish_reason: + title: Finish Reason + type: string + index: + title: Index + type: integer + logprobs: + anyOf: + - $ref: '#/components/schemas/OpenAIChoiceLogprobs' + - type: 'null' + nullable: true + required: + - message + - finish_reason + - index + title: OpenAIChoice + type: object OpenAICompletionChoice: description: |- A choice from an OpenAI-compatible completion response. @@ -10714,53 +11368,6 @@ components: - content title: UserMessage type: object - RouteInfo: - description: Information about an API route including its path, method, and implementing providers. - properties: - route: - title: Route - type: string - method: - title: Method - type: string - provider_types: - items: - type: string - title: Provider Types - type: array - required: - - route - - method - - provider_types - title: RouteInfo - type: object - ListRoutesResponse: - description: Response containing a list of all available API routes. - properties: - data: - items: - $ref: '#/components/schemas/RouteInfo' - title: Data - type: array - required: - - data - title: ListRoutesResponse - type: object - PostTrainingJobArtifactsResponse: - description: Artifacts of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - title: PostTrainingJobArtifactsResponse - type: object PostTrainingJobLogStream: description: Stream of logs from a finetuning job. properties: @@ -10777,52 +11384,6 @@ components: - log_lines title: PostTrainingJobLogStream type: object - PostTrainingJobStatusResponse: - description: Status of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - status: - $ref: '#/components/schemas/JobStatus' - scheduled_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Scheduled At - nullable: true - started_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Started At - nullable: true - completed_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Completed At - nullable: true - resources_allocated: - anyOf: - - additionalProperties: true - type: object - - type: 'null' - title: Resources Allocated - nullable: true - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - - status - title: PostTrainingJobStatusResponse - type: object RLHFAlgorithm: description: Available reinforcement learning from human feedback algorithms. enum: @@ -10872,18 +11433,6 @@ components: - logger_config title: PostTrainingRLHFRequest type: object - ListToolDefsResponse: - description: Response containing a list of tool definitions. - properties: - data: - items: - $ref: '#/components/schemas/ToolDef' - title: Data - type: array - required: - - data - title: ListToolDefsResponse - type: object ToolGroupInput: description: Input data for registering a tool group. properties: @@ -10994,102 +11543,6 @@ components: type: object title: VectorStoreCreateRequest type: object - VectorStoreFilesListInBatchResponse: - description: Response from listing files in a vector store file batch. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreFilesListInBatchResponse - type: object - VectorStoreListFilesResponse: - description: Response from listing files in a vector store. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreFileObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListFilesResponse - type: object - VectorStoreListResponse: - description: Response from listing vector stores. - properties: - object: - default: list - title: Object - type: string - data: - items: - $ref: '#/components/schemas/VectorStoreObject' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - title: Last Id - nullable: true - has_more: - default: false - title: Has More - type: boolean - required: - - data - title: VectorStoreListResponse - type: object VectorStoreModifyRequest: description: Request to modify a vector store. properties: diff --git a/docs/static/stainless-llama-stack-spec.yaml b/docs/static/stainless-llama-stack-spec.yaml index f45ea0e82..72475b8bd 100644 --- a/docs/static/stainless-llama-stack-spec.yaml +++ b/docs/static/stainless-llama-stack-spec.yaml @@ -5674,6 +5674,37 @@ components: type: object title: ChatCompletionInputType description: Parameter type for chat completion input. + Checkpoint: + properties: + identifier: + type: string + title: Identifier + created_at: + type: string + format: date-time + title: Created At + epoch: + type: integer + title: Epoch + post_training_job_id: + type: string + title: Post Training Job Id + path: + type: string + title: Path + training_metrics: + anyOf: + - $ref: '#/components/schemas/PostTrainingMetric' + - type: 'null' + type: object + required: + - identifier + - created_at + - epoch + - post_training_job_id + - path + title: Checkpoint + description: Checkpoint created during training runs. Chunk-Input: properties: content: @@ -8372,6 +8403,155 @@ components: - status title: OpenAIResponseObject description: Complete OpenAI response object containing generation results and metadata. + OpenAIResponseObjectWithInput-Output: + properties: + created_at: + type: integer + title: Created At + error: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseError' + - type: 'null' + id: + type: string + title: Id + model: + type: string + title: Model + object: + type: string + const: response + title: Object + default: response + output: + items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + type: array + title: Output + parallel_tool_calls: + type: boolean + title: Parallel Tool Calls + default: false + previous_response_id: + anyOf: + - type: string + - type: 'null' + title: Previous Response Id + prompt: + anyOf: + - $ref: '#/components/schemas/OpenAIResponsePrompt' + - type: 'null' + status: + type: string + title: Status + temperature: + anyOf: + - type: number + - type: 'null' + title: Temperature + text: + $ref: '#/components/schemas/OpenAIResponseText' + default: + format: + type: text + top_p: + anyOf: + - type: number + - type: 'null' + title: Top P + tools: + anyOf: + - items: + oneOf: + - $ref: '#/components/schemas/OpenAIResponseInputToolWebSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFileSearch' + - $ref: '#/components/schemas/OpenAIResponseInputToolFunction' + - $ref: '#/components/schemas/OpenAIResponseToolMCP' + discriminator: + propertyName: type + mapping: + file_search: '#/components/schemas/OpenAIResponseInputToolFileSearch' + function: '#/components/schemas/OpenAIResponseInputToolFunction' + mcp: '#/components/schemas/OpenAIResponseToolMCP' + web_search: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_2025_08_26: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview: '#/components/schemas/OpenAIResponseInputToolWebSearch' + web_search_preview_2025_03_11: '#/components/schemas/OpenAIResponseInputToolWebSearch' + type: array + - type: 'null' + title: Tools + truncation: + anyOf: + - type: string + - type: 'null' + title: Truncation + usage: + anyOf: + - $ref: '#/components/schemas/OpenAIResponseUsage' + - type: 'null' + instructions: + anyOf: + - type: string + - type: 'null' + title: Instructions + max_tool_calls: + anyOf: + - type: integer + - type: 'null' + title: Max Tool Calls + input: + items: + anyOf: + - oneOf: + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + discriminator: + propertyName: type + mapping: + file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' + function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' + mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' + mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' + mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' + message: '#/components/schemas/OpenAIResponseMessage-Output' + web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' + - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' + - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' + - $ref: '#/components/schemas/OpenAIResponseMessage-Output' + type: array + title: Input + type: object + required: + - created_at + - id + - model + - output + - status + - input + title: OpenAIResponseObjectWithInput + description: OpenAI response object extended with input context information. OpenAIResponseOutputMessageContentOutputText: properties: text: @@ -8937,6 +9117,28 @@ components: required: - reasoning_tokens title: OutputTokensDetails + PaginatedResponse: + properties: + data: + items: + additionalProperties: true + type: object + type: array + title: Data + has_more: + type: boolean + title: Has More + url: + anyOf: + - type: string + - type: 'null' + title: Url + type: object + required: + - data + - has_more + title: PaginatedResponse + description: A generic paginated response that follows a simple format. PostTrainingJob: properties: job_uuid: @@ -8946,6 +9148,85 @@ components: required: - job_uuid title: PostTrainingJob + PostTrainingJobArtifactsResponse: + properties: + job_uuid: + type: string + title: Job Uuid + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + title: PostTrainingJobArtifactsResponse + description: Artifacts of a finetuning job. + PostTrainingJobStatusResponse: + properties: + job_uuid: + type: string + title: Job Uuid + status: + $ref: '#/components/schemas/JobStatus' + scheduled_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Scheduled At + started_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Started At + completed_at: + anyOf: + - type: string + format: date-time + - type: 'null' + title: Completed At + resources_allocated: + anyOf: + - additionalProperties: true + type: object + - type: 'null' + title: Resources Allocated + checkpoints: + items: + $ref: '#/components/schemas/Checkpoint' + type: array + title: Checkpoints + type: object + required: + - job_uuid + - status + title: PostTrainingJobStatusResponse + description: Status of a finetuning job. + PostTrainingMetric: + properties: + epoch: + type: integer + title: Epoch + train_loss: + type: number + title: Train Loss + validation_loss: + type: number + title: Validation Loss + perplexity: + type: number + title: Perplexity + type: object + required: + - epoch + - train_loss + - validation_loss + - perplexity + title: PostTrainingMetric + description: Training metrics captured during post-training jobs. Prompt: properties: prompt: @@ -9093,6 +9374,26 @@ components: - data title: RerankResponse description: Response from a reranking request. + RouteInfo: + properties: + route: + type: string + title: Route + method: + type: string + title: Method + provider_types: + items: + type: string + type: array + title: Provider Types + type: object + required: + - route + - method + - provider_types + title: RouteInfo + description: Information about an API route including its path, method, and implementing providers. RowsDataSource: properties: type: @@ -9895,6 +10196,96 @@ components: - vector_store_id title: VectorStoreFileObject description: OpenAI Vector Store File object. + VectorStoreFilesListInBatchResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreFilesListInBatchResponse + description: Response from listing files in a vector store file batch. + VectorStoreListFilesResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreFileObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListFilesResponse + description: Response from listing files in a vector store. + VectorStoreListResponse: + properties: + object: + type: string + title: Object + default: list + data: + items: + $ref: '#/components/schemas/VectorStoreObject' + type: array + title: Data + first_id: + anyOf: + - type: string + - type: 'null' + title: First Id + last_id: + anyOf: + - type: string + - type: 'null' + title: Last Id + has_more: + type: boolean + title: Has More + default: false + type: object + required: + - data + title: VectorStoreListResponse + description: Response from listing vector stores. VectorStoreObject: properties: id: @@ -18934,43 +19325,15 @@ components: - $ref: '#/components/schemas/UnstructuredLogEvent' - $ref: '#/components/schemas/MetricEvent' - $ref: '#/components/schemas/StructuredLogEvent' - ListOpenAIResponseInputItem: - description: List container for OpenAI response input items. + ResponseGuardrailSpec: + description: Specification for a guardrail to apply during response generation. properties: - data: - items: - anyOf: - - discriminator: - mapping: - file_search_call: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - function_call: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - mcp_approval_request: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - mcp_call: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - mcp_list_tools: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - message: '#/components/schemas/OpenAIResponseMessage' - web_search_call: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - propertyName: type - oneOf: - - $ref: '#/components/schemas/OpenAIResponseMessage' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageWebSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFileSearchToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageFunctionToolCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPCall' - - $ref: '#/components/schemas/OpenAIResponseOutputMessageMCPListTools' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalRequest' - - $ref: '#/components/schemas/OpenAIResponseInputFunctionToolCallOutput' - - $ref: '#/components/schemas/OpenAIResponseMCPApprovalResponse' - - $ref: '#/components/schemas/OpenAIResponseMessage' - title: Data - type: array - object: - const: list - default: list - title: Object + type: + title: Type type: string required: - - data - title: ListOpenAIResponseInputItem + - type + title: ResponseGuardrailSpec type: object OpenAIResponseObjectWithInput: description: OpenAI response object extended with input context information. @@ -19125,82 +19488,6 @@ components: - input title: OpenAIResponseObjectWithInput type: object - ListOpenAIResponseObject: - description: Paginated list of OpenAI response objects with navigation metadata. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIResponseObjectWithInput' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIResponseObject - type: object - ResponseGuardrailSpec: - description: Specification for a guardrail to apply during response generation. - properties: - type: - title: Type - type: string - required: - - type - title: ResponseGuardrailSpec - type: object - ListBatchesResponse: - description: Response containing a list of batch objects. - properties: - object: - const: list - default: list - title: Object - type: string - data: - description: List of batch objects - items: - $ref: '#/components/schemas/Batch' - title: Data - type: array - first_id: - anyOf: - - type: string - - type: 'null' - description: ID of the first batch in the list - title: First Id - nullable: true - last_id: - anyOf: - - type: string - - type: 'null' - description: ID of the last batch in the list - title: Last Id - nullable: true - has_more: - default: false - description: Whether there are more batches available - title: Has More - type: boolean - required: - - data - title: ListBatchesResponse - type: object MetricInResponse: description: A metric value included in API responses. properties: @@ -19223,83 +19510,6 @@ components: - value title: MetricInResponse type: object - PaginatedResponse: - description: A generic paginated response that follows a simple format. - properties: - data: - items: - additionalProperties: true - type: object - title: Data - type: array - has_more: - title: Has More - type: boolean - url: - anyOf: - - type: string - - type: 'null' - title: Url - nullable: true - required: - - data - - has_more - title: PaginatedResponse - type: object - PostTrainingMetric: - description: Training metrics captured during post-training jobs. - properties: - epoch: - title: Epoch - type: integer - train_loss: - title: Train Loss - type: number - validation_loss: - title: Validation Loss - type: number - perplexity: - title: Perplexity - type: number - required: - - epoch - - train_loss - - validation_loss - - perplexity - title: PostTrainingMetric - type: object - Checkpoint: - description: Checkpoint created during training runs. - properties: - identifier: - title: Identifier - type: string - created_at: - format: date-time - title: Created At - type: string - epoch: - title: Epoch - type: integer - post_training_job_id: - title: Post Training Job Id - type: string - path: - title: Path - type: string - training_metrics: - anyOf: - - $ref: '#/components/schemas/PostTrainingMetric' - - type: 'null' - nullable: true - required: - - identifier - - created_at - - epoch - - post_training_job_id - - path - title: Checkpoint - type: object DialogType: description: Parameter type for dialog data with semantic output labels. properties: @@ -19384,35 +19594,6 @@ components: - status title: ConversationMessage type: object - ListOpenAIFileResponse: - description: Response for listing files in OpenAI Files API. - properties: - data: - items: - $ref: '#/components/schemas/OpenAIFileObject' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIFileResponse - type: object Bf16QuantizationConfig: description: Configuration for BFloat16 precision (typically no quantization). properties: @@ -19741,92 +19922,6 @@ components: title: Scheme title: Int4QuantizationConfig type: object - OpenAIChoice: - description: A choice from an OpenAI-compatible chat completion response. - properties: - message: - discriminator: - mapping: - assistant: '#/components/schemas/OpenAIAssistantMessageParam' - developer: '#/components/schemas/OpenAIDeveloperMessageParam' - system: '#/components/schemas/OpenAISystemMessageParam' - tool: '#/components/schemas/OpenAIToolMessageParam' - user: '#/components/schemas/OpenAIUserMessageParam' - propertyName: role - oneOf: - - $ref: '#/components/schemas/OpenAIUserMessageParam' - - $ref: '#/components/schemas/OpenAISystemMessageParam' - - $ref: '#/components/schemas/OpenAIAssistantMessageParam' - - $ref: '#/components/schemas/OpenAIToolMessageParam' - - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' - title: Message - finish_reason: - title: Finish Reason - type: string - index: - title: Index - type: integer - logprobs: - anyOf: - - $ref: '#/components/schemas/OpenAIChoiceLogprobs' - - type: 'null' - nullable: true - required: - - message - - finish_reason - - index - title: OpenAIChoice - type: object - OpenAIChoiceLogprobs: - description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. - properties: - content: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Content - nullable: true - refusal: - anyOf: - - items: - $ref: '#/components/schemas/OpenAITokenLogProb' - type: array - - type: 'null' - title: Refusal - nullable: true - title: OpenAIChoiceLogprobs - type: object - ListOpenAIChatCompletionResponse: - description: Response from listing OpenAI-compatible chat completions. - properties: - data: - items: - $ref: '#/components/schemas/OpenAICompletionWithInputMessages' - title: Data - type: array - has_more: - title: Has More - type: boolean - first_id: - title: First Id - type: string - last_id: - title: Last Id - type: string - object: - const: list - default: list - title: Object - type: string - required: - - data - - has_more - - first_id - - last_id - title: ListOpenAIChatCompletionResponse - type: object OpenAIChoiceDelta: description: A delta from an OpenAI-compatible chat completion streaming response. properties: @@ -19864,6 +19959,27 @@ components: nullable: true title: OpenAIChoiceDelta type: object + OpenAIChoiceLogprobs: + description: The log probabilities for the tokens in the message from an OpenAI-compatible chat completion response. + properties: + content: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Content + nullable: true + refusal: + anyOf: + - items: + $ref: '#/components/schemas/OpenAITokenLogProb' + type: array + - type: 'null' + title: Refusal + nullable: true + title: OpenAIChoiceLogprobs + type: object OpenAIChunkChoice: description: A chunk choice from an OpenAI-compatible chat completion streaming response. properties: @@ -19920,6 +20036,42 @@ components: - model title: OpenAIChatCompletionChunk type: object + OpenAIChoice: + description: A choice from an OpenAI-compatible chat completion response. + properties: + message: + discriminator: + mapping: + assistant: '#/components/schemas/OpenAIAssistantMessageParam' + developer: '#/components/schemas/OpenAIDeveloperMessageParam' + system: '#/components/schemas/OpenAISystemMessageParam' + tool: '#/components/schemas/OpenAIToolMessageParam' + user: '#/components/schemas/OpenAIUserMessageParam' + propertyName: role + oneOf: + - $ref: '#/components/schemas/OpenAIUserMessageParam' + - $ref: '#/components/schemas/OpenAISystemMessageParam' + - $ref: '#/components/schemas/OpenAIAssistantMessageParam' + - $ref: '#/components/schemas/OpenAIToolMessageParam' + - $ref: '#/components/schemas/OpenAIDeveloperMessageParam' + title: Message + finish_reason: + title: Finish Reason + type: string + index: + title: Index + type: integer + logprobs: + anyOf: + - $ref: '#/components/schemas/OpenAIChoiceLogprobs' + - type: 'null' + nullable: true + required: + - message + - finish_reason + - index + title: OpenAIChoice + type: object OpenAICompletionChoice: description: |- A choice from an OpenAI-compatible completion response. @@ -20040,53 +20192,6 @@ components: - content title: ToolResponse type: object - RouteInfo: - description: Information about an API route including its path, method, and implementing providers. - properties: - route: - title: Route - type: string - method: - title: Method - type: string - provider_types: - items: - type: string - title: Provider Types - type: array - required: - - route - - method - - provider_types - title: RouteInfo - type: object - ListRoutesResponse: - description: Response containing a list of all available API routes. - properties: - data: - items: - $ref: '#/components/schemas/RouteInfo' - title: Data - type: array - required: - - data - title: ListRoutesResponse - type: object - PostTrainingJobArtifactsResponse: - description: Artifacts of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - title: PostTrainingJobArtifactsResponse - type: object PostTrainingJobLogStream: description: Stream of logs from a finetuning job. properties: @@ -20103,52 +20208,6 @@ components: - log_lines title: PostTrainingJobLogStream type: object - PostTrainingJobStatusResponse: - description: Status of a finetuning job. - properties: - job_uuid: - title: Job Uuid - type: string - status: - $ref: '#/components/schemas/JobStatus' - scheduled_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Scheduled At - nullable: true - started_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Started At - nullable: true - completed_at: - anyOf: - - format: date-time - type: string - - type: 'null' - title: Completed At - nullable: true - resources_allocated: - anyOf: - - additionalProperties: true - type: object - - type: 'null' - title: Resources Allocated - nullable: true - checkpoints: - items: - $ref: '#/components/schemas/Checkpoint' - title: Checkpoints - type: array - required: - - job_uuid - - status - title: PostTrainingJobStatusResponse - type: object RLHFAlgorithm: description: Available reinforcement learning from human feedback algorithms. enum: diff --git a/scripts/fastapi_generator.py b/scripts/fastapi_generator.py index 4bc38b9f1..688360a0a 100755 --- a/scripts/fastapi_generator.py +++ b/scripts/fastapi_generator.py @@ -334,9 +334,34 @@ def _create_fastapi_endpoint(app: FastAPI, route, webmethod, api: Api): params_only_endpoint.__annotations__ = param_annotations endpoint_func = params_only_endpoint else: + # Endpoint with no parameters and no response model + # If we have a response_model from the function signature, use it even if _find_models_for_endpoint didn't find it + # This can happen if there was an exception during model finding + if response_model is None: + # Try to get response model directly from the function signature as a fallback + func = _get_protocol_method(api, name) + if func: + try: + sig = inspect.signature(func) + return_annotation = sig.return_annotation + if return_annotation != inspect.Signature.empty: + if hasattr(return_annotation, "model_json_schema"): + response_model = return_annotation + elif get_origin(return_annotation) is Annotated: + args = get_args(return_annotation) + if args and hasattr(args[0], "model_json_schema"): + response_model = args[0] + except Exception: + pass - async def no_params_endpoint(): - return {} + if response_model: + + async def no_params_endpoint() -> response_model: + return response_model() if response_model else {} + else: + + async def no_params_endpoint(): + return {} if operation_description: no_params_endpoint.__doc__ = operation_description @@ -386,6 +411,11 @@ def _create_fastapi_endpoint(app: FastAPI, route, webmethod, api: Api): }, } + # FastAPI needs response_model parameter to properly generate OpenAPI spec + # Use the non-streaming response model if available + if response_model: + route_kwargs["response_model"] = response_model + method_map = {"GET": app.get, "POST": app.post, "PUT": app.put, "DELETE": app.delete, "PATCH": app.patch} for method in methods: if handler := method_map.get(method.upper()): @@ -1434,10 +1464,30 @@ def _filter_schema_by_version( filtered_paths = {} for path, path_item in filtered_schema["paths"].items(): - if exclude_deprecated and _is_path_deprecated(path_item): + if not isinstance(path_item, dict): continue - if (stable_only and _is_stable_path(path)) or (not stable_only and _is_experimental_path(path)): - filtered_paths[path] = path_item + + # Filter at operation level, not path level + # This allows paths with both deprecated and non-deprecated operations + filtered_path_item = {} + for method in ["get", "post", "put", "delete", "patch", "head", "options"]: + if method not in path_item: + continue + operation = path_item[method] + if not isinstance(operation, dict): + continue + + # Skip deprecated operations if exclude_deprecated is True + if exclude_deprecated and operation.get("deprecated", False): + continue + + filtered_path_item[method] = operation + + # Only include path if it has at least one operation after filtering + if filtered_path_item: + # Check if path matches version filter + if (stable_only and _is_stable_path(path)) or (not stable_only and _is_experimental_path(path)): + filtered_paths[path] = filtered_path_item filtered_schema["paths"] = filtered_paths return _filter_schemas_by_references(filtered_schema, filtered_paths, openapi_schema)