AgentSkillsCN

external-docs

在编写代码前,验证外部库、API和框架是否符合当前文档。当即将使用外部依赖实现功能、编写第三方库的导入语句、不确定某个模式或方法是否最新,或用户提到“基础”或“验证”时,请使用此技能。

SKILL.md
--- frontmatter
name: external-docs
description: Verify external libraries, APIs, and frameworks against current documentation before writing code. Use when about to implement features using external dependencies, when writing import statements for third-party libraries, when unsure if a pattern or method is current, or when the user mentions grounding or verification.

External Docs

Verify external dependencies against current documentation before implementation.


When to Ground

SignalAction
About to write import for external libGround first
Using API/SDK methodsVerify current syntax
Framework-specific patternsCheck version compatibility
Auth/security codeAlways verify current best practices
User says "ground" or "verify"Run full grounding check

Default: When uncertain, ground.


Decision Tree

code
Where does truth live?

CODEBASE ────► Warp-Grep
              "How does X work in our code?"

WEB ─────────► Exa
              "What's the current API for X?"

HISTORY ─────► cm context → cass search
              "How did we do this before?"

TASKS ───────► bv --robot-*
              "What should I work on?"

Exa Query Patterns

Template:

code
{library} {feature} {version} 2024 2025

Good queries:

code
FastAPI Pydantic v2 model_validator 2024 2025
Next.js 14 app router server components
React useOptimistic hook 2024

Tools:

  • web_search_exa(query) — Documentation search
  • get_code_context_exa(query) — Code examples from GitHub
  • crawling(url) — Specific doc page

Verification

After grounding, check:

CriterionPass If
SourceOfficial docs or reputable repo
FreshnessUpdated within 12 months
VersionMatches your dependency
CompletenessFull import + usage pattern
StatusNot deprecated

Record in Bead

Add grounding status table:

markdown
## Grounding Status
| Pattern | Query | Source | Status |
|---------|-------|--------|--------|
| `@model_validator` | "Pydantic v2 2024" | docs.pydantic.dev | ✅ Verified |
| `useOptimistic` | "React 19 2024" | react.dev | ✅ Verified |

Status: ✅ Verified | ⚠️ Changed | ❌ Deprecated | ❓ Unverified


Failure Handling

IssueResponse
No resultsBroaden query, try alternate terms
Conflicting infoOfficial docs > GitHub > tutorials
Only outdated infoMark ❓, proceed with caution, add TODO
Can't verifyFlag for human review

See Also

  • queries.md — Extended query examples
  • patterns.md — Common grounding patterns by framework