language_detection message
The language spoken, once the engine knows it: a gaia session then moves to the model
that serves it best (receive_realtime_processing_events).
Delivery
On the WebSocket with messages_config.receive_realtime_processing_events; to your callback as live.language_detection with callback_config.receive_realtime_processing_events.
Fields
-
session_idstring requiredIdentifier of the session.
-
created_atstring requiredWhen the message was sent (ISO 8601, UTC).
-
type"language_detection" required -
dataobject requiredThe language spoken, as the engine detected it (
model: "gaia").6 fields
-
languagestring requiredThe language spoken (ISO 639-1).
-
confidencenumber requiredHow sure the engine is.
0 to 1
-
speech_snumberThe seconds of speech it decided on.
default:
null -
low_confidencebooleantrue: too unsure to act on; agaiasession stays on its model.default:
false -
modelstringThe detector that decided.
default:
null -
alternativesarray of objectThe runners-up, the likeliest first.
2 fields
-
languagestring requiredAnother language it may be (ISO 639-1).
-
confidencenumber required0 to 1
-
-
Example
{ "session_id": "string", "created_at": "string", "type": "language_detection", "data": { "language": "fr", "confidence": 0.93, "speech_s": 2.1, "low_confidence": false, "model": "language-id-v2", "alternatives": [ { "language": "en", "confidence": 0.04 } ] }}