feiskyer/deep-research
深度调研的多实例(多 Agent)编排工作流:把一个调研目标拆成可并行子目标,用 Codex CLI 子进程采集和分析证据,再聚合、核验并精修为完整报告。用于系统性网页或资料调研、竞品与行业分析、批量链接或数据集分片、长文证据整合,以及用户提及深度调研、Deep Research、Wide Research、多 Agent 并行调研或多进程调研的场景。
npx skills add https://github.com/feiskyer/claude-code-settings --skill deep-research
把深度调研作为可重复、可审计的生产流程执行。主控负责目标澄清、样本摸底、子任务设计、结果核验和最终综合;子进程负责边界清晰的采集或局部分析。
--model,不覆盖无关配置。workspace-write;只有确实需要 shell 网络访问时才启用 runner 的 --network。--dangerously-bypass-approvals-and-sandbox。.research/<name>/ 目录。先解析当前 Skill 的绝对目录并记为 <skill-dir>。
scripts/run_children.py:跨平台并行执行 codex exec,负责超时、重试、日志和结果状态。scripts/aggregate.py:按 manifest 顺序聚合成功的子报告,缺失或空结果时失败。两个脚本都使用 Python 标准库,不生成临时 shell 脚本。
明确目标、受众、时间范围、来源边界、评价标准和最终格式。通过当前可用工具获取少量真实样本,记录代表性来源和缺口,避免只凭经验拆分。
使用不重复的语义化名称,例如:
.research/20260712-codex-skills-a3f2/
├── prompts/
├── logs/
├── child_outputs/
├── raw/
├── cache/
└── manifest.json
把网页原文、数据和解析结果缓存到 raw/ 或 cache/,避免重复抓取。
每个子任务只负责一个明确边界,Prompt 至少包含:
将 Prompt 分别写入 prompts/,然后创建 manifest:
{
"tasks": [
{
"id": "market-history",
"title": "市场历史",
"prompt_file": "prompts/market-history.md"
},
{
"id": "current-competitors",
"title": "当前竞品",
"prompt_file": "prompts/current-competitors.md"
}
]
}
id 只能包含字母、数字、点、下划线和短横线。Prompt 必须位于本次运行目录内。
先预览命令,不启动 Codex 子进程:
python3 "<skill-dir>/scripts/run_children.py" \
--run-dir ".research/<name>" \
--workspace "$PWD" \
--dry-run
检查 manifest 和 Prompt 后执行:
python3 "<skill-dir>/scripts/run_children.py" \
--run-dir ".research/<name>" \
--workspace "$PWD" \
--parallel 8 \
--timeout 600 \
--retries 1
只有子任务必须通过 shell 直接联网时才添加 --network。根据任务成本调整并发和超时,先用 1–2 个子任务验证链路,再扩大并发。
Runner 固定输出:
child_outputs/<id>.mdlogs/<id>.logresults.json读取 results.json,检查失败、超时、空输出和引用缺失。只重试失败的边界任务;不要因为单个失败重新运行所有成功任务。需要改变模型、权限或来源范围时先说明原因。
python3 "<skill-dir>/scripts/aggregate.py" \
--run-dir ".research/<name>"
默认生成 aggregated_raw.md。该文件只是按 manifest 顺序整理的内部材料,不是最终报告。
通读子报告和关键原始来源,先设计章节大纲和素材映射,再分章节写入 polished_report.md。处理重复信息、来源冲突和证据强弱;验证关键数据和引用,不能把子报告简单拼接后直接交付。
最终回复提供:
不要把内部 Prompt、调度日志或完整中间稿当作成品发送给用户。
Take feiskyer/deep-research from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.