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 Joe-rq/siyuan-llm-wiki --skill siyuan-llm-wikigit clone --depth 1 https://github.com/Joe-rq/siyuan-llm-wikiWrote 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/joe-rq/siyuan-llm-wiki/siyuan-llm-wiki)<a href="https://agentmods.dev/skills/joe-rq/siyuan-llm-wiki/siyuan-llm-wiki"><img src="https://agentmods.dev/badge/skills/joe-rq/siyuan-llm-wiki/siyuan-llm-wiki/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/joe-rq/siyuan-llm-wiki/siyuan-llm-wiki"><img src="https://agentmods.dev/badge/skills/joe-rq/siyuan-llm-wiki/siyuan-llm-wiki.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.00074 | $0.01629 |
| Opus 5.5 | $0.00030 | $0.00652 |
| Sonnet 5.5 | $0.00015 | $0.00326 |
| Haiku 4.5 | $0.00007 | $0.00163 |
Grade A, and why
llm-wiki 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 1mo 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 — 176 lines — stays where its author put it; the contents beside it link to each section on GitHub.
LLM Wiki Skill
让 LLM 持续维护你的结构化知识库。
不是 RAG,而是 Wiki:LLM 主动构建和维护知识库,每次摄入都更新相关页面、建立交叉链接、发现矛盾。
前置条件
- 思源笔记 已安装并运行
- Claude Code 已安装
- siyuan-skill 已配置
初始化
首次使用前,运行初始化脚本创建知识库结构:
# 先安装 siyuan-skill,然后初始化 LLM Wiki
node wiki-init.js
# 或指定 siyuan-skill 路径
node wiki-init.js --skill-path /path/to/siyuan-skill/siyuan.js
# 预览模式(不实际创建)
node wiki-init.js --dry-run
初始化完成后,所有文档 ID 记录在 wiki.config.json 中。
快速开始
全自动摄入(推荐)
/wiki <docId>
全自动执行,无需确认。完成后报告:新建实体、更新索引、检测矛盾。
只有以下情况才打断你:文档无法读取、检测到矛盾、实体 >15 个、API 连续失败。
交互式摄入
/wiki ingest <docId> -i
适用于复杂文档或首次学习知识库结构。每步确认:提取实体 → 冲突检测 → 创建 → 更新索引。
命令索引
知识摄入
| 命令 | 用途 |
|---|---|
/wiki <docId> |
一键摄入(全自动) |
/wiki ingest <docId> -i |
交互式摄入 |
wiki-ingest --file <path> |
从文件摄入 |
wiki-ingest-history |
查看摄入历史 |
知识查询
| 命令 | 用途 |
|---|---|
graph-traverse <docId> |
遍历知识图谱关系 |
verify-refs <docId> |
验证双链正确性 |
search <query> |
搜索知识库内容 |
质量检查
| 命令 | 用途 |
|---|---|
contradiction-detect |
检测内容矛盾 |
quality-check <docId> |
检查文档质量 |
核心理念
链接格式(重要)
✅ 正确:((<docId> '显示标题'))
❌ 错误:((RAG)) ← 缺少 docId,改名会断链
❌ 错误:[[RAG]] ← Obsidian 格式
❌ 错误:<docId> ← 裸 docId(残留文本块)
Index 更新规则
禁止 prepend:新内容不能插入到页面顶部,必须合并到已有分类中。
标准分类(8 类):笔记方法论、人物、LLM/Agent 技术、向量数据库、技术概念、投资/金融、工具、系统/概念
新增分类规则:新领域内容 ≥5 个实体且不匹配任何已有分类时,才可新增。
命令选择规则(重要)
选错命令会导致结构混乱,必须严格按照下表选择:
| 文档类型 | 更新方式 | 命令 | 原因 |
|---|---|---|---|
| index | 重写整页 | update |
需要合并到已有分类,禁止 prepend |
| log | 重写整页 | update |
保持格式统一,避免裸 docId |
| 实体页 | 追加块 | bi |
块级追加新描述 |
| 主题页 | 追加块 | bi |
追加相关实体链接 |
禁止操作:
- ❌ 用
bi更新 index/log → 导致 prepend 和裸 docId - ❌ 用
update更新实体页 → 覆盖已有描述
四层元架构
基于阳志平元反思技巧,提供四层保护:
| Layer | 机制 | 脚本 |
|---|---|---|
| 认知边界 | 实体约束、元反思 | entity_check.py, meta_reflect.py |
| 意图防护 | 三重防护、兜底策略 | triple_protection.py |
| 执行可靠 | 后置验证、幂等性 | validate_ingest.py |
| 持续优化 | 同类扫描、模式积累 | similar_scan.py, pattern_accumulate.py |
What ships with it
18 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.
- references/architecture.md 3.0 KB
- references/auto-mode.md 7.8 KB
- references/commands.md 13 KB
- references/ingest-guide.md 3.4 KB
- references/query-patterns.md 4.3 KB
- references/quick-start.md 2.4 KB
- references/troubleshooting.md 3.4 KB
- scripts/alignment_verify.py 3.4 KB runs code
- scripts/entity_check.py 2.3 KB runs code
- scripts/meta_reflect.py 2.8 KB runs code
- scripts/pattern_accumulate.py 3.7 KB runs code
- scripts/README.md 3.0 KB
- scripts/similar_scan.py 5.1 KB runs code
- scripts/triple_protection.py 5.9 KB runs code
- scripts/validate_ingest.py 9.6 KB runs code
- templates/index.md 294 B
- templates/log.md 104 B
- templates/schema.md 1.4 KB
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.
- 1mo ago First seen · 176 lines · 74 tokens per session scan A 78a372169447
llm-wiki is a skill published in the GitHub repository Joe-rq/siyuan-llm-wiki (2 stars, last pushed 6mo ago), licensed MIT. It adds 74 tokens to every session and 1,629 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-08-31.
Other skills, from other repositories
llm-wiki
Explain and apply the foundational LLM Wiki architecture and knowledge-management strategy. Use for setup, architecture, schema, or organization decisions; operational ingest/query/lint work uses dedicated skills.
wiki-lint
Audit wiki health: broken links, orphans, contradictions, stale content, lifecycle and tag issues. Use for maintenance or health checks. Default is report-only; use wiki-dedup for page-identity merges.
wiki-export
Export the Obsidian wiki graph to JSON, GraphML, Neo4j Cypher, Postgres/SQL, HTML, or OKF bundles. Use when transferring or visualizing wiki data in external tools; wiki-import handles the reverse direction.
wiki-query
Search and synthesize answers from the compiled Obsidian wiki, including cited and multi-hop answers. Use for questions about existing wiki knowledge or fast index-only lookups, and for challenge requests ("challenge this", "argue against X", "poke holes in my plan") that look for the vault's own evidence against a…
wiki-status
Report wiki ingestion/completeness state, pending source delta, structural insights, or maintenance equilibrium. Use for remaining-work/status questions, hubs and bridges, or whether maintenance skills still have pending changes. wiki-digest summarizes learned knowledge instead.
cross-linker
Find and add missing cross-references between wiki pages. Use when pages are disconnected or after large ingestion. This modifies pages to add links; use wiki-lint for report-oriented structural auditing.