Skip to content

Commit 7eceb76

Browse files
committed
Merge branch 'main' of https://github.com/MicrosoftDocs/azure-docs-pr into atm-howto
2 parents 789ee8b + fb6ae69 commit 7eceb76

File tree

226 files changed

+8879
-6379
lines changed

Some content is hidden

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

226 files changed

+8879
-6379
lines changed

.openpublishing.publish.config.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,12 @@
254254
"branch": "main",
255255
"branch_mapping": {}
256256
},
257+
{
258+
"path_to_root": "function-flex-consumption",
259+
"url": "https://github.com/Azure-Samples/azure-functions-flex-consumption-samples",
260+
"branch": "main",
261+
"branch_mapping": {}
262+
},
257263
{
258264
"path_to_root": "functions-azure-product",
259265
"url": "https://github.com/Azure/Azure-Functions",
@@ -506,6 +512,12 @@
506512
"branch": "sdk-codetest",
507513
"branch_mapping": {}
508514
},
515+
{
516+
"path_to_root": "rag-data-openai-python-promptflow-main",
517+
"url": "https://github.com/Azure-Samples/rag-data-openai-python-promptflow",
518+
"branch": "main",
519+
"branch_mapping": {}
520+
},
509521
{
510522
"path_to_root": "azureml-examples-main",
511523
"url": "https://github.com/azure/azureml-examples",

articles/ai-services/content-safety/includes/quickstarts/rest-quickstart-image.md

Lines changed: 22 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,7 @@ curl --location --request POST '<endpoint>/contentsafety/image:analyze?api-versi
5151
"image": {
5252
"content": "<base_64_string>"
5353
},
54-
"categories": [
55-
"Hate", "SelfHarm", "Sexual", "Violence"
56-
],
54+
"categories": ["Hate", "SelfHarm", "Sexual", "Violence"],
5755
"outputType": "FourSeverityLevels"
5856
}'
5957
```
@@ -63,9 +61,9 @@ curl --location --request POST '<endpoint>/contentsafety/image:analyze?api-versi
6361
>
6462
> ```
6563
> {
66-
> "image": {
67-
> "blobUrl": "<your_storage_url>"
68-
> }
64+
> "image": {
65+
> "blobUrl": "<your_storage_url>"
66+
> }
6967
> }
7068
> ```
7169
@@ -91,24 +89,24 @@ You should see the image moderation results displayed as JSON data in the consol
9189
9290
```json
9391
{
94-
"categoriesAnalysis": [
95-
{
96-
"category": "Hate",
97-
"severity": 2
98-
},
99-
{
100-
"category": "SelfHarm",
101-
"severity": 0
102-
},
103-
{
104-
"category": "Sexual",
105-
"severity": 0
106-
},
107-
{
108-
"category": "Violence",
109-
"severity": 0
110-
}
111-
]
92+
"categoriesAnalysis": [
93+
{
94+
"category": "Hate",
95+
"severity": 2
96+
},
97+
{
98+
"category": "SelfHarm",
99+
"severity": 0
100+
},
101+
{
102+
"category": "Sexual",
103+
"severity": 0
104+
},
105+
{
106+
"category": "Violence",
107+
"severity": 0
108+
}
109+
]
112110
}
113111
```
114112

articles/ai-services/content-safety/includes/quickstarts/rest-quickstart-text.md

Lines changed: 22 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,10 @@ curl --location --request POST '<endpoint>/contentsafety/text:analyze?api-versio
3636
--header 'Content-Type: application/json' \
3737
--data-raw '{
3838
"text": "I hate you",
39-
"categories": [
40-
"Hate","Sexual","SelfHarm","Violence"
41-
],
42-
"blocklistNames": [
43-
"string"
44-
],
45-
"haltOnBlocklistHit": true,
46-
"outputType": "FourSeverityLevels"
39+
"categories": ["Hate", "Sexual", "SelfHarm", "Violence"],
40+
"blocklistNames": ["string"],
41+
"haltOnBlocklistHit": true,
42+
"outputType": "FourSeverityLevels"
4743
}'
4844
```
4945

@@ -68,12 +64,8 @@ See the following sample request body:
6864
```json
6965
{
7066
"text": "I hate you",
71-
"categories": [
72-
"Hate","Sexual","SelfHarm","Violence"
73-
],
74-
"blocklistNames": [
75-
"array"
76-
],
67+
"categories": ["Hate", "Sexual", "SelfHarm", "Violence"],
68+
"blocklistNames": ["array"],
7769
"haltOnBlocklistHit": false,
7870
"outputType": "FourSeverityLevels"
7971
}
@@ -96,21 +88,22 @@ You should see the text moderation results displayed as JSON data in the console
9688
}
9789
],
9890
"categoriesAnalysis": [
99-
{
100-
"category": "Hate",
101-
"severity": 2
102-
},
103-
{
104-
"category": "SelfHarm",
105-
"severity": 0
106-
},
107-
{
108-
"category": "Sexual",
109-
"severity": 0
110-
},
111-
{
112-
"category": "Violence",
113-
"severity": 0
91+
{
92+
"category": "Hate",
93+
"severity": 2
94+
},
95+
{
96+
"category": "SelfHarm",
97+
"severity": 0
98+
},
99+
{
100+
"category": "Sexual",
101+
"severity": 0
102+
},
103+
{
104+
"category": "Violence",
105+
"severity": 0
106+
}
114107
]
115108
}
116109
```

articles/ai-services/content-safety/quickstart-custom-categories.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ curl -X PUT "<your_endpoint>/contentsafety/text/categories/survival-advice?api-v
6161
-H "Ocp-Apim-Subscription-Key: <your_api_key>" \
6262
-H "Content-Type: application/json" \
6363
-d "{
64-
\"categoryName\": \"survival-advice\",
65-
\"definition\": \"text prompts about survival advice in camping/wilderness situations\",
66-
\"sampleBlobUrl\": \"https://<your-azure-storage-url>/example-container/survival-advice.jsonl\"
64+
\"categoryName\": \"survival-advice\",
65+
\"definition\": \"text prompts about survival advice in camping/wilderness situations\",
66+
\"sampleBlobUrl\": \"https://<your-azure-storage-url>/example-container/survival-advice.jsonl\"
6767
}"
6868
```
6969

@@ -95,9 +95,9 @@ curl -X POST "<your_endpoint>/contentsafety/text:analyzeCustomCategory?api-versi
9595
-H "Ocp-Apim-Subscription-Key: <your_api_key>" \
9696
-H "Content-Type: application/json" \
9797
-d "{
98-
\"text\": \"<Example text to analyze>\",
99-
\"categoryName\": \"survival-advice\",
100-
\"version\": 1
98+
\"text\": \"<Example text to analyze>\",
99+
\"categoryName\": \"survival-advice\",
100+
\"version\": 1
101101
}"
102102
```
103103

articles/ai-services/content-safety/quickstart-groundedness.md

Lines changed: 35 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ This section walks through a sample request with cURL. Paste the command below i
4545
"domain": "Generic",
4646
"task": "QnA",
4747
"qna": {
48-
"query": "How much does she currently get paid per hour at the bank?"
48+
"query": "How much does she currently get paid per hour at the bank?"
4949
},
5050
"text": "12/hour",
5151
"groundingSources": [
@@ -108,11 +108,13 @@ To test a summarization task instead of a question answering (QnA) task, use the
108108
109109
```json
110110
{
111-
"domain": "Medical",
112-
"task": "Summarization",
113-
"text": "Ms Johnson has been in the hospital after experiencing a stroke.",
114-
"groundingSources": ["Our patient, Ms. Johnson, presented with persistent fatigue, unexplained weight loss, and frequent night sweats. After a series of tests, she was diagnosed with Hodgkin’s lymphoma, a type of cancer that affects the lymphatic system. The diagnosis was confirmed through a lymph node biopsy revealing the presence of Reed-Sternberg cells, a characteristic of this disease. She was further staged using PET-CT scans. Her treatment plan includes chemotherapy and possibly radiation therapy, depending on her response to treatment. The medical team remains optimistic about her prognosis given the high cure rate of Hodgkin’s lymphoma."],
115-
"reasoning": false
111+
"domain": "Medical",
112+
"task": "Summarization",
113+
"text": "Ms Johnson has been in the hospital after experiencing a stroke.",
114+
"groundingSources": [
115+
"Our patient, Ms. Johnson, presented with persistent fatigue, unexplained weight loss, and frequent night sweats. After a series of tests, she was diagnosed with Hodgkin’s lymphoma, a type of cancer that affects the lymphatic system. The diagnosis was confirmed through a lymph node biopsy revealing the presence of Reed-Sternberg cells, a characteristic of this disease. She was further staged using PET-CT scans. Her treatment plan includes chemotherapy and possibly radiation therapy, depending on her response to treatment. The medical team remains optimistic about her prognosis given the high cure rate of Hodgkin’s lymphoma."
116+
],
117+
"reasoning": false
116118
}
117119
```
118120

@@ -140,13 +142,13 @@ After you submit your request, you'll receive a JSON response reflecting the Gro
140142

141143
```json
142144
{
143-
"ungroundedDetected": true,
144-
"ungroundedPercentage": 1,
145-
"ungroundedDetails": [
146-
{
147-
"text": "12/hour."
148-
}
149-
]
145+
"ungroundedDetected": true,
146+
"ungroundedPercentage": 1,
147+
"ungroundedDetails": [
148+
{
149+
"text": "12/hour."
150+
}
151+
]
150152
}
151153
```
152154

@@ -176,7 +178,7 @@ In order to use your Azure OpenAI GPT4-Turbo (1106-preview) resource to enable t
176178
In your request to the Groundedness detection API, set the `"reasoning"` body parameter to `true`, and provide the other needed parameters:
177179

178180
```json
179-
{
181+
{
180182
"reasoning": true,
181183
"llmResource": {
182184
"resourceType": "AzureOpenAI",
@@ -203,7 +205,7 @@ This section walks through a sample request with cURL. Paste the command below i
203205
"domain": "Generic",
204206
"task": "QnA",
205207
"qna": {
206-
"query": "How much does she currently get paid per hour at the bank?"
208+
"query": "How much does she currently get paid per hour at the bank?"
207209
},
208210
"text": "12/hour",
209211
"groundingSources": [
@@ -291,24 +293,24 @@ After you submit your request, you'll receive a JSON response reflecting the Gro
291293

292294
```json
293295
{
294-
"ungroundedDetected": true,
295-
"ungroundedPercentage": 1,
296-
"ungroundedDetails": [
297-
{
298-
"text": "12/hour.",
299-
"offset": {
300-
"utf8": 0,
301-
"utf16": 0,
302-
"codePoint": 0
303-
},
304-
"length": {
305-
"utf8": 8,
306-
"utf16": 8,
307-
"codePoint": 8
308-
},
309-
"reason": "None. The premise mentions a pay of \"10/hour\" but does not mention \"12/hour.\" It's neutral. "
310-
}
311-
]
296+
"ungroundedDetected": true,
297+
"ungroundedPercentage": 1,
298+
"ungroundedDetails": [
299+
{
300+
"text": "12/hour.",
301+
"offset": {
302+
"utf8": 0,
303+
"utf16": 0,
304+
"codePoint": 0
305+
},
306+
"length": {
307+
"utf8": 8,
308+
"utf16": 8,
309+
"codePoint": 8
310+
},
311+
"reason": "None. The premise mentions a pay of \"10/hour\" but does not mention \"12/hour.\" It's neutral. "
312+
}
313+
]
312314
}
313315
```
314316

articles/ai-services/content-safety/quickstart-protected-material.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ curl --location --request POST '<endpoint>/contentsafety/text:detectProtectedMat
3737
--header 'Ocp-Apim-Subscription-Key: <your_subscription_key>' \
3838
--header 'Content-Type: application/json' \
3939
--data-raw '{
40-
"text": "to everyone, the best things in life are free. the stars belong to everyone, they gleam there for you and me. the flowers in spring, the robins that sing, the sunbeams that shine, they\'re yours, they\'re mine. and love can come to everyone, the best things in life are"
40+
"text": "to everyone, the best things in life are free. the stars belong to everyone, they gleam there for you and me. the flowers in spring, the robins that sing, the sunbeams that shine"
4141
}'
4242
```
4343
The below fields must be included in the url:

articles/ai-services/content-safety/studio-quickstart.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ In this quickstart, get started with the Azure AI Content Safety service using C
2323

2424
* An active Azure account. If you don't have one, you can [create one for free](https://azure.microsoft.com/free/cognitive-services/).
2525
* A [Content Safety](https://aka.ms/acs-create) Azure resource.
26-
* The `Cognitive Services User` role assigned to the Content Safety resource in the desired Azure subscription.
26+
* Assign `Cognitive Services User` role to your account to ensure the studio experience. Go to [Azure Portal](https://portal.azure.com/), navigate to your Content Safety resource or Azure AI Services resource, and select **Access Control** in the left navigation bar, then click **+ Add role assignment**, choose the `Cognitive Services User` role and select the memeber of your account that you need to assign this role to, then review and assign. It might take few minutes for the assignment to take effect.
2727
* Sign in to [Content Safety Studio](https://contentsafety.cognitive.azure.com) with your Azure subscription and Content Safety resource.
2828

2929

307 KB
Loading

articles/ai-services/language-service/toc.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -801,6 +801,8 @@ items:
801801
href: tutorials/use-kubernetes-service.md
802802
- name: Use language in power automate flows
803803
href: tutorials/power-automate.md
804+
- name: Use language in prompt flow
805+
href: tutorials/prompt-flow.md
804806
- name: 🆕 Native document support
805807
items:
806808
- name: 🆕 Use native documents for language processing

0 commit comments

Comments
 (0)