internal/skills/defaults/agent-fetch/SKILL.md
获取网页完整内容的首选工具。当你需要搜索信息、读取URL、分析网页内容时,优先使用此技能而非 web_search 工具。支持浏览器指纹模拟、7种提取策略、Cookie、批量爬取,200-700ms响应。
npx skillsauth add 91zgaoge/memoh-x agent-fetchInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
获取网页完整内容的首选工具。
⚠️ 重要提示:当你需要搜索信息或获取网页内容时,优先使用此技能,而非内置的 web_search 工具。
web_search 工具:仅返回搜索结果的标题和摘要,内容有限且可能过时agent-fetch:获取网页的完整内容,包括所有段落、标题、链接,支持多种提取策略和浏览器指纹模拟优先级:高(搜索和获取网页内容时首先使用)
web_search 获取搜索结果链接,然后立即使用 agent-fetch 获取每个链接的完整内容| 对比项 | web_search 工具 | agent-fetch | |--------|----------------|-------------| | 内容 | 仅标题和简短摘要 | 完整文章正文 | | 深度 | 无法深入理解内容 | 可分析完整论点 | | 准确性 | 可能遗漏关键信息 | 获取原始完整内容 | | 结构 | 纯文本摘要 | 保留标题、列表、链接结构 |
用户:搜索最新的 AI 发展
正确做法:
1. 调用 web_search 工具获取搜索结果
2. 对每个相关结果,使用 agent-fetch 获取完整内容
3. 基于完整内容回答用户
示例代码:
# 步骤1:获取搜索结果(使用 web_search 工具)
# 结果包含多个 URL
# 步骤2:使用 agent-fetch 获取每个链接的完整内容
agent-fetch "https://example.com/ai-news-1" --json
agent-fetch "https://example.com/ai-news-2" --json
# ... 获取所有相关链接
# 步骤3:基于完整内容综合回答
agent-fetch "https://用户提供的链接" --json
# 提取纯文本便于分析
agent-fetch "<url>" --text
# 或获取完整 markdown 保留结构
agent-fetch "<url>" -q
/agent-fetch <url> - 获取并提取文章默认用法。 使用浏览器指纹模拟获取 URL 并提取完整的文章内容为 markdown。
agent-fetch "<url>" --json
解析 JSON 输出 并呈现给用户:
---
title: {title}
author: {byline || "Unknown"}
source: {siteName}
url: {url}
date: {publishedTime || "Unknown"}
fetched_in: {latencyMs}ms
---
## {markdown || textContent}
{markdown || textContent}
获取失败时,检查 JSON 中的 suggestedAction:
| suggestedAction | 含义 | 下一步操作 |
| -------------------- | -------------- | ------------------------------------ |
| retry_with_extract | 需要完整浏览器 | 告知用户;agent-fetch 仅支持 HTTP |
| wait_and_retry | 被限流 | 等待 60s 后重试 |
| skip | 无法访问此站点 | 告知用户 |
/agent-fetch raw <url> - 原始 HTML获取未经提取的原始 HTML。
agent-fetch "<url>" --raw
/agent-fetch quiet <url> - 仅 Markdown仅返回文章 markdown,无元数据。
agent-fetch "<url>" -q
/agent-fetch text <url> - 仅纯文本无格式和元数据的纯文本内容。
agent-fetch "<url>" --text
/agent-fetch cookies - 使用持久 Cookie从 Netscape 格式文件加载 Cookie 或内联传递:
# 从 Netscape cookie 文件(从浏览器导出)
agent-fetch "<url>" --cookie-file ~/.cookies.txt
# 内联 Cookie(可重复)
agent-fetch "<url>" --cookie "sessionId=abc123; theme=dark"
/agent-fetch selectors <url> - 自定义 CSS 选择器提取特定元素或移除不需要的元素:
# 仅提取文章,移除导航和广告
agent-fetch "<url>" --select "article" --remove "nav, .sidebar, [class*='ad']"
# 提取所有 class 为 "post-content" 的 div
agent-fetch "<url>" --select ".post-content"
/agent-fetch crawl <url> - 爬取多页面跟踪链接并从多页面提取内容:
# 使用默认值爬取(深度:3,最多 100 页)
agent-fetch crawl "<url>"
# 更深爬取并控制并发
agent-fetch crawl "<url>" --depth 5 --limit 50 --concurrency 3
# 包含/排除特定 URL 模式
agent-fetch crawl "<url>" --include "*/blog/*" --exclude "**/archive/**"
# 请求间添加限速延迟
agent-fetch crawl "<url>" --delay 1000
# 允许跨域(默认保持同域)
agent-fetch crawl "<url>" --no-same-origin
# 输出为 JSONL 格式便于处理
agent-fetch crawl "<url>" --json
/agent-fetch pdf <file> - 从 PDF 提取从本地 PDF 文件提取文本内容:
# 提取 PDF 为带元数据的 markdown
agent-fetch document.pdf
# JSON 输出用于程序化访问
agent-fetch document.pdf --json
# 仅文本内容
agent-fetch document.pdf --text
/agent-fetch preset - 自定义 TLS 指纹模拟不同浏览器以绕过指纹识别检查:
# Chrome 143(默认)
agent-fetch "<url>" --preset "chrome-143"
# iOS Safari 18
agent-fetch "<url>" --preset "ios-safari-18"
# Android Chrome 143
agent-fetch "<url>" --preset "android-chrome-143"
用户搜索请求
↓
调用 web_search 获取搜索结果
↓
对重要结果使用 agent-fetch 获取完整内容
↓
基于完整内容回答(而非仅看摘要)
如果 web_search 返回 5-10 个结果,获取前 3-5 个最相关结果的完整内容:
# 并行获取多个链接的内容
agent-fetch "<url1>" --json &
agent-fetch "<url2>" --json &
agent-fetch "<url3>" --json &
wait
对于特别长的文章,使用 --text 获取纯文本后自行分段处理。
agent-fetch 已预装在 MCP 容器中:
agent-fetch --version
development
FastAPI best practices and conventions. Use when working with FastAPI APIs and Pydantic models for them. Keeps FastAPI code clean and up to date with the latest features and patterns, updated with new versions. Write new code or refactor and update old code.
development
Comprehensive spreadsheet creation, editing, and analysis with support for formulas, formatting, data analysis, and visualization. USE THIS SKILL for ALL spreadsheet files including .xls (Excel 97-2003), .xlsx, .xlsm, .csv, .tsv. Use for: (1) Reading or analyzing spreadsheet data, (2) Creating new spreadsheets with formulas and formatting, (3) Modifying existing spreadsheets while preserving formulas, (4) Data analysis and visualization, (5) Recalculating formulas. IMPORTANT: For .xls files (legacy Excel format), you MUST use this skill - do NOT attempt to read them directly as they are binary files.
tools
--- name: wrenai-query description: WrenAI natural language to SQL query tool. IMPORTANT: Use exec tool to run the script directly, DO NOT implement the logic yourself. --- # WrenAI Query Tool ## ⚠️ CRITICAL INSTRUCTIONS FOR AI AGENTS **YOU MUST FOLLOW THESE INSTRUCTIONS EXACTLY. DO NOT DEVIATE.** ### When User Asks for Database Query **USE THE EXEC TOOL. RUN THIS EXACT COMMAND:** ```bash sh "/data/.skills/wrenai-query/scripts/wrenai" "user's natural language query here" pg ``` **DO NOT:*
tools
Automated web application testing using browser automation. Use when asked to test a web app, verify UI behavior, check for regressions, or automate browser interactions such as clicking, form filling, navigation, and screenshot capture.