X Ingest

X(Twitter) 推文采集 → 统一 frontmatter Markdown。自动区分图文与视频: 图文下载图片本地嵌入,视频提取直链转成文字稿。无需登录(走官方嵌入端点)。

1,337 stars 155 forksOther

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add chubbyguan/chubbyskills --skill x-ingest
Manual install
git clone --depth 1 https://github.com/chubbyguan/chubbyskills.git /tmp/chubbyskills
mkdir -p ~/.claude/skills
cp -r /tmp/chubbyskills/x-ingest ~/.claude/skills/x-ingest

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

# X(Twitter) 推文采集 Skill

把 X 推文抓成结构化 Markdown 入库。**自动区分图文与视频笔记**:图文 → 下载图片本地嵌入;
视频 → 像抖音那样转成文字稿。通过 X 官方嵌入用的 syndication 端点采集,**无需登录、无需 API Key**。

## 环境要求

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

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

## 使用方法

```bash
# 采集推文 → 统一 frontmatter Markdown
python scripts/fetch_tweet.py "https://x.com/user/status/1234567890" -o ./out
python scripts/fetch_tweet.py "https://twitter.com/user/status/1234567890" -o ./out
python scripts/fetch_tweet.py "链接" -o ./out --thread   # 沿作者自回复链采集 thread

python scripts/fetch_tweet.py "链接" -o ./out --no-images   # 图文:只留图片链接不下载
python scripts/fetch_tweet.py "链接" -o ./out --no-video    # 视频:不转录,只留视频链接
python scripts/fetch_tweet.py "链接" -o ./out --fallback-text 手动正文.txt
python scripts/fetch_tweet.py "链接" -o ./out --fallback-json 推文.json --fallback-only

# X 长文章抓全文(需自己账号的登录 cookie):
python scripts/fetch_tweet.py "链接" -o ./out --cookies "auth_token=...; ct0=..."
X_COOKIES="auth_token=...; ct0=..." python scripts/fetch_tweet.py "链接" -o ./out
```

## 产出

`fetch_tweet.py` → 统一 frontmatter Markdown(`platform: x`,含 `note_type: image|video|text|article|thread`),含作者(`name @handle`)、互动数据(赞/回复)、话题标签。**按内容类型分流**:

- **图文 / 纯文字推文**:正文 + 图片下载到本地 `<标题>.assets/` 并以 `![]()` 嵌入;`--no-images` 只留链接,单张失败自动回退为链接
Read the full skill on GitHub

Details

Skill name
x-ingest
Path
x-ingest/SKILL.md
License
MIT
Repo updated
14 October 2026

FAQ

What does the X Ingest skill do?

X(Twitter) 推文采集 → 统一 frontmatter Markdown。自动区分图文与视频: 图文下载图片本地嵌入,视频提取直链转成文字稿。无需登录(走官方嵌入端点)。

How do I install the X Ingest skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add chubbyguan/chubbyskills --skill x-ingest. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is X Ingest popular?

It lives in chubbyguan/chubbyskills, which has 1,337 GitHub stars and 155 forks, and is included in 1 curated skill list.

Related skills

Browse the most popular Claude skills, all other skills, or write your own with the skills generator.