> ## Documentation Index
> Fetch the complete documentation index at: https://aisa.one/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# AIsa Perplexity Deep Research

> 使用 Perplexity Sonar 生成带引用的研究型答案。

[View on GitHub ->](https://github.com/AIsa-team/agent-skills/tree/main/perplexity-research)

**带引用的研究答案。** 当 Agent 需要综合答案而不只是链接列表时，通过 AIsa 调用 Perplexity Sonar。

## 安装

先安装 AIsa CLI：

```bash theme={null}
npm install -g @aisa-one/cli
```

然后安装 Skill：

```bash theme={null}
aisa skills install perplexity-research
```

## Agent 可以做什么？

<CardGroup cols={2}>
  <Card title="深度研究" icon="microscope">
    生成更长、更完整、带来源引用的答案。
  </Card>

  <Card title="快速回答" icon="bolt">
    用 Sonar 生成简洁且有依据的事实回答。
  </Card>

  <Card title="推理型研究" icon="brain">
    把复杂问题路由到具备推理能力的 Sonar 模型。
  </Card>

  <Card title="带来源摘要" icon="quote-left">
    让链接和引用跟随关键论断一起保留。
  </Card>
</CardGroup>

## 设置

该 Skill 需要 `AISA_API_KEY` 环境变量。作为 Claude plugin 安装时，key 通过 plugin 的 `userConfig` 配置。

## 用法

使用 `sonar` 子命令运行搜索客户端：

```bash theme={null}
python3 ${CLAUDE_PLUGIN_ROOT}/skills/perplexity-research/scripts/search_client.py sonar --query "<research question>" --model <model_name>
```

### 参数

| 参数               | 必填 | 默认值   | 说明      |
| ---------------- | -- | ----- | ------- |
| `--query` / `-q` | 是  | —     | 研究问题或查询 |
| `--model` / `-m` | 否  | sonar | 要使用的模型  |

### 可用模型

| Model                 | 速度 | 深度  | 最适合     |
| --------------------- | -- | --- | ------- |
| `sonar`               | 快  | 标准  | 快速事实查询  |
| `sonar-pro`           | 中  | 详细  | 深入主题探索  |
| `sonar-reasoning-pro` | 较慢 | 深   | 复杂推理和分析 |
| `sonar-deep-research` | 最慢 | 最完整 | 综合研究报告  |

### 示例

```bash theme={null}
# 快速事实查询
python3 ${CLAUDE_PLUGIN_ROOT}/skills/perplexity-research/scripts/search_client.py sonar --query "What is the current state of quantum computing?"

# 详细研究
python3 ${CLAUDE_PLUGIN_ROOT}/skills/perplexity-research/scripts/search_client.py sonar --query "Compare transformer and state-space model architectures" --model sonar-pro

# 复杂推理
python3 ${CLAUDE_PLUGIN_ROOT}/skills/perplexity-research/scripts/search_client.py sonar --query "Will AGI be achieved by 2030? Analyze arguments for and against." --model sonar-reasoning-pro

# 穷尽式深度研究
python3 ${CLAUDE_PLUGIN_ROOT}/skills/perplexity-research/scripts/search_client.py sonar --query "Comprehensive analysis of AI regulation frameworks worldwide" --model sonar-deep-research
```

## 输出

脚本会打印：

* **综合答案** — 连贯、结构化的回答
* **引用** — 支撑答案的来源 URL
* **成本** — API 使用成本（如可用）

## 适用场景

当用户需要经过综合、研究充分的答案，而不是原始搜索结果列表时使用该 Skill。适合复杂问题、对比分析、趋势报告，以及任何“带引用的深思熟虑答案”比链接列表更有价值的查询。

## 开始使用

1. 在 [aisa.one](https://aisa.one) 注册（新账号有 \$2 免费额度）。
2. 在控制台生成 API key。
3. 设置 key 并安装 Skill：
   ```bash theme={null}
   export AISA_API_KEY="YOUR_AISA_API_KEY"
   npm install -g @aisa-one/cli
   aisa skills install perplexity-research
   ```
4. 开启新的 Agent session，让 runtime 加载更新后的 Skill 指令。

## 相关

<CardGroup cols={3}>
  <Card title="Perplexity Search" icon="sparkles" href="/zh/agent-skills/perplexity-search">
    现有 Perplexity Sonar Skill。
  </Card>

  <Card title="Perplexity API reference" icon="code" href="/api-reference/perplexity/post_perplexity-sonar">
    Sonar endpoint 文档。
  </Card>

  <Card title="Multi-source Search" icon="magnifying-glass" href="/zh/agent-skills/search">
    将 Perplexity 与其他搜索源组合使用。
  </Card>
</CardGroup>
