Agent skill
fetch
使用 fetch 服务器获取网页内容并将内容转换为 Markdown。当需要从互联网获取实时信息或阅读特定网页内容时使用该技能。
Install this agent skill to your Project
npx add-skill https://github.com/ArcaneOrion/Alice/tree/main/skills/fetch
SKILL.md
MCP Fetch 技能
此技能允许 Agent 使用 Python 脚本调用 Model Context Protocol (MCP) 的 fetch 服务器来抓取网页内容。它特别适合于获取网页内容并将其作为上下文提供给 AI。
核心功能
- 自动化抓取: 自动启动并连接到
@smithery/mcp-fetch服务器。 - 内容提取: 能够从指定 URL 获取文本内容。
- 无需额外 Python 依赖: 使用 Python 标准库实现,无需安装额外的 pip 包(只需系统环境中安装了
node/npx和python)。
使用指令
- 确定目标 URL: 识别用户需要获取内容的网址。
- 调用脚本: 在项目根目录下,于终端运行以下命令:
bash
python fetch/fetch.py "https://example.com" - 处理输出: 脚本将直接在标准输出中打印网页内容的文本。
技术细节
- 通信协议: 使用 JSON-RPC 2.0 通过标准输入/输出 (stdio) 与 MCP 服务器通信。
- 服务器启动: 使用
npx -y @smithery/mcp-fetch启动服务器。 - 初始化过程: 脚本发送
initialize请求并处理notifications/initialized通知以建立符合 MCP 规范的连接。 - 工具调用: 通过
tools/call方法调用fetch工具,支持maxLength和raw参数(脚本中默认使用maxLength: 20000)。
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
akshare
使用 akshare 获取中国金融市场实时数据和历史数据。当需要查询A股、港股、美股、指数、基金、期货等金融产品的实时行情、历史数据、财务报表时使用该技能。
internal-comms
A set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill whenever asked to write some sort of internal communications (status reports, leadership updates, 3P updates, company newsletters, FAQs, incident reports, project updates, etc.).
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK).
获取微博热搜榜实时数据。当需要查看微博热点、热门话题、实时舆情时使用该技能。
playwright_browser
基于Playwright的高级浏览器自动化技能。支持动态网页抓取、点击/输入模拟、百度搜索、页面快照、数据提取和批量图片下载。当需要处理JavaScript渲染的页面、模拟用户交互或自动化网页操作时使用此技能。
Comprehensive PDF manipulation toolkit for extracting text and tables, creating new PDFs, merging/splitting documents, and handling forms. When Claude needs to fill in a PDF form or programmatically process, generate, or analyze PDF documents at scale.
Didn't find tool you were looking for?