Expand description
The common format for requests. This mostly hews to the OpenAI format except some response fields are made optional to accomodate different model providers.
Structs§
- Chat
Choice - A single choice in a chat
- Chat
Choice Delta - A delta in a streaming chat choice
- Chat
Message - A single message in a chat
- Chat
Request - The request that can be submitted to the proxy, for transformation and submission to a provider.
- Chat
Request Transformation - For providers that conform almost, but not quite, to the OpenAI spec, these transformations apply small changes that can alter the request in place to the form needed for the provider.
- Chat
Response - A chat response, in non-chunked format
- Function
Tool - Represents the function details of a tool
- Request
Info - Metadata about the request, from the proxy.
- Response
Info - Metadata about the response, from the provider.
- Stream
Options - Stream options for OpenAI. This is automatically set by the proxy when streaming. You can omit it in your requests.
- Tool
- Represents a tool that can be used by the OpenAI model
- Tool
Call - Represents a call to a tool by the OpenAI model
- Tool
Call Function - Represents the function details of a tool call
- Usage
Response - Counts of prompt, completion, and total tokens
Enums§
- Finish
Reason - Streaming
Response - Part of a streaming response, returned from the proxy
Type Aliases§
- Single
Chat Response - A non-streaming chat response
- Streaming
Chat Response - A chunk of streaming response
- Streaming
Response Receiver - A channel that can receive streaming responses
- Streaming
Response Sender - A channel on which streaming responses can be sent