> ## Documentation Index
> Fetch the complete documentation index at: https://arka-agent-mintlify-f21cea86.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# 聊天、网络搜索和事实问答技能

> 通过 Arka 的聊天引擎回答问题，支持网络搜索、深度爬取 RAG、数学、天气、附近地点查询以及位置感知的会话记忆。

Arka 的聊天引擎可处理事实性问题、深度网络研究、数学、天气以及位置感知搜索。

## 核心技能

| 技能 | 示例 |
| - | - |
| `web_answer` | `arka ask who won IPL 2025` |
| `deep_web_answer` | `deep_web_answer latest AI regulation news` |
| `calc` | `arka calc integrate sin(x) dx` |
| `hyperlocal_weather` | `arka weather near me` |
| `set_location` | `set_location Mumbai` |
| `nearby_places` | `nearby_places Kolkata` |
| `error_helper` | `error_helper <traceback>` |
| `arka chat_reset` | 清除会话 + 位置上下文 |

## 强制深度搜索

使用 `/` 前缀强制执行深度网络搜索：

```bash theme={null}
arka "/who won IPL 2025"
```

## 深度搜索队列

在后台运行深度搜索：

```bash theme={null}
arka "deep_queue add "who won the last IPL final""
arka "deep_queue list"
arka "deep_queue run"
arka "deep_queue results"
```

## 会话记忆

回答会被标记为 `[FROM SEARCH]` 或 `[FROM MEMORY]`（在 TTS 中会被剥离）。聊天会话会在同一会话内跨后续问题保留上下文。

```bash theme={null}
arka facing hair loss          # 路由到带会话的 web_answer
arka chat_reset                     # 清除上下文
```

## 位置定位

设置位置以获取超本地化结果：

```bash theme={null}
arka "set_location Mumbai"
arka "hyperlocal_weather"
arka "nearby_places"
arka map_download Kolkata           # 将城市地图缓存到 ~/.cache/arka/maps/
```

## 网络搜索调优

DuckDuckGo 查询遵循两个环境变量。若每次重试都超时或报错，聊天会记录失败并改用模型知识回答，而不是让回复卡住。

| 变量 | 默认值 | 说明 |
| - | - | - |
| `DDGS_TIMEOUT` | `20` | 每次调用的超时（秒），最小 `5`。 |
| `DDGS_RETRIES` | `2` | 回退前的尝试次数，最小 `1`。 |

在网络较慢或不稳定时可调高两项：

```env theme={null}
DDGS_TIMEOUT=30
DDGS_RETRIES=3
```

## 安装聊天附加组件

```bash theme={null}
pip install "arka-agent[chat]"
```

依赖：Agno、ddgs、trafilatura、sympy、geopy。

<Note>
  网络查询在搜索前会经过安全检查。参见 [安全](/cn/concepts/security)。
</Note>


## Related topics

- [有趣的知识](/cn/guides/interesting-fact.md)
- [Arka 与其他智能体的对比](/cn/concepts/comparison.md)
- [内置技能目录](/cn/guides/skills.md)
- [AI 智能体指南 — 通过 MCP 使用 Arka](/cn/guides/ai-agents.md)
- [个性化你的 Arka 体验](/cn/guides/personalize.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.