Real-Time Transcription and Translation
Phenix offers a transcription and translation service, which has the ability to transcribe from a specific source language and provide the output in that same language (for use as closed captions) and in other languages (for use as subtitles).
Status Notice
This service is currently experimental. If you would like to try using this service, please contact your Phenix technical representative for access to code and setup instructions, or for access to an example service.
Overview
The Transcription service subscribes to an audio-only stream from content that is published to a Channel in the Phenix PaaS using any publishing method supported by Phenix. This audio stream is transcribed by the service. The transcribed content is then passed to the translation service, along with a set of desired output (target) languages. The translated and transcribed text is sent back to the Phenix PaaS and is sent as a message in the original Channel. Any client that subscribes to the Channel will receive all the languages in a JSON object within the data stream. This maintains synchronization between all languages. Phenix provides an example client UI that can select a language for display.
Setup
Determine the IP address of the location where you will host your translation service
(e.g., localhost or the IP address of a cloud VM).
In this page, localhost
is used as an example.
Configure the transcription service as described in the GitHub repository provided by Phenix.
Server Usage
In the Phenix Customer Portal, create a channel and copy the Channel ID.
Open the calls.html page served from your transcription service.
Enter the Channel ID of the desired channel.
Enter the ISO 639-1 language code for the input language in the Input language box. Enter the codes for the desired output languages in the Language List box. Language codes in the Language List box must be separated by a comma with no spaces. Supported language codes are shown at the bottom of the page.
Using ISO 639-2 language codes or other non-supported text will result in an error and all text showing as "null".
Click Start to start the transcription and translation process. The translation service will create all the languages in the Language List and will make them available to all viewers. An example is shown below. In this example, the original language is Swedish (the first language in the array).
[{
"languageCode": "sv",
"translation": "Klarar du alla"
}, {
"languageCode": "zh-CN",
"translation": "你能处理所有的事情吗?"
}, {
"languageCode": "fr",
"translation": "Pouvez-vous tous les gérer ?"
}, {
"languageCode": "de",
"translation": "Kannst du mit allen umgehen?"
}, {
"languageCode": "el",
"translation": "Μπορείς να τα διαχειριστείς όλα;"
}, {
"languageCode": "es",
"translation": "¿Podrás manejarlos a todos?"
}
]
Use the Phenix Customer Portal's Messages tab for the Channel to verify that the translated messages are being sent as expected.
Click Stop to terminate the translation process.
Client
To see transcribed and translated messages in a client, generate a viewing token from the Phenix Customer Portal.
Use the token in a viewing page hosted at your server URL, e.g.,:
https://localhost:8080/translate_client.html?token=<viewing token>
Select the desired language from the dropdown list, as shown below.
Different clients can select different languages, with all languages available in real-time and in sync.