Skip to content

Commit 23b3d11

Browse files
Merge pull request #273425 from mrbullwinkle/mrb_04_25_2024_error
[Azure OpenAI] Update
2 parents 89b1440 + 4695e73 commit 23b3d11

File tree

2 files changed

+21
-12
lines changed

2 files changed

+21
-12
lines changed

articles/ai-services/openai/faq.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ metadata:
77
manager: nitinme
88
ms.service: azure-ai-openai
99
ms.topic: faq
10-
ms.date: 01/01/2024
10+
ms.date: 04/24/2024
1111
ms.author: mbullwin
1212
author: mrbullwinkle
1313
title: Azure OpenAI Service frequently asked questions
@@ -43,7 +43,7 @@ sections:
4343
- question: |
4444
Does Azure OpenAI support VNETs and Private Endpoints?
4545
answer: |
46-
Yes, as part of Azure AI services, Azure OpenAI supports VNETs and Private Endpoints. To learn more, consult the [Azure AI services virtual networking guidance](../cognitive-services-virtual-networks.md?context=/azure/ai-services/openai/context/context)
46+
Yes, as part of Azure AI services, Azure OpenAI supports VNETs and Private Endpoints. To learn more, consult the [Azure AI services virtual networking guidance](../cognitive-services-virtual-networks.md?context=/azure/ai-services/openai/context/context).
4747
- question: |
4848
Do the GPT-4 models currently support image input?
4949
answer: |
@@ -55,7 +55,7 @@ sections:
5555
- question: |
5656
I'm trying to use embeddings and received the error "InvalidRequestError: Too many inputs. The max number of inputs is 16." How do I fix this?
5757
answer: |
58-
This error typically occurs when you try to send a batch of text to embed in a single API request as an array. Currently Azure OpenAI only supports arrays of embeddings with multiple inputs for the `text-embedding-ada-002` Version 2 model. This model version supports an array consisting of up to 16 inputs per API request. The array can be up to 8191 tokens in length when using the text-embedding-ada-002 (Version 2) model.
58+
This error typically occurs when you try to send a batch of text to embed in a single API request as an array. Currently Azure OpenAI only supports arrays of embeddings with multiple inputs for the `text-embedding-ada-002` Version 2 model. This model version supports an array consisting of up to 16 inputs per API request. The array can be up to 8,191 tokens in length when using the text-embedding-ada-002 (Version 2) model.
5959
- question: |
6060
Where can I read about better ways to use Azure OpenAI to get the responses I want from the service?
6161
answer: |
@@ -109,7 +109,10 @@ sections:
109109
Where do I access pricing information for legacy models, which are no longer available for new deployments?
110110
answer: |
111111
Legacy pricing information is available via a [downloadable PDF file](https://download.microsoft.com/download/a/b/5/ab542db1-f1a7-4f92-b615-2e2eaccb64ea/Azure-OpenAI-Legacy-Pricing.pdf). For all other models, consult the [official pricing page](https://azure.microsoft.com/en-us/pricing/details/cognitive-services/openai-service/).
112-
112+
- question: |
113+
How do I fix InternalServerError - 500 - Failed to create completion as the model generated invalid Unicode output?
114+
answer:
115+
You can minimize the occurrence of these errors by reducing the temperature of your prompts to less than 1 and ensuring you're using a client with retry logic. Reattempting the request often results in a successful response.
113116
114117
- name: Getting access to Azure OpenAI Service
115118
questions:
@@ -134,8 +137,8 @@ sections:
134137
- question: |
135138
Where can I post questions and see answers to other common questions?
136139
answer: |
137-
- We recommend posting questions on [Microsoft Q&A](/answers/tags/387/azure-openai)
138-
- Alternatively, you can post questions on [Stack Overflow](https://stackoverflow.com/search?q=azure+openai)
140+
- We recommend posting questions on [Microsoft Q&A](/answers/tags/387/azure-openai).
141+
- Alternatively, you can post questions on [Stack Overflow](https://stackoverflow.com/search?q=azure+openai).
139142
- question: |
140143
Where do I go for Azure OpenAI customer support?
141144
answer: |
@@ -195,7 +198,7 @@ sections:
195198
- question: |
196199
Is there a limit to the size of the image I can upload?
197200
answer: |
198-
Yes, we restrict image uploads to 20MB per image.
201+
Yes, we restrict image uploads to 20 MB per image.
199202
- question: |
200203
Can I delete an image I uploaded?
201204
answer: |

articles/ai-services/openai/includes/chat-completion.md

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ author: mrbullwinkle #dereklegenzoff
66
ms.author: mbullwin #delegenz
77
ms.service: azure-ai-openai
88
ms.topic: include
9-
ms.date: 04/05/2024
9+
ms.date: 04/25/2024
1010
manager: nitinme
1111
keywords: ChatGPT
1212

@@ -363,11 +363,11 @@ while True:
363363

364364
---
365365

366-
When you run the preceding code, you get a blank console window. Enter your first question in the window and then select the Enter key. After the response is returned, you can repeat the process and keep asking questions.
366+
When you run the preceding code, you get a blank console window. Enter your first question in the window and then select the `Enter` key. After the response is returned, you can repeat the process and keep asking questions.
367367

368368
## Manage conversations
369369

370-
The previous example runs until you hit the model's token limit. With each question asked and answer received, the `messages` list grows in size. The token limit for `gpt-35-turbo` is 4,096 tokens. The token limits for `gpt-4` and `gpt-4-32k` are 8,192 and 32,768, respectively. These limits include the token count from both the message list sent and the model response. The number of tokens in the messages list combined with the value of the `max_tokens` parameter must stay under these limits or you receive an error.
370+
The previous example runs until you hit the model's token limit. With each question asked, and answer received, the `messages` list grows in size. The token limit for `gpt-35-turbo` is 4,096 tokens. The token limits for `gpt-4` and `gpt-4-32k` are 8,192 and 32,768, respectively. These limits include the token count from both the message list sent and the model response. The number of tokens in the messages list combined with the value of the `max_tokens` parameter must stay under these limits or you receive an error.
371371

372372
It's your responsibility to ensure that the prompt and completion fall within the token limit. For longer conversations, you need to keep track of the token count and only send the model a prompt that falls within the limit.
373373

@@ -551,9 +551,15 @@ Here's a troubleshooting tip.
551551

552552
Some customers try to use the [legacy ChatML syntax](../how-to/chat-markup-language.md) with the chat completion endpoints and newer models. ChatML was a preview capability that only worked with the legacy completions endpoint with the `gpt-35-turbo` version 0301 model. This model is [slated for retirement](../concepts/model-retirements.md). If you attempt to use ChatML syntax with newer models and the chat completion endpoint, it can result in errors and unexpected model response behavior. We don't recommend this use. This same issue can occur when using common special tokens.
553553

554-
| Error |Cause | Solution |
554+
| Error Code | Error Message | Solution |
555555
|---|---|---|
556-
| 400 - "Failed to generate output due to special tokens in the input." | Your prompt contains legacy ChatML tokens not recognized or supported by the model/endpoint. | Ensure that your prompt/messages array doesn't contain any legacy ChatML tokens/special tokens. If you're upgrading from a legacy model, exclude all special tokens before you submit an API request to the model.|
556+
| 400 | 400 - "Failed to generate output due to special tokens in the input." | Your prompt contains special tokens or legacy ChatML tokens not recognized or supported by the model/endpoint. Ensure that your prompt/messages array doesn't contain any legacy ChatML tokens/special tokens. If you're upgrading from a legacy model, exclude all special tokens before you submit an API request to the model.|
557+
558+
### Failed to create completion as the model generated invalid Unicode output
559+
560+
| Error Code | Error Message | Workaround |
561+
|---|---|---|
562+
| 500 | 500 - InternalServerError: Error code: 500 - {'error': {'message': 'Failed to create completion as the model generated invalid Unicode output}}. | You can minimize the occurrence of these errors by reducing the temperature of your prompts to less than 1 and ensuring you're using a client with retry logic. Reattempting the request often results in a successful response. |
557563

558564
## Next steps
559565

0 commit comments

Comments
 (0)