You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/cognitive-services/Speech-Service/language-identification.md
+7-21Lines changed: 7 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,7 +42,7 @@ Code snippets are included with the concepts described next. Complete samples fo
42
42
43
43
### Candidate languages
44
44
45
-
You provide candidate languages, at least one of which is expected to be in the audio. You can include up to four languages for [at-start LID](#at-start-and-continuous-language-identification) or up to 10 languages for [continuous LID](#at-start-and-continuous-language-identification). The Speech service returns one of the candidate languages provided even if those languages weren't in the audio. For example, if `fr-FR` (French) and `en-US` (English) are provided as candidates, but German is spoken, either `fr-FR` or `en-US` would be returned.
45
+
You provide candidate languages with the `AutoDetectSourceLanguageConfig` object, at least one of which is expected to be in the audio. You can include up to four languages for [at-start LID](#at-start-and-continuous-language-identification) or up to 10 languages for [continuous LID](#at-start-and-continuous-language-identification). The Speech service returns one of the candidate languages provided even if those languages weren't in the audio. For example, if `fr-FR` (French) and `en-US` (English) are provided as candidates, but German is spoken, either `fr-FR` or `en-US` would be returned.
46
46
47
47
You must provide the full locale with dash (`-`) separator, but language identification only uses one locale per base language. Don't include multiple locales (for example, "en-US" and "en-GB") for the same language.
48
48
@@ -106,7 +106,7 @@ Speech supports both at-start and continuous language identification (LID).
106
106
- At-start LID identifies the language once within the first few seconds of audio. Use at-start LID if the language in the audio won't change. With at-start LID, a single language is detected and returned in less than 5 seconds.
107
107
- Continuous LID can identify multiple languages for the duration of the audio. Use continuous LID if the language in the audio could change. Continuous LID doesn't support changing languages within the same sentence. For example, if you're primarily speaking Spanish and insert some English words, it will not detect the language change per word. With Continuous LID, a language is detected every 2 seconds for the duration of the audio.
108
108
109
-
You implement at-start LID or continuous LID by calling methods for [recognize once or continuous](#recognize-once-or-continuous).
109
+
You implement at-start LID or continuous LID by calling methods for [recognize once or continuous](#recognize-once-or-continuous). Continuous LID is only supported with continuous recognition.
110
110
111
111
### Recognize once or continuous
112
112
@@ -117,7 +117,7 @@ Language identification is completed with recognition objects and operations. Yo
117
117
118
118
You'll either call the "recognize once" method, or the start and stop continuous recognition methods. You choose from:
119
119
120
-
- Recognize once with at-start LID
120
+
- Recognize once with At-start LID. Continuous LID isn't supported for recognize once.
121
121
- Continuous recognition with at-start LID
122
122
- Continuous recognition with continuous LID
123
123
@@ -126,7 +126,7 @@ The `SpeechServiceConnection_LanguageIdMode` property is only required for conti
126
126
::: zone pivot="programming-language-csharp"
127
127
128
128
```csharp
129
-
// Recognize once with At-start LID
129
+
// Recognize once with At-start LID. Continuous LID isn't supported for recognize once.
130
130
var result =awaitrecognizer.RecognizeOnceAsync();
131
131
132
132
// Start and stop continuous recognition with At-start LID
0 commit comments