Search library/framework documentation via llms.txt (context7.com). Use for API docs, GitHub repository analysis, latest library features, technical documentation lookup.
Script-first documentation discovery using the llms.txt standard via context7.com.
Execute scripts in this order:
# 1. Detect query type (topic-specific vs general)
node .agent/skills/docs-seeker/scripts/detect-topic.js "<user query>"
# 2. Fetch documentation
node .agent/skills/docs-seeker/scripts/fetch-docs.js "<user query>"
# 3. Analyze if multiple URLs returned
cat llms.txt | node .agent/skills/docs-seeker/scripts/analyze-llms-txt.js -
Scripts handle URL construction, fallback chains, and error handling automatically.
| Script | Purpose |
|---|---|
detect-topic.js | Classify query; returns {topic, library, isTopicSpecific} |
fetch-docs.js | Fetch from context7.com; handles topic → general fallback |
analyze-llms-txt.js | Categorize URLs; recommend agent distribution strategy |
Topic query — "How do I use date picker in shadcn?":
node scripts/detect-topic.js "<query>" # → {isTopicSpecific: true}
node scripts/fetch-docs.js "<query>" # → 2-3 URLs
# WebFetch those URLs
General query — "Documentation for Next.js":
node scripts/detect-topic.js "<query>" # → {isTopicSpecific: false}
node scripts/fetch-docs.js "<query>" # → 8+ URLs
cat llms.txt | node scripts/analyze-llms-txt.js - # → distribution strategy
Scripts load API keys from: .env → .agent/skills/docs-seeker/.env → .agent/skills/.env → .agent/.env
references/context7-patterns.md — URL patterns, known repositoriesreferences/errors.md — Error handling and fallback strategiesworkflows/topic-search.md — Fast topic path (10–15s)workflows/library-search.md — Comprehensive coverage (30–60s)workflows/repo-analysis.md — GitHub fallback strategy