Skip to content

Commit 3d0c1ea

Browse files
committed
feedback
1 parent 87d5343 commit 3d0c1ea

File tree

5 files changed

+29
-29
lines changed

5 files changed

+29
-29
lines changed

articles/ai-services/translator/containers/install-run.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: laujan
77
manager: nitinme
88
ms.service: azure-ai-translator
99
ms.topic: how-to
10-
ms.date: 04/19/2024
10+
ms.date: 06/20/2024
1111
ms.author: lajanuar
1212
recommendations: false
1313
keywords: on-premises, Docker, container, identify
@@ -312,7 +312,7 @@ The following example shows the formatting for the `docker run` command with pla
312312
|:-------------|:-------|:---:|
313313
| `[image]` | The container image you want to use. | `mcr.microsoft.com/azure-cognitive-services/translator/text-translation` |
314314
| `{LICENSE_MOUNT}` | The path where the license is downloaded, and mounted. | `/host/license:/path/to/license/directory` |
315-
| `{MODEL_MOUNT_PATH}`| The path where the machine translation models are downloaded, and mounted. Your directory structure must be formatted as **/usr/local/models** | `/host/translator/models:/usr/local/models`|
315+
| `{MODEL_MOUNT_PATH}`| The path where the machine translation models are downloaded, and mounted. Your directory structure must be formatted as **/usr/local/models** | `/host/translator/models:/usr/local/models`|
316316
| `{ENDPOINT_URI}` | The endpoint for authenticating your service request. You can find it on your resource's **Key and endpoint** page, in the Azure portal. | `https://<your-custom-subdomain>.cognitiveservices.azure.com` |
317317
| `{API_KEY}` | The key for your Text Translation resource. You can find it on your resource's **Key and endpoint** page, in the Azure portal. |`{string}`|
318318
| `{LANGUAGES_LIST}` | List of language codes separated by commas. It's mandatory to have English (en) language as part of the list.| `en`, `fr`, `it`, `zu`, `uk` |
@@ -477,15 +477,15 @@ If you installed Docker Desktop CLI, it includes Docker compose and its prerequi
477477
image: mcr.microsoft.com/azure-cognitive-services/textanalytics/language:latest
478478
environment:
479479
- EULA=accept
480-
- billing={TRANSLATOR_ENDPOINT_URI}
481-
- apiKey={TRANSLATOR_KEY}
480+
- billing={LANGUAGE_RESOURCE_ENDPOINT_URI}
481+
- apiKey={LANGUAGE_RESOURCE_KEY}
482482
azure-ai-read:
483483
container_name: azure-ai-read
484484
image: mcr.microsoft.com/azure-cognitive-services/vision/read:latest
485485
environment:
486486
- EULA=accept
487-
- billing={TRANSLATOR_ENDPOINT_URI}
488-
- apiKey={TRANSLATOR_KEY}
487+
- billing={COMPUTER_VISION_ENDPOINT_URI}
488+
- apiKey={COMPUTER_VISION_KEY}
489489
```
490490
491491
1. Open a terminal navigate to the `container-environment` folder, and start the containers with the following `docker-compose` command:

articles/ai-services/translator/document-translation/document-sdk-overview.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ DocumentTranslationInput input = new DocumentTranslationInput(sourceUri, targetU
176176

177177
***Synchronous single document translation***
178178

179-
[Single document translation](/dotnet/api/overview/azure/ai.translation.document-readme?view=azure-dotnet-preview#single-document-translation&preserve-view=true)
179+
[Single document translation](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/translation/Azure.AI.Translation.Document/samples/Sample5_SynchronousTranslation.md)
180180
181181
### [Python](#tab/python)
182182

articles/ai-services/translator/document-translation/quickstarts/rest-api.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -92,13 +92,13 @@ Before you run the **POST** request, replace `{your-document-translator-endpoint
9292
***PowerShell***
9393

9494
```powershell
95-
cmd /c curl "{your-document-translator-endpoint}/translator/text/batch/v1.1/batches" -i -X POST --header "Content-Type: application/json" --header "Ocp-Apim-Subscription-Key: {your-key}" --data "@document-translation.json"
95+
cmd /c curl "{document-translation-endpoint}/translator/document/batches?api-version={date}" -i -X POST --header "Content-Type: application/json" --header "Ocp-Apim-Subscription-Key: {your-key}" --data "@document-translation.json"
9696
```
9797

9898
***command prompt / terminal***
9999

100-
```curl
101-
curl "{your-document-translator-endpoint}/translator/text/batch/v1.1/batches" -i -X POST --header "Content-Type: application/json" --header "Ocp-Apim-Subscription-Key: {your-key}" --data "@document-translation.json"
100+
```bash
101+
curl "{document-translation-endpoint}/translator/document/batches?api-version={date}" -i -X POST --header "Content-Type: application/json" --header "Ocp-Apim-Subscription-Key: {your-key}" --data "@document-translation.json"
102102
```
103103

104104
Upon successful completion:
@@ -142,13 +142,13 @@ To call the synchronous translation feature via the [REST API](../reference/sync
142142

143143
```bash
144144

145-
curl -i -X POST "{your-document-translation-endpoint}/translator/document:translate?sourceLanguage=en&targetLanguage=hi&api-version=2023-11-01-preview" -H "Ocp-Apim-Subscription-Key:{your-key}" -F "document={path-to-your-document-with-file-extension};type={ContentType}/{file-extension}" -F "glossary={path-to-your-glossary-with-file-extension};type={ContentType}/{file-extension}" -o "{path-to-output-file}"
145+
curl -i -X POST "{document-translation-endpoint}/translator/document:translate?targetLanguage={target_language}&api-version={date}" -H "Ocp-Apim-Subscription-Key:{your-key}" -F "document={path-to-your-document-with-file-extension};type={ContentType}/{file-extension}" -F "glossary={path-to-your-glossary-with-file-extension};type={ContentType}/{file-extension}" -o "{path-to-output-file}"
146146
```
147147

148148
***PowerShell***
149149

150150
```powershell
151-
cmd /c curl "{your-document-translation-endpoint}/translator/document:translate?sourceLanguage=en&targetLanguage=es&api-version=2023-11-01-preview" -i -X POST -H "Ocp-Apim-Subscription-Key: {your-key}" -F "{path-to-your-document-with-file-extension};type=text/{file-extension}" -o "{path-to-output-file}
151+
cmd /c curl "{document-translation-endpoint}/translator/document:translate?targetLanguage={target_language}&api-version={date}" -i -X POST -H "Ocp-Apim-Subscription-Key: {your-key}" -F "{path-to-your-document-with-file-extension};type=text/{file-extension}" -o "{path-to-output-file}
152152
153153
```
154154
@@ -164,4 +164,4 @@ That's it, congratulations! You just learned to translate documents using the Az
164164
## Next steps
165165
166166
> [!div class="nextstepaction"]
167-
> [Document Translation REST API guide](../reference/rest-api-guide.md "Learn more about Document Translation REST API operations).
167+
> [Document Translation REST API guide](../reference/rest-api-guide.md "Learn more about Document Translation REST API operations)

articles/ai-services/translator/document-translation/reference/start-batch-translation.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,6 @@ HTTP method: **POST**
2323
* Use the `Start Translation` method to execute an asynchronous batch translation request.
2424
* The method requires an Azure Blob storage account with storage containers for your source and translated documents.
2525

26-
> [!TIP]
27-
> This method returns the job `id` parameter for the [get-translation-status](get-translation-status.md), [get-documents-status](get-documents-status.md), [get-document-status](get-document-status.md), and [cancel-translation](cancel-translation.md) request query strings.
28-
29-
* You can find the job `id` in the POST `start-batch-translation` method response Header `Operation-Location` URL value. The alphanumeric string following the `/document/` parameter is the operation's job **`id`**:
30-
31-
|**Response header**|**Response URL**|
32-
|-----------------------|----------------|
33-
|Operation-Location | {document-translation-endpoint}/translator/document/`9dce0aa9-78dc-41ba-8cae-2e2f3c2ff8ec`?api-version=2024-05-01|
34-
35-
* You can also use a [get-translations-status](../reference/get-translations-status.md) request to retrieve a list of translation jobs and their `id`s.
36-
3726
## Request URL
3827

3928
> [!IMPORTANT]
@@ -63,7 +52,7 @@ Request headers are:
6352

6453
* Glossaries can be included in the request. If the glossary is invalid or unreachable during translation, an error is indicated in the document status.
6554

66-
* If a file with the same name already exists in the target destination, the job fails.
55+
* If a file with the same name already exists in the target destination, the job fails.
6756

6857
* The targetUrl for each target language must be unique.
6958

@@ -274,6 +263,17 @@ This sample request shows a single document translated into two target languages
274263
}
275264
```
276265

266+
> [!TIP]
267+
> This method returns the job `id` parameter for the [get-translation-status](get-translation-status.md), [get-documents-status](get-documents-status.md), [get-document-status](get-document-status.md), and [cancel-translation](cancel-translation.md) request query strings.
268+
269+
* You can find the job `id` in the POST `start-batch-translation` method response Header `Operation-Location` URL value. The alphanumeric string following the `/document/` parameter is the operation's job **`id`**:
270+
271+
|**Response header**|**Response URL**|
272+
|-----------------------|----------------|
273+
|Operation-Location | {document-translation-endpoint}/translator/document/`9dce0aa9-78dc-41ba-8cae-2e2f3c2ff8ec`?api-version=2024-05-01|
274+
275+
* You can also use a [get-translations-status](../reference/get-translations-status.md) request to retrieve a list of translation jobs and their `id`s.
276+
277277
## Response status codes
278278

279279
The following are the possible HTTP status codes that a request returns.

articles/ai-services/translator/toc.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -125,15 +125,15 @@ items:
125125
href: document-translation/reference/rest-api-guide.md
126126
- name: Quickstarts
127127
items:
128-
- name: "🆕 Quickstart: Document Translation client libraries"
128+
- name: "Quickstart: Document Translation client libraries"
129129
displayName: batch,c#,dotnet,.net,python,blob,set up,install,cli,storage,domain,custom domain
130130
href: document-translation/quickstarts/client-library-sdks.md
131-
- name: "🆕 Quickstart: Document Translation REST APIs"
131+
- name: "Quickstart: Document Translation REST APIs"
132132
displayName: get,post,cancel,delete
133133
href: document-translation/quickstarts/rest-api.md
134134
- name: How-to guides
135135
items:
136-
- name: 🆕 Use Document Translation APIs programmatically
136+
- name: Use Document Translation APIs programmatically
137137
displayName: get started,batch,sdk,c#,.net,dotnet,python,javascript,java,go,source,target,blob,set up,storage
138138
href: document-translation/how-to-guides/use-rest-api-programmatically.md
139139
- name: Authentication and authorization
@@ -146,7 +146,7 @@ items:
146146
href: document-translation/how-to-guides/create-sas-tokens.md
147147
- name: Reference
148148
items:
149-
- name: 🆕 Document Translation operations
149+
- name: Document Translation operations
150150
href: document-translation/reference/rest-api-guide.md
151151
- name: Translate a single document
152152
href: document-translation/reference/translate-document.md

0 commit comments

Comments
 (0)