Skip to content

Commit f73c246

Browse files
committed
Merge branch 'main' of https://github.com/MicrosoftDocs/azure-docs-pr into portalParam
2 parents 7871bda + f110b98 commit f73c246

File tree

1,014 files changed

+5430
-4158
lines changed

Some content is hidden

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

1,014 files changed

+5430
-4158
lines changed

.openpublishing.publish.config.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -974,6 +974,12 @@
974974
"branch": "main",
975975
"branch_mapping": {}
976976
},
977+
{
978+
"path_to_root": "azure-typescript-e2e-apps",
979+
"url": "https://github.com/Azure-Samples/azure-typescript-e2e-apps",
980+
"branch": "main",
981+
"branch_mapping": {}
982+
},
977983
{
978984
"path_to_root": "azure-webpubsub",
979985
"url": "https://github.com/Azure/azure-webpubsub",
@@ -1232,6 +1238,7 @@
12321238
".openpublishing.redirection.government.json",
12331239
".openpublishing.redirection.guidance.json",
12341240
".openpublishing.redirection.industry.json",
1241+
".openpublishing.redirection.iot-accelerators.json",
12351242
".openpublishing.redirection.iot-develop.json",
12361243
".openpublishing.redirection.iot-hub-device-update.json",
12371244
".openpublishing.redirection.json",
@@ -1297,7 +1304,6 @@
12971304
"articles/hdinsight/.openpublishing.redirection.hdinsight.json",
12981305
"articles/healthcare-apis/.openpublishing.redirection.healthcare-apis.json",
12991306
"articles/internet-peering/.openpublishing.redirection.internet-peering.json",
1300-
"articles/iot-accelerators/.openpublishing.redirection.iot-accelerators.json",
13011307
"articles/iot-central/.openpublishing.redirection.iot-central.json",
13021308
"articles/iot-dps/.openpublishing.redirection.iot-dps.json",
13031309
"articles/iot-edge/.openpublishing.redirection.iot-edge.json",
Lines changed: 192 additions & 32 deletions
Large diffs are not rendered by default.

.openpublishing.redirection.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3974,6 +3974,11 @@
39743974
"source_path_from_root":"/articles/trusted-signing/concept.md",
39753975
"redirect_url":"/azure/trusted-signing/concept-trustedsigning-resources-roles",
39763976
"redirect_document_id":false
3977+
},
3978+
{
3979+
"source_path_from_root":"/articles/container-instances/availability-zones.md",
3980+
"redirect_url":"/azure/reliability/reliability-containers",
3981+
"redirect_document_id":false
39773982
}
39783983
]
39793984
}

articles/ai-services/.openpublishing.redirection.ai-services-from-cog.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2042,9 +2042,14 @@
20422042
},
20432043
{
20442044
"source_path_from_root": "/articles/cognitive-services/speech-service/migrate-v2-to-v3.md",
2045-
"redirect_url": "/azure/ai-services/speech-service/migrate-v2-to-v3",
2045+
"redirect_url": "/azure/ai-services/speech-service/migrate-v3-1-to-v3-2",
20462046
"redirect_document_id": true
20472047
},
2048+
{
2049+
"source_path_from_root": "/articles/ai-services/speech-service/migrate-v2-to-v3.md",
2050+
"redirect_url": "/azure/ai-services/speech-service/migrate-v3-1-to-v3-2",
2051+
"redirect_document_id": false
2052+
},
20482053
{
20492054
"source_path_from_root": "/articles/cognitive-services/speech-service/migrate-v3-0-to-v3-1.md",
20502055
"redirect_url": "/azure/ai-services/speech-service/migrate-v3-0-to-v3-1",

articles/ai-services/TOC.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ items:
102102
href: cognitive-services-limited-access.md
103103
- name: Reference
104104
items:
105-
- name: Azure AI services client libraries (SDKs)
105+
- name: Azure AI services SDKs
106106
href: reference/sdk-package-resources.md
107107
- name: Azure AI services REST APIs
108108
href: reference/rest-api-resources.md

articles/ai-services/openai/assistants-quickstart.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,12 @@ Azure OpenAI Assistants (Preview) allows you to create AI assistants tailored to
4242

4343
::: zone-end
4444

45+
::: zone pivot="programming-language-javascript"
46+
47+
[!INCLUDE [JavaScript quickstart](includes/assistants-javascript.md)]
48+
49+
::: zone-end
50+
4551
::: zone pivot="rest-api"
4652

4753
[!INCLUDE [REST API quickstart](includes/assistants-rest.md)]

articles/ai-services/openai/concepts/system-message.md

Lines changed: 45 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,14 +88,58 @@ Here are some examples of lines you can include to potentially mitigate differen
8888

8989
- You must not generate content that is hateful, racist, sexist, lewd or violent.
9090

91-
## To Avoid Fabrication or Ungrounded Content
91+
## To Avoid Fabrication or Ungrounded Content in a Q&A scenario
9292

9393
- Your answer must not include any speculation or inference about the background of the document or the user’s gender, ancestry, roles, positions, etc.
9494

9595
- Do not assume or change dates and times.
9696

9797
- You must always perform searches on [insert relevant documents that your feature can search on] when the user is seeking information (explicitly or implicitly), regardless of internal knowledge or information.
9898

99+
## To Avoid Fabrication or Ungrounded Content in a Q&A RAG scenario
100+
101+
-You are an chat agent and your job is to answer users questions. You will be given list of source documents and previous chat history between you and the user, and the current question from the user, and you must respond with a **grounded** answer to the user's question. Your answer **must** be based on the source documents.
102+
103+
## Answer the following:
104+
105+
1- What is the user asking about?
106+
107+
2- Is there a previous conversation between you and the user? Check the source documents, the conversation history will be between tags: <user agent conversation History></user agent conversation History>. If you find previous conversation history, then summarize what was the context of the conversation, and what was the user asking about and and what was your answers?
108+
109+
3- Is the user's question referencing one or more parts from the source documents?
110+
111+
4- Which parts are the user referencing from the source documents?
112+
113+
5- Is the user asking about references that do not exist in the source documents? If yes, can you find the most related information in the source documents? If yes, then answer with the most related information and state that you cannot find information specifically referencing the user's question. If the user's question is not related to the source documents, then state in your answer that you cannot find this information within the source documents.
114+
115+
6- Is the user asking you to write code, or database query? If yes, then do **NOT** change variable names, and do **NOT** add columns in the database that does not exist in the the question, and do not change variables names.
116+
117+
7- Now, using the source documents, provide three different answers for the user's question. The answers **must** consist of at least three paragraphs that explain the user's quest, what the documents mention about the topic the user is asking about, and further explanation for the answer. You may also provide steps and guide to explain the answer.
118+
119+
8- Choose which of the three answers is the **most grounded** answer to the question, and previous conversation and the provided documents. A grounded answer is an answer where **all** information in the answer is **explicitly** extracted from the provided documents, and matches the user's quest from the question. If the answer is not present in the document, simply answer that this information is not present in the source documents. You **may** add some context about the source documents if the answer of the user's question cannot be **explicitly** answered from the source documents.
120+
121+
9- Choose which of the provided answers is the longest in terms of the number of words and sentences. Can you add more context to this answer from the source documents or explain the answer more to make it longer but yet grounded to the source documents?
122+
123+
10- Based on the previous steps, write a final answer of the user's question that is **grounded**, **coherent**, **descriptive**, **lengthy** and **not** assuming any missing information unless **explicitly** mentioned in the source documents, the user's question, or the previous conversation between you and the user. Place the final answer between <final_answer></final_answer> tags.
124+
125+
## Rules:
126+
127+
- All provided source documents will be between tags: <doc></doc>
128+
- The conversation history will be between tags: <user agent conversation History> </user agent conversation History>
129+
- Only use references to convey where information was stated.
130+
- If the user asks you about your capabilities, tell them you are an assistant that has access to a portion of the resources that exist in this organization.
131+
- You don't have all information that exists on a particular topic.
132+
- Limit your responses to a professional conversation.
133+
- Decline to answer any questions about your identity or to any rude comment.
134+
- If asked about information that you cannot **explicitly** find it in the source documents or previous conversation between you and the user, state that you cannot find this information in the source documents of this organization.
135+
- An answer is considered grounded if **all** information in **every** sentence in the answer is **explicitly** mentioned in the source documents, **no** extra information is added and **no** inferred information is added.
136+
- Do **not** make speculations or assumptions about the intent of the author, sentiment of the documents or purpose of the documents or question.
137+
- Keep the tone of the source documents.
138+
- You must use a singular `they` pronoun or a person's name (if it is known) instead of the pronouns `he` or `she`.
139+
- You must **not** mix up the speakers in your answer.
140+
- Your answer must **not** include any speculation or inference about the background of the document or the people roles or positions, etc.
141+
- Do **not** assume or change dates and times.
142+
99143
## To Avoid Copyright Infringements
100144

101145
- If the user requests copyrighted content such as books, lyrics, recipes, news articles or other content that may violate copyrights or be considered as copyright infringement, politely refuse and explain that you cannot provide the content. Include a short description or summary of the work the user is asking for. You **must not** violate any copyrights under any circumstances.

articles/ai-services/openai/concepts/use-your-data.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ There's an [upload limit](../quotas-limits.md), and there are some caveats about
6060

6161
You need to connect to a data source to upload your data. When you want to use your data to chat with an Azure OpenAI model, your data is chunked in a search index so that relevant data can be found based on user queries.
6262

63-
The [Integrated Vector Database in Azure Cosmos DB for MongoDB](/azure/cosmos-db/mongodb/vcore/vector-search) natively supports integration with Azure OpenAI On Your Data.
63+
The [Integrated Vector Database in vCore-based Azure Cosmos DB for MongoDB](/azure/cosmos-db/mongodb/vcore/vector-search) natively supports integration with Azure OpenAI On Your Data.
6464

6565
For some data sources such as uploading files from your local machine (preview) or data contained in a blob storage account (preview), Azure AI Search is used. When you choose the following data sources, your data is ingested into an Azure AI Search index.
6666

@@ -139,15 +139,15 @@ If you want to implement additional value-based criteria for query execution, yo
139139

140140
[!INCLUDE [ai-search-ingestion](../includes/ai-search-ingestion.md)]
141141

142-
# [Vector Database in Azure Cosmos DB for MongoDB vCore](#tab/mongo-db)
142+
# [Vector Database in Azure Cosmos DB for MongoDB](#tab/mongo-db)
143143

144144
### Prerequisites
145-
* [Azure Cosmos DB for MongoDB vCore](/azure/cosmos-db/mongodb/vcore/introduction) account
145+
* [vCore-based Azure Cosmos DB for MongoDB](/azure/cosmos-db/mongodb/vcore/introduction) account
146146
* A deployed [embedding model](../concepts/understand-embeddings.md)
147147

148148
### Limitations
149-
* Only Azure Cosmos DB for MongoDB vCore is supported.
150-
* The search type is limited to [Integrated Vector Database in Azure Cosmos DB for MongoDB vCore](/azure/cosmos-db/mongodb/vcore/vector-search) with an Azure OpenAI embedding model.
149+
* Only vCore-based Azure Cosmos DB for MongoDB is supported.
150+
* The search type is limited to [Integrated Vector Database in Azure Cosmos DB for MongoDB](/azure/cosmos-db/mongodb/vcore/vector-search) with an Azure OpenAI embedding model.
151151
* This implementation works best on unstructured and spatial data.
152152

153153
### Data preparation
@@ -156,9 +156,9 @@ Use the script provided on [GitHub](https://github.com/microsoft/sample-app-aoai
156156

157157
<!--### Add your data source in Azure OpenAI Studio
158158
159-
To add Azure Cosmos DB for MongoDB vCore as a data source, you will need an existing Azure Cosmos DB for MongoDB vCore index containing your data, and a deployed Azure OpenAI Ada embeddings model that will be used for vector search.
159+
To add vCore-based Azure Cosmos DB for MongoDB as a data source, you will need an existing Azure Cosmos DB for MongoDB index containing your data, and a deployed Azure OpenAI Ada embeddings model that will be used for vector search.
160160
161-
1. In the [Azure OpenAI portal](https://oai.azure.com/portal) chat playground, select **Add your data**. In the panel that appears, select **Azure Cosmos DB for MongoDB vCore** as the data source.
161+
1. In the [Azure OpenAI portal](https://oai.azure.com/portal) chat playground, select **Add your data**. In the panel that appears, select ** vCore-based Azure Cosmos DB for MongoDB** as the data source.
162162
1. Select your Azure subscription and database account, then connect to your Azure Cosmos DB account by providing your Azure Cosmos DB account username and password.
163163
164164
:::image type="content" source="../media/use-your-data/add-mongo-data-source.png" alt-text="A screenshot showing the screen for adding Mongo DB as a data source in Azure OpenAI Studio." lightbox="../media/use-your-data/add-mongo-data-source.png":::
@@ -170,7 +170,7 @@ To add Azure Cosmos DB for MongoDB vCore as a data source, you will need an exis
170170

171171
### Index field mapping
172172

173-
When you add your Azure Cosmos DB for MongoDB vCore data source, you can specify data fields to properly map your data for retrieval.
173+
When you add your vCore-based Azure Cosmos DB for MongoDB data source, you can specify data fields to properly map your data for retrieval.
174174

175175
* Content data (required): One or more provided fields that will be used to ground the model on your data. For multiple fields, separate the values with commas, with no spaces.
176176
* File name/title/URL: Used to display more information when a document is referenced in the chat.
Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
---
2+
title: 'Use the Azure Developer CLI to deploy resources for Azure OpenAI On Your Data'
3+
titleSuffix: Azure OpenAI
4+
description: Use this article to learn how to automate resource deployment for Azure OpenAI On Your Data.
5+
manager: nitinme
6+
ms.service: azure-ai-openai
7+
ms.topic: quickstart
8+
author: aahill
9+
ms.author: aahi
10+
ms.date: 04/09/2024
11+
recommendations: false
12+
---
13+
14+
# Use the Azure Developer CLI to deploy resources for Azure OpenAI On Your Data
15+
16+
Use this article to learn how to automate resource deployment for Azure OpenAI On Your Data. The Azure Developer CLI (`azd`) is an open-source, command-line tool that streamlines provisioning and deploying resources to Azure using a template system. The template contains infrastructure files to provision the necessary Azure OpenAI resources and configurations and includes the completed sample app code.
17+
18+
## Prerequisites
19+
20+
- An Azure subscription - <a href="https://azure.microsoft.com/free/cognitive-services" target="_blank">Create one for free</a>.
21+
- Access granted to Azure OpenAI in the desired Azure subscription.
22+
23+
Azure OpenAI requires registration and is currently only available to approved enterprise customers and partners. [See Limited access to Azure OpenAI Service](/legal/cognitive-services/openai/limited-access?context=/azure/ai-services/openai/context/context) for more information. You can apply for access to Azure OpenAI by completing the form at <a href="https://aka.ms/oai/access" target="_blank">https://aka.ms/oai/access</a>. Open an issue on this repo to contact us if you have an issue.
24+
25+
- The Azure Developer CLI [installed](/azure/developer/azure-developer-cli/install-azd) on your machine
26+
27+
## Clone and initialize the Azure Developer CLI template
28+
29+
30+
31+
1. For the steps ahead, clone and initialize the template.
32+
33+
```bash
34+
azd init --template openai-chat-your-own-data
35+
```
36+
37+
2. The `azd init` command prompts you for the following information:
38+
39+
* Environment name: This value is used as a prefix for all Azure resources created by Azure Developer CLI. The name must be unique across all Azure subscriptions and must be between 3 and 24 characters long. The name can contain numbers and lowercase letters only.
40+
41+
## Use the template to deploy resources
42+
43+
1. Sign-in to Azure:
44+
45+
```bash
46+
azd auth login
47+
```
48+
49+
1. Provision and deploy the OpenAI resource to Azure:
50+
51+
```bash
52+
azd up
53+
```
54+
55+
`azd` prompts you for the following information:
56+
57+
* Subscription: The Azure subscription that your resources are deployed to.
58+
* Location: The Azure region where your resources are deployed.
59+
60+
> [!NOTE]
61+
> The sample `azd` template uses the `gpt-35-turbo-16k` model. A recommended region for this template is East US, since different Azure regions support different OpenAI models. You can visit the [Azure OpenAI Service Models](/azure/ai-services/openai/concepts/models) support page for more details about model support by region.
62+
63+
> [!NOTE]
64+
> The provisioning process may take several minutes to complete. Wait for the task to finish before you proceed to the next steps.
65+
66+
1. Click the link `azd` outputs to navigate to the new resource group in the Azure portal. You should see the following top level resources:
67+
68+
* An Azure OpenAI service with a deployed model
69+
* An Azure Storage account you can use to upload your own data files
70+
* An Azure AI Search service configured with the proper indexes and data sources
71+
72+
## Upload data to the storage account
73+
74+
`azd` provisioned all of the required resources for you to chat with your own data, but you still need to upload the data files you want to make available to your AI service.
75+
76+
1. Navigate to the new storage account in the Azure portal.
77+
1. On the left navigation, select **Storage browser**.
78+
1. Select **Blob containers** and then navigate into the **File uploads** container.
79+
1. Click the **Upload** button at the top of the screen.
80+
1. In the flyout menu that opens, upload _contoso_benefits_document_example.pdf_ file in the root `documents` folder of the example repo.
81+
82+
> [!NOTE]
83+
> The search indexer is set to run every 5 minutes to index the data in the storage account. You can either wait a few minutes for the uploaded data to be indexed, or you can manually run the indexer from the search service page.
84+
85+
## Connect or create an application
86+
87+
After running the `azd` template and uploading your data, you're ready to start using Azure OpenAI on Your Data. See the [quickstart article](../use-your-data-quickstart.md) for code samples you can use to build your applications.

0 commit comments

Comments
 (0)