This topic describes server events for the Qwen real-time speech and audiovisual translation API, including event types, parameters, and examples.
Reference: Real-time audio and video translation - Qwen
This page is the event reference for Qwen-LiveTranslate-Realtime. Event definitions are based on WebSocket access. AOQ and WebRTC use their respective data channels to send and receive model events, and media tracks to transmit media. First read WebSocket access, WebRTC access, or AOQ access.
error
Error message returned by the server.
event_idstringtypestringerror.errorobjectProperties
Properties
typestringcodestringmessagestringparamstringsession.modalities.session.created
When a client connects, the server returns this event first with the default session configurations.
event_idstringtypestringsession.created.sessionobjectProperties
Properties
idstringobjectstringrealtime.session.modelstringinput_modalitiesarrayqwen3.8-livetranslate-flash-realtime. Input modalities, such as ["audio"].output_modalitiesarrayqwen3.8-livetranslate-flash-realtime. Output modalities: ["text"] or ["text", "audio"].audioobjectqwen3.8-livetranslate-flash-realtime. Audio input and output configuration.Properties
Properties
inputobjectProperties
Properties
formatobjecttype defaults to pcm, and sample_rate defaults to 16000 (Hz).turn_detectionobjecttype is speaker_detection, threshold is 0.5, and silence_duration_ms is 1000.outputobjectProperties
Properties
formatobjecttype is pcm, and sample_rate is 24000 Hz.voicestringTina.modalitiesarrayqwen3.5-livetranslate-flash-realtime.The output modality settings for the model.voicestringqwen3.5-livetranslate-flash-realtime.The voice for the audio generated by the model.input_audio_formatstringqwen3.5-livetranslate-flash-realtime.The format of the input audio. Defaults to pcm.sample_rateintegerqwen3.5-livetranslate-flash-realtime.The sample rate of the input audio, in Hz.output_audio_formatstringqwen3.5-livetranslate-flash-realtime.The format of the output audio. Defaults to pcm.turn_detectionobjectqwen3.5-livetranslate-flash-realtime.The VAD (Voice Activity Detection) configuration.translationobject(Optional)Properties
Properties
languagestring(Optional)corpusobject(Optional)Properties
Properties
phrasesobject(Optional)- qwen3.8-livetranslate-flash-realtime
- qwen3.5-livetranslate-flash-realtime
Applies to
qwen3.8-livetranslate-flash-realtime.session.updated
Returned after a successful session.update request. If the request fails, an error event is returned instead.
event_idstringtypestringsession.updated.sessionobjectProperties
Properties
idstringobjectstringrealtime.session.modelstringinput_modalitiesarrayqwen3.8-livetranslate-flash-realtime. Input modalities, such as ["audio"].output_modalitiesarrayqwen3.8-livetranslate-flash-realtime. Output modalities: ["text"] or ["text", "audio"].audioobjectqwen3.8-livetranslate-flash-realtime. Audio input and output configuration.Properties
Properties
inputobjectProperties
Properties
formatobjecttype defaults to pcm, and sample_rate defaults to 16000 (Hz).turn_detectionobjecttype is speaker_detection, threshold is 0.5, and silence_duration_ms is 1000.outputobjectProperties
Properties
formatobjectvoicestringTina.modalitiesarrayqwen3.5-livetranslate-flash-realtime.The output modality settings for the model.voicestringqwen3.5-livetranslate-flash-realtime.The voice for the audio generated by the model.sample_rateinteger(Optional)qwen3.5-livetranslate-flash-realtime.The sample rate of the input audio, in Hz.input_audio_formatstringqwen3.5-livetranslate-flash-realtime.The format of the input audio. The value is always pcm.output_audio_formatstringqwen3.5-livetranslate-flash-realtime.The format of the output audio. The value is always pcm.input_audio_transcriptionobjectqwen3.5-livetranslate-flash-realtime.The input audio transcription configuration. Returned only when the input_audio_transcription.model parameter is configured in the session.Properties
Properties
modelstringlanguagestringturn_detectionobjectqwen3.5-livetranslate-flash-realtime.The VAD (Voice Activity Detection) configuration. This field is not returned in Manual mode (when the client sets this parameter to null in session.update).Properties
Properties
typestringserver_vad.thresholdfloatprefix_padding_msintegersilence_duration_msintegercreate_responsebooleaninterrupt_responsebooleantranslationobject(Optional)Properties
Properties
languagestring(Optional)corpusobject(Optional)Properties
Properties
phrasesobject(Optional)enable_voice_clonebooleanvoice_clone_optionsobjectenable_voice_clone is true.Properties
Properties
frequencystring- qwen3.8-livetranslate-flash-realtime
- qwen3.5-livetranslate-flash-realtime
Applies to
qwen3.8-livetranslate-flash-realtime.session.finished
Session is finished and all audio translations are complete.
This event is returned after the client sends session.finish. After receiving this event, the client must finish local playback of any remaining translated audio before actively disconnecting, if playback is needed.
event_idstringtypestringsession.finished.response.created
Returned when the server generates a new model response.
event_idstringtypestringresponse.created.responseobjectProperties
Properties
idstringconversation_idstringobjectstringrealtime.response.statusstringcompletedfailedin_progressincomplete
modalitiesarrayvoicestringoutput_audio_formatstringoutputarrayresponse.done
Returned after response generation is complete. Contains all output items except raw audio data.
event_idstringtypestringresponse.done.responseobjectProperties
Properties
idstringconversation_idstringobjectstringrealtime.response.statusstringmodalitiesarrayvoicestringoutput_audio_formatstringoutputobjectProperties
Properties
idstringtypestringmessage.objectstringrealtime.item.statusstringrolestringcontentarrayProperties
Properties
typestringtext for plain text output and audio when the output includes audio.textstringtranscriptstringusageobjectresponse.done reports the current cumulative values. To total the session usage, use the last usage report rather than adding the reports together.Properties
Properties
total_tokensintegerinput_tokens and output_tokens.input_tokensintegeroutput_tokensintegerinput_tokens_detailsobjectProperties
Properties
text_tokensintegeraudio_tokensintegervideo_tokensintegeroutput_tokens_detailsobjectProperties
Properties
text_tokensintegeraudio_tokensintegerresponse.text.delta
Applies to qwen3.8-livetranslate-flash-realtime. Returns a new translation fragment for text-only output.
event_idstringtypestringresponse.text.delta.response_idstringitem_idstringoutput_indexintegercontent_indexintegerdeltastringresponse.text.text
Applies to models such as qwen3.5-livetranslate-flash-realtime. For qwen3.8-livetranslate-flash-realtime, handle response.text.delta instead.
Returned for text-only output when the model generates text incrementally.
event_idstringtypestringresponse.text.text.textstringresponse_idstringitem_idstringoutput_indexintegercontent_indexintegerstashstringstash with the current text to form an interim result. The system updates text and stash continuously using response.text.text events until it receives a response.text.done event. The final complete text is then available in the text field.response.text.done
Returned when text generation finishes for text-only output, or if the response is interrupted, incomplete, or canceled.
event_idstringtypestringresponse.text.done.response_idstringitem_idstringoutput_indexintegercontent_indexintegertextstringresponse.audio.delta
For WebSocket access, the server returns this event when the output modalities include audio and the model incrementally generates new audio data.
event_idstringtypestringresponse.audio.delta.response_idstringitem_idstringoutput_indexintegercontent_indexintegerdeltastringresponse.audio.done
Returned when audio generation is complete. Also returned if the response is interrupted, incomplete, or canceled. Does not contain complete audio data.
event_idstringtypestringresponse.audio.done.response_idstringitem_idstringoutput_indexintegercontent_indexintegerinput_audio_buffer.speech_started
Returned when the server-side VAD (Voice Activity Detection) detects that the user has started speaking.
event_idstringtypestringinput_audio_buffer.speech_started.audio_start_msintegeritem_idstringspeaker_idintegerqwen3.8-livetranslate-flash-realtime. The speaker identifier returned when speaker_detection is enabled. Use this event's item_id to associate the speaker with the transcription, and the translation item's previous_item_id to associate it with the translation.input_audio_buffer.speech_stopped
Returned when the server-side VAD detects that the user has stopped speaking, indicating the end of the current speech input turn. Because the translation response is generated synchronously with the streaming speech input, the actual translation response may have already started during the speech input process, without needing to wait for this event.
event_idstringtypestringinput_audio_buffer.speech_stopped.audio_end_msintegeritem_idstringinput_audio_buffer.committed
In Manual mode (turn_detection is null), after the client sends an input_audio_buffer.commit event, the server returns this event as confirmation and automatically starts generating the translation response.
event_idstringtypestringinput_audio_buffer.committed.input_audio_buffer.cleared
After the client sends an input_audio_buffer.clear event, the server returns this event as confirmation that the uncommitted audio data in the buffer has been cleared.
event_idstringtypestringinput_audio_buffer.cleared.conversation.item.created
Returned when a new message item is created in the conversation. This event is triggered in the following scenarios:
- When the server starts generating a translation response, it creates a corresponding assistant message item (at this point,
contentis an empty array, and the content is progressively populated with the streaming response). - In Manual mode, after the client sends an
input_audio_buffer.commitevent, the server additionally creates a message item corresponding to the user's input audio (contentcontains{"type": "input_audio"}).
item.id of the speech recognition result matches the previous_item_id in the translation result event. Use these values to associate and display the source text with its translation.
event_idstringtypestringconversation.item.created.previous_item_idstringitem.id of the speech recognition result for the same VAD segment.itemobjectProperties
Properties
idstringtypestringmessage.objectstringrealtime.item.statusstringrolestringassistant or user.contentarray{"type": "input_audio"}.conversation.item.input_audio_transcription.delta
Applies to qwen3.8-livetranslate-flash-realtime. Returns source transcription increments for input audio.
event_idstringtypestringconversation.item.input_audio_transcription.delta.item_idstringcontent_indexintegerdeltastringconversation.item.input_audio_transcription.text
Applies to models such as qwen3.5-livetranslate-flash-realtime. For qwen3.8-livetranslate-flash-realtime, handle conversation.item.input_audio_transcription.delta instead.
When input_audio_transcription.model is configured, the server streams speech recognition results in the original source language.
event_idstringtypestringconversation.item.input_audio_transcription.text.item_idstringcontent_indexintegertextstringstashstringlanguagestringemotionstringsurprised: Surprisedneutral: Neutralhappy: Happysad: Saddisgusted: Disgustedangry: Angryfearful: Fearful
conversation.item.input_audio_transcription.completed
When input_audio_transcription.model is configured, returns the final recognition result after speech recognition completes.
event_idstringtypestringconversation.item.input_audio_transcription.completed.item_idstringcontent_indexintegertranscriptstringlanguagestringemotionstringsurprised: surprisedneutral: calm/neutralhappy: happysad: saddisgusted: disgustedangry: angryfearful: fearful
conversation.item.input_audio_transcription.failed
Returned when audio input was received but speech recognition failed. This event is handled separately from other error events, making it easier for the client to identify the specific associated item.
typestringconversation.item.input_audio_transcription.failed.item_idstringcontent_indexintegererrorobjectProperties
Properties
codestringmessagestringresponse.audio_transcript.delta
Applies to qwen3.8-livetranslate-flash-realtime. Returns a new translation fragment for text and audio output.
event_idstringtypestringresponse.audio_transcript.delta.response_idstringitem_idstringoutput_indexintegercontent_indexintegerdeltastringresponse.audio_transcript.text
Applies to models such as qwen3.5-livetranslate-flash-realtime. For qwen3.8-livetranslate-flash-realtime, handle response.audio_transcript.delta instead.
Returned for audio output to display real-time translation.
event_idstringtypestringresponse.audio_transcript.text.response_idstringitem_idstringoutput_indexintegercontent_indexintegertextstringstashstringtext to form interim results. The system updates text and stash continuously via response.audio_transcript.text events until a response.audio_transcript.done event is received. Then retrieve the final translation from transcript.response.audio_transcript.done
Returned when audio output is enabled and text generation finishes.
event_idstringtypestringresponse.audio_transcript.done.response_idstringitem_idstringoutput_indexintegercontent_indexintegertranscriptstringresponse.output_item.added
Returned when a new output item is added during response generation.
event_idstringtypestringresponse.output_item.added.response_idstringoutput_indexintegeritemobjectProperties
Properties
idstringtypestringmessage.objectstringrealtime.item.statusstringrolestringcontentstringresponse.output_item.done
Returned when an output item is completed.
event_idstringtypestringresponse.output_item.done.response_idstringoutput_indexintegeritemobjectProperties
Properties
idstringobjectstringrealtime.item.typestringmessage.statusstringrolestringcontentstringresponse.content_part.added
Returned when a new content part is added.
event_idstringtypestringresponse.content_part.added.response_idstringitem_idstringoutput_indexintegercontent_indexintegerpartobjectProperties
Properties
typestringtextstringresponse.content_part.done
Returned when a content part is completed.
event_idstringtypestringresponse.content_part.done.response_idstringitem_idstringoutput_indexintegercontent_indexintegerpartobjectProperties
Properties
typestringtextstring