Skip to content

Commit

Permalink
feat(speech-to-text-v1): add more languages supported for next genera…
Browse files Browse the repository at this point in the history
…tion models
  • Loading branch information
kevinkowa committed Sep 9, 2021
1 parent 54d2338 commit 2fbd050
Showing 1 changed file with 53 additions and 30 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* (C) Copyright IBM Corp. 2018, 2021.
* (C) Copyright IBM Corp. 2021.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
Expand All @@ -25,8 +25,9 @@ public class CreateJobOptions extends GenericModel {

/**
* The identifier of the model that is to be used for the recognition request. (**Note:** The
* model `ar-AR_BroadbandModel` is deprecated; use `ar-MS_BroadbandModel` instead.) See [Languages
* and models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models) and
* model `ar-AR_BroadbandModel` is deprecated; use `ar-MS_BroadbandModel` instead.) See
* [Previous-generation languages and
* models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models) and
* [Next-generation languages and
* models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models-ng).
*/
Expand All @@ -49,6 +50,8 @@ public interface Model {
String EN_AU_NARROWBANDMODEL = "en-AU_NarrowbandModel";
/** en-AU_Telephony. */
String EN_AU_TELEPHONY = "en-AU_Telephony";
/** en-IN_Telephony. */
String EN_IN_TELEPHONY = "en-IN_Telephony";
/** en-GB_BroadbandModel. */
String EN_GB_BROADBANDMODEL = "en-GB_BroadbandModel";
/** en-GB_NarrowbandModel. */
Expand Down Expand Up @@ -99,10 +102,14 @@ public interface Model {
String FR_CA_TELEPHONY = "fr-CA_Telephony";
/** fr-FR_BroadbandModel. */
String FR_FR_BROADBANDMODEL = "fr-FR_BroadbandModel";
/** fr-FR_Multimedia. */
String FR_FR_MULTIMEDIA = "fr-FR_Multimedia";
/** fr-FR_NarrowbandModel. */
String FR_FR_NARROWBANDMODEL = "fr-FR_NarrowbandModel";
/** fr-FR_Telephony. */
String FR_FR_TELEPHONY = "fr-FR_Telephony";
/** hi-IN_Telephony. */
String HI_IN_TELEPHONY = "hi-IN_Telephony";
/** it-IT_BroadbandModel. */
String IT_IT_BROADBANDMODEL = "it-IT_BroadbandModel";
/** it-IT_NarrowbandModel. */
Expand All @@ -111,12 +118,20 @@ public interface Model {
String IT_IT_TELEPHONY = "it-IT_Telephony";
/** ja-JP_BroadbandModel. */
String JA_JP_BROADBANDMODEL = "ja-JP_BroadbandModel";
/** ja-JP_Multimedia. */
String JA_JP_MULTIMEDIA = "ja-JP_Multimedia";
/** ja-JP_NarrowbandModel. */
String JA_JP_NARROWBANDMODEL = "ja-JP_NarrowbandModel";
/** ko-KR_BroadbandModel. */
String KO_KR_BROADBANDMODEL = "ko-KR_BroadbandModel";
/** ko-KR_Multimedia. */
String KO_KR_MULTIMEDIA = "ko-KR_Multimedia";
/** ko-KR_NarrowbandModel. */
String KO_KR_NARROWBANDMODEL = "ko-KR_NarrowbandModel";
/** ko-KR_Telephony. */
String KO_KR_TELEPHONY = "ko-KR_Telephony";
/** nl-BE_Telephony. */
String NL_BE_TELEPHONY = "nl-BE_Telephony";
/** nl-NL_BroadbandModel. */
String NL_NL_BROADBANDMODEL = "nl-NL_BroadbandModel";
/** nl-NL_NarrowbandModel. */
Expand All @@ -137,9 +152,9 @@ public interface Model {
* If the job includes a callback URL, a comma-separated list of notification events to which to
* subscribe. Valid events are * `recognitions.started` generates a callback notification when the
* service begins to process the job. * `recognitions.completed` generates a callback notification
* when the job is complete. You must use the **Check a job** method to retrieve the results
* before they time out or are deleted. * `recognitions.completed_with_results` generates a
* callback notification when the job is complete. The notification includes the results of the
* when the job is complete. You must use the [Check a job](#checkjob) method to retrieve the
* results before they time out or are deleted. * `recognitions.completed_with_results` generates
* a callback notification when the job is complete. The notification includes the results of the
* request. * `recognitions.failed` generates a callback notification if the service experiences
* an error while processing the job.
*
Expand Down Expand Up @@ -737,8 +752,9 @@ public String contentType() {
* Gets the model.
*
* <p>The identifier of the model that is to be used for the recognition request. (**Note:** The
* model `ar-AR_BroadbandModel` is deprecated; use `ar-MS_BroadbandModel` instead.) See [Languages
* and models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models) and
* model `ar-AR_BroadbandModel` is deprecated; use `ar-MS_BroadbandModel` instead.) See
* [Previous-generation languages and
* models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models) and
* [Next-generation languages and
* models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models-ng).
*
Expand All @@ -752,9 +768,9 @@ public String model() {
* Gets the callbackUrl.
*
* <p>A URL to which callback notifications are to be sent. The URL must already be successfully
* allowlisted by using the **Register a callback** method. You can include the same callback URL
* with any number of job creation requests. Omit the parameter to poll the service for job
* completion and results.
* allowlisted by using the [Register a callback](#registercallback) method. You can include the
* same callback URL with any number of job creation requests. Omit the parameter to poll the
* service for job completion and results.
*
* <p>Use the `user_token` parameter to specify a unique user-specified string with each job to
* differentiate the callback notifications for the jobs.
Expand All @@ -771,11 +787,11 @@ public String callbackUrl() {
* <p>If the job includes a callback URL, a comma-separated list of notification events to which
* to subscribe. Valid events are * `recognitions.started` generates a callback notification when
* the service begins to process the job. * `recognitions.completed` generates a callback
* notification when the job is complete. You must use the **Check a job** method to retrieve the
* results before they time out or are deleted. * `recognitions.completed_with_results` generates
* a callback notification when the job is complete. The notification includes the results of the
* request. * `recognitions.failed` generates a callback notification if the service experiences
* an error while processing the job.
* notification when the job is complete. You must use the [Check a job](#checkjob) method to
* retrieve the results before they time out or are deleted. *
* `recognitions.completed_with_results` generates a callback notification when the job is
* complete. The notification includes the results of the request. * `recognitions.failed`
* generates a callback notification if the service experiences an error while processing the job.
*
* <p>The `recognitions.completed` and `recognitions.completed_with_results` events are
* incompatible. You can specify only of the two events.
Expand Down Expand Up @@ -1022,7 +1038,8 @@ public Boolean profanityFilter() {
* final transcript of a recognition request. For US English, the service also converts certain
* keyword strings to punctuation symbols. By default, the service performs no smart formatting.
*
* <p>**Note:** Applies to US English, Japanese, and Spanish transcription only.
* <p>**Beta:** The parameter is beta functionality. Applies to US English, Japanese, and Spanish
* transcription only.
*
* <p>See [Smart
* formatting](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-formatting#smart-formatting).
Expand All @@ -1039,11 +1056,13 @@ public Boolean smartFormatting() {
* <p>If `true`, the response includes labels that identify which words were spoken by which
* participants in a multi-person exchange. By default, the service returns no speaker labels.
* Setting `speaker_labels` to `true` forces the `timestamps` parameter to be `true`, regardless
* of whether you specify `false` for the parameter. * For previous-generation models, can be used
* for US English, Australian English, German, Japanese, Korean, and Spanish (both broadband and
* narrowband models) and UK English (narrowband model) transcription only. * For next-generation
* models, can be used for English (Australian, UK, and US), German, and Spanish transcription
* only.
* of whether you specify `false` for the parameter.
*
* <p>**Beta:** The parameter is beta functionality. * For previous-generation models, the
* parameter can be used for Australian English, US English, German, Japanese, Korean, and Spanish
* (both broadband and narrowband models) and UK English (narrowband model) transcription only. *
* For next-generation models, the parameter can be used for English (Australian, Indian, UK, and
* US), German, Japanese, Korean, and Spanish transcription only.
*
* <p>Restrictions and limitations apply to the use of speaker labels for both types of models.
* See [Speaker
Expand Down Expand Up @@ -1075,7 +1094,11 @@ public String customizationId() {
* grammar, you must also use the `language_customization_id` parameter to specify the name of the
* custom language model for which the grammar is defined. The service recognizes only strings
* that are recognized by the specified grammar; it does not recognize other custom words from the
* model's words resource. See [Using a grammar for speech
* model's words resource.
*
* <p>**Beta:** The parameter is beta functionality.
*
* <p>See [Using a grammar for speech
* recognition](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-grammarUse).
*
* @return the grammarName
Expand All @@ -1097,7 +1120,8 @@ public String grammarName() {
* disables keyword spotting (ignores the `keywords` and `keywords_threshold` parameters) and
* returns only a single final transcript (forces the `max_alternatives` parameter to be `1`).
*
* <p>**Note:** Applies to US English, Japanese, and Korean transcription only.
* <p>**Beta:** The parameter is beta functionality. Applies to US English, Japanese, and Korean
* transcription only.
*
* <p>See [Numeric
* redaction](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-formatting#numeric-redaction).
Expand Down Expand Up @@ -1260,12 +1284,11 @@ public Float backgroundAudioSuppression() {
* parameter causes the models to produce results even more quickly, though the results might be
* less accurate when the parameter is used.
*
* <p>**Note:** The parameter is beta functionality. It is not available for previous-generation
* `Broadband` and `Narrowband` models. It is available only for some next-generation models.
*
* <p>* For a list of next-generation models that support low latency, see [Supported language
* models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models-ng#models-ng-supported)
* for next-generation models. * For more information about the `low_latency` parameter, see [Low
* <p>The parameter is not available for previous-generation `Broadband` and `Narrowband` models.
* It is available only for some next-generation models. For a list of next-generation models that
* support low latency, see [Supported next-generation language
* models](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-models-ng#models-ng-supported).
* * For more information about the `low_latency` parameter, see [Low
* latency](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-interim#low-latency).
*
* @return the lowLatency
Expand Down

0 comments on commit 2fbd050

Please sign in to comment.