arrow_back

Managing Environments with Conversational Agents

Sign in Join
Get access to 700+ labs and courses

Managing Environments with Conversational Agents

Lab 1 hour 30 minutes universal_currency_alt 5 Credits show_chart Intermediate
info This lab may incorporate AI tools to support your learning.
Get access to 700+ labs and courses

SCBL095

Lab objectives

In this lab, you will explore the management of Conversational Agents environments. By the end of this lab, you will be able to:

  • Create versions of your conversational agent.
  • Create environments where your conversational agent will be published.
  • Load a saved version of your conversational agent to an environment.
  • Change which version is loaded to an environment.

Resources

The following are some resources intended to help you complete the lab components:

Setup and requirements

Setting up the lab

Before you click the Start Lab button

Read these instructions. Labs are timed and you cannot pause them. The timer, which starts when you click Start Lab, shows how long Google Cloud resources will be made available to you.

This Qwiklabs hands-on lab lets you do the lab activities yourself in a real cloud environment, not in a simulation or demo environment. It does so by giving you new, temporary credentials that you use to sign in and access Google Cloud for the duration of the lab.

What you need

To complete this lab, you need:

  • Access to a standard internet browser (Chrome browser recommended).
  • Time to complete the lab.

Note: If you already have your own personal Google Cloud account or project, do not use it for this lab.

Note: If you are using a Pixelbook, open an Incognito window to run this lab.

Task 1. Getting started with Conversational Agents

In this task, you'll get logged into Conversational Agents and create a new agent.

  1. Enable the Dialogflow API and Vertex AI Agent Builder API.

  2. In your Google Cloud Console, navigate to Agent Builder > Conversational agent.

  3. Click on Build your own when prompted to create an agent.

  4. Name your agent Flight Booker .

  5. Set the location to .

  6. Ensure timezone and default language are set appropriately. Set the Conversation Start to Flow.

  7. Click on Create. Once the agent is created, you will see the design and configuration of the Conversational agent UI.


Task 2. Importing a .blob conversational agent file

In this task, you will import a conversational agent from an earlier lab.

  1. Select View all agents from the Agent dropdown menu at the top.

  2. Click the context menu (three vertical dots) to the right of your conversational agent.

  3. Select Restore from the expanded menu options.

  4. Select the Cloud Storage radio button if not already selected.

  5. Enter gs://cloud-training/T-CECCAI-I/T-CCAICDCX-I/lab-solns/Cloudio-cx-speak-to-person.blob for URI.

  6. Click Restore.

    Refer to the Conversational Agents restore documentation as needed.

    Now you have a conversational agent that has everything completed from an earlier lab.

Note: If you'd like to retain a copy of the sample agent, download gsp929-start-agent.blob to your local hard drive.


Task 3. Creating environments

  1. In the Google Cloud Console, navigate to Conversational Agents > Environments.

  2. Click + Create to create a new environment.

  3. Enter QA for the display name.

  4. Click on Save.

    You'll see a message saying Version must be provided for start flow resource. Why do you think this is?

    Hint: We haven't yet created a published version of the Default Start Flow (or any other flow for that matter).

  5. Select Versions in the main menu.

  6. Click on Default Start Flow.

  7. Click + Create to create a version of the flow.

  8. Enter Cloudio main v1 basic chat bot for the display name.

  9. Click Save.

    You should now see the Default Start Flow in the Versions list with the number of # versions equal to 1.

  10. Select Environments to return to configuring a new environment.

  11. Click + Create.

  12. Enter QA for the display name.

  13. Choose Cloudio main v1 basic chat bot from the Version dropdown list next to the Default Start Flow.

  14. Click Save.

    You may see a message such as:

    Version 'projects/qwiklabs-gcp-03-407df58d36b0/locations/us-central1/agents/e2779218-b813-4844-a0ea-ec2ef504636d/flows/00000000-0000-0000-0000-000000000000/versions/1' is not ready to serve because its training is RUNNING. Wait for training to finish or fix the version if its training failed.

    This is caused when Conversational Agents is still capturing and training your conversational agent. Try saving again after waiting a few moments.

    You should now see your new QA environment in the list.


Task 4. Managing environments

Next, you can test out your versioned conversational agent in the environment you created.

  1. Click on Toogle Simulator in the upper right to open the simulator pane.

  2. Enter Is there a customer service rep I can talk to? in the text box.

    You should get a response from the agent saying "Please stand by while I connect you with a customer service representative."

    This is one of the ways you can run test cases in different environments.

    Next, you'll make a change to your conversational agent and save it as a new version.

  3. Navigate to Conversational Agents > Flows > Build.

  4. Click on the Speak to Person page.

  5. Click on the Entry fulfillment that says Please stand by while I connect you with a customer service representative.

  6. Change the Agent says prompt to I'll get you to a live agent right away.

  7. Click on Save.

  8. Go back to Conversational Agents > Versions.

  9. Repeat the versioning steps above to create a new version of your Default Start Flow called Cloudio main v2 basic chat bot.

  10. Repeat the steps above to create a new environment called Dev that uses the new version of your Default Start Flow.

    You should now see the number of versions incremented to 2 for the Default Start Flow in the Versions list.

Note: You may again get an error similar to the following, so just wait a few moments and try saving again. "Version 'projects/qwiklabs-gcp-00-fe6cab958249/locations/us-central1/agents/6792c492-5f79-4ccf-8f17-e757b34f38b9/flows/00000000-0000-0000-0000-000000000000/versions/2' is not ready to serve because its training is RUNNING. Wait for training to finish or fix the version if its training failed."
  1. Click on QA in your Environments section.

  2. Select your Cloudio main v2 basic chat bot from the dropdown.

  3. Click on Save.

    Now your latest version of your flow is loaded to the QA environment.

    Next you'll go back to the toggle simulator to test your new Cloudio main v2 basic chat bot version.

  4. Enter Is there a customer service rep I can talk to? in the text box.

    You should get a response from the agent saying I'll get you to a live agent right away. indicating that it was running the v2 of your agent.

Note: You could have run the test against your conversational agent in Draft. By selecting a specific environment, the test is running the version of your conversational agent loaded to the specified environment (which may be different from what you're currently working on in Conversational Agents in Draft mode). Another benefit is you can test different versions without going through the process of retraining the model (which can take some time for larger, more complex conversational agents).

That's it! Now you can manage different versions and run tests in different environments.


End your lab

When you have completed your lab, click End Lab. Qwiklabs removes the resources you’ve used and cleans the account for you.

You will be given an opportunity to rate the lab experience. Select the applicable number of stars, type a comment, and then click Submit.

The number of stars indicates the following:

  • 1 star = Very dissatisfied
  • 2 stars = Dissatisfied
  • 3 stars = Neutral
  • 4 stars = Satisfied
  • 5 stars = Very satisfied

You can close the dialog box if you don't want to provide feedback.

For feedback, suggestions, or corrections, please use the Support tab.

Copyright 2023 Google LLC All rights reserved. Google and the Google logo are trademarks of Google LLC. All other company and product names may be trademarks of the respective companies with which they are associated.

Before you begin

  1. Labs create a Google Cloud project and resources for a fixed time
  2. Labs have a time limit and no pause feature. If you end the lab, you'll have to restart from the beginning.
  3. On the top left of your screen, click Start lab to begin

This content is not currently available

We will notify you via email when it becomes available

Great!

We will contact you via email if it becomes available

One lab at a time

Confirm to end all existing labs and start this one

Use private browsing to run the lab

Use an Incognito or private browser window to run this lab. This prevents any conflicts between your personal account and the Student account, which may cause extra charges incurred to your personal account.