Skip to main content

User guide

This guide explains how to use agent building and visual flow skill orchestration in Tongyi Xiaomi Conversational Agent.

1. Activate the product

  • Path: Alibaba Cloud Bailian - Application Square - Customer Service Conversational Agent.
  • Go to the console of the Customer Service Conversational Agent application and click Enable for Free in the upper-right corner.
  • On the activation page of the Customer Service Conversational Agent, activate the service. After activation, you are billed based on your actual call volume, that is, bills are generated daily and deducted from your Alibaba Cloud account balance.

2.Agent building

2.1 Create an application

Click Create Application, enter an application name and description, and a basic agent is created.
  • Application Name: Enter a name for the agent based on your business requirements;
  • Application Description: Add a description for the agent based on your business use case.
The console after creation:
image

2.2 Configuration

1. Persona

  • Definition: In the bot space, each bot can have a persona. You can debug the bot through prompts, and define the bot's role, workflow, skills, constraints, and other requirements in the persona.
  • Select Template: In the Select Template window, you can insert a general template and enter the corresponding persona constraints as required by the template.
  • Optimize: After you finish editing the persona, you can click Optimize, and the model will optimize the persona content based on your input.

2. Bot greeting

  • Definition: The opening message the bot sends when you open the bot conversation window.

3. Knowledge base (flow skills and FAQ)

4. More settings

  • Model: The built-in Lingque conversational large model is used. You can change the temperature and the number of context turns to adjust the model.
  • General knowledge:
  • Response Language: The language in which the bot replies.
    • Same as user's language: The bot replies in the same language as your query;
    • Chinese only: The bot always replies in Chinese, regardless of the language you use;
    • English only: The bot always replies in English, regardless of the language you use.
  • Security:
    • Security Interception: When the system detects that the input or output content involves "answer sensitive words", it automatically replies with the "sensitive word response";
    • Preset security response: When a user's question contains "user sensitive words" or the model's generated reply contains sensitive content, the bot automatically replies with the preset sensitive response. The default preset security response is: "I cannot answer this question. Please try asking something else."
  • Model generation failure: The fallback response the bot sends when a system error occurs or the service times out.

2.3 Call volume

On the call volume page, you can view the token consumption.

2.4 API

The debugging information of the conversational agent is synced to the API. You can copy the code to make calls.

3.Visual flow skill orchestration

3.1 Create a flow

  1. Click Knowledge Base Management > Flow or + Bind Flow to open the flow list window.
    image
  2. Click New Flow to open the flow creation window.
    image
  3. Fill in the flow Name and Description as required, then click Confirm to create a blank flow.
    image
    image
  4. Find the new flow and click Edit to enter the flow orchestration page.
    image.gif
  5. Create a starting branch to enter the flow canvas. After the start node, add a "Branch" and set the conditions that trigger the subsequent branches after the flow is entered. For detailed steps, watch the video below:
    image.png
  6. Select and arrange nodes based on the conversation logic to build the dialogue flow.
After the flow orchestration is complete, click Test. The bot automatically checks the flow for completeness. If there are errors, optimize the flow based on the error prompts. For details, see the video below:
image.gif

3.2 Flow debugging

  1. Configure the environment before debugging.
  • Service Simulation: API plugins in the flow directly return mock values. This is suitable for cases where the API is not yet ready.
  • Passthrough Parameters: External parameters passed to the bot along with the user's question. For example, when a phone call is connected, you can pass the caller's number to the bot as a passthrough parameter, which can then be used in subsequent API plugin calls.
image.png
  1. Conversation debugging Have a conversation directly. After the bot replies, you can click Generation Complete to view the bot's output. For parameter collection, you can view the specific parameters collected by the bot.
    image.gif

4. Configure FAQ

4.1 Create FAQ knowledge

  1. Click Knowledge Base Management > FAQ or + Bind FAQ to open the FAQ list window.
    image
    image
  2. Click Create FAQ Base to open the creation window and enter a name for the FAQ base.
    image
  3. Find the new FAQ base and click Edit to enter the page for adding FAQ knowledge.
    image
    image
  4. Click Add FAQ or Import FAQ to add the corresponding frequently asked questions to the FAQ base. Fill in the Question, Answer Type, Answer, Effective Time, and Similar Questions as required, then click Submit.
    image
    image
    After successfully adding an entry:
    image

4.2 Bind the FAQ knowledge base and test the results

  1. Click Bind to bind the corresponding knowledge base to the bot.
    image
After a successful binding:
image
  1. Test the results in the conversation test window on the left, as shown below:
    image