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 Piasy/lark-skills --skill markdown-larkdoc-syncgit clone --depth 1 https://github.com/Piasy/lark-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/piasy/lark-skills/markdown-larkdoc-sync)<a href="https://agentmods.dev/skills/piasy/lark-skills/markdown-larkdoc-sync"><img src="https://agentmods.dev/badge/skills/piasy/lark-skills/markdown-larkdoc-sync.svg" alt="Measured on agentmods" 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.00052 | $0.01351 |
| Opus 5 | $0.00026 | $0.00675 |
| Sonnet 5 | $0.00010 | $0.00270 |
| Haiku 4.5 | $0.00005 | $0.00135 |
Grade A, and why
markdown-larkdoc-sync 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 8d 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.
What it actually says
markdown-larkdoc-sync
开始前先确认:
- 只支持一个手动触发的同步工作流。
- 每次只处理一篇明确指定的 Markdown 文件。
- frontmatter 是受限子集,绑定读写必须走脚本。
- 一致性审校必须由独立 sub-agent 执行,且 sub-agent 使用与父 agent 相同的模型配置。
- 成功收尾时要解决全部未解决评论,并创建专用 sync commit。
- Mermaid 特殊约束:飞书正文中必须落地为“文本绘图 add-on(codeChart)”,不能保留 whiteboard 块。
执行约束:
- 确定性结构化步骤优先调用仓库脚本,不要在 prompt 中手写 Git 或 Lark 解析逻辑。
bin/resolve_doc_key.py、bin/find_last_sync_commit.py、bin/extract_markdown_body.py、bin/fetch_open_comments.py、bin/fetch_remote_markdown.py、bin/write_back_and_verify.py、bin/resolve_all_comments.py、bin/create_sync_commit.py、bin/create_bootstrap_doc.py都应被视为工作流标准入口。- 调用
bin/find_last_sync_commit.py时,第二个参数doc_key必须直接使用bin/resolve_doc_key.py输出中的doc_key原值。 doc_key格式固定为<file_type>:<resolved_doc_token>(示例:docx:KlpudvT7so6kfwxyzZsl0L9ogbg),不得手工改写成docx/KlpudvT7so6kfwxyzZsl0L9ogbg这类/分隔格式。profile必须使用本机可用的 lark-cli profile(通常为 appId),不要硬编码default。可用值通过lark-cli auth list和lark-cli config show确认。- 调用
bin/create_bootstrap_doc.py时可以不传--profile让脚本自动选择;若传入的--profile不可用,脚本会按 active profile 或单 profile 自动回退,并在输出中标记profile_resolution/profile_warning。 - 读取 frontmatter 绑定必须调用
bin/read_frontmatter_binding.py。 - 修改 frontmatter 绑定必须调用
bin/write_frontmatter_binding.py。 - 读取远端正文用于合并或落盘时,必须调用
bin/fetch_remote_markdown.py --canonical,禁止直接使用docs +fetch原始文本参与比较。 - 回写飞书必须调用
bin/write_back_and_verify.py,并使用脚本内置的overwrite策略。 bin/write_back_and_verify.py会先写占位符,再通过 raw docx block API 把 mermaid 占位符替换为文本绘图 add-on(block_type=40,view=codeChart)。- 当本地包含 mermaid 代码块时,若回读仍出现
<whiteboard .../>,视为写回验证失败并中止 sync。 - agent 不得手改 frontmatter。
- agent 不得自行解析 frontmatter。
- sync commit message 与
Markdown-Pathtrailer 中的markdown_path必须是相对于 git repo root 的相对路径,不得写入绝对路径或基于当前目录的非归一化路径。 - 任何低置信合并、评论冲突、一致性审校失败、remote 漂移或写回验证失败,都要中止整次 sync。
执行顺序:
- 调用
bin/read_frontmatter_binding.py读取绑定与正文。 - 调用
bin/resolve_doc_key.py。 - 调用
bin/find_last_sync_commit.py,并直接复用上一步产出的doc_key参数。 - 调用
bin/fetch_remote_markdown.py --canonical获取远端正文,并调用bin/fetch_open_comments.py获取当前全部未解决评论。 - 做正文三方合并。
- 把评论转成 review patch。
- 调用 sub-agent 做一致性审校。
- 调用
bin/write_back_and_verify.py回写飞书并验证(含 mermaid->文本绘图 add-on 替换和 canonical 回读比对)。 - 调用
bin/resolve_all_comments.py,解决当前文档全部未解决评论。 - 调用
bin/create_sync_commit.py。
首版建链(本地已有 Markdown,远端还没有文档)必须流程:
- 调用
bin/create_bootstrap_doc.py <markdown_path> --title <title> --identity <user|bot> [--profile <appId>]创建初版飞书文档,并在脚本输出中确认auto_normalized=true且normalized_verified=true。 - 从输出中获取
doc_id/doc_url,并调用bin/write_frontmatter_binding.py写回 frontmatter 绑定;--profile必须使用输出中的effective_profile(不要继续写入无效 profile)。 - 若
create_bootstrap_doc.py返回非零或normalized_verified=false,必须中止本次 sync,不得进入收尾步骤。 - 完成后按常规流程进入
bin/create_sync_commit.py收尾。
收尾成功条件:
- 飞书 canonical 正文与最终候选正文一致。
- Mermaid 代码块在飞书中已落地为文本绘图 add-on(codeChart)。
- 当前文档全部未解决评论均已解决。
- 已创建专用 sync commit。
参考文档:
- frontmatter 受限子集:
references/frontmatter-subset.md - 安装与前置说明:
references/installation.md
What ships with it
23 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.
- agents/openai.yaml 252 B
- bin/create_bootstrap_doc.py 10 KB runs code
- bin/create_sync_commit.py 1.8 KB runs code
- bin/extract_markdown_body.py 683 B runs code
- bin/fetch_open_comments.py 899 B runs code
- bin/fetch_remote_markdown.py 2.0 KB runs code
- bin/find_last_sync_commit.py 633 B runs code
- bin/read_frontmatter_binding.py 898 B runs code
- bin/resolve_all_comments.py 1.5 KB runs code
- bin/resolve_doc_key.py 595 B runs code
- bin/write_back_and_verify.py 4.1 KB runs code
- bin/write_frontmatter_binding.py 1.5 KB runs code
- lib/__init__.py 13 B runs code
- lib/comments.py 966 B runs code
- lib/doc_binding.py 1.6 KB runs code
- lib/frontmatter.py 4.5 KB runs code
- lib/git_sync.py 5.8 KB runs code
- lib/journal.py 544 B runs code
- lib/jsonio.py 284 B runs code
- lib/lark_cli.py 2.9 KB runs code
- lib/mermaid_addons.py 17 KB runs code
- references/frontmatter-subset.md 596 B
- references/installation.md 671 B
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.
- 8d ago First seen · 67 lines · 52 tokens per session scan A 3c0331b3a742
markdown-larkdoc-sync is a skill published in the GitHub repository Piasy/lark-skills (5 stars, last pushed 4mo ago), licensed MIT. It adds 52 tokens to every session and 1,351 once invoked, about $0.0003 per session on Opus 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
orbit-notion
Open Orbit briefing skill — selected by the Orbit pipeline when Notion is the user's only connected connector, or when the user explicitly scopes their daily digest to Notion. Pulls the past 24 hours of document edits, comments, mentions, and database row changes from the user's authenticated Notion connection and…
instrument-data-to-allotrope
Convert laboratory instrument output files (PDF, CSV, Excel, TXT) to Allotrope Simple Model (ASM) JSON format or flattened 2D CSV. Use this skill when scientists need to standardize instrument data for LIMS systems, data lakes, or downstream analysis. Supports auto-detection of instrument types. Outputs include full…
baoyu-youtube-transcript
A tool for downloading the written captions, subtitles, chapter information, speaker labels, and cover image from a YouTube video using its URL or ID.
feishu
Work with Feishu or Lark bots, docs, sheets, bitables, approval flows, and OpenAPI/MCP setup without hardcoding credentials.
read
Reads URLs and PDFs by fetching source content, defaulting to concise summaries for plain read requests and clean Markdown when asked to convert, save, quote, cite, or feed downstream work. Use when users ask in any language to read, fetch, check, summarize, quote, cite, convert, or save a URL or PDF. Not for local…
overleaf-sync
A two-way connection between a local paper folder and Overleaf, a web-based LaTeX editor for writing research papers. It lets you move changes between the local files and the shared Overleaf project.