From 2a70f0ca5267348ec2742c33ef1ea3a37d73af62 Mon Sep 17 00:00:00 2001 From: awstools Date: Wed, 6 Dec 2023 19:19:16 +0000 Subject: [PATCH] docs(client-comprehend): Documentation updates for Trust and Safety features. --- .../commands/BatchDetectEntitiesCommand.ts | 4 +- .../commands/BatchDetectKeyPhrasesCommand.ts | 4 +- .../commands/BatchDetectSentimentCommand.ts | 4 +- .../src/commands/BatchDetectSyntaxCommand.ts | 4 +- .../BatchDetectTargetedSentimentCommand.ts | 4 +- .../src/commands/ClassifyDocumentCommand.ts | 13 +-- .../commands/ContainsPiiEntitiesCommand.ts | 4 +- .../CreateDocumentClassifierCommand.ts | 4 +- .../commands/CreateEntityRecognizerCommand.ts | 4 +- .../src/commands/CreateFlywheelCommand.ts | 4 +- .../src/commands/DetectEntitiesCommand.ts | 4 +- .../src/commands/DetectKeyPhrasesCommand.ts | 4 +- .../src/commands/DetectPiiEntitiesCommand.ts | 4 +- .../src/commands/DetectSentimentCommand.ts | 4 +- .../src/commands/DetectSyntaxCommand.ts | 4 +- .../DetectTargetedSentimentCommand.ts | 4 +- .../src/commands/DetectToxicContentCommand.ts | 9 +- .../StartDocumentClassificationJobCommand.ts | 2 +- .../client-comprehend/src/models/models_0.ts | 95 +++++++++---------- .../sdk-codegen/aws-models/comprehend.json | 34 +++---- 20 files changed, 88 insertions(+), 125 deletions(-) diff --git a/clients/client-comprehend/src/commands/BatchDetectEntitiesCommand.ts b/clients/client-comprehend/src/commands/BatchDetectEntitiesCommand.ts index 315138928709..b5f7320ebe6d 100644 --- a/clients/client-comprehend/src/commands/BatchDetectEntitiesCommand.ts +++ b/clients/client-comprehend/src/commands/BatchDetectEntitiesCommand.ts @@ -120,9 +120,7 @@ export interface BatchDetectEntitiesCommandOutput extends BatchDetectEntitiesRes *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/BatchDetectKeyPhrasesCommand.ts b/clients/client-comprehend/src/commands/BatchDetectKeyPhrasesCommand.ts index 070ddde83294..5d18e57f1946 100644 --- a/clients/client-comprehend/src/commands/BatchDetectKeyPhrasesCommand.ts +++ b/clients/client-comprehend/src/commands/BatchDetectKeyPhrasesCommand.ts @@ -102,9 +102,7 @@ export interface BatchDetectKeyPhrasesCommandOutput extends BatchDetectKeyPhrase *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/BatchDetectSentimentCommand.ts b/clients/client-comprehend/src/commands/BatchDetectSentimentCommand.ts index 9b02d0942834..1ce9d9e6cdc0 100644 --- a/clients/client-comprehend/src/commands/BatchDetectSentimentCommand.ts +++ b/clients/client-comprehend/src/commands/BatchDetectSentimentCommand.ts @@ -103,9 +103,7 @@ export interface BatchDetectSentimentCommandOutput extends BatchDetectSentimentR *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/BatchDetectSyntaxCommand.ts b/clients/client-comprehend/src/commands/BatchDetectSyntaxCommand.ts index d010fe8687a0..ba33347893b2 100644 --- a/clients/client-comprehend/src/commands/BatchDetectSyntaxCommand.ts +++ b/clients/client-comprehend/src/commands/BatchDetectSyntaxCommand.ts @@ -109,9 +109,7 @@ export interface BatchDetectSyntaxCommandOutput extends BatchDetectSyntaxRespons *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/BatchDetectTargetedSentimentCommand.ts b/clients/client-comprehend/src/commands/BatchDetectTargetedSentimentCommand.ts index 09cc2323b67d..d8742fbe0e6a 100644 --- a/clients/client-comprehend/src/commands/BatchDetectTargetedSentimentCommand.ts +++ b/clients/client-comprehend/src/commands/BatchDetectTargetedSentimentCommand.ts @@ -127,9 +127,7 @@ export interface BatchDetectTargetedSentimentCommandOutput *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/ClassifyDocumentCommand.ts b/clients/client-comprehend/src/commands/ClassifyDocumentCommand.ts index 0f0464dbe5a3..437b96887abc 100644 --- a/clients/client-comprehend/src/commands/ClassifyDocumentCommand.ts +++ b/clients/client-comprehend/src/commands/ClassifyDocumentCommand.ts @@ -47,18 +47,19 @@ export interface ClassifyDocumentCommandOutput extends ClassifyDocumentResponse, * *

If the system detects errors while processing a page in the input document, - * the API response includes an entry in Errors that describes the errors.

+ * the API response includes an Errors field that describes the errors.

*

If the system detects a document-level error in your input document, the API returns an * InvalidRequestException error response. * For details about this exception, see diff --git a/clients/client-comprehend/src/commands/ContainsPiiEntitiesCommand.ts b/clients/client-comprehend/src/commands/ContainsPiiEntitiesCommand.ts index b51bb5801e2d..58357c418abd 100644 --- a/clients/client-comprehend/src/commands/ContainsPiiEntitiesCommand.ts +++ b/clients/client-comprehend/src/commands/ContainsPiiEntitiesCommand.ts @@ -79,9 +79,7 @@ export interface ContainsPiiEntitiesCommandOutput extends ContainsPiiEntitiesRes *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/CreateDocumentClassifierCommand.ts b/clients/client-comprehend/src/commands/CreateDocumentClassifierCommand.ts index c1b258fa3af8..296849f3e963 100644 --- a/clients/client-comprehend/src/commands/CreateDocumentClassifierCommand.ts +++ b/clients/client-comprehend/src/commands/CreateDocumentClassifierCommand.ts @@ -150,9 +150,7 @@ export interface CreateDocumentClassifierCommandOutput extends CreateDocumentCla * current request.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/CreateEntityRecognizerCommand.ts b/clients/client-comprehend/src/commands/CreateEntityRecognizerCommand.ts index 513feb2988b7..41997eaf734e 100644 --- a/clients/client-comprehend/src/commands/CreateEntityRecognizerCommand.ts +++ b/clients/client-comprehend/src/commands/CreateEntityRecognizerCommand.ts @@ -143,9 +143,7 @@ export interface CreateEntityRecognizerCommandOutput extends CreateEntityRecogni * current request.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/CreateFlywheelCommand.ts b/clients/client-comprehend/src/commands/CreateFlywheelCommand.ts index 98cfd58e5606..9957d79e65ab 100644 --- a/clients/client-comprehend/src/commands/CreateFlywheelCommand.ts +++ b/clients/client-comprehend/src/commands/CreateFlywheelCommand.ts @@ -146,9 +146,7 @@ export interface CreateFlywheelCommandOutput extends CreateFlywheelResponse, __M * current request.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/DetectEntitiesCommand.ts b/clients/client-comprehend/src/commands/DetectEntitiesCommand.ts index f27f20b596c4..b1b2bf2b8e51 100644 --- a/clients/client-comprehend/src/commands/DetectEntitiesCommand.ts +++ b/clients/client-comprehend/src/commands/DetectEntitiesCommand.ts @@ -179,9 +179,7 @@ export interface DetectEntitiesCommandOutput extends DetectEntitiesResponse, __M *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/DetectKeyPhrasesCommand.ts b/clients/client-comprehend/src/commands/DetectKeyPhrasesCommand.ts index 5c8b731e56f8..f56dc063bfb9 100644 --- a/clients/client-comprehend/src/commands/DetectKeyPhrasesCommand.ts +++ b/clients/client-comprehend/src/commands/DetectKeyPhrasesCommand.ts @@ -84,9 +84,7 @@ export interface DetectKeyPhrasesCommandOutput extends DetectKeyPhrasesResponse, *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/DetectPiiEntitiesCommand.ts b/clients/client-comprehend/src/commands/DetectPiiEntitiesCommand.ts index 83418c3bdc0b..f14b8bc290f0 100644 --- a/clients/client-comprehend/src/commands/DetectPiiEntitiesCommand.ts +++ b/clients/client-comprehend/src/commands/DetectPiiEntitiesCommand.ts @@ -80,9 +80,7 @@ export interface DetectPiiEntitiesCommandOutput extends DetectPiiEntitiesRespons *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/DetectSentimentCommand.ts b/clients/client-comprehend/src/commands/DetectSentimentCommand.ts index 4206159fabba..3733b41f679c 100644 --- a/clients/client-comprehend/src/commands/DetectSentimentCommand.ts +++ b/clients/client-comprehend/src/commands/DetectSentimentCommand.ts @@ -84,9 +84,7 @@ export interface DetectSentimentCommandOutput extends DetectSentimentResponse, _ *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/DetectSyntaxCommand.ts b/clients/client-comprehend/src/commands/DetectSyntaxCommand.ts index 44111856b360..fe625135eb08 100644 --- a/clients/client-comprehend/src/commands/DetectSyntaxCommand.ts +++ b/clients/client-comprehend/src/commands/DetectSyntaxCommand.ts @@ -91,9 +91,7 @@ export interface DetectSyntaxCommandOutput extends DetectSyntaxResponse, __Metad *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/DetectTargetedSentimentCommand.ts b/clients/client-comprehend/src/commands/DetectTargetedSentimentCommand.ts index 154aab0a7fed..4cd03489af8d 100644 --- a/clients/client-comprehend/src/commands/DetectTargetedSentimentCommand.ts +++ b/clients/client-comprehend/src/commands/DetectTargetedSentimentCommand.ts @@ -103,9 +103,7 @@ export interface DetectTargetedSentimentCommandOutput extends DetectTargetedSent *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/DetectToxicContentCommand.ts b/clients/client-comprehend/src/commands/DetectToxicContentCommand.ts index 54eb8d0c0486..9488bd5d14b0 100644 --- a/clients/client-comprehend/src/commands/DetectToxicContentCommand.ts +++ b/clients/client-comprehend/src/commands/DetectToxicContentCommand.ts @@ -42,10 +42,9 @@ export interface DetectToxicContentCommandOutput extends DetectToxicContentRespo /** * @public *

Performs toxicity analysis on the list of text strings that you provide as input. - * The analysis uses the order of strings in the list to determine context when predicting toxicity. * The API response contains a results list that matches the size of the input list. - * For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide - *

+ * For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide. + *

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript @@ -94,9 +93,7 @@ export interface DetectToxicContentCommandOutput extends DetectToxicContentRespo *

The size of the input text exceeds the limit. Use a smaller document.

* * @throws {@link UnsupportedLanguageException} (client fault) - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

* diff --git a/clients/client-comprehend/src/commands/StartDocumentClassificationJobCommand.ts b/clients/client-comprehend/src/commands/StartDocumentClassificationJobCommand.ts index 9d08d104c6d1..4445c896d62f 100644 --- a/clients/client-comprehend/src/commands/StartDocumentClassificationJobCommand.ts +++ b/clients/client-comprehend/src/commands/StartDocumentClassificationJobCommand.ts @@ -42,7 +42,7 @@ export interface StartDocumentClassificationJobCommandOutput /** * @public - *

Starts an asynchronous document classification job. Use the + *

Starts an asynchronous document classification job using a custom classification model. Use the * DescribeDocumentClassificationJob * operation to track the progress of the job.

* @example diff --git a/clients/client-comprehend/src/models/models_0.ts b/clients/client-comprehend/src/models/models_0.ts index 6ef40350462f..cc757a43059d 100644 --- a/clients/client-comprehend/src/models/models_0.ts +++ b/clients/client-comprehend/src/models/models_0.ts @@ -270,26 +270,35 @@ export type InvalidRequestDetailReason = (typeof InvalidRequestDetailReason)[key /** * @public - *

Provides additional detail about why the request failed:

- * + *

Provides additional detail about why the request failed.

*/ export interface InvalidRequestDetail { /** * @public - *

Reason code is INVALID_DOCUMENT.

+ *

Reason codes include the following values:

+ * */ Reason?: InvalidRequestDetailReason; } @@ -318,21 +327,7 @@ export class InvalidRequestException extends __BaseException { Reason?: InvalidRequestReason; /** * @public - *

Provides additional detail about why the request failed:

- * + *

Provides additional detail about why the request failed.

*/ Detail?: InvalidRequestDetail; /** @@ -588,9 +583,7 @@ export interface BatchDetectEntitiesResponse { /** * @public - *

Amazon Comprehend can't process the language of the input text. For custom entity - * recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted. - * For a list of supported languages, + *

Amazon Comprehend can't process the language of the input text. For a list of supported languages, * Supported languages in the Comprehend Developer Guide. *

*/ @@ -1573,11 +1566,11 @@ export interface DocumentReaderConfig { * */ @@ -1598,7 +1591,8 @@ export interface ClassifyDocumentRequest { /** * @public *

The Amazon Resource Number (ARN) of the endpoint.

- *

For prompt classification, Amazon Comprehend provides the endpoint ARN: zzz.

+ *

For prompt safety classification, Amazon Comprehend provides the endpoint ARN. For more information about prompt safety classifiers, see Prompt safety classification in the Amazon Comprehend Developer Guide + *

*

For custom classification, you create an endpoint for your custom model. For more information, * see Using Amazon Comprehend endpoints.

*/ @@ -1609,7 +1603,7 @@ export interface ClassifyDocumentRequest { *

Use the Bytes parameter to input a text, PDF, Word or image file.

*

When you classify a document using a custom model, you can also use the Bytes parameter to input an Amazon Textract DetectDocumentText * or AnalyzeDocument output file.

- *

To classify a document using the prompt classifier, use the Text parameter for input.

+ *

To classify a document using the prompt safety classifier, use the Text parameter for input.

*

Provide the input document as a sequence of base64-encoded bytes. * If your code uses an Amazon Web Services SDK to classify documents, the SDK may encode * the document file bytes for you.

@@ -1866,18 +1860,18 @@ export interface WarningsListItem { export interface ClassifyDocumentResponse { /** * @public - *

The classes used by the document being analyzed. These are used for multi-class trained - * models. Individual classes are mutually exclusive and each document is expected to have only a + *

The classes used by the document being analyzed. These are used for models trained in multi-class mode. + * Individual classes are mutually exclusive and each document is expected to have only a * single class assigned to it. For example, an animal can be a dog or a cat, but not both at the * same time.

- *

For prompt classification, the response includes a single class (UNDESIRED_PROMPT), along with a confidence score. - * A higher confidence score indicates that the input prompt is undesired in nature.

+ *

For prompt safety classification, the response includes only two classes (SAFE_PROMPT and UNSAFE_PROMPT), + * along with a confidence score for each class. The value range of the score is zero to one, where one is the highest confidence.

*/ Classes?: DocumentClass[]; /** * @public - *

The labels used the document being analyzed. These are used for multi-label trained + *

The labels used in the document being analyzed. These are used for multi-label trained * models. Individual labels represent different categories that are related in some manner and * are not mutually exclusive. For example, a movie can be just an action movie, or it can be an * action movie, a science fiction movie, and a comedy, all at the same time.

@@ -2829,8 +2823,9 @@ export interface CreateDocumentClassifierRequest { /** * @public *

Indicates the mode in which the classifier will be trained. The classifier can be trained - * in multi-class mode, which identifies one and only one class for each document, or multi-label - * mode, which identifies one or more labels for each document. In multi-label mode, multiple + * in multi-class (single-label) mode or multi-label mode. + * Multi-class mode identifies a single class label for each document and + * multi-label mode identifies one or more class labels for each document. Multiple * labels for an individual document are separated by a delimiter. The default delimiter between * labels is a pipe (|).

*/ @@ -3075,7 +3070,7 @@ export interface EntityTypesListItem { * custom entity recognizer.

*

Entity types must not contain the following invalid characters: \n (line break), \\n * (escaped line break, \r (carriage return), \\r (escaped carriage return), \t (tab), \\t - * (escaped tab), space, and , (comma).

+ * (escaped tab), and , (comma).

*/ Type: string | undefined; } @@ -6383,7 +6378,8 @@ export interface TextSegment { export interface DetectToxicContentRequest { /** * @public - *

A list of up to 10 text strings. The maximum size for the list is 10 KB.

+ *

A list of up to 10 text strings. Each string has a maximum size of 1 KB, and + * the maximum size of the list is 10 KB.

*/ TextSegments: TextSegment[] | undefined; @@ -6435,8 +6431,7 @@ export interface ToxicContent { /** * @public - *

Toxicity analysis result for one string. For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide - *

+ *

Toxicity analysis result for one string. For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide.

*/ export interface ToxicLabels { /** @@ -6447,7 +6442,7 @@ export interface ToxicLabels { /** * @public - *

Overall toxicity score for the string.

+ *

Overall toxicity score for the string. Value range is zero to one, where one is the highest confidence.

*/ Toxicity?: number; } diff --git a/codegen/sdk-codegen/aws-models/comprehend.json b/codegen/sdk-codegen/aws-models/comprehend.json index 5ae0469139ce..631868b9e569 100644 --- a/codegen/sdk-codegen/aws-models/comprehend.json +++ b/codegen/sdk-codegen/aws-models/comprehend.json @@ -979,7 +979,7 @@ } ], "traits": { - "smithy.api#documentation": "

Creates a classification request to analyze a single document in real-time. ClassifyDocument \n supports the following model types:

\n \n

If the system detects errors while processing a page in the input document,\n the API response includes an entry in Errors that describes the errors.

\n

If the system detects a document-level error in your input document, the API returns an\n InvalidRequestException error response.\n For details about this exception, see\n \n Errors in semi-structured documents in the Comprehend Developer Guide.\n

" + "smithy.api#documentation": "

Creates a classification request to analyze a single document in real-time. ClassifyDocument \n supports the following model types:

\n \n

If the system detects errors while processing a page in the input document,\n the API response includes an Errors field that describes the errors.

\n

If the system detects a document-level error in your input document, the API returns an\n InvalidRequestException error response.\n For details about this exception, see\n \n Errors in semi-structured documents in the Comprehend Developer Guide.\n

" } }, "com.amazonaws.comprehend#ClassifyDocumentRequest": { @@ -994,14 +994,14 @@ "EndpointArn": { "target": "com.amazonaws.comprehend#DocumentClassifierEndpointArn", "traits": { - "smithy.api#documentation": "

The Amazon Resource Number (ARN) of the endpoint.

\n

For prompt classification, Amazon Comprehend provides the endpoint ARN: zzz.

\n

For custom classification, you create an endpoint for your custom model. For more information, \n see Using Amazon Comprehend endpoints.

", + "smithy.api#documentation": "

The Amazon Resource Number (ARN) of the endpoint.

\n

For prompt safety classification, Amazon Comprehend provides the endpoint ARN. For more information about prompt safety classifiers, see Prompt safety classification in the Amazon Comprehend Developer Guide\n

\n

For custom classification, you create an endpoint for your custom model. For more information, \n see Using Amazon Comprehend endpoints.

", "smithy.api#required": {} } }, "Bytes": { "target": "com.amazonaws.comprehend#SemiStructuredDocumentBlob", "traits": { - "smithy.api#documentation": "

Use the Bytes parameter to input a text, PDF, Word or image file.

\n

When you classify a document using a custom model, you can also use the Bytes parameter to input an Amazon Textract DetectDocumentText\n or AnalyzeDocument output file.

\n

To classify a document using the prompt classifier, use the Text parameter for input.

\n

Provide the input document as a sequence of base64-encoded bytes.\n If your code uses an Amazon Web Services SDK to classify documents, the SDK may encode\n the document file bytes for you.

\n

The maximum length of this field depends on the input document type. For details, see\n \n Inputs for real-time custom analysis in the Comprehend Developer Guide.

\n

If you use the Bytes parameter, do not use the Text parameter.

" + "smithy.api#documentation": "

Use the Bytes parameter to input a text, PDF, Word or image file.

\n

When you classify a document using a custom model, you can also use the Bytes parameter to input an Amazon Textract DetectDocumentText\n or AnalyzeDocument output file.

\n

To classify a document using the prompt safety classifier, use the Text parameter for input.

\n

Provide the input document as a sequence of base64-encoded bytes.\n If your code uses an Amazon Web Services SDK to classify documents, the SDK may encode\n the document file bytes for you.

\n

The maximum length of this field depends on the input document type. For details, see\n \n Inputs for real-time custom analysis in the Comprehend Developer Guide.

\n

If you use the Bytes parameter, do not use the Text parameter.

" } }, "DocumentReaderConfig": { @@ -1021,13 +1021,13 @@ "Classes": { "target": "com.amazonaws.comprehend#ListOfClasses", "traits": { - "smithy.api#documentation": "

The classes used by the document being analyzed. These are used for multi-class trained\n models. Individual classes are mutually exclusive and each document is expected to have only a\n single class assigned to it. For example, an animal can be a dog or a cat, but not both at the\n same time.

\n

For prompt classification, the response includes a single class (UNDESIRED_PROMPT), along with a confidence score. \n A higher confidence score indicates that the input prompt is undesired in nature.

" + "smithy.api#documentation": "

The classes used by the document being analyzed. These are used for models trained in multi-class mode.\n Individual classes are mutually exclusive and each document is expected to have only a\n single class assigned to it. For example, an animal can be a dog or a cat, but not both at the\n same time.

\n

For prompt safety classification, the response includes only two classes (SAFE_PROMPT and UNSAFE_PROMPT), \n along with a confidence score for each class. The value range of the score is zero to one, where one is the highest confidence.

" } }, "Labels": { "target": "com.amazonaws.comprehend#ListOfLabels", "traits": { - "smithy.api#documentation": "

The labels used the document being analyzed. These are used for multi-label trained\n models. Individual labels represent different categories that are related in some manner and\n are not mutually exclusive. For example, a movie can be just an action movie, or it can be an\n action movie, a science fiction movie, and a comedy, all at the same time.

" + "smithy.api#documentation": "

The labels used in the document being analyzed. These are used for multi-label trained\n models. Individual labels represent different categories that are related in some manner and\n are not mutually exclusive. For example, a movie can be just an action movie, or it can be an\n action movie, a science fiction movie, and a comedy, all at the same time.

" } }, "DocumentMetadata": { @@ -2526,7 +2526,7 @@ "Mode": { "target": "com.amazonaws.comprehend#DocumentClassifierMode", "traits": { - "smithy.api#documentation": "

Indicates the mode in which the classifier will be trained. The classifier can be trained\n in multi-class mode, which identifies one and only one class for each document, or multi-label\n mode, which identifies one or more labels for each document. In multi-label mode, multiple\n labels for an individual document are separated by a delimiter. The default delimiter between\n labels is a pipe (|).

" + "smithy.api#documentation": "

Indicates the mode in which the classifier will be trained. The classifier can be trained\n in multi-class (single-label) mode or multi-label mode. \n Multi-class mode identifies a single class label for each document and\n multi-label mode identifies one or more class labels for each document. Multiple\n labels for an individual document are separated by a delimiter. The default delimiter between\n labels is a pipe (|).

" } }, "ModelKmsKeyId": { @@ -4997,7 +4997,7 @@ } ], "traits": { - "smithy.api#documentation": "

Performs toxicity analysis on the list of text strings that you provide as input.\n The analysis uses the order of strings in the list to determine context when predicting toxicity.\n The API response contains a results list that matches the size of the input list.\n For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide\n

" + "smithy.api#documentation": "

Performs toxicity analysis on the list of text strings that you provide as input.\n The API response contains a results list that matches the size of the input list.\n For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide.\n

" } }, "com.amazonaws.comprehend#DetectToxicContentRequest": { @@ -5006,7 +5006,7 @@ "TextSegments": { "target": "com.amazonaws.comprehend#ListOfTextSegments", "traits": { - "smithy.api#documentation": "

A list of up to 10 text strings. The maximum size for the list is 10 KB.

", + "smithy.api#documentation": "

A list of up to 10 text strings. Each string has a maximum size of 1 KB, and\n the maximum size of the list is 10 KB.

", "smithy.api#required": {} } }, @@ -5674,7 +5674,7 @@ } }, "traits": { - "smithy.api#documentation": "

Specifies the type of Amazon Textract features to apply. If you chose TEXTRACT_ANALYZE_DOCUMENT\n as the read action, you must specify one or both of the following values:

\n " + "smithy.api#documentation": "

TABLES or FORMS

" } }, "com.amazonaws.comprehend#DocumentReadMode": { @@ -5713,7 +5713,7 @@ "FeatureTypes": { "target": "com.amazonaws.comprehend#ListOfDocumentReadFeatureTypes", "traits": { - "smithy.api#documentation": "

Specifies the type of Amazon Textract features to apply. If you chose TEXTRACT_ANALYZE_DOCUMENT\n as the read action, you must specify one or both of the following values:

\n " + "smithy.api#documentation": "

Specifies the type of Amazon Textract features to apply. If you chose TEXTRACT_ANALYZE_DOCUMENT\n as the read action, you must specify one or both of the following values:

\n " } } }, @@ -6858,7 +6858,7 @@ "Type": { "target": "com.amazonaws.comprehend#EntityTypeName", "traits": { - "smithy.api#documentation": "

An entity type within a labeled training dataset that Amazon Comprehend uses to train a\n custom entity recognizer.

\n

Entity types must not contain the following invalid characters: \\n (line break), \\\\n\n (escaped line break, \\r (carriage return), \\\\r (escaped carriage return), \\t (tab), \\\\t\n (escaped tab), space, and , (comma).

", + "smithy.api#documentation": "

An entity type within a labeled training dataset that Amazon Comprehend uses to train a\n custom entity recognizer.

\n

Entity types must not contain the following invalid characters: \\n (line break), \\\\n\n (escaped line break, \\r (carriage return), \\\\r (escaped carriage return), \\t (tab), \\\\t\n (escaped tab), and , (comma).

", "smithy.api#required": {} } } @@ -7660,12 +7660,12 @@ "Reason": { "target": "com.amazonaws.comprehend#InvalidRequestDetailReason", "traits": { - "smithy.api#documentation": "

Reason code is INVALID_DOCUMENT.

" + "smithy.api#documentation": "

Reason codes include the following values:

\n " } } }, "traits": { - "smithy.api#documentation": "

Provides additional detail about why the request failed:

\n " + "smithy.api#documentation": "

Provides additional detail about why the request failed.

" } }, "com.amazonaws.comprehend#InvalidRequestDetailReason": { @@ -10907,7 +10907,7 @@ } ], "traits": { - "smithy.api#documentation": "

Starts an asynchronous document classification job. Use the \n DescribeDocumentClassificationJob\n operation to track the progress of the job.

" + "smithy.api#documentation": "

Starts an asynchronous document classification job using a custom classification model. Use the \n DescribeDocumentClassificationJob\n operation to track the progress of the job.

" } }, "com.amazonaws.comprehend#StartDocumentClassificationJobRequest": { @@ -13421,12 +13421,12 @@ "Toxicity": { "target": "com.amazonaws.comprehend#Float", "traits": { - "smithy.api#documentation": "

Overall toxicity score for the string.

" + "smithy.api#documentation": "

Overall toxicity score for the string. Value range is zero to one, where one is the highest confidence.

" } } }, "traits": { - "smithy.api#documentation": "

Toxicity analysis result for one string. For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide\n

" + "smithy.api#documentation": "

Toxicity analysis result for one string. For more information about toxicity detection, see Toxicity detection in the Amazon Comprehend Developer Guide.

" } }, "com.amazonaws.comprehend#UnsupportedLanguageException": { @@ -13437,7 +13437,7 @@ } }, "traits": { - "smithy.api#documentation": "

Amazon Comprehend can't process the language of the input text. For custom entity\n recognition APIs, only English, Spanish, French, Italian, German, or Portuguese are accepted.\n For a list of supported languages,\n Supported languages in the Comprehend Developer Guide.\n

", + "smithy.api#documentation": "

Amazon Comprehend can't process the language of the input text. For a list of supported languages,\n Supported languages in the Comprehend Developer Guide.\n

", "smithy.api#error": "client", "smithy.api#httpError": 400 }