Voiceprint Comparison: start task
POST/api/technology/speaker-identification-voiceprint-comparison
Start voiceprint comparison task for two voiceprint sets.
The voiceprint sets are provided in voiceprints_a
and voiceprints_b
parameters. Size of each set
is completely arbitrary, provided that there is at least one voiceprint in each set.
Each voiceprint is expected to be in a string form, encoded in Base64.
How voiceprint comparison request is arranged
See Voiceprint comparison task result documentation for details on how the result is arranged.
Request consists of two voiceprint sets arranged as columns and rows headers of resulting score matrix.
As a result all voiceprints from columns set will be compared to all voiceprints in rows set.
Resulting scores will be filled in a matrix of (sizeof(voiceprints_a), sizeof(voiceprints_b))
dimensions.
For example, the following input:
{
"voiceprints_a": ["vp_a_1", "vp_a_2", "vp_a_3"],
"voiceprints_b": ["vp_b_1", "vp_b_2", "vp_b_3"]
}
encodes the following empty voiceprint comparison score input matrix:
voiceprints_a set | ||||
---|---|---|---|---|
vp_a_1 | vp_a_2 | vp_a_3 | ||
voiceprints_b set | vp_b_1 | |||
vp_b_2 | ||||
vp_b_3 |
Voiceprint comparison technology will then fill in the empty cells with scores.
Request
Header Parameters
Correlation ID is a special type of request ID which is unique over a series of requests and responses, identifying a transaction in a distributed system. Correlation ID will be generated if not provided.
In distributed system architecture (microservices architecture) it is a unique ID of request and response combination throughout all components of a distributed system. Request ID will be generated if not provided.
- application/json
Bodyrequired
required
Possible values: >= 1
, <= 50000
Set A of base64 encoded voiceprints to compare.
Possible values: >= 1
, <= 50000
Set B of base64 encoded voiceprints to compare.
Responses
- 202
- 400
- 403
- 422
- 429
Voiceprint comparison task was accepted. Follow the X-Location
header to poll for the task state.
Response Headers
X-Location
string
Example: /api/technology/speaker-identification-voiceprint-comparison/651f10f1-3025-41e7-ad4f-d4ae385c8b7d
A URL the client should poll for task state and result.
- application/json
- Schema
- Example (from schema)
Schema
task
object
required
Possible values: [pending
, running
, rejected
, failed
, done
]
{
"task": {
"task_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"state": "pending"
}
}
Request payload data was invalid and could not be parsed.
- application/json
- Schema
- Example (from schema)
- request.invalid
Schema
Array [
Array [
- MOD1
- MOD2
]
- MOD1
- MOD2
- MOD3
- MOD4
- MOD5
Array [
- MOD1
- MOD2
- MOD3
- MOD4
]
]
Possible values: [internal
, resource.not-found
, method.invalid
, request.forbidden
, request.invalid
, request.validation-error
, request.rate-limit-exceeded
, request.size-limit-exceeded
, storage.capacity-exceeded
]
Machine-readable error type.
Human-readable summary of the error.
detail
object[]
Optional higher level of detail. It is intended for better understanding of the error or advanced error handling.
location
object[]
required
Location of the error.
anyOf
integer
string
Human-readable summary of the error.
Machine-readable error type.
context
object
Optional key-value object with additional context
property name*
object
anyOf
string
integer
number
boolean
anyOf
string
integer
number
boolean
{
"type": "internal",
"message": "string",
"detail": [
{
"location": [
0,
"string"
],
"message": "string",
"type": "string",
"context": {}
}
]
}
Invalid request.
{
"type": "request.invalid",
"message": "Invalid request.",
"detail": []
}
Request is forbidden.
- application/json
- Schema
- Example (from schema)
- request.forbidden
Schema
Array [
Array [
- MOD1
- MOD2
]
- MOD1
- MOD2
- MOD3
- MOD4
- MOD5
Array [
- MOD1
- MOD2
- MOD3
- MOD4
]
]
Possible values: [internal
, resource.not-found
, method.invalid
, request.forbidden
, request.invalid
, request.validation-error
, request.rate-limit-exceeded
, request.size-limit-exceeded
, storage.capacity-exceeded
]
Machine-readable error type.
Human-readable summary of the error.
detail
object[]
Optional higher level of detail. It is intended for better understanding of the error or advanced error handling.
location
object[]
required
Location of the error.
anyOf
integer
string
Human-readable summary of the error.
Machine-readable error type.
context
object
Optional key-value object with additional context
property name*
object
anyOf
string
integer
number
boolean
anyOf
string
integer
number
boolean
{
"type": "internal",
"message": "string",
"detail": [
{
"location": [
0,
"string"
],
"message": "string",
"type": "string",
"context": {}
}
]
}
Processing capacity allowed for the operation was exceeded.
{
"type": "request.forbidden",
"message": "Request is forbidden.",
"detail": [
{
"location": [
"license"
],
"message": "Licensed processing capacity exceeded.",
"type": "licensing.capacity-exceeded",
"context": {}
}
]
}
Error during validation of request payload data occurred.
- application/json
- Schema
- Example (from schema)
- request validation error
Schema
Array [
Array [
- MOD1
- MOD2
]
- MOD1
- MOD2
- MOD3
- MOD4
- MOD5
Array [
- MOD1
- MOD2
- MOD3
- MOD4
]
]
Possible values: [internal
, resource.not-found
, method.invalid
, request.forbidden
, request.invalid
, request.validation-error
, request.rate-limit-exceeded
, request.size-limit-exceeded
, storage.capacity-exceeded
]
Machine-readable error type.
Human-readable summary of the error.
detail
object[]
Optional higher level of detail. It is intended for better understanding of the error or advanced error handling.
location
object[]
required
Location of the error.
anyOf
integer
string
Human-readable summary of the error.
Machine-readable error type.
context
object
Optional key-value object with additional context
property name*
object
anyOf
string
integer
number
boolean
anyOf
string
integer
number
boolean
{
"type": "internal",
"message": "string",
"detail": [
{
"location": [
0,
"string"
],
"message": "string",
"type": "string",
"context": {}
}
]
}
Request validation error.
{
"type": "request.validation-error",
"message": "Request validation error.",
"detail": []
}
Request rate limit exceeded.
The request may be retried after a while. The following response headers may be checked for details: retry-after
, x-ratelimit-limit
, x-ratelimit-remaining
, x-ratelimit-reset
.
Response Headers
retry-after
number
Header indicates how long the user agent should wait before making a follow-up request.
x-ratelimit-limit
number
Size of the current rate limiting window.
x-ratelimit-remaining
number
Remaining number of requests in the current rate limiting window.
x-ratelimit-reset
number
Time at which the current rate limiting window resets (in UTC epoch).
- application/json
- Schema
- Example (from schema)
- request.rate-limit-exceeded
Schema
Array [
Array [
- MOD1
- MOD2
]
- MOD1
- MOD2
- MOD3
- MOD4
- MOD5
Array [
- MOD1
- MOD2
- MOD3
- MOD4
]
]
Possible values: [internal
, resource.not-found
, method.invalid
, request.forbidden
, request.invalid
, request.validation-error
, request.rate-limit-exceeded
, request.size-limit-exceeded
, storage.capacity-exceeded
]
Machine-readable error type.
Human-readable summary of the error.
detail
object[]
Optional higher level of detail. It is intended for better understanding of the error or advanced error handling.
location
object[]
required
Location of the error.
anyOf
integer
string
Human-readable summary of the error.
Machine-readable error type.
context
object
Optional key-value object with additional context
property name*
object
anyOf
string
integer
number
boolean
anyOf
string
integer
number
boolean
{
"type": "internal",
"message": "string",
"detail": [
{
"location": [
0,
"string"
],
"message": "string",
"type": "string",
"context": {}
}
]
}
Rate limit exceeded.
{
"type": "request.rate-limit-exceeded",
"message": "Rate limit exceeded: 1 per 5 second.",
"detail": []
}