Skip to content

Commit 33f6855

Browse files
committed
fixing conflict
2 parents 0ae0cbe + cc80f89 commit 33f6855

File tree

461 files changed

+4211
-3080
lines changed

Some content is hidden

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

461 files changed

+4211
-3080
lines changed

articles/ai-services/containers/azure-kubernetes-recipe.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: aahill
77
manager: nitinme
88
ms.service: azure-ai-language
99
ms.topic: conceptual
10-
ms.date: 01/10/2022
10+
ms.date: 02/26/2024
1111
ms.author: aahi
1212
ms.custom: devx-track-azurecli
1313
ms.devlang: azurecli

articles/ai-services/language-service/whats-new.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: jboback
77
manager: nitinme
88
ms.service: azure-ai-language
99
ms.topic: whats-new
10-
ms.date: 01/31/2024
10+
ms.date: 02/26/2024
1111
ms.author: jboback
1212
---
1313

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

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ ms.service: azure-ai-openai
88
ms.topic: quickstart
99
author: aahill
1010
ms.author: aahi
11-
ms.date: 01/09/2023
11+
ms.date: 02/26/2024
1212
recommendations: false
1313
ms.custom: references_regions
1414
---
@@ -125,7 +125,12 @@ If you're using your own index, you will be prompted in the Azure OpenAI Studio
125125

126126
In this example, the fields mapped to **Content data** and **Title** provide information to the model to answer questions. **Title** is also used to title citation text. The field mapped to **File name** generates the citation names in the response.
127127

128-
Mapping these fields correctly helps ensure the model has better response and citation quality. You can additionally configure this [in the API](../reference.md#completions-extensions) using the `fieldsMapping` parameter.
128+
Mapping these fields correctly helps ensure the model has better response and citation quality. You can additionally configure this [in the API](../references/on-your-data.md) using the `fieldsMapping` parameter.
129+
130+
### Search filter (API)
131+
132+
If you want to implement additional value-based criteria for query execution, you can set up a search filter using the `filter` parameter in the [REST API](../references/azure-search.md).
133+
129134

130135
# [Azure Cosmos DB for MongoDB vCore](#tab/mongo-db)
131136

@@ -232,7 +237,7 @@ Once you have added the URL/web address for data ingestion, the web pages from y
232237

233238
Data is ingested into Azure AI search using the following process:
234239

235-
1. Ingestion assets are created in Azure AI Search resource and Azure storage account. Currently these assets are: indexers, indexes, data sources, a [custom skill](/azure/search/cognitive-search-custom-skill-interface) in the search resource, and a container (later called the chunks container) in the Azure storage account. You can specify the input Azure storage container using the [Azure OpenAI studio](https://oai.azure.com/), or the [ingestion API (preview)](../reference.md#start-an-ingestion-job-preview).
240+
1. Ingestion assets are created in Azure AI Search resource and Azure storage account. Currently these assets are: indexers, indexes, data sources, a [custom skill](/azure/search/cognitive-search-custom-skill-interface) in the search resource, and a container (later called the chunks container) in the Azure storage account. You can specify the input Azure storage container using the [Azure OpenAI studio](https://oai.azure.com/), or the [ingestion API (preview)](/rest/api/azureopenai/ingestion-jobs).
236241

237242
2. Data is read from the input container, contents are opened and chunked into small chunks with a maximum of 1,024 tokens each. If vector search is enabled, the service calculates the vector representing the embeddings on each chunk. The output of this step (called the "preprocessed" or "chunked" data) is stored in the chunks container created in the previous step.
238243

@@ -261,7 +266,7 @@ Use the following sections to learn how to improve the quality of responses give
261266

262267
### Runtime parameters
263268

264-
You can modify the following additional settings in the **Data parameters** section in Azure OpenAI Studio and [the API](../reference.md#completions-extensions). You don't need to reingest your data when you update these parameters.
269+
You can modify the following additional settings in the **Data parameters** section in Azure OpenAI Studio and [the API](../references/on-your-data.md). You don't need to reingest your data when you update these parameters.
265270

266271

267272
|Parameter name | Description |
@@ -274,7 +279,7 @@ You can modify the following additional settings in the **Data parameters** sect
274279

275280
You can define a system message to steer the model's reply when using Azure OpenAI On Your Data. This message allows you to customize your replies on top of the retrieval augmented generation (RAG) pattern that Azure OpenAI On Your Data uses. The system message is used in addition to an internal base prompt to provide the experience. To support this, we truncate the system message after a specific [number of tokens](#token-usage-estimation-for-azure-openai-on-your-data) to ensure the model can answer questions using your data. If you are defining extra behavior on top of the default experience, ensure that your system prompt is detailed and explains the exact expected customization.
276281

277-
Once you select add your dataset, you can use the **System message** section in the Azure OpenAI Studio, or the `roleInformation` [parameter in the API](../reference.md#completions-extensions).
282+
Once you select add your dataset, you can use the **System message** section in the Azure OpenAI Studio, or the `roleInformation` [parameter in the API](../references/on-your-data.md).
278283

279284
:::image type="content" source="../media/use-your-data/system-message.png" alt-text="A screenshot showing the system message option in Azure OpenAI Studio." lightbox="../media/use-your-data/system-message.png":::
280285

@@ -361,9 +366,9 @@ You can send a streaming request using the `stream` parameter, allowing data to
361366
{
362367
"type": "AzureCognitiveSearch",
363368
"parameters": {
364-
"endpoint": "'$SearchEndpoint'",
365-
"key": "'$SearchKey'",
366-
"indexName": "'$SearchIndex'"
369+
"endpoint": "'$AZURE_AI_SEARCH_ENDPOINT'",
370+
"key": "'$AZURE_AI_SEARCH_API_KEY'",
371+
"indexName": "'$AZURE_AI_SEARCH_INDEX'"
367372
}
368373
}
369374
],
@@ -386,9 +391,9 @@ When you chat with a model, providing a history of the chat will help the model
386391
{
387392
"type": "AzureCognitiveSearch",
388393
"parameters": {
389-
"endpoint": "'$SearchEndpoint'",
390-
"key": "'$SearchKey'",
391-
"indexName": "'$SearchIndex'"
394+
"endpoint": "'$AZURE_AI_SEARCH_ENDPOINT'",
395+
"key": "'$AZURE_AI_SEARCH_API_KEY'",
396+
"indexName": "'$AZURE_AI_SEARCH_INDEX'"
392397
}
393398
}
394399
],

articles/ai-services/openai/how-to/migration.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
---
22
title: How to migrate to OpenAI Python v1.x
33
titleSuffix: Azure OpenAI Service
4-
description: Learn about migrating to the latest release of the OpenAI Python library with Azure OpenAI
4+
description: Learn about migrating to the latest release of the OpenAI Python library with Azure OpenAI.
55
author: mrbullwinkle
66
ms.author: mbullwin
77
ms.service: azure-ai-openai
88
ms.custom: devx-track-python
99
ms.topic: how-to
10-
ms.date: 11/15/2023
10+
ms.date: 02/26/2024
1111
manager: nitinme
1212
---
1313

@@ -17,7 +17,7 @@ OpenAI has just released a new version of the [OpenAI Python API library](https:
1717

1818
## Updates
1919

20-
- This is a completely new version of the OpenAI Python API library.
20+
- This is a new version of the OpenAI Python API library.
2121
- Starting on November 6, 2023 `pip install openai` and `pip install openai --upgrade` will install `version 1.x` of the OpenAI Python library.
2222
- Upgrading from `version 0.28.1` to `version 1.x` is a breaking change, you'll need to test and update your code.
2323
- Auto-retry with backoff if there's an error
@@ -259,7 +259,7 @@ print(completion.model_dump_json(indent=2))
259259

260260
## Use your data
261261

262-
For the full configuration steps that are required to make these code examples work, please consult the [use your data quickstart](../use-your-data-quickstart.md).
262+
For the full configuration steps that are required to make these code examples work, consult the [use your data quickstart](../use-your-data-quickstart.md).
263263
# [OpenAI Python 0.28.1](#tab/python)
264264

265265
```python
@@ -270,10 +270,10 @@ import requests
270270

271271
dotenv.load_dotenv()
272272

273-
openai.api_base = os.environ.get("AOAIEndpoint")
273+
openai.api_base = os.environ.get("AZURE_OPENAI_ENDPOINT")
274274
openai.api_version = "2023-08-01-preview"
275275
openai.api_type = 'azure'
276-
openai.api_key = os.environ.get("AOAIKey")
276+
openai.api_key = os.environ.get("AZURE_OPENAI_API_KEY")
277277

278278
def setup_byod(deployment_id: str) -> None:
279279
"""Sets up the OpenAI Python SDK to use your own data for the chat endpoint.
@@ -299,19 +299,19 @@ def setup_byod(deployment_id: str) -> None:
299299

300300
openai.requestssession = session
301301

302-
aoai_deployment_id = os.environ.get("AOAIDeploymentId")
302+
aoai_deployment_id = os.environ.get("AZURE_OPEN_AI_DEPLOYMENT_ID")
303303
setup_byod(aoai_deployment_id)
304304

305305
completion = openai.ChatCompletion.create(
306306
messages=[{"role": "user", "content": "What are the differences between Azure Machine Learning and Azure AI services?"}],
307-
deployment_id=os.environ.get("AOAIDeploymentId"),
307+
deployment_id=os.environ.get("AZURE_OPEN_AI_DEPLOYMENT_ID"),
308308
dataSources=[ # camelCase is intentional, as this is the format the API expects
309309
{
310310
"type": "AzureCognitiveSearch",
311311
"parameters": {
312-
"endpoint": os.environ.get("SearchEndpoint"),
313-
"key": os.environ.get("SearchKey"),
314-
"indexName": os.environ.get("SearchIndex"),
312+
"endpoint": os.environ.get("AZURE_AI_SEARCH_ENDPOINT"),
313+
"key": os.environ.get("AZURE_AI_SEARCH_API_KEY"),
314+
"indexName": os.environ.get("AZURE_AI_SEARCH_INDEX"),
315315
}
316316
}
317317
]
@@ -328,9 +328,9 @@ import dotenv
328328

329329
dotenv.load_dotenv()
330330

331-
endpoint = os.environ.get("AOAIEndpoint")
332-
api_key = os.environ.get("AOAIKey")
333-
deployment = os.environ.get("AOAIDeploymentId")
331+
endpoint = os.environ.get("AZURE_OPENAI_ENDPOINT")
332+
api_key = os.environ.get("AZURE_OPENAI_API_KEY")
333+
deployment = os.environ.get("AZURE_OPEN_AI_DEPLOYMENT_ID")
334334

335335
client = openai.AzureOpenAI(
336336
base_url=f"{endpoint}/openai/deployments/{deployment}/extensions",
@@ -351,9 +351,9 @@ completion = client.chat.completions.create(
351351
{
352352
"type": "AzureCognitiveSearch",
353353
"parameters": {
354-
"endpoint": os.environ["SearchEndpoint"],
355-
"key": os.environ["SearchKey"],
356-
"indexName": os.environ["SearchIndex"]
354+
"endpoint": os.environ["AZURE_AI_SEARCH_ENDPOINT"],
355+
"key": os.environ["AZURE_AI_SEARCH_API_KEY"],
356+
"indexName": os.environ["AZURE_AI_SEARCH_INDEX"]
357357
}
358358
}
359359
]

articles/ai-services/openai/how-to/use-web-app.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ ms.service: azure-ai-openai
77
ms.topic: how-to
88
author: aahill
99
ms.author: aahi
10-
ms.date: 02/09/2024
10+
ms.date: 02/23/2024
1111
recommendations: false
1212
---
1313

@@ -33,7 +33,7 @@ Along with Azure OpenAI Studio, APIs and SDKs, you can also use the available st
3333

3434
## Web app customization
3535

36-
You can customize the app's frontend and backend logic. For example, you could change the icon that appears in the center of the app by updating `/frontend/src/assets/Contoso.svg` and then redeploying the app [using the Azure CLI](https://github.com/microsoft/sample-app-aoai-chatGPT#deploy-with-the-azure-cli). See the source code for the web app, and more information on [GitHub](https://github.com/microsoft/sample-app-aoai-chatGPT).
36+
You can customize the app's frontend and backend logic. The app provides several [environment variables](https://github.com/microsoft/sample-app-aoai-chatGPT#common-customization-scenarios-eg-updating-the-default-chat-logo-and-headers) for common customization scenarios such as changing the icon in the app. See the source code for the web app, and more information on [GitHub](https://github.com/microsoft/sample-app-aoai-chatGPT).
3737

3838
When customizing the app, we recommend:
3939

@@ -43,6 +43,8 @@ When customizing the app, we recommend:
4343

4444
- When you rotate API keys for your Azure OpenAI or Azure AI Search resource, be sure to update the app settings for each of your deployed apps to use the new keys.
4545

46+
Sample source code for the web app is available on [GitHub](https://github.com/microsoft/sample-app-aoai-chatGPT). Source code is provided "as is" and as a sample only. Customers are responsible for all customization and implementation of their web apps.
47+
4648
### Updating the web app
4749

4850
We recommend pulling changes from the `main` branch for the web app's source code frequently to ensure you have the latest bug fixes, API version, and improvements.

articles/ai-services/openai/how-to/use-your-data-securely.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,9 +90,9 @@ When using the API, pass the `filter` parameter in each API request. For example
9090
{
9191
"type": "AzureCognitiveSearch",
9292
"parameters": {
93-
"endpoint": "'$SearchEndpoint'",
94-
"key": "'$SearchKey'",
95-
"indexName": "'$SearchIndex'",
93+
"endpoint": "'$AZURE_AI_SEARCH_ENDPOINT'",
94+
"key": "'$AZURE_AI_SEARCH_API_KEY'",
95+
"indexName": "'$AZURE_AI_SEARCH_INDEX'",
9696
"filter": "my_group_ids/any(g:search.in(g, 'group_id1, group_id2'))"
9797
}
9898
}

articles/ai-services/openai/includes/use-your-data-common-variables.md

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -14,82 +14,82 @@ To successfully make a call against Azure OpenAI, you need the following variabl
1414

1515
|Variable name | Value |
1616
|--------------------------|-------------|
17-
| `AOAIEndpoint` | This value can be found in the **Keys & Endpoint** section when examining your Azure OpenAI resource from the Azure portal. Alternatively, you can find the value in **Azure AI studio** > **Chat playground** > **Code view**. An example endpoint is: `https://my-resoruce.openai.azure.com`.|
18-
| `AOAIKey` | This value can be found in **Resource management** > **Keys & Endpoint** section when examining your Azure OpenAI resource from the Azure portal. You can use either `KEY1` or `KEY2`. Always having two keys allows you to securely rotate and regenerate keys without causing a service disruption. |
19-
| `AOAIDeploymentId` | This value corresponds to the custom name you chose for your deployment when you deployed a model. This value can be found under **Resource Management** > **Deployments** in the Azure portal or alternatively under **Management** > **Deployments** in Azure AI studio.|
20-
| `SearchEndpoint` | This value can be found in the **Overview** section when examining your Azure AI Search resource from the Azure portal. |
21-
| `SearchKey` | This value can be found in the **Settings** > **Keys** section when examining your Azure AI Search resource from the Azure portal. You can use either the primary admin key or secondary admin key. Always having two keys allows you to securely rotate and regenerate keys without causing a service disruption. |
22-
| `SearchIndex` | This value corresponds to the name of the index you created to store your data. You can find it in the **Overview** section when examining your Azure AI Search resource from the Azure portal. |
17+
| `AZURE_OPENAI_ENDPOINT` | This value can be found in the **Keys & Endpoint** section when examining your Azure OpenAI resource from the Azure portal. Alternatively, you can find the value in **Azure AI studio** > **Chat playground** > **Code view**. An example endpoint is: `https://my-resoruce.openai.azure.com`.|
18+
| `AZURE_OPENAI_API_KEY` | This value can be found in **Resource management** > **Keys & Endpoint** section when examining your Azure OpenAI resource from the Azure portal. You can use either `KEY1` or `KEY2`. Always having two keys allows you to securely rotate and regenerate keys without causing a service disruption. |
19+
| `AZURE_OPEN_AI_DEPLOYMENT_ID` | This value corresponds to the custom name you chose for your deployment when you deployed a model. This value can be found under **Resource Management** > **Deployments** in the Azure portal or alternatively under **Management** > **Deployments** in Azure AI studio.|
20+
| `AZURE_AI_SEARCH_ENDPOINT` | This value can be found in the **Overview** section when examining your Azure AI Search resource from the Azure portal. |
21+
| `AZURE_AI_SEARCH_API_KEY` | This value can be found in the **Settings** > **Keys** section when examining your Azure AI Search resource from the Azure portal. You can use either the primary admin key or secondary admin key. Always having two keys allows you to securely rotate and regenerate keys without causing a service disruption. |
22+
| `AZURE_AI_SEARCH_INDEX` | This value corresponds to the name of the index you created to store your data. You can find it in the **Overview** section when examining your Azure AI Search resource from the Azure portal. |
2323

2424
### Environment variables
2525

2626
# [Command Line](#tab/command-line)
2727

2828
```CMD
29-
setx AOAIEndpoint REPLACE_WITH_YOUR_AOAI_ENDPOINT_VALUE_HERE
29+
setx AZURE_OPENAI_ENDPOINT REPLACE_WITH_YOUR_AOAI_ENDPOINT_VALUE_HERE
3030
```
3131
```CMD
32-
setx AOAIKey REPLACE_WITH_YOUR_AOAI_KEY_VALUE_HERE
32+
setx AZURE_OPENAI_API_KEY REPLACE_WITH_YOUR_AOAI_KEY_VALUE_HERE
3333
```
3434
```CMD
35-
setx AOAIDeploymentId REPLACE_WITH_YOUR_AOAI_DEPLOYMENT_VALUE_HERE
35+
setx AZURE_OPENAI_DEPLOYMENT_ID REPLACE_WITH_YOUR_AOAI_DEPLOYMENT_VALUE_HERE
3636
```
3737
```CMD
38-
setx SearchEndpoint REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_VALUE_HERE
38+
setx AZURE_AI_SEARCH_ENDPOINT REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_VALUE_HERE
3939
```
4040
```CMD
41-
setx SearchKey REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_KEY_VALUE_HERE
41+
setx AZURE_AI_SEARCH_API_KEY REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_KEY_VALUE_HERE
4242
```
4343
```CMD
44-
setx SearchIndex REPLACE_WITH_YOUR_INDEX_NAME_HERE
44+
setx AZURE_AI_SEARCH_INDEX REPLACE_WITH_YOUR_INDEX_NAME_HERE
4545
```
4646

4747

4848
# [PowerShell](#tab/powershell)
4949

5050
```powershell
51-
[System.Environment]::SetEnvironmentVariable('AOAIEndpoint', 'REPLACE_WITH_YOUR_AOAI_ENDPOINT_VALUE_HERE', 'User')
51+
[System.Environment]::SetEnvironmentVariable('AZURE_OPENAI_ENDPOINT', 'REPLACE_WITH_YOUR_AOAI_ENDPOINT_VALUE_HERE', 'User')
5252
```
5353

5454
```powershell
55-
[System.Environment]::SetEnvironmentVariable('AOAIKey', 'REPLACE_WITH_YOUR_AOAI_KEY_VALUE_HERE', 'User')
55+
[System.Environment]::SetEnvironmentVariable('AZURE_OPENAI_API_KEY', 'REPLACE_WITH_YOUR_AOAI_KEY_VALUE_HERE', 'User')
5656
```
5757

5858
```powershell
59-
[System.Environment]::SetEnvironmentVariable('AOAIDeploymentId', 'REPLACE_WITH_YOUR_AOAI_DEPLOYMENT_VALUE_HERE', 'User')
59+
[System.Environment]::SetEnvironmentVariable('AZURE_OPEN_AI_DEPLOYMENT_ID', 'REPLACE_WITH_YOUR_AOAI_DEPLOYMENT_VALUE_HERE', 'User')
6060
```
6161

6262
```powershell
63-
[System.Environment]::SetEnvironmentVariable('SearchEndpoint', 'REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_VALUE_HERE', 'User')
63+
[System.Environment]::SetEnvironmentVariable('AZURE_AI_SEARCH_ENDPOINT', 'REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_VALUE_HERE', 'User')
6464
```
6565

6666
```powershell
67-
[System.Environment]::SetEnvironmentVariable('SearchKey', 'REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_KEY_VALUE_HERE', 'User')
67+
[System.Environment]::SetEnvironmentVariable('AZURE_AI_SEARCH_API_KEY', 'REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_KEY_VALUE_HERE', 'User')
6868
```
6969

7070
```powershell
71-
[System.Environment]::SetEnvironmentVariable('SearchIndex', 'REPLACE_WITH_YOUR_INDEX_NAME_HERE', 'User')
71+
[System.Environment]::SetEnvironmentVariable('AZURE_AI_SEARCH_INDEX', 'REPLACE_WITH_YOUR_INDEX_NAME_HERE', 'User')
7272
```
7373

7474
# [Bash](#tab/bash)
7575

7676
```Bash
77-
export AOAIEndpoint=REPLACE_WITH_YOUR_AOAI_ENDPOINT_VALUE_HERE
77+
export AZURE_OPENAI_ENDPOINT=REPLACE_WITH_YOUR_AOAI_ENDPOINT_VALUE_HERE
7878
```
7979
```Bash
80-
export AOAIKey=REPLACE_WITH_YOUR_AOAI_KEY_VALUE_HERE
80+
export AZURE_OPENAI_API_KEY=REPLACE_WITH_YOUR_AOAI_KEY_VALUE_HERE
8181
```
8282
```Bash
83-
export AOAIDeploymentId=REPLACE_WITH_YOUR_AOAI_DEPLOYMENT_VALUE_HERE
83+
export AZURE_OPEN_AI_DEPLOYMENT_ID=REPLACE_WITH_YOUR_AOAI_DEPLOYMENT_VALUE_HERE
8484
```
8585
```Bash
86-
export SearchEndpoint=REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_VALUE_HERE
86+
export AZURE_AI_SEARCH_ENDPOINT=REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_VALUE_HERE
8787
```
8888
```Bash
89-
export SearchKey=REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_KEY_VALUE_HERE
89+
export AZURE_AI_SEARCH_API_KEY=REPLACE_WITH_YOUR_AZURE_SEARCH_RESOURCE_KEY_VALUE_HERE
9090
```
9191
```Bash
92-
export SearchIndex=REPLACE_WITH_YOUR_INDEX_NAME_HERE
92+
export AZURE_AI_SEARCH_INDEX=REPLACE_WITH_YOUR_INDEX_NAME_HERE
9393
```
9494

9595
---

0 commit comments

Comments
 (0)