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
[Accessing the response](https://github.com/Azure/azure-sdk-for-net/blob/Azure.AI.OpenAI_1.0.0-beta.7/sdk/core/Azure.Core/README.md#accessing-http-response-details-using-responset) |
[Accessing the response](https://github.com/Azure/azure-sdk-for-net/blob/Azure.AI.OpenAI_1.0.0-beta.8/sdk/core/Azure.Core/README.md#accessing-http-response-details-using-responset) |
You can familiarize yourself with different APIs using [Samples](https://github.com/Azure/azure-sdk-for-net/tree/Azure.AI.OpenAI_1.0.0-beta.7/sdk/openai/Azure.AI.OpenAI/tests/Samples).
115
+
You can familiarize yourself with different APIs using [Samples](https://github.com/Azure/azure-sdk-for-net/tree/Azure.AI.OpenAI_1.0.0-beta.8/sdk/openai/Azure.AI.OpenAI/tests/Samples).
116
116
117
117
### Generate Chatbot Response
118
118
@@ -242,6 +242,8 @@ You can read more about Chat Functions on OpenAI's blog: https://openai.com/blog
242
242
**NOTE**: Chat Functions require model versions beginning with gpt-4 and gpt-3.5-turbo's `-0613` labels. They are not
243
243
available with older versions of the models.
244
244
245
+
**NOTE:** The concurrent use of Chat Functions and [Azure Chat Extensions](#use-your-own-data-with-azure-openai) on a single request is not yet supported. Supplying both will result in the Chat Functions information being ignored and the operation behaving as if only the Azure Chat Extensions were provided. To address this limitation, consider separating the evaluation of Chat Functions and Azure Chat Extensions across multiple requests in your solution design.
246
+
245
247
To use Chat Functions, you first define the function you'd like the model to be able to use when appropriate. Using
246
248
the example from the linked blog post, above:
247
249
@@ -334,7 +336,10 @@ if (responseChoice.FinishReason == CompletionsFinishReason.FunctionCall)
// Now make a new request using all three messages in conversationMessages
340
345
}
@@ -346,6 +351,8 @@ if (responseChoice.FinishReason == CompletionsFinishReason.FunctionCall)
346
351
The use your own data feature is unique to Azure OpenAI and won't work with a client configured to use the non-Azure service.
347
352
See [the Azure OpenAI using your own data quickstart](https://learn.microsoft.com/azure/ai-services/openai/use-your-data-quickstart) for conceptual background and detailed setup instructions.
348
353
354
+
**NOTE:** The concurrent use of [Chat Functions](#use-chat-functions) and Azure Chat Extensions on a single request is not yet supported. Supplying both will result in the Chat Functions information being ignored and the operation behaving as if only the Azure Chat Extensions were provided. To address this limitation, consider separating the evaluation of Chat Functions and Azure Chat Extensions across multiple requests in your solution design.
// .Text will be translated to English (ISO-639-1 "en")
455
+
Console.WriteLine(translation.Text);
456
+
```
457
+
406
458
## Troubleshooting
407
459
408
460
When you interact with Azure OpenAI using the .NET SDK, errors returned by the service correspond to the same HTTP status codes returned for [REST API][openai_rest] requests.
@@ -432,11 +484,11 @@ This project has adopted the [Microsoft Open Source Code of Conduct][code_of_con
0 commit comments