# Obsidian Favorites Harvest

> 每周收藏收割 · 抓小红书/抖音收藏里新增的内容，筛掉纯娱乐，转成文字入 Obsidian 知识库

- **Type:** Skill
- **Install:** `agentstack add skill-qianquandong-real-agent-workflows-obsidian-favorites-harvest`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [qianquandong](https://agentstack.voostack.com/s/qianquandong)
- **Installs:** 0
- **Category:** [AI & ML](https://agentstack.voostack.com/c/ai-and-ml)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [qianquandong](https://github.com/qianquandong)
- **Source:** https://github.com/qianquandong/real-agent-workflows/tree/main/obsidian-favorites-harvest
- **Website:** https://realagentusecases.com

## Install

```sh
agentstack add skill-qianquandong-real-agent-workflows-obsidian-favorites-harvest
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

你在用户的电脑上，每周把他小红书和抖音**收藏**里**新增**的内容抓下来、转成文字、入 Obsidian 知识库。

> 使用前替换占位符：``、``（入库目标相对路径）、``（你自己主页的收藏 tab，形如 `https://www.xiaohongshu.com/user/profile/?tab=fav`）、``（知识卡分类用，例如：AI / 健身 / 美食 / 内容创作 / 商业）。

## 安全红线（先读）

- 用带登录态的浏览器访问收藏页（作者用 Claude in Chrome 扩展；换其他 agent 的浏览器控制同理，关键是复用你真实浏览器的登录态）。**如果页面弹出登录/扫码，跳过该平台并在收尾报告里提示用户自己去登录——绝不代替用户登录。**
- 只读收藏，**绝不动收藏夹本身**：不取消收藏、不删除。知识库是积累，不是收藏夹的镜像。
- 所有媒体只下载到本次任务新建的独立临时目录。转写结束后，只删除这个目录里由本次任务创建的文件，绝不按宽泛路径或通配符清理用户文件。

## 步骤

1. **抓收藏清单**：
   - 小红书：navigate 到 ``，分步滚动加载到底（每步滚动后等约 1 秒，高度不再增长为止），从页面状态里收集每条的 id、类型（视频/图文）、标题。
   - 抖音：navigate 到 `https://www.douyin.com/user/self?showTab=favorite_collection`「视频」子 tab，同样滚动到底，收集 `/video/` 和标题。

2. **对台账过滤**：维护 `fav-ledger.json`，按平台和 ID 记录状态，例如 `{"xhs":{"noteId":{"status":"ingested","updatedAt":"2026-07-18"}},"douyin":{}}`。状态只用四种：`ingested`（已入库）、`skipped`（纯娱乐）、`pending_review`（待用户判断）、`failed`（抓取或转写失败）。不存在就当空台账起步。**只处理台账里没有记录的新 ID**；`failed` 由用户决定是否重试，`pending_review` 等用户改状态后再处理。首次运行 = 全量 backfill，量大时分批（单次不超过 4 条，剩下的留给下次触发），防止单次运行超时。

3. **内容筛选**：收藏夹里往往一半是娱乐。从标题判断，**只入教学 / 知识 / 干货类**（教程、方法、拆解、清单）；纯娱乐（音乐、影视剪辑、游戏对局、搞笑、vlog）不入库，台账记为 `skipped`。拿不准的记为 `pending_review`，在收尾报告里列出让用户定，不硬塞。

4. **逐条转文字**：
   - 视频：`yt-dlp` 下载后用 Whisper 转写（抖音下载被拦时的备选：在浏览器里取视频直链再 curl 下载）。
   - 小红书图文：真实鼠标点开卡片（JS click 会跳页），读取文案、作者、高赞评论，逐图转录图内文字并各配一句画面描述，Esc 关闭弹层。
   - **转写成功后立即删除本次任务临时目录里的视频/音频文件**——只留文字稿，不留媒体。转写失败也只清理本次任务创建的临时文件。

5. **入库**：每条按 `` 判定领域，生成一张知识卡写进 `//`，文件名 `YYYY-MM-DD_平台_标题.md`。正文四段：为什么收藏（站在用户的目标角度）/ 一句话摘要 / 原始转写或图文 / 候选结论（提得出就列 1-3 条，提不出留空）。入库前先搜库去重：已有同主题卡就更新旧卡，别新建。

6. **记台账**：每处理一条都立即写入状态：入库成功记 `ingested`，纯娱乐记 `skipped`，待判断记 `pending_review`，抓取或转写失败记 `failed`。同时写 `updatedAt` 和一句 `reason`（成功可省略）。这是「只处理新的」的保证，也避免每周反复扫描同一批娱乐内容。

## 收尾

只关闭本次任务打开的工作标签页，不碰用户原本打开的页面。一句话汇报：本次两个平台各新增几条、入库几条、跳过几条（旧的/娱乐/待定），抓取或转写失败的单独列出。绝不编造。

## 怎么定时跑

注册为每周定时任务，挑流量低峰时段（作者设在周三凌晨 3 点）。backfill 期间可以临时调成每几小时一次，清完存量再改回每周。

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [qianquandong](https://github.com/qianquandong)
- **Source:** [qianquandong/real-agent-workflows](https://github.com/qianquandong/real-agent-workflows)
- **License:** MIT
- **Homepage:** https://realagentusecases.com

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** yes
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-qianquandong-real-agent-workflows-obsidian-favorites-harvest
- Seller: https://agentstack.voostack.com/s/qianquandong
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
