1.0.0b4 (2024-08-30)
Features Added
- Support chat completion streaming response with function arguments (tool calls). Add new classes
StreamingChatResponseMessageUpdate
andStreamingChatResponseToolCallUpdate
. - Support text embeddings result in base64 encoded string format.
- Nicely formated print of chat completions and embeddings result objects.
Breaking Changes
- Classes
ChatCompletionsToolSelectionPreset
,ChatCompletionsNamedToolSelection
andChatCompletionsFunctionToolSelection
renamed toChatCompletionsToolChoicePreset
ChatCompletionsNamedToolChoice
andChatCompletionsNamedToolChoiceFunction
respectively. - Update the object type of
embeddings
property onEmbeddingsResult
, fromembedding: List[float]
toembedding: Union[str, List[float]]
. - Instead of base class
ChatCompletionsToolCall
and derived classChatCompletionsFunctionToolCall
, we now have a flat representation of only one classChatCompletionsToolCall
that that represents a function tool. This is because the only support tool is a function call.
Bugs Fixed
- Fix setting of chat completions response format, to allow response in JSON format. See classes
ChatCompletionsResponseFormat
(base class) and
derived classesChatCompletionsResponseFormatJSON
andChatCompletionsResponseFormatText
.