vania-janet/multiturn-rag-retrieval-data huggingface dataset:
The following example shows how to access the devops.cloud.ibm.com/build-number annotation. To provide that annotation as an environment variable, replace it with one of the run annotations from Table 1. PipelineRun annotations.

apiVersion: tekton.dev/v1beta1
kind: Task
metadata:
name: simple-task
spec:
steps:
- name: simple-step
image: ubuntu
env:
- name: BUILD_NUMBER
valueFrom:
fieldRef:
fieldPath: metadata.annotations['devops.cloud.ibm.com/build-number']
command: ["bash", "-c"]
args:
- echo $BUILD_NUMBER;
echo "COMPLETED"

Show more







 PipelineRun ConfigMap and Secret 

The Continuous Delivery Tekton PipelineRun resource creates a specific ConfigMap and Secret for environment properties. Secure properties are available in the secure-properties Kubernetes Secret, including any Tool integration properties for which the selected field contains a secure value. Nonsecure properties are available in the environment-properties Kubernetes ConfigMap. The keys are the name of the field that is provided in the pipeline authoring user interface.

When you access a ConfigMap or Secret, make sure that you locate the correct object name and references so that your pipeline can successfully complete.



 Accessing individual values 

You can access individual key-values within a Task. The following code snippet uses the sample apikey property name (with secure properties) and the environment property name (with text properties). These property names are set in the delivery pipeline Properties page.

apiVersion: tekton.dev/v1beta1
kind: Task
metadata:
name: cm-echo-props
spec:
steps:
- name: cm-show-props
image: ubuntu
env:
- name: SECURE_VALUE
valueFrom:
secretKeyRef:
name: secure-properties
key: apikey
If you are migrating workspaces across different instances, consider making a list of users and their roles for the instance that you are backing up. Someone with the Admin role can print the list from the User Account Management page. After the workspaces are recreated on the new instance, someone with the Admin role must add the users and assign their roles.

For more information about roles, see [User roles in Knowledge Studio](https://cloud.ibm.com/docs/watson-knowledge-studio-data?topic=watson-knowledge-studio-data-roles).
6. Make note of workspace information.

While you still have access to the current instance, for each workspace that you want to migrate, make a note of the following information:



* Workspace name
* Workspace description
* Workspace owner
* Language
* If you have any incomplete annotation tasks, because they can't be backed up or migrated, note the human annotators who are assigned to incomplete tasks in the workspace. Also note the annotation task details, such as the task name, due date, and which document sets are assigned to which users.









 Downloading artifacts 

For each workspace that you want to migrate, download the following artifacts. Store them in a secure location from which you will be able to upload them into the new instance later.



* Type system
* Dictionaries

Note:



* Only editable dictionaries will be downloaded. You cannot download read-only dictionaries.
* For dictionaries, entity type mappings are not migrated. After you restore these artifacts, you will need to map the dictionaries to entity types, as necessary.



* Documents

See [Uploading resources from another workspace](https://cloud.ibm.com/docs/watson-knowledge-studio-data?topic=watson-knowledge-studio-data-exportimport) for information about how to download these artifacts so that they can be imported into a new workspace.







 Recreating workspaces 

NOTE: In this step, the only setting that must match the setting of the original (downloaded) workspace is the language.
[Entity search return](https://cloud.ibm.com/docs-content/v1/content/a2b18c153837bce00a5b4de496e4b4ca64bbf56e/assistant-data/images/entities-search-results.png)





 Exporting entities 

You can export a number of entities to a CSV file, so you can then import and reuse them for another Watson Assistant application.



* Pattern information is included in the CSV export. Any string wrapped with / will be considered a pattern (as opposed to a synonym).
* Annotations associated with contexual entities are not exported. You must export the entire dialog skill to capture both the entity value and any associated annotations.





1. Go to the Entities page



* To export all entities, meaning the entities that are listed on this and any additional pages, do not select any individual entities. Instead, click the Export icon. ![Export option](https://cloud.ibm.com/docs-content/v1/content/a2b18c153837bce00a5b4de496e4b4ca64bbf56e/assistant-data/images/export-c10.png)
* To export the entities that are listed on the current page only, select the checkbox in the header. This action selects all of the entities on the current page. Click Export.
* To export one or more specific entities, select the entities that you want to export, and then click Export.



2. Specify the name and location in which to store the CSV file that is generated.







 Importing entities 

If you have a large number of entities, you might find it easier to import them from a comma-separated value (CSV) file than to define them one by one.

Entity annotations are not included in the import of an entity CSV file. You must import the entire dialog skill to retain the associated annotations for a contextual entity in that skill. If you export and import entities only, then any contextual entities that you exported are treated as dictionary-based entities after you import them.
If you fail to withdraw the model from deployment, the result is an orphaned deployed model. Orphaned deployed models continue to generate charges on your monthly bills.
4. Manage read-only dictionary information.

Read-only dictionaries cannot be migrated. Find out where the read-only dictionary was imported from, so you can re-upload it to your workspace after the migration.
5. Make a list of current user roles.

This step is optional. It is typically performed when a workspace is migrated across instances and the new workspace must be identical to the original workspace. If you want to migrate only the workspace data into a new workspace, you can skip this step.

If you are migrating workspaces across different instances, consider making a list of users and their roles for the instance that you are backing up. Someone with the Admin role can print the list from the User Account Management page. After the workspaces are re-created on the new instance, someone with the Admin role must add the users and assign their roles.

For more information about roles, see [User roles in Knowledge Studio](https://cloud.ibm.com/docs/watson-knowledge-studio?topic=watson-knowledge-studio-roles).
6. Make note of workspace information.

While you still have access to the current instance, for each workspace that you want to migrate, make a note of the following information:



* Workspace name
* Workspace description
* Workspace owner
* Language
* If you have any incomplete annotation tasks, because they can't be backed up or migrated, note the human annotators who are assigned to incomplete tasks in the workspace. Also note the annotation task details, such as the task name, due date, and which document sets are assigned to which users.









 Downloading artifacts 

For each workspace that you want to migrate, download the following artifacts. Store them in a secure location from which you will be able to upload them into the new instance later.



* Type system
* Dictionaries

Note:



* Only editable dictionaries will be downloaded. You cannot download read-only dictionaries.
Versioning and updating apps 

You put in a lot of effort preparing for the next version of your app. You can use IBM Cloud and Kubernetes update tools to roll out different versions of your app.



 How can I organize my deployments to make them easier to update and manage? 

Now that you have a good idea of what to include in your deployment, you might wonder how are you going to manage all these different YAML files? Not to mention the objects that they create in your Kubernetes environment!

The following tips can help you organize your deployment YAML files.



* Use a version-control system, such as Git.
* Group closely related Kubernetes objects within a single YAML file. For example, if you are creating a deployment, you might also add the service file to the YAML. Separate objects with --- such as in the following example.

apiVersion: apps/v1
kind: Deployment
metadata:
...
---
apiVersion: v1
kind: Service
metadata:
...
* You can use the oc apply -f command to apply to an entire directory, not just a single file.
* Try out the [kustomize project](https://cloud.ibm.com/docs/openshift?topic=openshift-openshift_appskustomize) that you can use to help write, customize, and reuse your Kubernetes resource YAML configurations.



Within the YAML file, you can use labels or annotations as metadata to manage your deployments.

Labels
: [Labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/) are key:value pairs that can be attached to Kubernetes objects such as pods and deployments. They can be whatever you want, and are useful for selecting objects based on the label information. Labels provide the foundation for grouping objects. See the following examples for ideas for labels.



* app: nginx
* version: v1
* env: dev



Annotations
26 July 2017 

Updated ASP.NET Core buildpack v1.0.22-20170724-0813
: This release includes the following updates:



* Add support for .NET Core runtime 2.0.0 Preview 2
* Add support for .NET Core SDK 1.1.0-preview1-005051
* Add support for .NET Core SDK 2.0.0-preview2-006497
* Update Node version to 6.11.1
* Always make self-contained apps executable







 14 July 2017 

Updated Liberty buildpack v3.11-20170710-0312
: The default Liberty runtime version 17.0.0.2 was updated to include the IFPI83713 interim fix.



* The monthly Liberty runtime version was updated to the [2017.7.0.0](https://developer.ibm.com/wasdev/blog/2017/07/07/beta-websphere-liberty-tools-july-2017/) release.
* The buildpack also contains updated IBM JREs: version 8 SR4 FP7 and version 7.1 SR4 FP5.
* The default Cloudant Library is now the official [java-cloudant](https://github.com/cloudant/java-cloudant), the [Ektorp library](https://github.com/helun/Ektorp) is still available as an option, for details about this change see the [blog post](https://www.ibm.com/blogs/bluemix/2017/05/default-library-change-cloudant-auto-wiring-liberty-buildpack/).
* The default heap size ratio is now 50% when your app has less than 512mb of memory, if it has more than 512mb it will still be 75%.
* A new staging task log is now generated, which allows for easier debugging of staging errors.
You must assume that these factors might combine to produce considerable inaccuracy in your estimate.

See the example of extracting the changes_done field by using jq:

curl ... | jq '.[] | select(.type=="search_indexer") | .changes_done'





 Monitoring replication 

To find all replication tasks, pipe the curl output to jq, and filter the documents in the array by their type field.

Make it easier to select the information about a replication process from the list of active tasks by following these steps:



1. Start the replication process by creating a document in the _replicator database.
2. Set its _id field to a known value.



See an example of finding all replication tasks, by filtering for the replication type:

curl -s "$SERVICE_URL/_active_tasks" | jq '.[] | select(.type=="replication")'

See an example of finding a specific replication task, by filtering for a known document identity:

curl ... | jq '.[] | select(.doc_id=="ID")'

See an example of finding a specific replication task, by filtering for a known replication_id:

curl ... | jq '.[] | select(.replication_id=="ID")'

See an example result after you search for a replication task:

{
"started_on": 1371094220,
"source_seq": "62960-sakdjflksdfjsdlkafjalskdfjlsakfjlasdkjksald",
"source": "",
"revisions_checked": 12,
"continuous": true,
"doc_id": null,
"doc_write_failures": 0,
"docs_read": 12,
"target": "",
"type": "replication",
"updated_on": 1371118477,
"user": "username",
(images/rule-regex-add5.png "Shows the cursor hovering over the magnifying glass icon next to the "RegExpYear" class in the Class panel of the Rules page.")

The Find Annotations page is displayed. Occurrences of year mentions are highlighted in the sample documents in which they occur.

![Shows eight annotations of years highlighted in excerpts from the sample documents.](https://cloud.ibm.com/docs-content/v1/content/50eddb8fd81f33092880335ff107a78ff5cd0f65/watson-knowledge-studio/images/rule-regex-add6.png)









 Lesson 7: Defining a rule 

In this lesson, you will learn how to define a rule.



 About this task 

You already defined a dictionary-based class for annotating month mentions. You also defined a regular expression that finds numeric values which represent a year. Now, you will define a rule that captures the sequence of a month followed by a number, a comma, and then a year. You will define a rule for date expressions like September 21, 2016.

For more information about defining rules, see [Defining a rule](https://cloud.ibm.com/docs/watson-knowledge-studio?topic=watson-knowledge-studio-wks_rule_creation).





 Procedure 



1. Select Rule-based Model > Rules, and open the Technology - computerworld.com document.
2. Select the text February 3, 2009 in the document. Make sure you select the comma, too.

![Shows the text "February 3, 2009" selected in the document.](images/rule-add1.png "Shows the text "February 3, 2009" selected in the document.")
3. Click the Add a rule icon.

The rule editor shows a depiction of the rule pattern that you identified.

The text February 3, 2009 is visible. A solid line that connects the cells in the depiction identifies which cells are currently part of the pattern.
If the task is running, the command waits for the task to complete, reporting status changes as it regularly polls.

ibmcloud cdb task-show <CRN> [--nowait] [--json]



 Command options 



* --nowait or -n Do not wait for the task to complete. Display the user password change task details and exit.
* --json or -j Display results as JSON.







 Examples 

Show details of a particular backup task.

ibmcloud cdb task-show crn:v1:bluemix:public:databases-for-postgresql:us-south:a/54e8ffe85dcedf470db5b5ee6ac4a8d8:1b8f53db-fc2d-4e24-8470-f82b15c71717:task:0faea465-de5a-4f14-a5ff-b402fefbd652









 Elasticsearch 

Perform tasks specific to Elasticsearch deployments.



 ibmcloud cdb elasticsearch file-sync 

Short version - fs

Synchronizes files from the ibm_file_sync index to disk. For more information, see the [Uploading Files to Elasticsearch](https://cloud.ibm.com/docs/services/databases-for-elasticsearch?topic=databases-for-elasticsearch-uploading-files) documentation for more information.

ibmcloud cdb elasticsearch file-sync <deployment name or CRN> [--json] [--nowait]



 Command options 



* --nowait or -n Do not wait for the group setting task to complete. Display the scaling task's details and exit.
* --json or -j Return the results as JSON.







 Examples 

Sync a file to disk on a deployment named "MyElasticsearch".

ibmcloud cdb elasticsearch file-sync MyElasticsearch









 PostgreSQL 

Perform tasks specific to PostgreSQL deployments.
Managing the cluster 



 Preparing your local machine 

Ensure that you have the following prerequisites installed and working correctly on your local machine before performing any cluster-management tasks.



1. Install and configure the following command-line tools:



* [cloudctl](https://www.ibm.com/support/knowledgecenter/SSBS6K_3.1.2/manage_cluster/install_cli.html)
* [kubectl](https://docs-icpdata.mybluemix.net/docs/content/SSQNUZ_current/com.ibm.icpdata.doc/zen/install/kubectl-access.html)
* [helm](https://helm.sh)



2. Start helm:



 {: pre}
helm init --client-only
. Verify that the tools are installed correctly by running the following test commands.

- Test the IBM Cloud Private CLI (cloudctl):

 {: pre}
cloudctl login -a https://{hostname}:8443 -u {admin_user_id} -p {admin_password}

If you are using a load balancer, specify the hostname of the load balancer instead of the hostname of the master node.
{: note}

- Test Kubernetes (kubectl):

 {: pre}
kubectl get namespaces

If you cannot run the kubectl command, see [Enabling access to the Kubernetes command-line interface](https://www.ibm.com/support/knowledgecenter/SSQNUZ_2.1.0/com.ibm.icpdata.doc/zen/install/kubectl-access.html){: external}.
{: note}

- Test Helm (helm):

 {: pre}
helm version --tls

Show more





 Managing user access 

After you provision an instance, you can share the URL for the product user interface with other users.
If the task is running, the command waits for the task to complete, reporting status changes as it regularly polls.

ibmcloud cdb task-show <CRN> [--nowait] [--json]



 Command options 



* --nowait or -n Do not wait for the task to complete. Display the user password change task details and exit.
* --json or -j Display results as JSON.







 Examples 

Show details of a particular backup task.

ibmcloud cdb task-show crn:v1:bluemix:public:databases-for-postgresql:us-south:a/54e8ffe85dcedf470db5b5ee6ac4a8d8:1b8f53db-fc2d-4e24-8470-f82b15c71717:task:0faea465-de5a-4f14-a5ff-b402fefbd652









 Elasticsearch 

Perform tasks specific to Elasticsearch deployments.



 ibmcloud cdb elasticsearch file-sync 

Short version - fs

Synchronizes files from the ibm_file_sync index to disk. For more information, see the [Uploading Files to Elasticsearch](https://cloud.ibm.com/docs/services/databases-for-elasticsearch?topic=databases-for-elasticsearch-uploading-files) documentation for more information.

ibmcloud cdb elasticsearch file-sync <deployment name or CRN> [--json] [--nowait]



 Command options 



* --nowait or -n Do not wait for the group setting task to complete. Display the scaling task's details and exit.
* --json or -j Return the results as JSON.







 Examples 

Sync a file to disk on a deployment named "MyElasticsearch".

ibmcloud cdb elasticsearch file-sync MyElasticsearch







 ibmcloud cdb elasticsearch user-list 

Short version - ul

Lists all users from the database internal credential store.
For descriptions of the roles that are available, see [User roles in Knowledge Studio](https://cloud.ibm.com/docs/watson-knowledge-studio-data?topic=watson-knowledge-studio-data-roles).

Important: You must create a workspace, associate a user with a document set, and assign an annotation task to a user before a user with the human annotator role can see any workspaces listed in the Knowledge Studio application. Set up the workspace as soon as possible after users register so they see your workspace when they first access the application. You might want to notify users after you set up the workspace to let them know that they can start annotating documents.
5. Optional: When you finish administering users in Knowledge Studio, exit the session by closing the web browser. The Knowledge Studio user interface does not provide an action for explicitly logging out.







 Deactivating user accounts 

Later, if you want to remove users, follow the previous steps to open the Service Details page. From the list of user IDs, find the user you want to remove and click Deactivate.

> Attention: If users are assigned documents to annotate and you deactivate their accounts, their annotations are affected. If annotations made by deactivated users were not promoted to ground truth, those annotations are deleted.



 Related tasks 

[Creating and assigning annotation sets](https://cloud.ibm.com/docs/watson-knowledge-studio-data?topic=watson-knowledge-studio-data-documents-for-annotation)
Process access policies It is the responsibility of IBM to ensure that the policies are processed. 
 Set up access policies It is your responsibility to set up access policies. For more information, see [Creating policies](https://cloud.ibm.com/docs/Registry?topic=Registry-usercreate). 
 Access to back-end resources It is the responsibility of IBM to access to back-end resources. 
 Access to namespaces It is your responsibility to set up access to namespaces. For more information, see [Automating access to IBM Cloud Container Registry](https://cloud.ibm.com/docs/Registry?topic=Registry-registry_access). 







 Security and regulation compliance 

Security and regulation compliance includes tasks such as security controls implementation and compliance certification.



Table 4. Responsibilities for security and regulation compliance
The first column describes the task that the customer or IBM might be responsible for. The second column describes IBM responsibilities for that task. The third column describes your responsibilities as the customer for that task.

 Task IBM Responsibilities Your Responsibilities 

 Secure confidential information. It is your responsibility to make sure that no confidential information is put into your images. 
 Ensure that the service instance is secure. It is the responsibility of IBM to ensure the security of the service instance. 







 Disaster recovery 

Disaster recovery includes tasks such as providing dependencies on disaster recovery sites, provision disaster recovery environments, data and configuration backup, replicating data and configuration to the disaster recovery environment, and fail over on disaster events. For more information, see [High availability for Container Registry](https://cloud.ibm.com/docs/Registry?topic=Registry-ha-dr) and [Business continuity and disaster recovery for Container Registry](https://cloud.ibm.com/docs/Registry?topic=Registry-bc-dr).



Table 5. Responsibilities for disaster recovery
The first column describes the task that the customer or IBM might be responsible for. The second column describes IBM responsibilities for that task. The third column describes your responsibilities as the customer for that task.

 Task IBM Responsibilities Your Responsibilities 

 Copy your data to another region. It is your responsibility to copy the data to another region.
* --nowait or -n Do not wait for the group setting task to complete. Display the scaling task's details and exit.
* --json or -j Return the results as JSON.







 Examples 

Deletes a replication slot on a deployment named "MyPostgres" and slot named "slot1".

ibmcloud cdb postgresql replication-slot-delete MyPostgres slot1









 EnterpriseDB 

Perform tasks specific to EnterpriseDB deployments.



 ibmcloud cdb enterprisedb earliest-pitr-timestamp 

Short version - ept

Returns the earliest available time for point-in-time-recovery in ISO8601 UTC format. For more informaiton, see the [Point in Time Recovery](https://cloud.ibm.com/docs/databases-for-postgresql?topic=databases-for-postgresql-pitr) documentation for more information.

ibmcloud cdb enterprisedb earliest-pitr-timestamp <deployment name or CRN> [--json] [--nowait]



 Command options 



* --nowait or -n Do not wait for the group setting task to complete. Display the scaling task's details and exit.
* --json or -j Return the results as JSON.







 Examples 

ibmcloud cdb enterprisedb earliest-pitr-timestamp enterprisedb-preproduction