

翻訳は機械翻訳により提供されています。提供された翻訳内容と英語版の間で齟齬、不一致または矛盾がある場合、英語版が優先します。

# StartMedicalStreamTranscription
<a name="API_streaming_StartMedicalStreamTranscription"></a>

双方向 HTTP/2 を開始します。オーディオが Amazon Transcribe Medical WebSocket にストリーミングされると、文字起こしの結果がアプリケーションにストリーミングされます。

以下のパラメータは必須です。
+  `language-code` 
+  `media-encoding` 
+  `sample-rate` 

Amazon Transcribe Medical でのストリーミングの詳細については、[ストリーミング音声の文字起こしを参照してください](https://docs.aws.amazon.com/transcribe/latest/dg/streaming.html)。

## リクエストの構文
<a name="API_streaming_StartMedicalStreamTranscription_RequestSyntax"></a>

```
POST /medical-stream-transcription HTTP/2
x-amzn-transcribe-language-code: {{LanguageCode}}
x-amzn-transcribe-sample-rate: {{MediaSampleRateHertz}}
x-amzn-transcribe-media-encoding: {{MediaEncoding}}
x-amzn-transcribe-vocabulary-name: {{VocabularyName}}
x-amzn-transcribe-specialty: {{Specialty}}
x-amzn-transcribe-type: {{Type}}
x-amzn-transcribe-show-speaker-label: {{ShowSpeakerLabel}}
x-amzn-transcribe-session-id: {{SessionId}}
x-amzn-transcribe-enable-channel-identification: {{EnableChannelIdentification}}
x-amzn-transcribe-number-of-channels: {{NumberOfChannels}}
x-amzn-transcribe-content-identification-type: {{ContentIdentificationType}}
Content-type: application/json

{
   "AudioStream": { 
      "AudioEvent": { 
         "AudioChunk": {{blob}}
      }
   }
}
```

## URI リクエストパラメータ
<a name="API_streaming_StartMedicalStreamTranscription_RequestParameters"></a>

リクエストでは、次の URI パラメータを使用します。

 ** [ContentIdentificationType](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-ContentIdentificationType"></a>
トランスクリプトで特定されたすべての個人の健康情報 (PHI) にラベル付けします。  
コンテンツの識別はセグメントレベルで行われ、PHIはオーディオセグメントの文字起こしが完了するとフラグが付けられます。  
詳細については、[トランスクリプションにおける個人の健康情報 (PHI) の特定](https://docs.aws.amazon.com/transcribe/latest/dg/phi-id.html)を参照してください。  
有効な値: ` PHI` 

 ** [EnableChannelIdentification](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-EnableChannelIdentification"></a>
マルチチャネルの音声でチャネル識別を有効にします。  
チャンネル識別では、各チャンネルのオーディオが個別に文字変換され、各チャンネルの出力が 1 つのトランスクリプトに追加されます。  
マルチチャンネルオーディオを使用していて、チャンネル識別が有効になっていない場合、オーディオは連続的に文字変換され、トランスクリプトはチャンネルごとに区切られません。  
`EnableChannelIdentification`リクエストに含める場合は、その内容も含める必要があります`NumberOfChannels`。  
詳細については、[[マルチチャンネルオーディオの文字起こし]](https://docs.aws.amazon.com/transcribe/latest/dg/channel-id.html) を参照してください。

 ** [LanguageCode](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-LanguageCode"></a>
音声で話されている言語を表す言語コードを指定します。  
Amazon トランスクリプブメディカルは米国英語 (`en-US`) のみをサポートしています。
有効な値: ` en-US | en-GB | es-US | fr-CA | fr-FR | en-AU | it-IT | de-DE | pt-BR | ja-JP | ko-KR | zh-CN | hi-IN | th-TH`   
必須: はい

 ** [MediaEncoding](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-MediaEncoding"></a>
入力オーディオに使用されるエンコーディングを指定します。サポートされる形式:  
+ FLAC
+ Ogg コンテナ内の OPUS エンコードオーディオ
+ PCM (符号付き 16 ビットリトルエンディアンオーディオフォーマットのみ、WAV は含まない)
詳しくは、「[メディアフォーマット](https://docs.aws.amazon.com/transcribe/latest/dg/how-input.html#how-input-audio)」を参照してください。  
有効な値: ` pcm | ogg-opus | flac`   
必須: はい

 ** [MediaSampleRateHertz](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-MediaSampleRateHertz"></a>
入力オーディオのサンプルレート (Hz 単位)。Amazon Transcribe Medical では、16,000 Hz ～ 48,000 Hz の範囲がサポートされます。指定するサンプルレートは、音声のサンプルレートと一致する必要があることに注意してください。  
有効範囲: 最小値 は 8,000 です。最大値は 48,000 です。  
必須: はい

 ** [NumberOfChannels](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-NumberOfChannels"></a>
オーディオストリーミングのチャネル数を指定します。2 つのチャネルしかサポートされていないため`2`、この値はでなければなりません。音声に複数のチャンネルが含まれていない場合は、このパラメーターをリクエストに含めないでください。  
`NumberOfChannels`リクエストに含める場合は、その内容も含める必要があります`EnableChannelIdentification`。  
値の範囲: 最小値は 2 です。

 ** [SessionId](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-SessionId"></a>
トランスクリプションセッションの名前を指定します。このパラメータをリクエストに含めない場合、Amazon Transcribe Medical は ID を生成し、レスポンスの中でそれを返します。  
長さの制限: 最大長は 36 です。  
パターン: `[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}` 

 ** [ShowSpeakerLabel](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-ShowSpeakerLabel"></a>
トランスクリプション出力のスピーカーパーティショニング (ダイアライゼーション) を有効にします。スピーカーパーティショニングは、メディアファイル内の個々のスピーカーからのスピーチにラベルを付けます。  
詳細については、「[スピーカーのパーティショニング (ダイアライゼーション)](https://docs.aws.amazon.com/transcribe/latest/dg/diarization.html)」を参照してください。

 ** [Specialty](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-Specialty"></a>
オーディオに含まれる専門分野を指定してください。  
有効な値: ` PRIMARYCARE | CARDIOLOGY | NEUROLOGY | ONCOLOGY | RADIOLOGY | UROLOGY`   
必須: はい

 ** [Type](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-Type"></a>
入力オーディオのタイプを指定します。たとえば、医療提供者が患者のメモを口述したり、`CONVERSATION`患者と医療専門家が対話したりするようにします。`DICTATION`  
有効な値: ` CONVERSATION | DICTATION`   
必須: はい

 ** [VocabularyName](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-VocabularyName"></a>
トランスクリプションの処理時に使用するカスタムボキャブラリーの名前を指定します。語彙名では大文字と小文字が区別されます。  
長さの制限: 最小長は 1 です。最大長は 200 です。  
Pattern: `^[0-9a-zA-Z._-]+` 

## リクエストボディ
<a name="API_streaming_StartMedicalStreamTranscription_RequestBody"></a>

リクエストは以下の JSON 形式のデータを受け入れます。

 ** [AudioStream](#API_streaming_StartMedicalStreamTranscription_RequestSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-request-AudioStream"></a>
エンコードされたオーディオブロブのストリーミング。オーディオストリームは HTTP/2 WebSocket またはデータフレームとしてエンコードされます。  
詳細については、[ストリーミング音声の文字起こしを参照してください](https://docs.aws.amazon.com/transcribe/latest/dg/streaming.html)。  
型: [AudioStream](API_streaming_AudioStream.md) オブジェクト  
必須: はい

## レスポンスの構文
<a name="API_streaming_StartMedicalStreamTranscription_ResponseSyntax"></a>

```
HTTP/2 200
x-amzn-request-id: {{RequestId}}
x-amzn-transcribe-language-code: {{LanguageCode}}
x-amzn-transcribe-sample-rate: {{MediaSampleRateHertz}}
x-amzn-transcribe-media-encoding: {{MediaEncoding}}
x-amzn-transcribe-vocabulary-name: {{VocabularyName}}
x-amzn-transcribe-specialty: {{Specialty}}
x-amzn-transcribe-type: {{Type}}
x-amzn-transcribe-show-speaker-label: {{ShowSpeakerLabel}}
x-amzn-transcribe-session-id: {{SessionId}}
x-amzn-transcribe-enable-channel-identification: {{EnableChannelIdentification}}
x-amzn-transcribe-number-of-channels: {{NumberOfChannels}}
x-amzn-transcribe-content-identification-type: {{ContentIdentificationType}}
Content-type: application/json

{
   "TranscriptResultStream": { 
      "BadRequestException": { 
      },
      "ConflictException": { 
      },
      "InternalFailureException": { 
      },
      "LimitExceededException": { 
      },
      "ServiceUnavailableException": { 
      },
      "TranscriptEvent": { 
         "Transcript": { 
            "Results": [ 
               { 
                  "Alternatives": [ 
                     { 
                        "Entities": [ 
                           { 
                              "Category": "string",
                              "Confidence": number,
                              "Content": "string",
                              "EndTime": number,
                              "StartTime": number
                           }
                        ],
                        "Items": [ 
                           { 
                              "Confidence": number,
                              "Content": "string",
                              "EndTime": number,
                              "Speaker": "string",
                              "StartTime": number,
                              "Type": "string"
                           }
                        ],
                        "Transcript": "string"
                     }
                  ],
                  "ChannelId": "string",
                  "EndTime": number,
                  "IsPartial": boolean,
                  "ResultId": "string",
                  "StartTime": number
               }
            ]
         }
      }
   }
}
```

## レスポンス要素
<a name="API_streaming_StartMedicalStreamTranscription_ResponseElements"></a>

アクションが成功すると、サービスは HTTP 200 レスポンスを返します。

レスポンスでは、以下の HTTP ヘッダーが返されます。

 ** [ContentIdentificationType](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-ContentIdentificationType"></a>
トランスクリプションでコンテンツ識別が有効になっているかどうかを示します。  
有効な値: ` PHI` 

 ** [EnableChannelIdentification](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-EnableChannelIdentification"></a>
トランスクリプションでチャンネル識別が有効になっているかどうかが表示されます。

 ** [LanguageCode](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-LanguageCode"></a>
リクエストで指定した言語コードを提供します。これは、`en-US` である必要があります。  
有効な値: ` en-US | en-GB | es-US | fr-CA | fr-FR | en-AU | it-IT | de-DE | pt-BR | ja-JP | ko-KR | zh-CN | hi-IN | th-TH` 

 ** [MediaEncoding](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-MediaEncoding"></a>
リクエストで指定したメディアエンコーディングを提供します。  
有効な値: ` pcm | ogg-opus | flac` 

 ** [MediaSampleRateHertz](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-MediaSampleRateHertz"></a>
リクエストで指定したサンプルレートを提供します。  
有効範囲: 最小値 は 8,000 です。48,000 の最大値。

 ** [NumberOfChannels](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-NumberOfChannels"></a>
リクエストで指定したチャンネル数を提供します。  
値の範囲: 最小値は 2 です。

 ** [RequestId](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-RequestId"></a>
ストリーミングリクエストの識別子を提供します。

 ** [SessionId](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-SessionId"></a>
トランスクリプションセッションの識別子を提供します。  
長さの制限: 最大長は 36 です。  
パターン: `[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}` 

 ** [ShowSpeakerLabel](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-ShowSpeakerLabel"></a>
トランスクリプションでスピーカーパーティショニングが有効になっているかどうかが表示されます。

 ** [Specialty](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-Specialty"></a>
リクエストで指定した専門医療を提供します。  
有効な値: ` PRIMARYCARE | CARDIOLOGY | NEUROLOGY | ONCOLOGY | RADIOLOGY | UROLOGY` 

 ** [Type](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-Type"></a>
リクエストで指定したオーディオのタイプを提供します。  
有効な値: ` CONVERSATION | DICTATION` 

 ** [VocabularyName](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-VocabularyName"></a>
リクエストで指定したカスタムボキャブラリーの名前を指定します。  
長さの制限: 最小長は 1 です。最大長は 200 です。  
Pattern: `^[0-9a-zA-Z._-]+` 

サービスから以下のデータが JSON 形式で返されます。

 ** [TranscriptResultStream](#API_streaming_StartMedicalStreamTranscription_ResponseSyntax) **   <a name="transcribe-streaming_StartMedicalStreamTranscription-response-TranscriptResultStream"></a>
ストリーミングセッションに関する詳細情報を提供します。  
型: [MedicalTranscriptResultStream](API_streaming_MedicalTranscriptResultStream.md) オブジェクト

## エラー
<a name="API_streaming_StartMedicalStreamTranscription_Errors"></a>

すべてのアクションに共通のエラーについては、「[共通エラー](CommonErrors.md)」を参照してください。

 ** BadRequestException **   
`StartStreamTranscription`、`StartMedicalStreamTranscription`、`StartCallAnalyticsStreamTranscription`または操作の 1 つまたは複数の引数が無効でした。たとえば、`MediaEncoding``LanguageCode`またはサポートされていない値を使用しました。指定されたパラメーターを確認して、リクエストを再度試みてください。  
HTTP ステータスコード: 400

 ** ConflictException **   
同じセッション ID で新しいストリーミングが開始されました。現在のストリーミングは終了しました。  
HTTP ステータスコード: 409

 ** InternalFailureException **   
音声処理中に問題が発生しました。Amazon Transcribe が処理を終了しました。  
HTTP ステータスコード: 500

 ** LimitExceededException **   
クライアントが Amazon Transcribe の制限の 1 つを超えています。これは通常、オーディオの長さの制限です。オーディオストリームをより小さなチャンクに分割して、リクエストを再試行してください。  
HTTP ステータスコード: 429

 ** ServiceUnavailableException **   
現在、サービスをご利用いただけません。後でリクエストを試してください。  
HTTP ステータスコード: 503

## 以下の資料も参照してください。
<a name="API_streaming_StartMedicalStreamTranscription_SeeAlso"></a>

言語固有の AWS SDK のいずれかでこの API を使用する方法の詳細については、以下を参照してください。
+  [AWS コマンドラインインターフェイス](https://docs.aws.amazon.com/goto/aws-cli/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS SDK for .NET](https://docs.aws.amazon.com/goto/DotNetSDKV3/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS SDK for C\+\+](https://docs.aws.amazon.com/goto/SdkForCpp/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS SDK for Go](https://docs.aws.amazon.com/goto/SdkForGoV1/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS SDK for Java V2](https://docs.aws.amazon.com/goto/SdkForJavaV2/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS用の SDK JavaScript](https://docs.aws.amazon.com/goto/AWSJavaScriptSDK/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS SDK for PHP V3](https://docs.aws.amazon.com/goto/SdkForPHPV3/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS SDK for Python](https://docs.aws.amazon.com/goto/boto3/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 
+  [AWS SDK for Ruby V3](https://docs.aws.amazon.com/goto/SdkForRubyV3/transcribe-streaming-2017-10-26/StartMedicalStreamTranscription) 