You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Features Added
Added new EmbeddingsClient, to provide support for generating text embeddings using supported models.
Add support for passing a string file path on disk in order to provide an image for chat completions.
Breaking Changes
ChatCompletionsClientOptions has been renamed to AzureAIInferenceClientOptions.
ChatCompletions response object has been flattened. ChatCompletions.Choices has been removed, and the underlying properties have been bubbled up to be on the ChatCompletions object instead.
ChatCompletionsFunctionToolCall has been replaced with ChatCompletionsToolCall.
ChatCompletionsFunctionToolDefinition has been replaced with ChatCompletionsToolDefinition.
ChatCompletionsToolSelectionPreset has been replaced with ChatCompletionsToolChoicePreset.
ChatCompletionsNamedFunctionToolSelection has been replaced with ChatCompletionsNamedToolChoice.
ChatCompletionsFunctionToolSelection has been replaced with ChatCompletionsNamedToolChoiceFunction.
Bugs Fixed
Fixed support for chat completions streaming while using tools.
Other Changes
Removed the need to manually provide an api-key header when talking to Azure OpenAI.
----------------------------------------------------------
Signed-off-by: Travis Angevine <trangevi@microsoft.com>
Co-authored-by: Liudmila Molkova <limolkova@microsoft.com>
Copy file name to clipboardExpand all lines: sdk/ai/Azure.AI.Inference/CHANGELOG.md
+14-1
Original file line number
Diff line number
Diff line change
@@ -1,14 +1,27 @@
1
1
# Release History
2
2
3
-
## 1.0.0-beta.2 (Unreleased)
3
+
## 1.0.0-beta.2 (2024-10-24)
4
4
5
5
### Features Added
6
+
- Added new `EmbeddingsClient`, to provide support for generating text embeddings using supported models.
7
+
- Add support for passing a string file path on disk in order to provide an image for chat completions.
6
8
7
9
### Breaking Changes
10
+
-`ChatCompletionsClientOptions` has been renamed to `AzureAIInferenceClientOptions`.
11
+
-`ChatCompletions` response object has been flattened. `ChatCompletions.Choices` has been removed, and the underlying properties have been bubbled up to be on the `ChatCompletions` object instead.
12
+
-`ChatCompletionsFunctionToolCall` has been replaced with `ChatCompletionsToolCall`.
13
+
-`ChatCompletionsFunctionToolDefinition` has been replaced with `ChatCompletionsToolDefinition`.
14
+
-`ChatCompletionsToolSelectionPreset` has been replaced with `ChatCompletionsToolChoicePreset`.
15
+
-`ChatCompletionsNamedFunctionToolSelection` has been replaced with `ChatCompletionsNamedToolChoice`.
16
+
-`ChatCompletionsFunctionToolSelection` has been replaced with `ChatCompletionsNamedToolChoiceFunction`.
17
+
-`StreamingChatCompletionsUpdate.AuthorName` has been removed
18
+
- Removed `extraParams` from the `complete` and `completeAsync` methods. It is now set implicitly if `additionalProperties` is provided in the options object.
8
19
9
20
### Bugs Fixed
21
+
- Fixed support for chat completions streaming while using tools.
10
22
11
23
### Other Changes
24
+
- Removed the need to manually provide an `api-key` header when talking to Azure OpenAI.
@@ -106,13 +106,13 @@ The `ChatCompletionsClient` has a method named `complete`. The method makes a RE
106
106
107
107
See simple chat completion examples below. More can be found in the [samples](https://aka.ms/azsdk/azure-ai-inference/csharp/samples) folder.
108
108
109
-
<!--
110
109
### Text Embeddings
111
110
112
-
The `EmbeddingsClient` has a method named `embedding`. The method makes a REST API call to the `/embeddings` route on the provided endpoint, as documented in [the REST API reference](https://learn.microsoft.com/azure/ai-studio/reference/reference-model-inference-embeddings).
111
+
The `EmbeddingsClient` has a method named `embed`. The method makes a REST API call to the `/embeddings` route on the provided endpoint, as documented in [the REST API reference](https://learn.microsoft.com/azure/ai-studio/reference/reference-model-inference-embeddings).
113
112
114
113
See simple text embedding example below. More can be found in the [samples](https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/ai/azure-ai-inference/samples) folder.
115
114
115
+
<!--
116
116
### Image Embeddings
117
117
118
118
TODO: Add overview and link to explain image embeddings.
@@ -150,7 +150,7 @@ In the following sections you will find simple examples of:
The examples create a client as mentioned in [Create and authenticate a client directly, using key](#create-and-authenticate-a-client-directly-using-key). Only mandatory input settings are shown for simplicity.
@@ -165,7 +165,7 @@ This example demonstrates how to generate a single chat completions, with key au
The following types or messages are supported: `SystemMessage`,`UserMessage`, `AssistantMessage`, `ToolMessage`. See also samples:
184
184
185
-
*[Sample5_ChatCompletionsWithImageUrl.md](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/ai/Azure.AI.Inference/samples/Sample5_ChatCompletionsWithImageUrl.md) for usage of `UserMessage` that includes sending an image URL.
185
+
*[Sample5_ChatCompletionsWithImages.md](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/ai/Azure.AI.Inference/samples/Sample5_ChatCompletionsWithImages.md) for usage of `UserMessage` that includes sending an image URL or image data from a local file.
186
186
*[Sample7_ChatCompletionsWithTools.md](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/ai/Azure.AI.Inference/samples/Sample7_ChatCompletionsWithTools.md) for usage of `ToolMessage`.
187
187
188
188
Alternatively, you can read a `BinaryData` object based on a JSON string instead of using the strongly typed classes like `ChatRequestSystemMessage` and `ChatRequestUserMessage`:
@@ -191,7 +191,7 @@ Alternatively, you can read a `BinaryData` object based on a JSON string instead
@@ -255,15 +255,13 @@ In this example, extra JSON elements are inserted at the root of the request bod
255
255
256
256
Note that by default, the service will reject any request payload that includes unknown parameters (ones that are not defined in the REST API [Request Body table](https://learn.microsoft.com/azure/ai-studio/reference/reference-model-inference-chat-completions#request-body)). In order to change the default service behaviour, when the `Complete` method includes `AdditonalProperties`, the client library will automatically add the HTTP request header `"unknown_params": "pass-through"`.
257
257
258
-
<!-- The input argument `Additional` is not restricted to chat completions. It is suppored on other client methods as well. -->
0 commit comments