Skip to content

Commit f5d33f9

Browse files
committed
Merge branch 'main' into release-scommi
2 parents 2c4af25 + b70a526 commit f5d33f9

File tree

531 files changed

+5191
-1319
lines changed

Some content is hidden

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

531 files changed

+5191
-1319
lines changed

articles/active-directory-b2c/oauth2-error-technical-profile.md

Lines changed: 52 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ manager: CelesteDG
99
ms.service: active-directory
1010

1111
ms.topic: reference
12-
ms.date: 01/11/2024
12+
ms.date: 05/07/2024
1313
ms.author: kengaderdus
1414
ms.subservice: B2C
1515

@@ -73,6 +73,43 @@ The following example shows a technical profile for `ReturnOAuth2Error`:
7373
</ClaimsProviders> -->
7474
```
7575

76+
## Define claims transformation to generate custom values of error code and error message
77+
78+
Use these steps to generate custom values of error code and error message:
79+
80+
1. Locate the `ClaimsTransformations` element, then add the following code inside it
81+
82+
```xml
83+
<!--
84+
<ClaimsTransformations> -->
85+
<ClaimsTransformation Id="GenerateErrorCode" TransformationMethod="CreateStringClaim">
86+
<InputParameters>
87+
<InputParameter Id="value" DataType="string" Value="Error_001" />
88+
</InputParameters>
89+
<OutputClaims>
90+
<OutputClaim ClaimTypeReferenceId="errorCode" TransformationClaimType="createdClaim" />
91+
</OutputClaims>
92+
</ClaimsTransformation>
93+
<ClaimsTransformation Id="GenerateErrorMessage" TransformationMethod="CreateStringClaim">
94+
<InputParameters>
95+
<InputParameter Id="value" DataType="string" Value="Insert error description." />
96+
</InputParameters>
97+
<OutputClaims>
98+
<OutputClaim ClaimTypeReferenceId="errorMessage" TransformationClaimType="createdClaim" />
99+
</OutputClaims>
100+
</ClaimsTransformation>
101+
<!--
102+
</ClaimsTransformations> -->
103+
```
104+
105+
1. Add the two claims transformations in the `OutputClaimsTransformations` element of any technical profile before Oauth2 technical that you define:
106+
107+
```xml
108+
<OutputClaimsTransformations>
109+
<OutputClaimsTransformation ReferenceId="generateErrorCode" />
110+
<OutputClaimsTransformation ReferenceId="generateErrorMessage" />
111+
</OutputClaimsTransformations>
112+
```
76113
## Input claims
77114

78115
The **InputClaims** element contains a list of claims required to return OAuth2 error.
@@ -123,6 +160,20 @@ In the following example:
123160
</UserJourney>
124161
```
125162

163+
Optionally, you can use preconditions to manipulate the Oauth2 error technical profile. For example, if there is no email claim, you can set to call Oauth2 error technical profile:
164+
165+
```xml
166+
<OrchestrationStep Order="3" Type="SendClaims" CpimIssuerTechnicalProfileReferenceId="ReturnOAuth2Error">
167+
<Preconditions>
168+
<Precondition Type="ClaimsExist" ExecuteActionsIf="false">
169+
<Value>email</Value>
170+
<Action>SkipThisOrchestrationStep</Action>
171+
</Precondition>
172+
</Preconditions>
173+
</OrchestrationStep>
174+
```
175+
176+
126177
## Next steps
127178

128179
Learn about [UserJourneys](userjourneys.md)

articles/ai-services/openai/concepts/model-retirements.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,9 @@ These models are currently available for use in Azure OpenAI Service.
6666
| `gpt-35-turbo` | 0125 | No earlier than Feb 22, 2025 |
6767
| `gpt-4`<br>`gpt-4-32k` | 0314 | No earlier than July 13, 2024 |
6868
| `gpt-4`<br>`gpt-4-32k` | 0613 | No earlier than Sep 30, 2024 |
69-
| `gpt-4` | 1106-preview | To be upgraded to `gpt-4` Version: `turbo-2024-04-09`, starting on June 10, 2024, or later **<sup>1</sup>** |
70-
| `gpt-4` | 0125-preview |To be upgraded to `gpt-4` Version: `turbo-2024-04-09`, starting on June 10, 2024, or later **<sup>1</sup>** |
71-
| `gpt-4` | vision-preview | To be upgraded to `gpt-4` Version: `turbo-2024-04-09`, starting on June 10, 2024, or later **<sup>1</sup>** |
69+
| `gpt-4` | 1106-preview | To be upgraded to `gpt-4` Version: `turbo-2024-04-09`, starting on July 15, 2024, or later **<sup>1</sup>** |
70+
| `gpt-4` | 0125-preview |To be upgraded to `gpt-4` Version: `turbo-2024-04-09`, starting on July 15, 2024, or later **<sup>1</sup>** |
71+
| `gpt-4` | vision-preview | To be upgraded to `gpt-4` Version: `turbo-2024-04-09`, starting on July 15, 2024, or later **<sup>1</sup>** |
7272
| `gpt-3.5-turbo-instruct` | 0914 | No earlier than Sep 14, 2025 |
7373
| `text-embedding-ada-002` | 2 | No earlier than April 3, 2025 |
7474
| `text-embedding-ada-002` | 1 | No earlier than April 3, 2025 |

articles/ai-services/openai/faq.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,6 +265,7 @@ sections:
265265
answer: |
266266
* Inference cost (input and output) of the base model you're using for each Assistant (for example gpt-4-0125). If you've created multiple Assistants, you will be charged for the base model attached to each Assistant.
267267
* If you've enabled the Code Interpreter tool. For example if your assistant calls Code Interpreter simultaneously in two different threads, this would create two Code Interpreter sessions, each of which would be charged. Each session is active by default for one hour, which means that you would only pay this fee once if your user keeps giving instructions to Code Interpreter in the same thread for up to one hour.
268+
* File search is currently not billed.
268269
269270
For more information, see the [pricing page](https://azure.microsoft.com/pricing/details/cognitive-services/openai-service/).
270271
- question: |

articles/ai-services/speech-service/captioning-concepts.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ The following are aspects to consider when using captioning:
2727
* Let your audience know that captions are generated by an automated service.
2828
* Center captions horizontally on the screen, in a large and prominent font.
2929
* Consider whether to use partial results, when to start displaying captions, and how many words to show at a time.
30-
* Learn about captioning protocols such as [SMPTE-TT](https://ieeexplore.ieee.org/document/7291854).
30+
* Learn about captioning protocols such as [SMPTE-TT](https://pub.smpte.org/doc/st2052-1/20101203-pub/st2052-1-2010.pdf).
3131
* Consider output formats such as SRT (SubRip Text) and WebVTT (Web Video Text Tracks). These can be loaded onto most video players such as VLC, automatically adding the captions on to your video.
3232

3333
> [!TIP]

articles/ai-services/speech-service/includes/speech-studio-vnet.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ This section describes working with the different kind of Speech Studio projects
2626
1. In the **Resource Management** group in the left pane, select **Networking** > **Firewalls and virtual networks**.
2727
1. Select one option from **All networks**, **Selected Networks and Private Endpoints**, or **Disabled**.
2828

29-
#### Custom speech
29+
#### Custom speech, Custom voice and Audio Content Creation
3030

31-
The following table describes custom speech project accessibility per Speech resource **Networking** > **Firewalls and virtual networks** security setting.
31+
The following table describes custom speech/custom voice/audio content creation project accessibility per Speech resource **Networking** > **Firewalls and virtual networks** security setting.
3232

3333
> [!NOTE]
3434
> If you allow only private endpoints via the **Networking** > **Private endpoint connections** tab, then you can't use Speech Studio with the Speech resource. You can still use the Speech resource outside of Speech Studio.
@@ -47,6 +47,4 @@ To use custom speech without relaxing network access restrictions on your produc
4747
* Create another Speech resource for development that can be used on a public network. Prepare your custom model in Speech Studio on the development resource, and then copy the model to your production resource. See the [Models_CopyTo](/rest/api/speechtotext/models/copy-to) REST request with [Speech to text REST API](../rest-speech-to-text.md).
4848
* You have the option to not use Speech Studio for custom speech. Use the [Speech to text REST API](../rest-speech-to-text.md) for all custom speech operations.
4949

50-
#### Custom voice and Audio Content Creation
51-
52-
You can use custom voice and Audio Content Creation Speech Studio projects only when the Speech resource network security setting is **All networks**.
50+
To use custom voice without relaxing network access restrictions on your production Speech resource, consider Use the [Custom voice REST API](/rest/api/speechapi/operation-groups?&preserve-view=true=rest-speechapi-2023-12-01-preview) for all custom voice operations.

articles/ai-studio/how-to/create-projects.md

Lines changed: 70 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Create an Azure AI Studio project in Azure AI Studio
33
titleSuffix: Azure AI Studio
4-
description: This article describes how to create an Azure AI Studio project.
4+
description: This article describes how to create an Azure AI Studio project from an Azure AI Studio hub that was previously created.
55
manager: scottpolly
66
ms.service: azure-ai-studio
77
ms.custom:
@@ -12,20 +12,69 @@ ms.date: 5/21/2024
1212
ms.reviewer: deeikele
1313
ms.author: sgilley
1414
author: sdgilley
15+
# customer intent: As a developer, I want to create an Azure AI Studio project so I can work with generative AI.
1516
---
1617

1718
# Create a project in Azure AI Studio
1819

19-
This article describes how to create a project in Azure AI Studio. A project is used to organize your work and save state while building customized AI apps.
20+
This article describes how to create an Azure AI Studio project. A project is used to organize your work and save state while building customized AI apps.
2021

2122
Projects are hosted by an Azure AI Studio hub that provides enterprise-grade security and a collaborative environment. For more information about the projects and resources model, see [Azure AI Studio hubs](../concepts/ai-resources.md).
2223

2324
## Create a project
2425

26+
Use the following tabs to select the method you plan to use to create a project:
27+
28+
# [Azure AI Studio](#tab/ai-studio)
29+
2530
[!INCLUDE [Create Azure AI Studio project](../includes/create-projects.md)]
2631

32+
# [Python SDK](#tab/python)
33+
34+
[!INCLUDE [SDK setup](../includes/development-environment-config.md)]
35+
36+
8. Use the following code to create a project from a hub you or your administrator created previously. Replace example string values with your own values:
37+
38+
```Python
39+
from azure.ai.ml.entities import Project
40+
41+
my_project_name = "myexampleproject"
42+
my_location = "East US"
43+
my_display_name = "My Example Project"
44+
hub_id = "" # Azure resource manager ID of the hub
45+
46+
my_project = Project(name=my_hub_name,
47+
location=my_location,
48+
display_name=my_display_name,
49+
hub_id=created_hub.id)
50+
51+
created_project = ml_client.workspaces.begin_create(workspace=my_hub).result()
52+
```
53+
54+
# [Azure CLI](#tab/azurecli)
55+
56+
1. If you don't have the Azure CLI and machine learning extension installed, follow the steps in the [Install and set up the machine learning extension](/azure/machine-learning/how-to-configure-cli) article.
57+
58+
1. To authenticate to your Azure subscription from the Azure CLI, use the following command:
59+
60+
```azurecli
61+
az login
62+
```
63+
64+
For more information on authenticating, see [Authentication methods](/cli/azure/authenticate-azure-cli).
65+
66+
1. Once the extension is installed and authenticated to your Azure subscription, use the following command to create a new Azure AI project from an existing Azure AI hub:
67+
68+
```azurecli
69+
az ml workspace create --kind project --hub-id {my_hub_ARM_ID} --resource-group {my_resource_group} --name {my_project_name}
70+
```
71+
72+
---
73+
2774
## Project settings
2875

76+
# [Azure AI Studio](#tab/ai-studio)
77+
2978
On the project **Settings** page you can find information about the project, such as the project name, description, and the hub that hosts the project. You can also find the project ID, which is used to identify the project via SDK or API.
3079

3180
:::image type="content" source="../media/how-to/projects/project-settings.png" alt-text="Screenshot of an AI Studio project settings page." lightbox = "../media/how-to/projects/project-settings.png":::
@@ -38,6 +87,25 @@ On the project **Settings** page you can find information about the project, suc
3887

3988
Select **Manage in the Azure portal** to navigate to the project resources in the Azure portal.
4089

90+
# [Python SDK](#tab/python)
91+
92+
To manage or use the new project, include it in the `MLClient`:
93+
94+
```python
95+
ml_client = MLClient(workspace_name=my_project_name, resource_group_name=my_resource_group, subscription_id=my_subscription_id,credential=DefaultAzureCredential())
96+
```
97+
98+
# [Azure CLI](#tab/azurecli)
99+
100+
To view settings for the project, use the `az ml workspace show` command. For example:
101+
102+
```azurecli
103+
az ml workspace show --name {my_project_name} --resource-group {my_resource_group}
104+
```
105+
106+
107+
---
108+
41109
## Next steps
42110

43111
- [Deploy an enterprise chat web app](../tutorials/deploy-chat-web-app.md)
Lines changed: 66 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: How to create a hub and project using the Azure Machine Learning SDK
2+
title: How to create a hub using the Azure Machine Learning SDK/CLI
33
titleSuffix: Azure AI Studio
4-
description: This article provides instructions on how to create an AI Studio hub and project using the Azure Machine Learning SDK.
4+
description: This article provides instructions on how to create an AI Studio hub using the Azure Machine Learning SDK and Azure CLI extension.
55
manager: nitinme
66
ms.service: azure-ai-studio
77
ms.custom:
@@ -13,30 +13,48 @@ ms.author: eur
1313
author: eric-urban
1414
---
1515

16-
# Create a hub and project using the Azure Machine Learning SDK
16+
# Create a hub using the Azure Machine Learning SDK and CLI
1717

1818
[!INCLUDE [Feature preview](~/reusable-content/ce-skilling/azure/includes/ai-studio/includes/feature-preview.md)]
1919

20-
In this article, you learn how to create the following AI Studio resources using the Azure Machine Learning SDK:
20+
In this article, you learn how to create the following AI Studio resources using the Azure Machine Learning SDK and Azure CLI (with machine learning extension):
2121
- An Azure AI Studio hub
2222
- An Azure AI Services connection
23-
- An Azure AI Studio project
2423

2524
## Prerequisites
2625

2726
- An Azure subscription. If you don't have an Azure subscription, create a free account before you begin. Try the [free or paid version of Azure AI Studio](https://azure.microsoft.com/free/) today.
2827

2928
## Set up your environment
3029

30+
Use the following tabs to select whether you're using the Python SDK or Azure CLI:
31+
32+
# [Python SDK](#tab/python)
33+
3134
[!INCLUDE [SDK setup](../../includes/development-environment-config.md)]
3235

36+
# [Azure CLI](#tab/azurecli)
37+
38+
1. If you don't have the Azure CLI and machine learning extension installed, follow the steps in the [Install and set up the machine learning extension](/azure/machine-learning/how-to-configure-cli) article.
39+
40+
1. To authenticate to your Azure subscription from the Azure CLI, use the following command:
41+
42+
```azurecli
43+
az login
44+
```
45+
46+
For more information on authenticating, see [Authentication methods](/cli/azure/authenticate-azure-cli).
47+
48+
---
49+
3350
## Create the AI Studio hub and AI Services connection
3451
35-
Use the following code to create a new hub and AI Services connection. Replace example string values with your own values:
52+
Use the following examples to create a new hub. Replace example string values with your own values:
53+
54+
# [Python SDK](#tab/python)
3655
3756
```Python
3857
from azure.ai.ml.entities import Hub
39-
from azure.ai.ml.entities import AzureAIServicesConnection
4058
4159
my_hub_name = "myexamplehub"
4260
my_location = "East US"
@@ -49,49 +67,69 @@ my_hub = Hub(name=my_hub_name,
4967
5068
created_hub = ml_client.workspaces.begin_create(my_hub).result()
5169
70+
```
71+
72+
# [Azure CLI](#tab/azurecli)
73+
74+
```azurecli
75+
az ml workspace create --kind hub --resource-group {my_resource_group} --name {my_hub_name}
76+
```
77+
78+
---
79+
80+
## Create an AI Services connection
81+
82+
After creating your own AI Services, you can connect it to your hub:
83+
84+
# [Python SDK](#tab/python)
85+
86+
```python
87+
from azure.ai.ml.entities import AzureAIServicesConnection
88+
5289
# constrict an AI Services connection
5390
my_connection_name = "myaiservivce"
5491
my_endpoint = "demo.endpoint" # this could also be called target
5592
my_api_keys = None # leave blank for Authentication type = AAD
5693
my_ai_services_resource_id = "" # ARM id required
5794

58-
my_connection = AIServicesConnection(name=my_connection_name,
95+
my_connection = AzureAIServicesConnection(name=my_connection_name,
5996
endpoint=my_endpoint,
6097
api_key= my_api_keys,
6198
ai_services_resource_id=my_ai_services_resource_id)
6299

100+
# Create the connection
63101
ml_client.connections.create_or_update(my_connection)
64102
```
65103

66-
## Create AI Studio project
104+
# [Azure CLI](#tab/azurecli)
67105

68-
Use the following code to create a project from the hub you created previously. Replace example string values with your own values:
69-
70-
```Python
71-
from azure.ai.ml.entities import Project
106+
```azurecli
107+
az ml connection create --file {connection.yml} --resource-group {my_resource_group} --workspace-name {my_hub_name}
108+
```
72109

73-
my_project_name = "myexampleproject"
74-
my_location = "East US"
75-
my_display_name = "My Example Project"
110+
You can use either an API key or credential-less YAML configuration file. For more information on the YAML configuration file, see the [AI Services connection YAML schema](/azure/machine-learning/reference-yaml-connection-ai-services):
76111

77-
my_hub = Project(name=my_hub_name,
78-
location=my_location,
79-
display_name=my_display_name,
80-
hub_id=created_hub.id)
112+
- API Key example:
81113

82-
created_project = ml_client.workspaces.begin_create(workspace=my_hub).result()
83-
```
114+
```yml
115+
name: myazai_ei
116+
type: azure_ai_services
117+
endpoint: https://contoso.cognitiveservices.azure.com/
118+
api_key: XXXXXXXXXXXXXXX
119+
```
84120
85-
## Update the MLClient
121+
- Credential-less
86122
87-
To use the new project, include it in the `MLClient`.
123+
```yml
124+
name: myazai_apk
125+
type: azure_ai_services
126+
endpoint: https://contoso.cognitiveservices.azure.com/
127+
```
88128
89-
```python
90-
ml_client = MLClient(workspace_name=my_project_name, resource_group_name=my_resource_group, subscription_id=my_subscription_id,credential=DefaultAzureCredential())
91-
```
129+
---
92130
93131
## Related content
94132
95133
- [Get started building a chat app using the prompt flow SDK](../../quickstarts/get-started-code.md)
96-
- [Work with projects in VS Code](vscode.md)
134+
- [Work with projects in Visual Studio Code](vscode.md)
97135
- [Configure a managed network](../configure-managed-network.md?tabs=python)

articles/ai-studio/toc.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,11 @@ items:
4848
- name: Create a hub in the Azure portal
4949
href: how-to/create-secure-ai-hub.md
5050
- name: Create a hub from template
51-
href: how-to/create-azure-ai-hub-template.md
51+
href: how-to/create-azure-ai-hub-template.md
52+
- name: Create a hub using the Azure Machine Learning SDK and CLI
53+
href: how-to/develop/create-hub-project-sdk.md
5254
- name: Create a project
5355
href: how-to/create-projects.md
54-
- name: Create a hub and project using the Azure Machine Learning SDK
55-
href: how-to/develop/create-hub-project-sdk.md
5656
- name: Create and manage compute
5757
href: how-to/create-manage-compute.md
5858
- name: Connect to external resources

0 commit comments

Comments
 (0)