vania-janet/multiturn-rag-retrieval-data huggingface dataset:
Research references 

For more information about the research behind the IBM Watson® Speech to Text service, see the following documents. IBM® researchers wrote or contributed to all of these papers.



1. Audhkhasi, Kartik, Bhuvana Ramabhadran, George Saon, Michael Picheny, and David Nahamoo. [Direct Acoustics-to-Word Models for English Conversational Speech Recognition.](https://www.isca-speech.org/archive_v0/Interspeech_2017/pdfs/0546.PDF) Proceedings of Interspeech 2017 (August 2017): pp. 959-963.
2. Audhkhasi, Kartik, Brian Kingsbury, Bhuvana Ramabhadran, George Saon, and Michael Picheny. [Building competitive direct acoustics-to-word models for English conversational speech recognition.](https://arxiv.org/pdf/1712.03133.pdf) Proceedings of the IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP) (2018).
3. Bahl, Lalit R., Frederick Jelinek, and Robert L. Mercer. [A Maximum Likelihood Approach to Continuous Speech Recognition.](https://ieeexplore.ieee.org/document/4767370) IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. 5(2) (March 1983): pp. 179-190.
4. Fukuda, Takashi, Masayuki Suzuki, Gakuto Kurata, Samuel Thomas, Jia Cui, and Bhuvana Ramabhadran. [Efficient Knowledge Distillation from an Ensemble of Teachers.](https://www.isca-speech.org/archive_v0/Interspeech_2017/pdfs/0614.PDF) Proceedings of Interspeech 2017 (August 2017): pp. 3697-3701.
5. Graves, Alex. [Sequence Transduction with Recurrent Neural Networks.]
add PUT /conferences/{conference_id}/speakers/{id} 201 Created or 200 OK (if the binding exists) add_conference_speaker Create (or ensure) a binding between the conference identified by {conference_id} and the speaker identified by {id} 
 remove DELETE /conferences/{conference_id}/speakers/{id} 204 No Content remove_conference_speaker Remove the binding between the conference identified by {conference_id} and the speaker identified by {id} 



The verbs add and remove SHOULD NOT be used except in a symmetrical pair of operations.







 Minimally represented resource operations 

The following conventions for operations on resources (especially child resources) that can each be wholly represented by a unique string SHOULD be used where applicable.



Operations for minimally represented resources

 Verb Example method and path Success status code Recommended operation ID Description 

 add PUT /books/{id}/genres/{genre} 201 Created or 204 No Content (if the child already exists) add_book_genre Create (or ensure the existence) of the genre described by {genre} for the book identified by {id} 
 remove DELETE /books/{id}/genres/{genre} 204 No Content remove_book_genre Remove the genre described by {genre} from the book identified by {id} 
 check GET /books/{id}/genres/{genre} 204 No Content check_book_genre Check for the existence of the genre described by {genre} on the book identified by {id} 







 Custom operations 

Some operations do not fit one of the defined conventions. Typically these operations are either:



* Inherently functional — for example, an operation that converts text in a request payload to audio in a response
* Result in an unchanged end state — for example, an operation that reboots a virtual server instance



A custom operation SHOULD use a POST or a GET method, following [the requirements for those methods](https://cloud.ibm.com/docs/api-handbook?topic=api-handbook-methods).







 Examples 

Each media type definition within an operation's request body and a successful response body definitions MUST include at least one example. A single example can be provided within the media type's example property. Multiple, named examples can be provided in the (mutually exclusive) examples property.
To find conflicts for multiple documents in a database, write a view.

The following map function is an example that emits all conflicting revisions for every document that has a conflict.

See the following example of a map function to find documents with a conflict:

function (doc) {
if (doc._conflicts) {
emit(null, [doc._rev].concat(doc._conflicts));
}
}

You might regularly query this view and resolve conflicts as needed, or query the view after each replication.





 Steps to resolve conflicts 

After you find a conflict, you can resolve it in four steps: get, merge, upload, and delete, as shown later.

Let's consider an example of how to resolve a conflict. Suppose that you have a database of products for an online shop. The first version of a document might look like the following example:

{
"_id": "74b2be56045bed0c8c9d24b939000dbe",
"_rev": "1-7438df87b632b312c53a08361a7c3299",
"name": "Samsung Galaxy S4",
"description": "",
"price": 650
}

As the document doesn't have a description yet, someone might add one.

See the second version of the document, which is created by adding a description:

{
"_id": "74b2be56045bed0c8c9d24b939000dbe",
"_rev": "2-61ae00e029d4f5edd2981841243ded13",
"name": "Samsung Galaxy S4",
"description": "Latest smartphone from Samsung",
"price": 650
}

At the same time, someone else - working with a replicated database - reduces the price.

See a different revision, conflicting with the previous one because of different price value:

{
Create individual extractors for all needed terms by extending provided extractors, or creating [dictionaries](https://cloud.ibm.com/docs/watson-knowledge-studio-data?topic=watson-knowledge-studio-data-managing-projects-and-extractorscreating-a-dictionary), [regular expressions](https://cloud.ibm.com/docs/watson-knowledge-studio-data?topic=watson-knowledge-studio-data-managing-projects-and-extractorscreating-a-regular-expression), [literals](https://cloud.ibm.com/docs/watson-knowledge-studio-data?topic=watson-knowledge-studio-data-managing-projects-and-extractorscreating-a-literal).
2. Drag and drop one extractor to another extractor on the canvas, aligning your cursor to reflect the order in which the term appears in the text pattern. A dark, bold blue line to the left or right of the extractor on which you are dropping the new extractor indicates the relative positions of the extractors. After you drop the new extractor, a box surrounds the two extractors to indicate the sequence. The box has a temporary title, Sequence n.
3. Optional: Select the sequence on the canvas and rename it in Extractor Properties under General.
4. Optional: If needed, repeat steps 1 and 2 to add additional elements to the pattern.





 Sequence pattern example 

To select references to military personnel:



1. Create a dictionary called Military Ranks that includes terms such as Warrant Officer, Sergeant, and Lieutenant.
2. Drag the Person extractor onto the canvas following the Military Ranks dictionary to indicate that the new sequence finds ranks then names. The dark blue line after the Military Ranks extractor indicates placement of the Person extractor in the text pattern.

![Person extractor](https://cloud.ibm.com/docs-content/v1/content/148d3bd95f946aa1bb53ea1540475f522e6b61c9/watson-knowledge-studio-data/images/military_ranks.png)
Speech to text package entities

 Entity Type Parameters Description 

 [speech-to-text-v1](https://cloud.ibm.com/apidocs/speech-to-text) Package username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url Work with the Speech to Text V1 service. 
 [get-model](https://cloud.ibm.com/apidocs/speech-to-textget-model) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, model_id Get a model. 
 [list-models](https://cloud.ibm.com/apidocs/speech-to-textlist-models) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url List models. 
 [recognize-audio](https://cloud.ibm.com/apidocs/speech-to-textrecognize-audio) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, audio, content_type, model, customization_id, acoustic_customization_id, base_model_version, customization_weight, inactivity_timeout, keywords, keywords_threshold, max_alternatives, word_alternatives_threshold, word_confidence, timestamps, profanity_filter, smart_formatting, speaker_labels Recognize audio. 
 [check-job](https://cloud.ibm.com/apidocs/speech-to-textcheck-a-job) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, id Check a job.
[get-word](https://cloud.ibm.com/apidocs/speech-to-textget-a-custom-word) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, customization_id, word_name Get a custom word. 
 [list-words](https://cloud.ibm.com/apidocs/speech-to-textlist-custom-words) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, customization_id, word_type, sort List custom words. 
 [create-acoustic-model](https://cloud.ibm.com/apidocs/speech-to-textcreate-a-custom-acoustic-model) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, name, base_model_name, description Create a custom acoustic model. 
 [delete-acoustic-model](https://cloud.ibm.com/apidocs/speech-to-textdelete-a-custom-acoustic-model) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, customization_id Delete a custom acoustic model. 
 [get-acoustic-model](https://cloud.ibm.com/apidocs/speech-to-textget-a-custom-acoustic-model) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, customization_id Get a custom acoustic model.
Text to Speech docs 

Use the IBM Watson Text to Speech service to synthesize written text to natural-sounding speech. The synthesized audio uses appropriate cadence and intonation for its language and dialect. The documentation describes the Text to Speech service for IBM Cloud, IBM Cloud Pak for Data, and IBM Cloud Pak for Data as a Service.

  Developer tools 

[API & SDK reference](https://cloud.ibm.com/apidocs/text-to-speech)

  Recommended content 

[About A brief introduction to the service and its capabilities.](https://cloud.ibm.com/docs/text-to-speech?topic=text-to-speech-about)[Service features A more detailed description of the service and its capabilities.](https://cloud.ibm.com/docs/text-to-speech?topic=text-to-speech-service-features)[Getting started with Text to Speech A brief tutorial that demonstrates speech synthesis.](https://cloud.ibm.com/docs/text-to-speech?topic=text-to-speech-gettingStarted)[Release notes for IBM Cloud A summary of the latest releases and updates for IBM Watson Text to Speech for IBM Cloud.](https://cloud.ibm.com/docs/text-to-speech?topic=text-to-speech-release-notes)[Release notes for IBM Cloud Pak for Data A summary of the latest releases and updates for IBM Watson Text to Speech for IBM Cloud Pak for Data.](https://cloud.ibm.com/docs/text-to-speech?topic=text-to-speech-release-notes-data)

  Video library 

[![carousel thumbnail](https://cloud.ibm.com/docs-content/v1/content/text-to-speech//images/getting-started-thumbnail.png)<br><br>Getting started with the Text to Speech service for IBM Cloud](https://cloud.ibm.com/docs/text-to-speech?topic=text-to-speech-gettingStarted)
text-to-speech.custom-model-word.create Create a word for a custom model (PUT /v1/customizations/{customization_id}/words/{word}). 







 Read events 



Table 2. Customization .read actions that generate events

 Action Description 

 text-to-speech.custom-model-list.read Read a list of custom models created by a user (GET /v1/customizations). 
 text-to-speech.custom-model.read Read a custom model (GET /v1/customizations/{customization_id}). 
 text-to-speech.custom-model-word-list.read Read a word list for a custom model (GET /v1/customizations/{customization_id}/words). 
 text-to-speech.custom-model-word.read Read a word for a custom model (GET /v1/customizations/{customization_id}/words/{word}). 







 Update event 



Table 3. Customization .update action that generates an event

 Action Description 

 text-to-speech.custom-model.update Update a custom model (POST /v1/customizations/{customization_id}). 







 Delete events 



Table 4. Customization .delete actions that generate events

 Action Description 

 text-to-speech.custom-model.delete Delete a custom model (DELETE /v1/customizations/{customization_id}). 
 text-to-speech.custom-model-word.delete Delete a word from a custom model (DELETE /v1/customizations/{customization_id}/words/{word}). 









 Tune by Example events 

The following tables list the Text to Speech actions for the Tune by Example feature that generate events.



 Create events 



Table 5. Tune by Example .create actions that generate events

 Action Description 

 text-to-speech.speaker.create Create a speaker (POST /v1/speakers/{speaker_name}).
For example, the following statement contains an operator element that uses stringEquals to specify that the account ID and service name must exactly match the value element. The statement also contains an operator element that uses stringMatch to specify a naming pattern for Event Streams topics that you might use to organize access to those specific resources. This way, you can assign one policy to all topics in your account that begin with messagehub-topic-dev.

"resource": {
"attributes": [
{
"operator": "stringEquals",
"value": "0aeab68aabd14d89bd72e4330150710a0",
"key": "accountId"
},
{
"value": "messagehub",
"operator": "stringEquals",
"key": "serviceName"
},
{
"value": "messagehub-topic-dev",
"operator": "stringMatch",
"key": "resource"
}
]
},
Show more

[Authorization policies](https://cloud.ibm.com/docs/account?topic=account-serviceauth) are currently only supported in /v1/policies.





 Checking a policy version in the console 

Time-based conditions for IAM access policies use /v2/policies syntax. Policies that use /v1/policies syntax aren't eligible to add time-based conditions. To check whether you can add time-based conditions to an existing policy in the console, complete the following steps.



1. Go to Manage > Access (IAM).
2. Select Users, Trusted profiles, Service IDs, or Access groups, depending on the policy you want to check.
3. Select a specific users, trusted profile, service ID, or access group.
4. Go to Access > Access policies.
5. Click on a policy. /v1/policies are indicated by the following notification:

> Conditions unavailable for v1 policies
6.
app.kubernetes.io/name: speech-to-text
release: {{ <custom-resource-name> }}
name: <custom-resource-name>-postgres-network-policy
namespace: {{ <cpd-instance-namespace> }}
spec:
ingress:
- from:
- namespaceSelector: {}
podSelector:
matchLabels:
app.kubernetes.io/name: cloud-native-postgresql
EOF
Show more

where



* <custom-resource-name> is the name of the Speech services custom resource. The recommended name for version 4.0.x is speech-prod-cr; the recommended name for version 4.5.x is speech-cr.
* <cpd-instance-name> is the name of the project (namespace) in which the Speech services are installed. The documentation uses the environment variable ${PROJECT_CPD_INSTANCE} to identity the namespace.



3. To verify that the updated Network Policy allows the operator to monitor the operands and that the PostgreSQL cluster is in a healthy state, enter the following command, where <custom-resource-name> and <cpd-instance-name> are the values you used in the previous step:

oc -get cluster {{ <custom-resource-name> }}-postgres -n {{ <cpd-instance-namespace> }}

If the PostgreSQL cluster is functioning properly, the command produces output similar to the following:

NAME AGE INSTANCES READY STATUS PRIMARY
speech-cr-postgres 14d 3 3 Cluster in healthy state speech-cr-postgres-1



These steps do not cause operator to update the operands to the latest versions. However, the operands are upgraded as expected when you next upgrade the Speech services software.





 13 October 2022 (Version 4.5.3) 

Version 4.5.3 is now available
: Speech to Text for IBM Cloud Pak for Data version 4.5.3 is now available.
* For the [synchronous HTTP interface](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-http), pass both parameters with the POST /v1/recognize method.

IBM Cloud

curl -X POST -u "apikey:{apikey}" --header "Content-Type: audio/flac" --data-binary @audio-file.flac "{url}/v1/recognize?language_customization_id={customization_id}&grammar_name={grammar_name}"

IBM Cloud Pak for Data

curl -X POST --header "Authorization: Bearer {token}" --header "Content-Type: audio/flac" --data-binary @audio-file.flac "{url}/v1/recognize?language_customization_id={customization_id}&grammar_name={grammar_name}"
* For the [asynchronous HTTP interface](https://cloud.ibm.com/docs/speech-to-text?topic=speech-to-text-async), pass both parameters with the POST /v1/recognitions method.

IBM Cloud

curl -X POST -u "apikey:{apikey}" --header "Content-Type: audio/flac" --data-binary @audio-file.flac "{url}/v1/recognitions?language_customization_id={customization_id}&grammar_name={grammar_name}"

IBM Cloud Pak for Data

curl -X POST --header "Authorization: Bearer {token}" --header "Content-Type: audio/flac" --data-binary @audio-file.flac "{url}/v1/recognitions?language_customization_id={customization_id}&grammar_name={grammar_name}"
The value must match regular expression /[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/.

--version-id (string)
: The v4 UUID that uniquely identifies the secret version. You can also use previous to retrieve the previous version.

Note: To find the version ID of a secret, use the Get secret metadata method and check the response details. Required.

The value must match regular expression /^([0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}|previous)$/.

--action (string)
: The action to perform on the specified secret version. Required.

Allowable values are: revoke.





 Examples 

ibmcloud secrets-manager secret-version-update --secret-type=private_cert --id=exampleString --version-id=exampleString --action=revoke





 Example output 

Revoke private certificate secret version

Example response for revoking a version of a private_cert secret.

{
"metadata" : {
"collection_type" : "application/vnd.ibm.secrets-manager.secret+json",
"collection_total" : 1
},
"resources" : [ {
"created_by" : "iam-ServiceId-e4a2f0a4-3c76-4bef-b1f2-fbeae11c0f21",
"creation_date" : "2022-03-07T13:06:15Z",
"state" : 1,
"state_description" : "Active",
[register-callback](https://cloud.ibm.com/apidocs/speech-to-textregister-a-callback) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, callback_url, user_secret Register a callback. 
 [unregister-callback](https://cloud.ibm.com/apidocs/speech-to-textunregister-a-callback) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, callback_url Unregister a callback. 
 [create-language-model](https://cloud.ibm.com/apidocs/speech-to-textcreate-a-custom-language-model) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, name, base_model_name, dialect, description Create a custom language model. 
 [delete-language-model](https://cloud.ibm.com/apidocs/speech-to-textdelete-a-custom-language-model) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, customization_id Delete a custom language model. 
 [get-language-model](https://cloud.ibm.com/apidocs/speech-to-textget-a-custom-language-model) Action username, password, iam_access_token, iam_apikey, iam_url, headers, headers[X-Watson-Learning-Opt-Out], url, customization_id Get a custom language model.
ibmcloud iam trusted-profile-link-create sample-compute-profile --name my_link --cr-type IKS_SA --link-name default --link-namespace default --link-crn my_compute_resource_crn

For more information, see the [CLI reference](https://cloud.ibm.com/docs/account?topic=cli-ibmcloud_commands_iamibmcloud_iam_trusted_profile_link_create).
3. Create an access policy by running the following command:

ibmcloud iam trusted-profile-policy-create --roles Viewer

For more information, see the [CLI reference](https://cloud.ibm.com/docs/account?topic=cli-ibmcloud_commands_iamibmcloud_iam_trusted_profile_policy_create).







 Establishing trust with federated users by using the API 

Complete the following steps to define which federated users can access specific resources:



1. [Enable authentication from an external identity provider](https://cloud.ibm.com/docs/account?topic=account-idp-integration).
2. Create a trusted profile by specifying your account ID.

curl -X POST 'https://iam.cloud.ibm.com/v1/profiles' -H 'Authorization: Bearer TOKEN' -H 'Content-Type: application/json' -H 'Accept: application/json' -d '{
"name": "My Nice Profile",
"description": "My Nice Profile - desc",
"account_id": "ACCOUNT_ID"
}'

In the description, provide a list of actions available for this trusted profile.
3. Create conditions for your trusted profile. For federated users, set the type attribute to Profile-SAML. The realm-name is the IdP URL. For more information, see the [IAM Identity Services API](https://cloud.ibm.com/apidocs/iam-identity-token-api).
ibm_iam_user_policy.test_policy: Creation complete after 2s [id=ibm_id@ibm.com/f81b161f-e1db-4084-8b28-cfcbe88fec72]
5. Verify that the IAM access policy was successfully created by running the command and searching for the policy ID you previously noted.

ibmcloud iam user-policies ibm_id@ibm.com

Example output:

Policy ID: f81b161f-e1db-4084-8b28-cfcbe88fec72
Roles: Viewer, Editor, Administrator
Resources:
Service Name containers-kubernetes
Service Instance my-cluster
[uniqueId] => 750352919747xxx,
[groupUniqueId] => 618887378480xxx,
[lastPurge] => '1582188622',
[name] => 'UNIQUE_GROUP_NAME',
[saved] => 'SAVED',
[option] => 3,
[pathCount] => 2,
[paths] => ['/test1.html', 'test2.html'],
[purgeStatus] => 'SUCCESS'
)

The rate limit related headers also returned:

lastResponseHeaders =>
[
X-RateLimit-Purge-Paths-Limit-Burst => 1000,
X-RateLimit-Purge-Paths-Limit-Per-Second => 20,
X-RateLimit-Purge-Paths-Remaining => 998
]





 Example code for creating a token authentication 

This example shows how to create a token authentication.

$client = SoftLayerSoapClient::getClient(
'SoftLayer_Network_CdnMarketplace_Configuration_Behavior_TokenAuth',
null,
$apiUsername,
$apiKey
);

try {
$inputObject = new stdClass();

$inputObject->uniqueId = "351752925563xxx"; // CDN Domain mapping unique ID
$inputObject->path = "/path/to/protect/"; // Path you want to protect

// CDN Token authentication configurations
$inputObject->tokenKey = "abc123"; // Primary encryption key
$inputObject->transitionKey = "def987"; // Transition encryption key (optional)
$inputObject->name = "__token__"; // Token name (optional)

$tokenAuth = $client->createTokenAuth($inputObject);
print_r($tokenAuth);
print_r("n");