StartTranscriptionJob - Amazon Transcribe
AWS 文档中描述的 AWS 服务或功能可能因区域而异。要查看适用于中国区域的差异,请参阅中国的 AWS 服务入门

本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。

StartTranscriptionJob

启动异步任务以显示节目中的词性文本。

Request Syntax

{ "ContentRedaction": { "RedactionOutput": "string", "RedactionType": "string" }, "IdentifyLanguage": boolean, "JobExecutionSettings": { "AllowDeferredExecution": boolean, "DataAccessRoleArn": "string" }, "LanguageCode": "string", "LanguageOptions": [ "string" ], "Media": { "MediaFileUri": "string" }, "MediaFormat": "string", "MediaSampleRateHertz": number, "ModelSettings": { "LanguageModelName": "string" }, "OutputBucketName": "string", "OutputEncryptionKMSKeyId": "string", "OutputKey": "string", "Settings": { "ChannelIdentification": boolean, "MaxAlternatives": number, "MaxSpeakerLabels": number, "ShowAlternatives": boolean, "ShowSpeakerLabels": boolean, "VocabularyFilterMethod": "string", "VocabularyFilterName": "string", "VocabularyName": "string" }, "TranscriptionJobName": "string" }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

ContentRedaction

Type: ContentRedaction object

Required: No

IdentifyLanguage

Type: Boolean

Required: No

JobExecutionSettings

Type: JobExecutionSettings object

Required: No

LanguageCode

语言中使用 的语言代码的输入媒体文件。

Type: String

Valid Values: af-ZA | ar-AE | ar-SA | cy-GB | da-DK | de-CH | de-DE | en-AB | en-AU | en-GB | en-IE | en-IN | en-US | en-WL | es-ES | es-US | fa-IR | fr-CA | fr-FR | ga-IE | gd-GB | he-IL | hi-IN | id-ID | it-IT | ja-JP | ko-KR | ms-MY | nl-NL | pt-BR | pt-PT | ru-RU | ta-IN | te-IN | tr-TR | zh-CN

Required: No

LanguageOptions

Type: Array of strings

Array Members: Minimum number of 2 items.

Valid Values: af-ZA | ar-AE | ar-SA | cy-GB | da-DK | de-CH | de-DE | en-AB | en-AU | en-GB | en-IE | en-IN | en-US | en-WL | es-ES | es-US | fa-IR | fr-CA | fr-FR | ga-IE | gd-GB | he-IL | hi-IN | id-ID | it-IT | ja-JP | ko-KR | ms-MY | nl-NL | pt-BR | pt-PT | ru-RU | ta-IN | te-IN | tr-TR | zh-CN

Required: No

Media

输入媒介类的 对象,用于描述转录的任务。

Type: Media object

Required: Yes

MediaFormat

媒体输入文件的格式。

Type: String

Valid Values: mp3 | mp4 | wav | flac | ogg | amr | webm

Required: No

MediaSampleRateHertz

评价(单位:赫兹), 该示例在输入媒体文件的音频。

Type: Integer

Valid Range: Minimum value of 8000. Maximum value of 48000.

Required: No

ModelSettings

Type: ModelSettings object

Required: No

OutputBucketName

Type: String

Length Constraints: Maximum length of 64.

Pattern: [a-z0-9][\.\-a-z0-9]{1,61}[a-z0-9]

Required: No

OutputEncryptionKMSKeyId

Type: String

Length Constraints: Minimum length of 1. Maximum length of 2048.

Pattern: ^[A-Za-z0-9][A-Za-z0-9:_/+=,@.-]{0,2048}$

Required: No

OutputKey

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1024.

Pattern: [a-zA-Z0-9-_.!*'()/]{1,1024}$

Required: No

Settings

Type: Settings object

Required: No

TranscriptionJobName

任务名称。该名称在 AWS 账户中必须是唯一的。

Type: String

Length Constraints: Minimum length of 1. Maximum length of 200.

Pattern: ^[0-9a-zA-Z._-]+

Required: Yes

Response Syntax

{ "TranscriptionJob": { "CompletionTime": number, "ContentRedaction": { "RedactionOutput": "string", "RedactionType": "string" }, "CreationTime": number, "FailureReason": "string", "IdentifiedLanguageScore": number, "IdentifyLanguage": boolean, "JobExecutionSettings": { "AllowDeferredExecution": boolean, "DataAccessRoleArn": "string" }, "LanguageCode": "string", "LanguageOptions": [ "string" ], "Media": { "MediaFileUri": "string" }, "MediaFormat": "string", "MediaSampleRateHertz": number, "ModelSettings": { "LanguageModelName": "string" }, "Settings": { "ChannelIdentification": boolean, "MaxAlternatives": number, "MaxSpeakerLabels": number, "ShowAlternatives": boolean, "ShowSpeakerLabels": boolean, "VocabularyFilterMethod": "string", "VocabularyFilterName": "string", "VocabularyName": "string" }, "StartTime": number, "Transcript": { "RedactedTranscriptFileUri": "string", "TranscriptFileUri": "string" }, "TranscriptionJobName": "string", "TranscriptionJobStatus": "string" } }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

TranscriptionJob

该对象包含详细的异步转录的任务信息。

Type: TranscriptionJob object

Errors

For information about the errors that are common to all actions, see Common Errors.

BadRequestException

某个输入字段存在问题。检查 S3 存储桶名称,请确保任务名称不重复,并确认您正在使用正确的文件格式。然后重新发送您的请求。

HTTP Status Code: 400

ConflictException

JobName 字段中输入了重复的任务名称。请使用不同的名称,重新发送您的请求。

HTTP Status Code: 400

InternalFailureException

发生内部服务器错误。检查错误消息并再次尝试请求。

HTTP Status Code: 500

LimitExceededException

您已经发送过多的请求或您的输入文件中包含超过 2 小时。等待,然后再重新发送您的请求,或使用较小的文件,然后重新发送请求。

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: