-
Notifications
You must be signed in to change notification settings - Fork 324
Update the docs for nemotron multi-lingual ASR model #728
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
657ce7b
bd3bb70
d36efac
ac99f7d
de2b8f6
f873f62
494b382
1ca5433
c70207a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -300,6 +300,41 @@ audioClient.Settings.Language = "en"; | |||||
| audioClient.Settings.Temperature = 0.0f; | ||||||
| ``` | ||||||
|
|
||||||
| #### Multilingual Language Codes | ||||||
|
|
||||||
| When using a multilingual ASR model (e.g. `nvidia-nemotron-3.5-asr-streaming-multilingual-0.6b`), set `Language` to a BCP-47 language code to hint the expected language. This applies to both `OpenAIAudioClient.Settings.Language` and `LiveAudioTranscriptionSession.Settings.Language`. | ||||||
|
|
||||||
| | Code | Language | Code | Language | | ||||||
| |------|----------|------|----------| | ||||||
| | `en-US` | English (US) | `en-GB` | English (UK) | | ||||||
| | `zh-CN` | Chinese (Simplified) | `ja-JP` | Japanese | | ||||||
| | `ko-KR` | Korean | `de-DE` | German | | ||||||
| | `fr-FR` | French | `fr-CA` | French (Canada) | | ||||||
| | `es-ES` | Spanish (Spain) | `es-US` | Spanish (US) | | ||||||
| | `it-IT` | Italian | `pt-BR` | Portuguese (Brazil) | | ||||||
| | `pt-PT` | Portuguese (Portugal) | `ru-RU` | Russian | | ||||||
| | `ar-AR` | Arabic | `hi-IN` | Hindi | | ||||||
| | `nl-NL` | Dutch | `pl-PL` | Polish | | ||||||
| | `sv-SE` | Swedish | `da-DK` | Danish | | ||||||
| | `fi-FI` | Finnish | `cs-CZ` | Czech | | ||||||
| | `ro-RO` | Romanian | `hu-HU` | Hungarian | | ||||||
| | `sk-SK` | Slovak | `bg-BG` | Bulgarian | | ||||||
| | `el-GR` | Greek | `et-EE` | Estonian | | ||||||
| | `hr-HR` | Croatian | `lt-LT` | Lithuanian | | ||||||
| | `lv-LV` | Latvian | `sl-SL` | Slovenian | | ||||||
| | `uk-UA` | Ukrainian | `he-IL` | Hebrew | | ||||||
| | `nb-NO` | Norwegian (Bokmål) | `nn-NO` | Norwegian (Nynorsk) | | ||||||
| | `th-TH` | Thai | `tr-TR` | Turkish | | ||||||
| | `vi-VN` | Vietnamese | `auto` | Auto-detect | | ||||||
|
|
||||||
| Use `"auto"` to let the model detect the spoken language automatically. | ||||||
|
|
||||||
| ```csharp | ||||||
| // Multilingual example | ||||||
| audioClient.Settings.Language = "zh-CN"; // Chinese | ||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| session.Settings.Language = "auto"; // Auto-detect | ||||||
| ``` | ||||||
|
|
||||||
| ### Live Audio Transcription (Real-Time Streaming) | ||||||
|
|
||||||
| For real-time microphone-to-text transcription, use `CreateLiveTranscriptionSession()`. Audio is pushed as raw PCM chunks and transcription results stream back as an `IAsyncEnumerable`. | ||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -265,6 +265,39 @@ for await (const chunk of audioClient.transcribeStreaming('/path/to/audio.wav')) | |||||
| } | ||||||
| ``` | ||||||
|
|
||||||
| #### Multilingual Language Codes | ||||||
|
|
||||||
| When using a multilingual ASR model (e.g. `nvidia-nemotron-3.5-asr-streaming-multilingual-0.6b`), set `language` to a BCP-47 language code to hint the expected language. | ||||||
|
|
||||||
| | Code | Language | Code | Language | | ||||||
| |------|----------|------|----------| | ||||||
| | `en-US` | English (US) | `en-GB` | English (UK) | | ||||||
| | `zh-CN` | Chinese (Simplified) | `ja-JP` | Japanese | | ||||||
| | `ko-KR` | Korean | `de-DE` | German | | ||||||
| | `fr-FR` | French | `fr-CA` | French (Canada) | | ||||||
| | `es-ES` | Spanish (Spain) | `es-US` | Spanish (US) | | ||||||
| | `it-IT` | Italian | `pt-BR` | Portuguese (Brazil) | | ||||||
| | `pt-PT` | Portuguese (Portugal) | `ru-RU` | Russian | | ||||||
| | `ar-AR` | Arabic | `hi-IN` | Hindi | | ||||||
| | `nl-NL` | Dutch | `pl-PL` | Polish | | ||||||
| | `sv-SE` | Swedish | `da-DK` | Danish | | ||||||
| | `fi-FI` | Finnish | `cs-CZ` | Czech | | ||||||
| | `ro-RO` | Romanian | `hu-HU` | Hungarian | | ||||||
| | `sk-SK` | Slovak | `bg-BG` | Bulgarian | | ||||||
| | `el-GR` | Greek | `et-EE` | Estonian | | ||||||
| | `hr-HR` | Croatian | `lt-LT` | Lithuanian | | ||||||
| | `lv-LV` | Latvian | `sl-SL` | Slovenian | | ||||||
| | `uk-UA` | Ukrainian | `he-IL` | Hebrew | | ||||||
| | `nb-NO` | Norwegian (Bokmål) | `nn-NO` | Norwegian (Nynorsk) | | ||||||
| | `th-TH` | Thai | `tr-TR` | Turkish | | ||||||
| | `vi-VN` | Vietnamese | `auto` | Auto-detect | | ||||||
|
|
||||||
| ```typescript | ||||||
| // Multilingual example | ||||||
| audioClient.settings.language = 'zh-CN'; // Chinese | ||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| audioClient.settings.language = 'auto'; // Auto-detect | ||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| ``` | ||||||
|
|
||||||
| ### Embedded Web Service | ||||||
|
|
||||||
| Start a local HTTP server that exposes an OpenAI-compatible API: | ||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -441,6 +441,39 @@ while let Some(chunk) = stream.next().await { | |
| } | ||
| ``` | ||
|
|
||
| #### Multilingual Language Codes | ||
|
|
||
| When using a multilingual ASR model (e.g. `nvidia-nemotron-3.5-asr-streaming-multilingual-0.6b`), set `language` to a BCP-47 language code to hint the expected language. | ||
|
|
||
| | Code | Language | Code | Language | | ||
| |------|----------|------|----------| | ||
| | `en-US` | English (US) | `en-GB` | English (UK) | | ||
| | `zh-CN` | Chinese (Simplified) | `ja-JP` | Japanese | | ||
| | `ko-KR` | Korean | `de-DE` | German | | ||
| | `fr-FR` | French | `fr-CA` | French (Canada) | | ||
| | `es-ES` | Spanish (Spain) | `es-US` | Spanish (US) | | ||
| | `it-IT` | Italian | `pt-BR` | Portuguese (Brazil) | | ||
| | `pt-PT` | Portuguese (Portugal) | `ru-RU` | Russian | | ||
| | `ar-AR` | Arabic | `hi-IN` | Hindi | | ||
|
rui-ren marked this conversation as resolved.
|
||
| | `nl-NL` | Dutch | `pl-PL` | Polish | | ||
| | `sv-SE` | Swedish | `da-DK` | Danish | | ||
| | `fi-FI` | Finnish | `cs-CZ` | Czech | | ||
| | `ro-RO` | Romanian | `hu-HU` | Hungarian | | ||
| | `sk-SK` | Slovak | `bg-BG` | Bulgarian | | ||
| | `el-GR` | Greek | `et-EE` | Estonian | | ||
| | `hr-HR` | Croatian | `lt-LT` | Lithuanian | | ||
| | `lv-LV` | Latvian | `sl-SL` | Slovenian | | ||
|
rui-ren marked this conversation as resolved.
|
||
| | `uk-UA` | Ukrainian | `he-IL` | Hebrew | | ||
| | `nb-NO` | Norwegian (Bokmål) | `nn-NO` | Norwegian (Nynorsk) | | ||
| | `th-TH` | Thai | `tr-TR` | Turkish | | ||
| | `vi-VN` | Vietnamese | `auto` | Auto-detect | | ||
|
|
||
| ```rust | ||
| // Multilingual example | ||
| let audio_client = model.create_audio_client() | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Let's change this code section to the following. session.settings.language = Some("zh-CN".into()); // Chinese (Simplified)
session.settings.language = Some("auto".into()); // Auto-detect language |
||
| .language("zh-CN"); // Chinese | ||
| ``` | ||
|
|
||
| ### Embedded Web Service | ||
|
|
||
| Start a local HTTP server that exposes an OpenAI-compatible REST API: | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we move these sections into the READMEs for the live audio transcription samples? These sections are currently listed in the SDK READMEs, which a customer will likely not see.