Sample agent applications

You can use the sample agent applications built into the console to understand how a completed agent application is built and to learn best practices for design.

Import a sample agent application to your project

To import:

  1. Open the Gemini Enterprise for CX console.
  2. Select your project.
  3. Click the drop-down button next to the New agent button.
  4. Click Try a sample agent.

After a small delay, the sample agent application will be loaded in the console.

Cymbal retail agent

This sample agent application is an assistant for a fictitious company called Cymbal Home & Garden. This assistant can help customers select products, identify plants, and manage their shopping cart.

Try having a conversation by entering input in the Preview agent simulator. You can upload images of plants, ask the agent to identify them, and add them to your shopping cart.

The following features are demonstrated:

Feature Description
Multi agent architecture The root agent (cymbal_retail_agent) handles the majority of the conversation. The sub-agents handle upselling and out of scope questions.
Instructions Structured agent-specific and global instructions are defined for each agent. These instructions explicitly describe what the agent should do and how the agent should do it. These instructions also show how other agents, tools, and variables are referenced.
Tools Python tools, a Google Search tool, and an OpenAPI tool are included. The OpenAPI tool provides an example for defining an API with 3 endpoints. The end_session system tool is used to complete a phone call (see the "Session Management" section of the root agent). Many of these tools have stubbed implementations, but a few have completed implementations.
For example, look at the greeting Python tool, which is used to control greetings. This code shows how one tool can call another tool.
Variables A custom schema variable is used to store customer profile. You can update this profile to suit your needs. A boolean variable is used to indicate whether a manager has approved a discount. A boolean variable is used to track whether images have been uploaded.
Guardrails Guardrail settings have been customized. Prompt guard is enabled with a custom outcome, a blocklist is defined with a custom outcome, a safety outcome is defined, and a rule is configured with instructions.
Callbacks Callbacks have been defined for before_model_callback, after_model_callback, and after_tool_callback.
Evaluations When you first load the agent application, many golden and scenario based evaluations are defined and start execution. You can check on the results of these evaluations once the tests have completed.