新闻站点内容提取。支持微信公众号、今日头条、网易新闻、搜狐新闻、腾讯新闻。当用户需要提取新闻内容、抓取公众号文章、爬取新闻、或获取新闻JSON/Markdown时激活。
npx skills add https://github.com/NanmiCoder/skills-agent-proto --skill news-extractor
从主流新闻平台提取文章内容,输出 JSON 和 Markdown 格式。
| 平台 | ID | URL 示例 |
|------|-----|----------|
| 微信公众号 | wechat | https://mp.weixin.qq.com/s/xxxxx |
| 今日头条 | toutiao | https://www.toutiao.com/article/123456/ |
| 网易新闻 | netease | https://www.163.com/news/article/ABC123.html |
| 搜狐新闻 | sohu | https://www.sohu.com/a/123456_789 |
| 腾讯新闻 | tencent | https://news.qq.com/rain/a/20251016A07W8J00 |
本 skill 使用 uv 管理依赖。首次使用前需要安装:
# 项目级使用(推荐)
cd .claude/skills/news-extractor
uv sync
# 或用户级使用
cd ~/.claude/skills/news-extractor
uv sync
> 说明: 此 skill 可放置在项目级 (.claude/skills/) 或用户级 (~/.claude/skills/) 目录。项目级便于团队共享,用户级便于跨项目复用。
重要: 所有脚本必须使用 uv run 执行,不要直接用 python 运行。uv run 会自动使用项目虚拟环境中的依赖。
| 包名 | 用途 |
|------|------|
| pydantic | 数据模型验证 |
| requests | HTTP 请求 |
| curl_cffi | 浏览器模拟抓取 |
| tenacity | 重试机制 |
| parsel | HTML/XPath 解析 |
| demjson3 | 非标准 JSON 解析 |
# 提取新闻,自动检测平台,输出 JSON + Markdown
uv run .claude/skills/news-extractor/scripts/extract_news.py "URL"
# 指定输出目录
uv run .claude/skills/news-extractor/scripts/extract_news.py "URL" --output ./output
# 仅输出 JSON
uv run .claude/skills/news-extractor/scripts/extract_news.py "URL" --format json
# 仅输出 Markdown
uv run .claude/skills/news-extractor/scripts/extract_news.py "URL" --format markdown
# 列出支持的平台
uv run .claude/skills/news-extractor/scripts/extract_news.py --list-platforms
脚本默认输出两种格式到指定目录(默认 ./output):
{news_id}.json - 结构化 JSON 数据{news_id}.md - Markdown 格式文章{
"title": "文章标题",
"news_url": "原始链接",
"news_id": "文章ID",
"meta_info": {
"author_name": "作者/来源",
"author_url": "",
"publish_time": "2024-01-01 12:00"
},
"contents": [
{"type": "text", "content": "段落文本", "desc": ""},
{"type": "image", "content": "https://...", "desc": ""},
{"type": "video", "content": "https://...", "desc": ""}
],
"texts": ["段落1", "段落2"],
"images": ["图片URL1", "图片URL2"],
"videos": []
}
# 文章标题
## 文章信息
**作者**: xxx
**发布时间**: 2024-01-01 12:00
**原文链接**: [链接](URL)
---
## 正文内容
段落内容...

---
## 媒体资源
### 图片 (N)
1. URL1
2. URL2
uv run .claude/skills/news-extractor/scripts/extract_news.py \
"https://mp.weixin.qq.com/s/ebMzDPu2zMT_mRgYgtL6eQ"
输出:
[INFO] Platform detected: wechat (微信公众号)
[INFO] Extracting content...
[INFO] Title: 文章标题
[INFO] Author: 公众号名称
[INFO] Text paragraphs: 15
[INFO] Images: 3
[SUCCESS] Saved: ./output/ebMzDPu2zMT_mRgYgtL6eQ.json
[SUCCESS] Saved: ./output/ebMzDPu2zMT_mRgYgtL6eQ.md
uv run .claude/skills/news-extractor/scripts/extract_news.py \
"https://www.toutiao.com/article/7434425099895210546/"
| 错误类型 | 说明 | 解决方案 |
|----------|------|----------|
| 无法识别该平台 | URL 不匹配任何支持的平台 | 检查 URL 是否正确 |
| 平台不支持 | 非支持的站点 | 本 Skill 仅支持列出的新闻站点 |
| 提取失败 | 网络错误或页面结构变化 | 重试或检查 URL 有效性 |
Integration with protocols.io API for managing scientific protocols. This skill should be used when working with protocols.io to search, create, update, or publish protocols; manage protocol steps and materials; handle discussions and comments; organize workspaces; upload and manage files; or integrate protocols.io functionality into workflows. Applicable for protocol discovery, collaborative protocol development, experiment tracking, lab protocol management, and scientific documentation.
Analyzes job descriptions and generates tailored resumes that highlight relevant experience, skills, and achievements to maximize interview chances
Generate Excalidraw diagrams from natural language descriptions. Use when asked to "create a diagram", "make a flowchart", "visualize a process", "draw a system architecture", "create a mind map", or "generate an Excalidraw file". Supports flowcharts, relationship diagrams, mind maps, and system architecture diagrams. Outputs .excalidraw JSON files that can be opened directly in Excalidraw.
Build and distribute Expo development clients locally or via TestFlight
Use when you have a written implementation plan to execute in a separate session with review checkpoints
Data structure for annotated matrices in single-cell analysis. Use when working with .h5ad files or integrating with the scverse ecosystem. This is the data format skill—for analysis workflows use scanpy; for probabilistic models use scvi-tools; for population-scale queries use cellxgene-census.
Benchling R&D platform integration. Access registry (DNA, proteins), inventory, ELN entries, workflows via API, build Benchling Apps, query Data Warehouse, for lab data management automation.
Comprehensive molecular biology toolkit. Use for sequence manipulation, file parsing (FASTA/GenBank/PDB), phylogenetics, and programmatic NCBI/PubMed access (Bio.Entrez). Best for batch processing, custom bioinformatics pipelines, BLAST automation. For quick lookups use gget; for multi-service integration use bioservices.
Take nanmicoder/news-extractor from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.