Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add cafe3310/public-agent-skills --skill obs-archivegit clone --depth 1 https://github.com/cafe3310/public-agent-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/cafe3310/public-agent-skills/obs-archive)<a href="https://agentmods.dev/skills/cafe3310/public-agent-skills/obs-archive"><img src="https://agentmods.dev/badge/skills/cafe3310/public-agent-skills/obs-archive/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/cafe3310/public-agent-skills/obs-archive"><img src="https://agentmods.dev/badge/skills/cafe3310/public-agent-skills/obs-archive.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00068 | $0.02103 |
| Opus 5.5 | $0.00027 | $0.00841 |
| Sonnet 5.5 | $0.00014 | $0.00421 |
| Haiku 4.5 | $0.00007 | $0.00210 |
Grade A, and why
obs-archive scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 14d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 101 lines — stays where its author put it; the contents beside it link to each section on GitHub.
obs-archive
将用户提供的本地文件(文档、视频、图片、演示文稿)或外部链接(X/Twitter 推文、视频链接、互联网文章)下载并本地化到 Obsidian 仓库的附件目录中,同时阅读解析其内容,在仓库中生成一篇结构清晰、内嵌附件或原文的 Obsidian 归档说明笔记。
仓库、归档目录与附件目录约定
- 默认仓库定位顺序
- 若用户显式指定了仓库路径,或当前工作目录本身位于某个 Obsidian 仓库内(存在
.obsidian目录),直接使用该仓库。 - 否则优先查找名为
obsidian-agi的仓库(通过读取系统 Obsidian 注册表~/Library/Application Support/obsidian/obsidian.json或常见路径如~/Library/Mobile Documents/iCloud~md~obsidian/Documents/obsidian-agi、~/workspace/obsidian-agi)。 - 若仓库根目录下存在
AGENTS.md,在写入笔记前先读取并遵守其中的仓库约定。
- 若用户显式指定了仓库路径,或当前工作目录本身位于某个 Obsidian 仓库内(存在
- 归档笔记存放目录(
./cafe3310/archives)- 所有通过本技能生成的解析与说明文档,默认统一存放在目标 Obsidian 仓库的
./cafe3310/archives目录下(该目录由本技能维护,内含README.md说明目录职责与归档规则;若在新仓库首次运行且该目录尚无README.md,应一并创建)。
- 所有通过本技能生成的解析与说明文档,默认统一存放在目标 Obsidian 仓库的
- 附件目录解析
- 严禁硬编码附件目录名称,统一读取目标仓库
.obsidian/app.json中的attachmentFolderPath配置项确定附件存放路径。
- 严禁硬编码附件目录名称,统一读取目标仓库
- 本地文件移动与复制策略
- 若用户提供的本地文件位于桌面(
~/Desktop)或下载目录(~/Downloads),归档时直接将该文件移动到 Obsidian 附件目录。 - 若本地文件位于其他目录(如代码仓库、文稿目录),归档时将其复制到 Obsidian 附件目录,保留原路径文件不动。
- 外部链接抓取产生的临时文件在归档入库时直接移动并清理临时目录。
- 若用户提供的本地文件位于桌面(
工作流程
第一步:探测 Obsidian 仓库与附件配置
运行内置脚本的 inspect-vault 子命令,确认目标仓库路径、附件目录路径以及是否存在仓库级 AGENTS.md:
python3 <path_to_skill>/scripts/archive_helper.py inspect-vault [--vault <custom_vault_path>]
若返回的 agents_md_path 不为空,先读取该文件了解仓库特定规则。
第二步:获取与本地化输入源
根据用户提供的输入(本地路径或 URL),创建临时工作目录并运行 fetch 子命令:
python3 <path_to_skill>/scripts/archive_helper.py fetch \
--input "<url_or_local_path>" \
--work-dir "/tmp/obsidian_archiver_task"
不同类型输入的处理行为:
- 本地文件:校验文件存在性,识别媒体类型,并判断是否处于桌面或下载目录。
- X/Twitter 链接:调用
gallery-dl --write-metadata下载推文原图与文本元数据,同时调用yt-dlp抓取可能包含的推文视频与.info.json。若遇到需要登录权限的推文,可附加--cookies-from-browser chrome重试。 - 视频站点链接(YouTube、Bilibili 等):调用
yt-dlp下载最高画质视频、.info.json描述以及中英文字幕(.vtt/.srt)。 - 互联网文章链接:优先调用
markdown-new(带--retain-images)或pandoc将网页转换为 Markdown,同时提取正文中引用的所有远程图片并下载至临时目录article_images/。若目标网页存在动态渲染或反爬拦截导致正文为空,改用agent-browser打开页面提取正文与配图。
第三步:阅读资产并提炼简述标题
- 读取第二步生成的
fetch_manifest.json以及对应的正文、字幕、文档或图片内容:- 对文档、PDF、图片:使用文件读取工具直接查看内容。
- 对演示文稿(
.pptx/.key)或长视频:若无法直接读取二进制,可通过ffmpeg抽帧、读取字幕文件或转换工具提取关键信息后再做分析。
- 结合材料内容与用户提问时的补充说明,确定一个简明准确的中文简述标题
{简述}(不含特殊路径字符)。
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 14d ago First seen · 101 lines · 68 tokens per session scan A b1d509c03c5b
obs-archive is a skill published in the GitHub repository cafe3310/public-agent-skills (260 stars, last pushed 14d ago), licensed Apache-2.0. It adds 68 tokens to every session and 2,103 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-16.
obs-archive compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| obs-archivecafe3310/public-agent-skills | Skill | 260 | 14d ago | Apache-2.0 | A | 68 | Claude Code, Codex |
| yuqueflc1125/skills | Skill | 39 | today | MIT | A | 72 | Claude Code, Codex |
| getnoteflc1125/skills | Skill | 39 | today | MIT | A | 83 | Claude Code, Codex |
| preview-mermaidveelenga/preview-skills | Skill | 9 | 1mo ago | MIT | A | 25 | Claude Code |
| preview-csvveelenga/preview-skills | Skill | 9 | 1mo ago | MIT | A | 20 | Claude Code |
| preview-markdownveelenga/preview-skills | Skill | 9 | 1mo ago | MIT | A | 20 | Claude Code |
| visa-doc-translatex-cmd/skill | Skill | 26 | 4mo ago | Apache-2.0 | A | 23 | Claude Code, Codex |