Updating the Custom Component Package of a Skill

You would have to update the component package of a skill to interface with ODA's custom component service. This service is an active connection from the skill to the host server.

Note that you will have to perform this procedure for any new skills that you add to the digital assistant in the future.

  1. Make sure you have these software:

    • Oracle Digital Assistant Bots Node.js software development kit (SDK) (bots-node-sdk), which you can get from GitHub.

    • Node.js 8.11.4, which you can get from https://nodejs.org. Install this for global access. Node Package Manager (npm) is distributed with Node.js.

  2. To test if Node.js and npm are installed, open a terminal window and type these commands:

    node –v 
    npm –v
  3. To verify your Oracle Digital Assistant Bots Node.js SDK installation, type the following command:

    bots-node-sdk -v

    The command should print the Oracle Digital Assistant Bots Node.js SDK version.

  4. Log in to your ODA instance.

  5. Click icon to open the side menu, then select Development, and then Digital Assistants.

  6. Select the digital assistant to open its page. You will see the first skill on the list selected.

  7. From the selected skill, click Go to Skill.

  8. Click Components icon.

  9. Download the package (.tgz) file, then update the environments.json file.

    1. Look for the package (.tgz) file you downloaded.

    2. Extract the contents of the file to your local drive.

    3. Extract the .tar file in the same folder that the package file is in.

      A package folder will appear.

    4. From the package folder, navigate to psft-lib, and then config.

    5. Open environments.json.

    6. Update the server, port, and node values in baseURL using the information from your PIA server.

      "baseURL": "http://<server>:<port>/PSIGW/RESTListeningConnector/<node>/PTCB_APPL_SVC.v1"

      So, if your PIA URL looks like this:

      http://server.com:8000/psp/s17cbguix/?cmd=login&languageCd=ENG&

      Then your baseURL value will look like this:

      Field Value

      <server>

      server.com

      <port>

      8000

      <node>

      S17CBGUI (this alphanumeric text should be capitalized)

      If your PIA URL uses http, then the baseURL should also use http. If it uses https, then use https.

    7. From your computer, launch the command prompt.

    8. Go to the directory where the package folder is stored, then from the command prompt enter npm pack.

      This creates a package with the updates you made and a new TGZ file is saved in the same package folder.

      In the future, if you wish to update the component package file, make sure you delete the existing .tgz file before you run the npm pack command.

  10. Upload the package (.tgz) file you updated.

    1. Go back to your browser where you have your ODA instance open.

    2. From the Components page of the digital assistant (the one you accessed from step 8), make sure you're on the page of the skill you downloaded the package file from.

    3. In Package File, click the Change package file icon, then locate the .tgz file you created to upload it to the skill.

      The upload is complete when the Status indicates Ready.

  11. Repeat steps 7 to 10 for the other skills.

    Note:

    Skip the Small Talk skill.