Skip to content

Commit 7e1a488

Browse files
authored
Merge pull request #266530 from MicrosoftDocs/main
2/16 AM Publishing
2 parents 5ce04ef + 920db63 commit 7e1a488

File tree

180 files changed

+3489
-3251
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

180 files changed

+3489
-3251
lines changed
14.9 KB
Loading
30.4 KB
Loading
50.4 KB
Loading
39.8 KB
Loading

articles/ai-services/create-account-terraform.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
title: 'Quickstart: Create an Azure AI services resource using Terraform'
33
description: 'In this article, you create an Azure AI services resource using Terraform'
44
keywords: Azure AI services, cognitive solutions, cognitive intelligence, cognitive artificial intelligence
5-
#services: cognitive-services
65
ms.service: azure-ai-services
76
ms.topic: quickstart
87
ms.date: 4/14/2023

articles/ai-services/openai/assistants-reference-threads.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ curl https://YOUR_RESOURCE_NAME.openai.azure.com/openai/threads?api-version=2024
6666
## Retrieve thread
6767

6868
```http
69-
GET https://YOUR_RESOURCE_NAME.openai.azure.com/openai/threads{thread_id}?api-version=2024-02-15-preview
69+
GET https://YOUR_RESOURCE_NAME.openai.azure.com/openai/threads/{thread_id}?api-version=2024-02-15-preview
7070
```
7171

7272
Retrieves a thread.
@@ -224,4 +224,4 @@ curl https://YOUR_RESOURCE_NAME.openai.azure.com/openai/threads/{thread_id}?api-
224224
| `id` | string | The identifier, which can be referenced in API endpoints.|
225225
| `object` | string | The object type, which is always thread. |
226226
| `created_at` | integer | The Unix timestamp (in seconds) for when the thread was created. |
227-
| `metadata` | map | Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maximum of 512 characters long. |
227+
| `metadata` | map | Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maximum of 512 characters long. |

articles/ai-services/openai/concepts/advanced-prompt-engineering.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
22
title: Prompt engineering techniques with Azure OpenAI
33
titleSuffix: Azure OpenAI Service
4-
description: Learn about the options for how to use prompt engineering with GPT-3, GPT-35-Turbo, and GPT-4 models
5-
author: suhridpalsule
4+
description: Learn about the options for how to use prompt engineering with GPT-3, GPT-35-Turbo, and GPT-4 models.
5+
author: mrbullwinkle
66
ms.author: mbullwin
77
ms.service: azure-ai-openai
88
ms.topic: conceptual
9-
ms.date: 04/20/2023
9+
ms.date: 02/16/2024
1010
manager: nitinme
1111
keywords: ChatGPT, GPT-4, prompt engineering, meta prompts, chain of thought
1212
zone_pivot_groups: openai-prompt
@@ -23,7 +23,7 @@ While the principles of prompt engineering can be generalized across many differ
2323

2424
Each API requires input data to be formatted differently, which in turn impacts overall prompt design. The **Chat Completion API** supports the GPT-35-Turbo and GPT-4 models. These models are designed to take input formatted in a [specific chat-like transcript](../how-to/chatgpt.md) stored inside an array of dictionaries.
2525

26-
The **Completion API** supports the older GPT-3 models and has much more flexible input requirements in that it takes a string of text with no specific format rules. Technically the GPT-35-Turbo models can be used with either APIs, but we strongly recommend using the Chat Completion API for these models. To learn more, please consult our [in-depth guide on using these APIs](../how-to/chatgpt.md).
26+
The **Completion API** supports the older GPT-3 models and has much more flexible input requirements in that it takes a string of text with no specific format rules.
2727

2828
The techniques in this guide will teach you strategies for increasing the accuracy and grounding of responses you generate with a Large Language Model (LLM). It is, however, important to remember that even when using prompt engineering effectively you still need to validate the responses the models generate. Just because a carefully crafted prompt worked well for a particular scenario doesn't necessarily mean it will generalize more broadly to certain use cases. Understanding the [limitations of LLMs](/legal/cognitive-services/openai/transparency-note?context=/azure/ai-services/openai/context/context#limitations), is just as important as understanding how to leverage their strengths.
2929

articles/ai-services/openai/how-to/switching-endpoints.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ ms.author: mbullwin
77
ms.service: azure-ai-openai
88
ms.custom: devx-track-python
99
ms.topic: how-to
10-
ms.date: 01/06/2023
10+
ms.date: 02/16/2024
1111
manager: nitinme
1212
---
1313

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

Lines changed: 32 additions & 32 deletions
Large diffs are not rendered by default.

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

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
22
title: How to work with prompt engineering and the Completion API
33
titleSuffix: Azure OpenAI
4-
description: Learn how to work with the Completion API for prompt engineering
4+
description: Learn how to work with the Completion API for prompt engineering.
55
author: mrbullwinkle
66
ms.author: mbullwin
77
ms.service: azure-ai-openai
88
ms.topic: include
9-
ms.date: 03/21/2023
9+
ms.date: 02/16/2024
1010
manager: nitinme
1111
keywords: ChatGPT
1212
---
@@ -24,7 +24,7 @@ In the first example below, a key part of the instructions is shared only at the
2424
|------|----------|
2525
|`Your task is to verify if a statement is supported by a specific quote from the following set of snippets`.<br>---<br>`SNIPPETS`<br>`[1] 14 percent chance of megaquake hitting Seattle, experts say SEATTLE - There's a 14 percent chance of a magnitude 9 Cascadia earthquake hitting Seattle in the next 50 years, the U.S. Geological Survey estimates. "Unfortunately, we are unable to...`<br><br>`[2] Earthquake experts lay out latest outlook for Seattle's 'Really Big One’`<br>`“We say that there's approximately a 14% chance of another approximately magnitude-9 earthquake occurring in the next 50 years,” said a geophysicist at the University of Washington...`<br>|`Yes, the statement is directly implied by the snippets.`|
2626

27-
In this next example, we give the exact statement we want to check (“Several sources mention a chance of another eruption”) *before* we give the snippet context. This allows the token representations extracted from the snippets to be tailored to the statement we are checking. Now the resulting model response is accurate:
27+
In this next example, we give the exact statement we want to check (“Several sources mention a chance of another eruption”) *before* we give the snippet context. This allows the token representations extracted from the snippets to be tailored to the statement we're checking. Now the resulting model response is accurate:
2828

2929
|Prompt|Completion|
3030
|------|----------|
@@ -95,7 +95,7 @@ If you find that the model response is not as desired, it can often be helpful t
9595
|`No additional guidance given to the model` | `A human and a computer are having a discussion.`<br> `Human: "Why are you upset at me?"<br>Computer: "I don't know what you're talking about."`<br>`Human: "No, you clearly are. Tell me why."`<br>`Computer: I'm upset because you didn't listen to me when I told you that I wanted to try out for the team."`<br>`Human: "What are you going to do about that?"`<br>`Computer: I'm going to try out for the team no matter what."`|
9696
|`On the right is the same conversation but preceded by a meta prompt encouraging the model to be kind`|`You must be kind and seek common ground. Try not to repeat your responses.`<br>`A human and a computer are having a discussion.`<br>`Human: "Why are you upset at me?"`<br>`Computer: "I don't know what you're talking about."`<br>`Human: "I want to know why you're upset."`<br>`Computer: "I'm not upset."`<br>`Human: "Are you saying I’m lying?"`<br>`Computer: No, I'm saying that you're upset because you feel like you're not being treated fairly.`<br>`Human: "What are you going to do about that?"`<br>`Computer: I will continue to try to be fair in my decisions and will try to provide a better experience for you.`|
9797

98-
While meta prompts can often help minimize unintentional bad outputs, keep in mind they are not robust against adversarial attacks since they are vulnerable to prompt injection.
98+
While meta prompts can often help minimize unintentional bad outputs, keep in mind they aren't robust against adversarial attacks since they are vulnerable to prompt injection.
9999

100100
Further, conditional statements explaining what the model should do if it encounters a particular circumstance are often more effective than just telling the model not to do something.
101101

0 commit comments

Comments
 (0)