> 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/features/spatial-awareness/spatial-awareness-reference.md).

# 空间感知设置参考

查找所有空间感知和对象命名项目设置、默认值、单位以及启用条件。

每个控制空间感知的项目设置，以及筛选单个聊天机器人接收内容的按聊天机器人偏好设置的规范参考。事实来源： `Source/Convai/Convai.h` (`UConvaiSettings`，类别 **空间感知** 和 **对象**）以及 `Source/Convai/Public/ConvaiSpatialPreferences.h` (`FConvaiSpatialAwarenessPreferences`).

以下所有项目设置都位于 **编辑 > 项目设置 > 插件 > Convai**.

### 该 `空间感知` 类别

| 显示名称    | 属性                           | 默认值      | 单位 | 编辑条件                                          |
| ------- | ---------------------------- | -------- | -- | --------------------------------------------- |
| 启用空间感知  | `bEnableSpatialAwareness`    | `true`   | —  | 无（总开关）                                        |
| 启用视线    | `bEnableLineOfSight`         | `false`  | —  | `bEnableSpatialAwareness`                     |
| 近距离     | `NearbyDistance`             | `1000.0` | 厘米 | `bEnableSpatialAwareness`                     |
| 中等距离    | `ModerateDistance`           | `4000.0` | 厘米 | `bEnableSpatialAwareness`                     |
| 启用关系    | `bEnableRelations`           | `true`   | —  | `bEnableSpatialAwareness`                     |
| 关系聚类距离  | `RelationClusterDistance`    | `600.0`  | 厘米 | `bEnableSpatialAwareness && bEnableRelations` |
| 从玩家视角描述 | `bDescribePlayerPerspective` | `true`   | —  | `bEnableSpatialAwareness`                     |

* `NearbyDistance` 低于该上限时，一个对象会被视为“附近”； `ModerateDistance` 低于该上限时，会被视为“有些距离”。超过 `ModerateDistance`时，一个对象会被视为“远处”。 `ModerateDistance` 应设置得大于 `NearbyDistance`.
* `bEnableLineOfSight` 每次轮询中，每个聊天机器人/对象对都要消耗一次射线检测。射线无法看见的对象会被报告为超出视野，其位置将被隐藏。
* `RelationClusterDistance` 限定两个对象必须相距多近，才会描述它们之间的关系（“木箱在桶旁边”）。
* `bDescribePlayerPerspective` 大约会使传递给聊天机器人的空间文本长度翻倍，因为它会为每条事实添加一个相对于玩家的从句。

参见 [空间感知的工作原理](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/spatial-awareness/how-spatial-awareness-works.md) 用于说明每项设置会如何改变角色接收的句子。

### 该 `对象` 类别

| 显示名称     | 属性                                                       | 默认值  | 单位 | 编辑条件 |
| -------- | -------------------------------------------------------- | ---- | -- | ---- |
| 重复名称后缀样式 | `ObjectNameSuffixStyle` (`EConvaiObjectNameSuffixStyle`) | `数字` | —  | 无    |

`ObjectNameSuffixStyle` 仅控制后缀样式—— `数字` （“Crate”、“Crate 2”、“Crate 3”）或 `字母` （“Crate”、“Crate A”、“Crate B”）——适用于共享同名且已 **不** 合并的 Convai 对象组件。第一个注册的对象保留其原始名称。一组同名对象是否合并为一个逻辑对象而不是添加后缀，是在 Convai 对象组件本身上的按对象选择，而不是项目设置——参见 [合并同名物体](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/spatial-awareness/merge-same-named-objects.md).

### 按聊天机器人设置的空间偏好

这些不是项目设置——它们位于每个 `UConvaiChatbotComponent`，在 `SpatialAwareness` 属性（`FConvaiSpatialAwarenessPreferences`，类别 **Convai | 空间感知**，高级显示）中。它们会筛选单个聊天机器人从上文所述的空间传递中接收到的内容；当 `启用空间感知` 在项目设置中关闭时，它们不起作用。

#### 周围环境

| 属性                     | 类型                       | 默认值    | 描述                                                                                                    |
| ---------------------- | ------------------------ | ------ | ----------------------------------------------------------------------------------------------------- |
| `bReceiveSurroundings` | `bool`                   | `true` | 是否向该聊天机器人告知对象、其他角色以及玩家相对于它自身的位置。                                                                      |
| `SurroundingsResponse` | `EC_RunLLMOption`        | `从不`   | 当其周围环境变化时，聊天机器人如何反应。 `从不` 静默更新； `Auto`/`总是` 同时提示 AI 回应。                                               |
| `SurroundingsDelivery` | `EConvaiContextDelivery` | `正常发送` | 周围环境变化何时传达到聊天机器人。仅在 `SurroundingsResponse` 为 `Auto`/`总是`. `正常发送` 批量并入下一次计划发送时相关； `等待对话空闲` 在无人发言前一直保持。 |

#### 关系

| 属性                  | 类型                       | 默认值    | 描述                                                                                     |
| ------------------- | ------------------------ | ------ | -------------------------------------------------------------------------------------- |
| `bReceiveRelations` | `bool`                   | `true` | 是否向该聊天机器人告知附近事物彼此之间的关系，与……无关 `bReceiveSurroundings`.                                   |
| `RelationsResponse` | `EC_RunLLMOption`        | `从不`   | 当这些关系变化时，聊天机器人如何反应。 `从不` 静默更新； `Auto`/`总是` 同时提示 AI 回应。                                 |
| `RelationsDelivery` | `EConvaiContextDelivery` | `正常发送` | 关系变化何时传达到聊天机器人。仅在 `RelationsResponse` 为 `Auto`/`总是`。与……相同的两个值： `SurroundingsDelivery`. |

### 下一步

{% content-ref url="/pages/280824f0950858984da0cf561a8148bbd7eee0e8" %}
[空间感知快速开始](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/spatial-awareness/spatial-awareness-quick-start.md)
{% endcontent-ref %}

{% content-ref url="/pages/7ae0cd173a36a87a1546f41623ce3ca4da2a289b" %}
[排查空间感知问题](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/spatial-awareness/troubleshoot-spatial-awareness.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, and the optional `goal` query parameter:

```
GET https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unreal-engine-plugin/features/spatial-awareness/spatial-awareness-reference.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.
