Xiaohongshu Ingest logo

Xiaohongshu Ingest

CommunityPopular
chubbyguan
xiaohongshu-ingest

小红书笔记采集 → 统一 frontmatter Markdown → 爆款拆解 + 衍生选题。 支持笔记链接和 xhslink 短链;爆款拆解按「人群×场景×痛点×情绪×钩子」生成可复用选题。

Overview

Publisherchubbyguan
Repositorychubbyskills
Skill namexiaohongshu-ingest
Stars
1.2K
Forks
147
Bundled files
3
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 3 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by chubbyguan on GitHub. Read the source before you install it.

Installation

Install the Xiaohongshu Ingest AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/chubbyguan/chubbyskills/tree/main/xiaohongshu-ingest
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/chubbyguan/chubbyskills.git /tmp/chubbyskills
mkdir -p .claude/skills
cp -r /tmp/chubbyskills/xiaohongshu-ingest .claude/skills/xiaohongshu-ingest
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Xiaohongshu Ingest in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Xiaohongshu Ingest on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Xiaohongshu Ingest is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

小红书采集 + 爆款拆解 Skill

把小红书笔记抓成结构化 Markdown 入库,再用 DeepSeek 拆解爆款逻辑、衍生可直接写的选题。 自动区分图文与视频笔记:图文 → 下载图片本地嵌入;视频 → 像抖音那样转成文字稿。 补齐了仓库在「中文内容采集」上最大的平台缺口,也是「采集 → 选题」创作工作流的起点。

环境要求

bash
# 图文采集零依赖(仅 Python 标准库)

# 视频笔记转录需要(与抖音/B站转录同一套依赖):
pip install funasr modelscope torch torchaudio
# macOS: brew install ffmpeg   |   Ubuntu: sudo apt install ffmpeg

# 强烈建议:配置 cookie 以规避风控(从浏览器登录后复制)
export XHS_COOKIE="你的小红书 cookie 字符串"

# 爆款拆解需要 DeepSeek API Key
export DEEPSEEK_API_KEY="your-api-key"

使用方法

bash
# 1) 采集笔记 → 统一 frontmatter Markdown
python scripts/fetch_note.py "https://www.xiaohongshu.com/explore/xxxx" -o ./out
python scripts/fetch_note.py "http://xhslink.com/xxxx" -o ./out
python scripts/fetch_note.py "链接" -o ./out --no-images   # 图文:只留图片链接不下载
python scripts/fetch_note.py "链接" -o ./out --no-video    # 视频:不转录,只留视频链接
python scripts/fetch_note.py "链接" -o ./out --fallback-text 手动正文.txt

# 2) 爆款拆解 → 拆解报告 + 5 条衍生选题
python scripts/analyze_hook.py ./out/某笔记.md -o ./out

产出

  • fetch_note.py:标题、正文、标签、作者、互动数据(赞/藏/评)→ 统一 frontmatter Markdown(platform: xiaohongshu,含 note_type: image|video)。按笔记类型分流:
    • 图文笔记:图片下载到本地 <标题>.assets/ 并以 ![]() 嵌入(正文常在图里,本地化后 Obsidian 直接可见)。--no-images 只留链接,单张失败自动回退为链接
    • 视频笔记:提取视频直链 → ffmpeg 抽音频 → SenseVoice 转录为文字稿写入 ## 视频文字稿。--no-video 只留视频链接;缺 funasr/ffmpeg 时自动降级为存链接
  • analyze_hook.py:目标人群 / 场景 / 痛点 / 情绪价值 / 标题钩子 / 正文结构 / 可复用模板 / 5 条衍生选题(带 - [ ] 勾选,可直接进选题库)

⚠️ 关于反爬(务必先读)

小红书风控严格,未登录的纯脚本访问经常被拦。本 skill 的策略:

  1. 优先解析页面内嵌的 __INITIAL_STATE__ 结构化数据
  2. 失败则回退到 og: 元标签
  3. 仍失败时给出明确提示——此时可手动复制笔记正文存成 .txt,用 --fallback-text 继续生成统一 Markdown,或直接走 analyze_hook.py 拆解(拆解环节不依赖抓取)

提供 XHS_COOKIE 能显著提高采集成功率。页面结构若调整,需更新 fetch_note.py 里的选择器。

合规声明

仅供个人学习与研究使用。请遵守小红书用户协议与 robots 规则,控制请求频率,不要用于批量抓取、商用爬取或侵犯他人权益的场景。

衔接工作流

  • 采集产物 → knowledge-base-management 入库(统一 frontmatter,按 platform 聚合)
  • 衍生选题 → 创作者选题流(采集 → 拆解 → 选题库 → 初稿)
  • 多篇拆解 → 沉淀「爆款选题库」,对接 industry-intelligence-radar 的趋势信号

参考

  • 小红书爆款方法论:人群 × 场景 × 痛点 + 情绪价值
  • DeepSeek — 拆解用 LLM

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Xiaohongshu Ingest AI skill do?

小红书笔记采集 → 统一 frontmatter Markdown → 爆款拆解 + 衍生选题。 支持笔记链接和 xhslink 短链;爆款拆解按「人群×场景×痛点×情绪×钩子」生成可复用选题。

Why use Xiaohongshu Ingest on TypingMind?

Because you install it once and use it with any model. Xiaohongshu Ingest is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Xiaohongshu Ingest in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/chubbyguan/chubbyskills/tree/main/xiaohongshu-ingest. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Xiaohongshu Ingest?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Xiaohongshu Ingest?

As many as you like. As long as a model supports skills, you can use Xiaohongshu Ingest with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Xiaohongshu Ingest AI skill free?

Yes. It is published on GitHub by chubbyguan under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇