Text Independent - Identify Single Speaker
単一話者プロファイルを識別する
候補プロファイルの一覧から入力オーディオで話しているユーザーを識別します。
制限事項:
オーディオ入力の最小長は 1 秒です
オーディオ入力の最大長は 120 秒です
候補スピーカーの最小数は 1 です
候補スピーカーの最大数は 50 です
有効な音声の最小長 (無音やその他の音声以外のフレームを除く) は 4 秒 です。この制限は、"ignoreMinLength" を true に設定することで無効にすることができます。
最小オーディオ信号対ノイズ比 (SNR) は 2dB です
POST {endpoint}/speaker-recognition/identification/text-independent/profiles:identifySingleSpeaker?api-version=2021-09-05&profileIds={profileIds}
POST {endpoint}/speaker-recognition/identification/text-independent/profiles:identifySingleSpeaker?api-version=2021-09-05&profileIds={profileIds}&ignoreMinLength={ignoreMinLength}
URI パラメーター
名前 | / | 必須 | 型 | 説明 |
---|---|---|---|---|
endpoint
|
path | True |
string |
サポートされている Cognitive Services エンドポイント (プロトコルとホスト名など)。 https://westus.api.cognitive.microsoft.com |
api-version
|
query | True |
string |
この要求に使用する操作のバージョンを指定します。 |
profile
|
query | True |
string[] |
コンマ区切りのプロファイル ID。 サポートされている最大数は 50 ID です。 |
ignore
|
query |
boolean |
true の場合、識別に必要な音声の最小量はスキップされます。 既定値は false です。 |
要求ヘッダー
Media Types: "audio/wav; codecs=audio/pcm"
名前 | 必須 | 型 | 説明 |
---|---|---|---|
Ocp-Apim-Subscription-Key | True |
string |
要求本文
Media Types: "audio/wav; codecs=audio/pcm"
名前 | 型 | 説明 |
---|---|---|
audioData |
object |
バイナリ オーディオ ファイル。 サポートされている形式はオーディオ/wav です。codecs=audio/pcm。 最大 5 MB のオーディオをサポートします。 |
応答
名前 | 型 | 説明 |
---|---|---|
200 OK |
OK |
|
Other Status Codes |
障害 Headers x-ms-error-code: string |
セキュリティ
Ocp-Apim-Subscription-Key
Type:
apiKey
In:
header
例
Successful Query
Sample Request
POST https://westus.api.cognitive.microsoft.com/speaker-recognition/identification/text-independent/profiles:identifySingleSpeaker?api-version=2021-09-05&profileIds=3669fa29-1bf3-45ad-beea-6b348d058d7e,111f427c-3791-468f-b709-fcef7660fff9,0e196cd9-32d5-4883-8631-54a0e7c7cb3d,0e196cd9-32d5-4883-8631-54a0e7c7cb3d,726e57d9-04e0-4214-b482-7f786fa83560,f95189fd-1bf5-4485-9c2e-e5897e0c98ca
"{binary file date}"
Sample Response
Content-Type: application/json
{
"identifiedProfile": {
"profileId": "111f427c-3791-468f-b709-fcef7660fff9",
"score": 0.63
},
"profilesRanking": [
{
"profileId": "111f427c-3791-468f-b709-fcef7660fff9",
"score": 0.63
},
{
"profileId": "3669fa29-1bf3-45ad-beea-6b348d058d7e",
"score": 0.49
},
{
"profileId": "0e196cd9-32d5-4883-8631-54a0e7c7cb3d",
"score": 0.4
},
{
"profileId": "726e57d9-04e0-4214-b482-7f786fa83560",
"score": 0.1
},
{
"profileId": "f95189fd-1bf5-4485-9c2e-e5897e0c98ca",
"score": 0.03
}
]
}
Content-Type: application/json
x-ms-error-code: Error Code
{
"error": {
"code": "Error Code",
"message": "Erro Messae"
}
}
定義
名前 | 説明 |
---|---|
Error | |
Identified |
|
Identify |
特定された話者情報 |
Speaker |
話者のエラー メッセージ |
Error
名前 | 型 | 説明 |
---|---|---|
code |
string |
|
message |
string |
IdentifiedSingleSpeakerInfo
名前 | 型 | 説明 |
---|---|---|
identifiedProfile |
識別されたプロファイルのデータを格納しているオブジェクト。 |
|
profilesRanking |
上位 5 つのプロファイル (識別されたプロファイルを含む) のデータを含むオブジェクト。スコア順に降順に並べ替えられます。 |
IdentifyInfo
特定された話者情報
名前 | 型 | 説明 |
---|---|---|
profileId |
string |
プロファイルの識別された ID。 候補が適切な話者として識別されない場合、値は空の GUID に設定されます。 |
score |
number |
入力オーディオと対象の音声印刷の類似性を示す浮動小数点数。 この数値は 0 から 1 の間である必要があります。 数値が大きいほど、類似性が高くなります。 |
SpeakerErrorInfo
話者のエラー メッセージ
名前 | 型 | 説明 |
---|---|---|
error |