vania-janet/multiturn-rag-retrieval-data huggingface dataset:
(https://cloud.ibm.com/docs-content/v1/content/50eddb8fd81f33092880335ff107a78ff5cd0f65/watson-knowledge-studio/images/rule-dict-map2.png)







 Results 

For documents that are associated with the rule editor, any references to terms in the dictionary are annotated as DictMonth class mentions. You will see proof that these references have been annotated in the next lesson.







 Lesson 5: Finding class annotations in documents 

In this lesson, you will learn how to find class annotations in rule editor documents.



 Procedure 



1. Select Rule-based Model > Rules.
2. From the Class panel, find the DictMonth class that you defined earlier, and click the Search annotations in documents icon that's next to it.

The Find Annotations page is displayed and shows all the documents that contain text references to months.
3. Click the Technology - computerworld.com document to view the full document. Notice that the text February is highlighted, which means it was annotated as a mention of the DictMonth class.









 Lesson 6: Defining a regular expression 

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



 About this task 

You will define a regular expression that can find year patterns like 2009.

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





 Procedure 



1. From the Rules page, click the Add a class icon ![The "Add a class" icon](images/wks_tut_dict_add.jpg "The "Add a class" icon") next to Class from the right side panel.
2. Enter RegExpYear as the class name, and click Add.
3. Click the Regex tab, and then click the Create a regular expression icon next to the Regular Expressions heading.
4. Click Add Entry.
5.
Click Add to save the regular expression entry.
8. Enter MyYearExp as the regular expression name, and then, from the Class menu, select the RegExpYear class that you defined earlier.
9. Click Save.

After you save the regular expression, it is automatically applied to the sample documents. Any text strings that follow the pattern that you defined in the regular expression are annotated as mentions of the RegExpYear class.
10. To check whether the expression you defined is capturing time occurrences correctly, you can search for mentions. Click the Search annotations in documents icon next to the RegExpYear class in the Class panel.

![Shows the hovering over the magnifying glass icon next to the "RegExpYear" class in the Class panel of the Rules page.](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/148d3bd95f946aa1bb53ea1540475f522e6b61c9/watson-knowledge-studio-data/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.
Download and install kubectl. For Red Hat OpenShift on IBM Cloud 3.11, release v1.11 of kubectl is required.

Download the appropriate version.

curl -LO https://dl.k8s.io/release/v1.11.10/bin/linux/amd64/kubectl

Set the executable attribute.

chmod +x ./kubectl

Move it to the local executables directory.

mv kubectl /usr/local/bin
4. Download a script from [The Kubernetes Package Manager](https://github.com/kubernetes/helm) and execute it with the latest release of helm for your SAP Data Hub (SDH) release. The helm version is v2.11.0 for SAP Data Hub 2.4, 2.5, 2.6 and 2.7.

curl --silent https://raw.githubusercontent.com/kubernetes/helm/master/scripts/get | 
DESIRED_VERSION=v2.11.0 bash
5. Download and install docker through the standard Red Hat repositories.

Enable the appropriate Red Hat repositories.

subscription-manager repos --enable=rhel-7-server-rpms 
--enable=rhel-7-server-extras-rpms 
--enable=rhel-7-server-optional-rpms

Install docker and some dependent packages.

yum install -y docker device-mapper-libs device-mapper-event-libs
 Start the docker process.
 {: pre}
systemctl enable --now docker.service
6. Verify the installation of the IBM Cloud CLI.

ibmcloud dev -v

Example output:

ibmcloud dev version 2.4.0
 Verify kubectl.
 {: pre}
kubectl version

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







 Examples 

This command kills all of the external connections to a deployment named postgresq-preproduction.

ibmcloud cdb deployment-kill-connections postgresq-preproduction









 Users 

Create, delete, or change the password for users on your deployment.



 ibmcloud cdb deployment-user-create 

Short version - user-create

Create a user on the deployment database.

ibmcloud cdb deployment-user-create <deployment name or CRN> <newusername> <newpassword> [--nowait] [--json]

The newusername needs to be a correctly formatted username for use on the deployment's database. The newpassword needs to comply with the database's password rules and must be at least 10 characters long.



 Command options 



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







 Examples 

Create a database user called "fred" with a password of "X1234Y5678" on the "MyPSQL" deployment.

ibmcloud cdb deployment-user-create MyPSQL fred X1234Y5678







 ibmcloud cdb deployment-user-delete 

Short version - user-delete

Removes an existing user from the specified database deployment.

ibmcloud cdb deployment-user-delete <deployment name or CRN> <username> [--nowait] [--json]



 Command options 



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







 Examples 

Remove the database user called "fred" from the "MyPSQL" deployment
From there you can search for and select the appropriate Redist (redistributable) client bundle for your operating system platform. This will include the sample applications and runmqsc.
* Once downloaded, unpack the bundle into a location of your choosing.
* Make a note of the full path to the bin directory, the location of which will depend upon where you chose to unpack the bundle. This path will be referenced as <PATH_TO_BIN_DIR> for the rest of this task.
* Make a note of the full path to the directory containing the sample applications. This path will be referenced as <PATH_TO_SAMPLE_BIN_DIR> for the rest of this task.



* For Windows, this will be the bin directory unpacked in the previous step, the location of which will depend upon where you chose to unpack the bundle.
* For Linux, this will be the samp/bin directory unpacked in the previous step, the location of which will depend upon where you chose to unpack the bundle.











 Gather required connection details 



1. Log in to the IBM Cloud console.
2. Click on the 'hamburger menu'.
3. Click Dashboard.



* Ensure that RESOURCE GROUP is set to All Resources.



4. Locate and click on your IBM MQ service instance, found under the 'Services' heading.
5. From the list of your queue managers, click on the one you want to administer.
6. Make note of the Queue manager name, Hostname and Port values for use in the next steps.
7. If you already know your MQ Username and IBM Cloud API Key, you can skip to the [next section](https://cloud.ibm.com/docs/mqcloud?topic=mqcloud-mqoc_admin_mqcliexpconnect_mqoc_admin_mqcliexp) of this task. Otherwise, Click the Administration tab.

!
For more information, see [Point in Time Recovery](https://cloud.ibm.com/docs/databases-for-postgresql?topic=databases-for-postgresql-pitr).

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.
* api-version value API Version used for request.







 Examples 

ibmcloud cdb enterprisedb earliest-pitr-timestamp enterprisedb-preproduction









 MongoDB Enterprise 

Perform tasks specific to MongoDB Enterprise deployments.



 ibmcloud cdb mongodbee earliest-pitr-timestamp 

Short version - ept

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

ibmcloud cdb mongodb-enterprise 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.
* api-version value API Version used for request.







 Examples 

ibmcloud cdb mongodb earliest-pitr-timestamp (NAME|ID)
Why doesn't the Kubernetes dashboard display utilization graphs? 

  What’s happening 

When you access the Kubernetes dashboard, utilization graphs don't display.

  Why it’s happening 

Sometimes after a cluster update or worker node reboot, the kube-dashboard pod does not update.

  How to fix it 

Delete the kube-dashboard pod to force a restart. The pod is re-created with RBAC policies to access heapster for utilization information.

 {: pre}
kubectl delete pod -n kube-system $(kubectl get pod -n kube-system --selector=k8s-app=kubernetes-dashboard -o jsonpath='{.items..metadata.name}')
The first column describes the task that the customer or IBM might be responsibility 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 

 Accessing projects IBM provides the ability to control user access to projects. Use Identity and Access Management (IAM) to [assign users access to projects](https://cloud.ibm.com/docs/secure-enterprise?topic=secure-enterprise-access-project). 
 Authorize a project to deploy a configuration IBM provides the ability to authorize a project to deploy a configuration. Choose an authentication method to authorize a project to deploy in an account. Use an API key or an existing secret to [authorize a project to deploy an architecture](https://cloud.ibm.com/docs/secure-enterprise?topic=secure-enterprise-authorize-project) in an account. 







 Security and regulation compliance 

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



Table 4. Responsibilites for security and regulation compliance
The first column describes the task that the customer or IBM might be responsibility 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 

 Meet security and compliance objectives Provide a secure Projects service that complies with key standards. For more information about data security, see [How do I know that my data is safe?](https://cloud.ibm.com/docs/overview/terms-of-use?topic=overview-security). Secure your workloads and data. Integrate tools into your toolchains that satisfy your security and compliance requirements. To learn more about securing your cloud apps, see [Security to safeguard and monitor your cloud apps](https://www.ibm.com/cloud/architecture/architecture/practices/securing-cloud-native-apps-risks-mitigation/).
* --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.



 ibmcloud cdb postgresql earliest-pitr-timestamp 

Short version - ept

Returns the earliest available time for point-in-time-recovery in ISO8601 UTC format. For more information, 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 postgresql 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 postgresql earliest-pitr-timestamp postgresql-preproduction







 ibmcloud cdb postgresql replication-slot-create 

Short version - rsc

Creates a new PostgreSQL replication slot. For more information, see the [Wal2json](https://cloud.ibm.com/docs/services/databases-for-postgresql?topic=databases-for-postgresql-wal2json) documentation for more information.

ibmcloud cdb postgresql replication-slot-create <deployment name or CRN> <databasename> <slotname> <plugintype> [--json] [--nowait]
Annotations 

IBM Cloud® Functions actions, triggers, rules, and packages (collectively referred to as entities) can include annotations.

Annotations are attached to entities like parameters. Annotations consist of a key that defines a name and value that defines the value. Annotations are most commonly used to document actions and packages. Packages in the Cloud Functions catalog carry annotations. These annotations include descriptions of the functionality that is offered by its actions, parameters to use at package binding time, invoke-time parameters, or whether a parameter is a secret. Annotations are invented as needed, for example, to allow for UI integration.

You can document an entity from the CLI by using the --annotation or -a flag.



 Action annotations 



Action annotations.

 Annotation Description 

 description A description of the action. 
 parameters An array that describes actions that are required to execute the action. 
 sampleInput An example that shows the input schema with typical values. 
 sampleOutput An example that shows the output schema, usually for the sampleInput. 



The following code is an example set of annotations for an echo action, which returns its input arguments unmodified. This action is useful for logging input parameters, for example, as part of a sequence or rule.

ibmcloud fn action create echo echo.js -a description 'An action which returns its input. Useful for logging input to enable debug/replay.' -a parameters '[{ "required":false, "description": "Any JSON entity" }]' -a sampleInput '{ "msg": "Five fuzzy felines"}' -a sampleOutput '{ "msg": "Five fuzzy felines"}'





 Web action annotations 

The following web action annotations must be explicitly set to true to enable API interactivity.



Annotations specific to web actions.

 Annotation Description 

 web-export When applied to an action, the action becomes a [web action](https://cloud.ibm.com/docs/openwhisk?topic=openwhisk-actions_web).
Customizing ALB routing 

Modify the default settings for ALBs that run the Kubernetes Ingress image.

Sometimes, you can customize routing for Ingress by adding [Kubernetes NGINX annotations](https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/) (nginx.ingress.kubernetes.io/<annotation>). Kubernetes NGINX annotations are always applied to all service paths in the resource, and you can't specify service names within the annotations. Custom IBM Cloud Kubernetes Service annotations (ingress.bluemix.net/<annotation>) are not supported.

Kubernetes Ingress Controllers (ALBs) on clusters created on or after 31 January 2022 do not process Ingress resources that have snippet annotations (for example, nginx.ingress.kubernetes.io/configuration-snippet) by default as all new clusters are deployed with allow-snippet-annotations: "false" configuration in the ALB's ConfigMap. If you add any configuration snippets recommended here, you need to edit the ALB's ConfigMap (kube-system/ibm-k8s-controller-config) and change allow-snippet-annotations: "false" to allow-snippet-annotations: "true".



 Routing incoming requests with a private ALB 

To route incoming requests to your apps with a private ALB, specify the private-iks-k8s-nginx class annotation in the [Ingress resource](https://cloud.ibm.com/docs/containers?topic=containers-managed-ingress-setup). Private ALBs are configured to use resources with this class.

kubernetes.io/ingress.class: "private-iks-k8s-nginx"





 Authenticating apps with App ID
* Variables from the pipeline UI (get_env)



Zoom

![Edit property](https://cloud.ibm.com/docs-content/v1/content/5eb88a2575e30e316dbb83829c7f4c8b1ddbc67c/devsecops/images/target-environment.png)

Figure 1. Edit property



* [Pipeline trigger webhook](https://cloud.ibm.com/docs/devsecops?topic=devsecops-cd-devsecops-webhook-payloads)



For more information about how to access these variables, see [Custom scripts](https://cloud.ibm.com/docs/devsecops?topic=devsecops-custom-scripts).





 Acceptance test 

You can run a set of automated tests to validate that the deployment was successful and is working as expected. For traceability purposes, make sure that the test log contains a reference to the code level or image that is being tested.





 Change request close 

The details for the deployment are uploaded to the closing summary change task and then the task closes the change request. The close_category is added to the close change request task, with the following values:



* Successful
* Successful with issues (if the summary has issues)







 Inventory conclude 

For more information about inventory conclude, see [Inventory](https://cloud.ibm.com/docs/devsecops?topic=devsecops-cd-devsecops-inventory).
After you generate the BOM file, use the ibmcloud cra cve command to list any vulnerabilities. For more information about running the ibmcloud cra cve command, see [Vulnerability scan](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-cd-configure-cra-reposvulnerability-command).

Make sure that the run-cra task does not contain any errors. If the task contains errors, check whether your pipeline uses the current version of DevSecOps. If the issue is not resolved by checking the version of DevSecOps, the following examples provide some common errors and proposed solutions.

FAILED
Error executing docker pull cmd: [docker pull us.icr.io/opentoolchain/ibmnode:14ubisecure]

You can verify that you have access to the private registry. If you do not have access, you can use the cra-custom-script-path parameter and specify the path to a custom script that runs before Code Risk Analyzer to authenticate to the private registry.

FAILED
Error executing docker build cmd for stage-0: exit status 1

If your Dockerfile requires ARGS, the docker build command for the build stages fails to build because of the missing ARGS. The cra-custom-script-path is required to set up the ARGS as environment variables. For more information about setting up the custom script, see [Example custom scripts for DevSecOps](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-cd-configure-cra-reposdevsecops-custom-script-examples).

FAILED
Error executing docker build cmd for stage-0: exit status 1
...
COPY file-to-copy.js file-to-copy.js:
------
failed to compute cache key: "/file-to-copy.js" not found: not found
After you generate the BOM file, use the ibmcloud cra cve command to list any vulnerabilities. For more information about running the ibmcloud cra cve command, see [Vulnerability scan](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-cra-cli-pluginvulnerability-command).

Make sure that the run-cra task does not contain any errors. If the task contains errors, check whether your pipeline uses the current version of DevSecOps. If the issue is not resolved by checking the version of DevSecOps, the following examples provide some common errors and proposed solutions.

FAILED
Error executing docker pull cmd: [docker pull us.icr.io/opentoolchain/ibmnode:14ubisecure]

You can verify that you have access to the private registry. If you do not have access, you can use the cra-custom-script-path parameter and specify the path to a custom script that runs before Code Risk Analyzer to authenticate to the private registry.

FAILED
Error executing docker build cmd for stage-0: exit status 1

If your Dockerfile requires ARGS, the docker build command for the build stages fails to build because of the missing ARGS. The cra-custom-script-path is required to set up the ARGS as environment variables. For more information about setting up the custom script, see [Example custom scripts for DevSecOps](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-cra-cli-plugindevsecops-custom-script-examples).

FAILED
Error executing docker build cmd for stage-0: exit status 1
...
COPY file-to-copy.js file-to-copy.js:
------
failed to compute cache key: "/file-to-copy.js" not found: not found
For more information, 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 postgresql 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 postgresql earliest-pitr-timestamp postgresql-preproduction







 ibmcloud cdb postgresql replication-slot-create 

Short version - rsc

Creates a new PostgreSQL replication slot. For more information, see the [Wal2json](https://cloud.ibm.com/docs/services/databases-for-postgresql?topic=databases-for-postgresql-wal2json) documentation for more information.

ibmcloud cdb postgresql replication-slot-create <deployment name or CRN> <databasename> <slotname> <plugintype> [--json] [--nowait]

The plug-in type is required to be "wal2json".



 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 

Create a replication slot on a deployment named "MyPostgres", database named "testdb", and slot named "slot1".

ibmcloud cdb postgresql replication-slot-create MyPostgres testdb slot1 wal2json







 ibmcloud cdb postgresql replication-slot-delete 

Short version - rsd

Deletes the specified PostgreSQL replication slot.