Loading...
Loading...
Compare original and translation side by side
┌─────────────────────────────────────────────┐
│ 1. NEED ANALYSIS │
│ Define what functionality is needed │
│ Identify language/framework constraints │
├─────────────────────────────────────────────┤
│ 2. PARALLEL SEARCH (researcher agent) │
│ ┌──────────┐ ┌──────────┐ ┌──────────┐ │
│ │ npm / │ │ MCP / │ │ GitHub / │ │
│ │ PyPI │ │ Skills │ │ Web │ │
│ └──────────┘ └──────────┘ └──────────┘ │
├─────────────────────────────────────────────┤
│ 3. EVALUATE │
│ Score candidates (functionality, maint, │
│ community, docs, license, deps) │
├─────────────────────────────────────────────┤
│ 4. DECIDE │
│ ┌─────────┐ ┌──────────┐ ┌─────────┐ │
│ │ Adopt │ │ Extend │ │ Build │ │
│ │ as-is │ │ /Wrap │ │ Custom │ │
│ └─────────┘ └──────────┘ └─────────┘ │
├─────────────────────────────────────────────┤
│ 5. IMPLEMENT │
│ Install package / Configure MCP / │
│ Write minimal custom code │
└─────────────────────────────────────────────┘┌─────────────────────────────────────────────┐
│ 1. 需求分析 │
│ 明确所需功能 │
│ 识别语言/框架约束 │
├─────────────────────────────────────────────┤
│ 2. 并行搜索(研究员Agent) │
│ ┌──────────┐ ┌──────────┐ ┌──────────┐ │
│ │ npm / │ │ MCP / │ │ GitHub / │ │
│ │ PyPI │ │ Skills │ │ Web │ │
│ └──────────┘ └──────────┘ └──────────┘ │
├─────────────────────────────────────────────┤
│ 3. 评估 │
│ 对候选方案评分(功能、维护情况、 │
│ 社区活跃度、文档、许可证、依赖) │
├─────────────────────────────────────────────┤
│ 4. 决策 │
│ ┌─────────┐ ┌──────────┐ ┌─────────┐ │
│ │ 直接采用 │ │ 扩展/封装 │ │ 自定义开发 │ │
│ │ │ │ │ │ │ │
│ └─────────┘ └──────────┘ └─────────┘ │
├─────────────────────────────────────────────┤
│ 5. 实现 │
│ 安装包 / 配置MCP / │
│ 编写最少的自定义代码 │
└─────────────────────────────────────────────┘| Signal | Action |
|---|---|
| Exact match, well-maintained, MIT/Apache | Adopt — install and use directly |
| Partial match, good foundation | Extend — install + write thin wrapper |
| Multiple weak matches | Compose — combine 2-3 small packages |
| Nothing suitable found | Build — write custom, but informed by research |
| 信号 | 行动 |
|---|---|
| 完全匹配、维护良好、采用MIT/Apache协议 | 直接采用 — 直接安装使用 |
| 部分匹配、基础良好 | 扩展 — 安装并编写轻量封装层 |
| 多个弱匹配方案 | 组合 — 整合2-3个小型包 |
| 未找到合适方案 | 自定义开发 — 基于调研结果编写自定义代码 |
~/.claude/settings.json~/.claude/skills/~/.claude/settings.json~/.claude/skills/Task(subagent_type="general-purpose", prompt="
Research existing tools for: [DESCRIPTION]
Language/framework: [LANG]
Constraints: [ANY]
Search: npm/PyPI, MCP servers, Claude Code skills, GitHub
Return: Structured comparison with recommendation
")Task(subagent_type="general-purpose", prompt="
Research existing tools for: [DESCRIPTION]
Language/framework: [LANG]
Constraints: [ANY]
Search: npm/PyPI, MCP servers, Claude Code skills, GitHub
Return: Structured comparison with recommendation
")eslintrufftextlintmarkdownlintprettierblackgofmtjestpytestgo testhuskylint-stagedpre-commiteslintrufftextlintmarkdownlintprettierblackgofmtjestpytestgo testhuskylint-stagedpre-commitunstructuredpdfplumbermammothunstructuredpdfplumbermammothhttpxkygotzodpydantichttpxkygotzodpydanticremarkunifiedmarkdown-itsharpimageminremarkunifiedmarkdown-itsharpimageminNeed: Check markdown files for broken links
Search: npm "markdown dead link checker"
Found: textlint-rule-no-dead-link (score: 9/10)
Action: ADOPT — npm install textlint-rule-no-dead-link
Result: Zero custom code, battle-tested solution需求:检查Markdown文件中的死链
搜索:npm "markdown dead link checker"
找到:textlint-rule-no-dead-link(评分:9/10)
行动:直接采用 — npm install textlint-rule-no-dead-link
结果:零自定义代码,经过实战检验的解决方案Need: Resilient HTTP client with retries and timeout handling
Search: npm "http client retry", PyPI "httpx retry"
Found: got (Node) with retry plugin, httpx (Python) with built-in retry
Action: ADOPT — use got/httpx directly with retry config
Result: Zero custom code, production-proven libraries需求:具备重试和超时处理的高可用HTTP客户端
搜索:npm "http client retry", PyPI "httpx retry"
找到:got(Node)带重试插件,httpx(Python)内置重试功能
行动:直接采用 — 直接使用got/httpx并配置重试
结果:零自定义代码,生产环境验证的库Need: Validate project config files against a schema
Search: npm "config linter schema", "json schema validator cli"
Found: ajv-cli (score: 8/10)
Action: ADOPT + EXTEND — install ajv-cli, write project-specific schema
Result: 1 package + 1 schema file, no custom validation logic需求:根据Schema验证项目配置文件
搜索:npm "config linter schema", "json schema validator cli"
找到:ajv-cli(评分:8/10)
行动:直接采用+扩展 — 安装ajv-cli,编写项目专属Schema
结果:1个包 + 1个Schema文件,无需自定义校验逻辑