> For the complete documentation index, see [llms.txt](https://docs.convai.com/api-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/validate-your-setup.md).

# 验证你的设置

在继续添加功能之前，请使用此页面确认你的 Convai 设置的每个部分都能正常工作。请按顺序完成每个部分。任何一步失败通常都指向一个具体问题，并且有明确的修复方法。

### 插件检查

| 检查      | 如何验证                                                  |
| ------- | ----------------------------------------------------- |
| 插件已启用   | 前往 **Edit > Plugins**，搜索 `Convai`，并确认 **已启用** 复选框已勾选。 |
| 工具栏图标可见 | Convai 图标会在插件加载后出现在 Unreal Editor 工具栏中。               |
| 没有加载错误  | 该 **输出日志** 未显示提及 `Convai` 或 `AudioCapture` 在编辑器启动时。   |

### API 密钥检查

| 检查    | 如何验证                                                                  |
| ----- | --------------------------------------------------------------------- |
| 已登录   | 打开 Convai 编辑器窗口（点击 Convai 工具栏图标），并确认已显示你的账户详情。                        |
| 密钥已存储 | `UConvaiSettings.API_Key` 已填充——可在以下位置读取： **编辑 > 项目设置 > 插件 > Convai**. |

如果你尚未登录，请参阅 [配置您的 API 密钥](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-your-api-key.md).

### 组件检查

| 检查                        | 如何验证                                                              |
| ------------------------- | ----------------------------------------------------------------- |
| 角色已添加 Convai Chatbot      | 打开角色蓝图并确认 `UConvaiChatbotComponent` 出现在 **组件** 面板。                |
| 角色 ID 已设置                 | 选择 **Convai 聊天机器人** 组件，并确认 **角色 ID** 字段不为空，并且与您仪表板中的某个角色匹配。       |
| 玩家 Pawn 已添加 Convai Player | 打开玩家 Pawn 蓝图并确认 `UConvaiPlayerComponent` 出现在 **组件** 面板。           |
| 已包含 Face Sync（如果使用口型同步）   | 请确认 `UConvaiFaceSyncComponent` 位于角色蓝图中，并且 **口型同步模式** 与你的骨骼绑定设置正确。 |

### 音频检查

| 检查             | 如何验证                                                                                                                       |
| -------------- | -------------------------------------------------------------------------------------------------------------------------- |
| 麦克风可用          | 按 **F10** 在播放模式下打开设置面板，然后查看并测试可用的麦克风设备。或者，调用 `GetAvailableCaptureDeviceNames()` on `UConvaiPlayerComponent` 在运行时，并确认列表不为空。 |
| 默认设备可打开        | 进入播放模式并确认 `GetIsStreaming()` 返回 `true` 在触发按住说话或启用免提模式后。                                                                    |
| 已授予 Android 权限 | 在 Android 上，确认 `android.permission.RECORD_AUDIO` 在开始对话前已请求并授予该权限。                                                          |

### 对话检查

请在其他所有检查通过后运行此检查。

{% stepper %}
{% step %}

#### 进入播放模式

按 **播放** 在 Unreal Editor 工具栏中。
{% endstep %}

{% step %}

#### 开始对话

按住按键通话（默认： **T**）并说一句简短的话，然后松开。或者，在聊天小部件中输入消息并按下 **回车**.
{% endstep %}

{% step %}

#### 观察角色状态

当角色正在说话时， `GetIsTalking()` （“正在说话”）在 `UConvaiChatbotComponent` 返回 `true`。 `IsInConversation()` 返回 `true`.

添加 **打印字符串** 在 Blueprint 中连接到这些函数的节点，以便在视口中观察状态转换。 `IsListening()` 是位于 `IsProcessing()` 已在 Blueprint 中公开，但目前返回 `false` 插件源代码中的
{% endstep %}

{% step %}

#### 确认音频输出

角色会发出可听见的回复。如果已配置口型同步，角色的嘴会与语音同步移动。
{% endstep %}
{% endstepper %}

{% hint style="success" %}
当验证通过后，角色会通过音频进行回应，并且——如果已配置——进行口型同步。前往功能页面添加动作、情感、动态上下文和其他能力。
{% endhint %}

### 常见故障点

#### 角色完全没有回应

**症状：** 角色从不对语音或文本输入生成回复。

**原因：** API 密钥未设置，或缺少角色 ID。

**修复：** 请参见 [配置您的 API 密钥](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-your-api-key.md)；请确认 **角色 ID** Chatbot 组件上的字段。

**验证：** 进入播放模式并发送一句简短的话。角色会发出可听见的回复。

#### 角色没有音频输出

**症状：** 角色似乎在处理输入，但没有发出语音音频。

**原因：** 音频输出设备问题，或会话未开始。

**修复：** 请确认 `bAutoInitializeSession` 为 `true` 在 Chatbot 组件上，或者调用 `StartSession()` 之前先检查。

**验证：** `GetIsTalking()` 返回 `true` ，同时角色作出回应。

#### 角色听不到玩家

**症状：** 角色从不对麦克风输入做出反应。

**原因：** 未捕获麦克风，或缺少 Player 组件。

**修复：** 请确认 `UConvaiPlayerComponent` 位于 Pawn 上；请参阅 [配置麦克风](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-the-microphone.md).

**验证：** `GetIsStreaming()` 返回 `true` 在按住说话或 VAD 激活之后。

#### 口型同步不播放

**症状：** 有音频播放，但角色的嘴没有动。

**原因：** 缺少 Face Sync 组件或口型同步模式错误。

**修复：** 添加 `UConvaiFaceSyncComponent` 并设置正确的 `LipSyncMode` 以适配你的骨骼绑定。

**验证：** 进入播放模式并确认说话时嘴部会移动。

#### OnFailureEvent 触发

**症状：** 该 `OnFailureEvent` 委托在对话期间触发。

**原因：** 网络错误或角色 ID 无效。

**修复：** 请查看 **输出日志** 请查看详情；验证网络访问和角色 ID。

**验证：** 修复报告的错误后重试。

### 下一步

{% content-ref url="/pages/ddab80eff30a95a57bb3cec04bc4566233e30263" %}
[配置麦克风](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-the-microphone.md)
{% endcontent-ref %}

{% content-ref url="/pages/2f681ae01ba11fe882d6b331cca0444e0a06402d" %}
[配置角色音频](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-character-audio.md)
{% endcontent-ref %}

{% content-ref url="/pages/9b983ed32e78e3fecceef1f1ca84663abe05edca" %}
[配置对话输入](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/configure-conversation-input.md)
{% endcontent-ref %}

{% content-ref url="/pages/16dba40249f8c38f0e33f50c10a68569851148b6" %}
[添加聊天 UI](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/add-the-chat-ui.md)
{% endcontent-ref %}


---

# 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:

```
GET https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/getting-started/validate-your-setup.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
