> For the complete documentation index, see [llms.txt](https://aican.gitbook.io/aican/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://aican.gitbook.io/aican/getting-started/chatbot.md).

# 聊天机器人

## 简介

聊天机器人可自动回复访客常见问题，并依照您建立的工作流程，引导访客完成咨询或转接人工客服。

首次使用时，建议先建立一个简单的机器人流程，确认运行正常后，再逐步扩充更多问答内容。

***

## 聊天机器人如何运作

聊天机器人采用**工作流**方式设置。

您只需依照实际需求，将各个节点连接成一条完整流程，当访客输入符合条件的关键字后，系统便会依照设置的流程自动回复。

一个基本流程通常包含：

<pre><code><strong>添加分类
</strong><strong> ↓
</strong><strong>新增问题
</strong><strong> ↓
</strong><strong>关键字
</strong><strong> ↓
</strong><strong>回复消息
</strong><strong> ↓
</strong><strong>按钮选择
</strong><strong> ↓
</strong><strong>转接人工客服
</strong></code></pre>

<figure><img src="/files/vuty6z0VzqOQC1M8O4oX" alt=""><figcaption></figcaption></figure>

***

## 操作说明

建议依照以下顺序完成聊天机器人设置：

1. 建立工作流
2. 建立关键字
3. 设置回复内容
4. 连接工作流程
5. 启用聊天机器人

***

{% stepper %}
{% step %}

### 步骤一：建立工作流

进入 **聊天机器人** 页面。

点击【新增流程】，建立第一个机器人工作流。

<figure><img src="/files/6FNfS9Hx4iVYfyDSud5i" alt=""><figcaption></figcaption></figure>

***

{% endstep %}

{% step %}

### 步骤二：建立关键字

在工作流中新增**关键字**节点。

<figure><img src="/files/REqvnAcGKngNGT9c5SGJ" alt=""><figcaption></figcaption></figure>

当访客输入符合条件的关键字时，即会触发对应流程。

建议将相同类型的问题建立在同一组关键字，例如：

* 产品介绍
* 产品
* 介绍

***

{% endstep %}

{% step %}

### 步骤三：设置回复内容

<figure><img src="/files/NsSNLf14t5TUnJ2gGTe7" alt=""><figcaption></figcaption></figure>

新增**回复消息**节点，并设置机器人回复内容。

您可以发送：

* 文字
* 图片
* 文件
* 视频
* 音频

也可以加入按钮，引导访客继续选择咨询内容。

***

{% endstep %}

{% step %}

### 步骤四：连接工作流程

依序将各节点连接，建立完整的机器人流程。

<div data-with-frame="true"><figure><img src="/files/ZHHJ4MhgW1XjAiCL2hXQ" alt=""><figcaption></figcaption></figure></div>

建议至少包含：

* 关键字
* 回复消息

如需人工服务，也可加入<mark style="color:$primary;">**转接人工客服**</mark>节点。

<figure><img src="/files/7ZWQ7NOYu2e45tYpJnjF" alt=""><figcaption></figcaption></figure>

***

{% endstep %}

{% step %}

### 步骤五：启用聊天机器人

完成工作流后，请前往对应渠道启用聊天机器人。

进入：

**AICAN Pro 后台 > 设置 > 渠道列表 > 点击欲接入渠道的【**![](/files/rHkzTWsoU0nLTqW78o8g)**】按钮 > 聊天机器人**

开启聊天机器人，并选择对应的机器人流程后保存设置。

<figure><img src="/files/KechFNKNsXNKAsQDZM8y" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/yuD2Femez0nDFN8VNlvb" alt=""><figcaption></figcaption></figure>

***

{% endstep %}
{% endstepper %}

{% hint style="warning" %}

#### 提醒

* 工作流中的所有节点都必须正确连接，才能完成保存。
* 建议建立完成后，先使用**对话测试**确认流程是否正常。
* 聊天机器人建立完成后，还需在对应渠道启用，访客进入该渠道时才会触发机器人。
  {% endhint %}

***

#### 下一步

完成聊天机器人设置后，您可以继续接入 LINE Official Account、WhatsApp、Facebook Messenger 或 Telegram，将多个渠道的客户对话集中管理。

***


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://aican.gitbook.io/aican/getting-started/chatbot.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
