lov-any2pdf
БесплатноЗапускает вложенные скриптыНе проверенConvert Markdown to polished PDF with CJK typography, code, tables, images, covers, TOC, bookmarks, and reading themes. Trigger on md2pdf, Chinese report…
Об этом скилле
PDF大师 · PDF Master
This skill converts any Markdown file into a publication-quality PDF using Python's reportlab library. It was developed through extensive iteration on real Chinese technical reports and solves several hard problems that naive MD→PDF converters get wrong.
Triggers
Activate when
- User wants to convert
.md→.pdf - User has a markdown report/document and wants professional typesetting
- Document contains CJK characters (Chinese/Japanese/Korean) mixed with Latin text
- Document has fenced code blocks, markdown tables, or nested lists
- Document has local/remote images, Obsidian callouts, emoji, or math formulas
- User wants a cover page, table of contents, or watermark in their PDF
Do not activate when
- The user only wants to revise Markdown content and does not need a PDF output.
- The source is HTML, DOCX, or another format and the user has not authorized a Markdown conversion step.
- The user needs a slide deck, editable Word document, or image export rather than a PDF.
Quick Start
python md2pdf/scripts/md2pdf.py \
--input report.md \
--output report.pdf \
--title "My Report" \
--author "Author Name"
All parameters except --input are optional. When no theme is supplied, the
renderer selects one from the document's content and structure.
Configuration Resolution (MANDATORY)
Do not present a full configuration form before every conversion. Resolve each setting independently in this order:
- the user's explicit instruction in the current request, then CLI arguments or document frontmatter;
- the user's last explicitly confirmed value from the
lov_any2pdfpreference namespace; - a content-aware decision for the theme, or the documented safe default for non-visual settings.
Proceed without asking when this resolves the conversion. Ask at most one concise question only when an unresolved choice would materially change the result, such as a missing local asset path or permission to generate a new image. Do not ask the user to choose from every theme unless they explicitly request the theme catalog.
After the user explicitly confirms or changes a reusable parameter, record that value as the latest preference. Reuse it next time when the user is silent. Never persist an inferred value as though the user confirmed it, and honor requests to reset or ignore saved preferences.
Reusable parameters include theme, cover/TOC, page size, frontispiece mode, watermark text and geometry, image-cover mode, back-cover mode/banner, disclaimer, copyright, header, and footer. Revalidate saved file paths before use; if an asset no longer exists, ask for a replacement instead of silently substituting one.
Content-Aware Theme Decision
When neither the current request nor the saved preferences specify a theme, read the title, opening, headings, document length, code blocks, tables, imagery, and publishing context, then select the theme that best serves the article. The following are decision cues, not a fixed keyword router:
| Content character | Good starting theme |
|---|---|
| Long Chinese prose, knowledge notes, dense tables | songti-reading |
| Strategy, business, market, or research report | consulting-navy |
| Academic paper with abstract/method/results/references | ieee-journal or classic-thesis |
| Code-heavy technical guide or API documentation | github-light |
| Data narrative with charts and metrics | tufte |
| Literary, art, photography, or design essay | ink-wash |
| Formal Chinese policy or institutional document | chinese-red |
| Neutral English prose or print-first document | paper-classic |
warm-academic remains available when its tone genuinely fits the article, but it
is never the default merely because the user omitted a style.
Mapping User Choices to CLI Args
| Choice | CLI arg |
|---|---|
| Design style | --theme with value from table below (latex-clean uses pandoc engine) |
| Frontispiece local | --frontispiece <path> |
| Frontispiece AI | Generate image first, then --frontispiece /tmp/frontispiece.png |
| Watermark text | --watermark "文字" |
| Watermark style | --wm-size 30 --wm-opacity 0.1 --wm-angle 45 (all optional) |
| Image as cover | --image-cover true (requires --frontispiece) |
| Back cover image | --banner <path> |
| Back cover text | --disclaimer "声明" and/or --copyright "© 信息" |
Theme Name Mapping
| Style | --theme value |
Inspiration |
|---|---|---|
| 暖学术 | warm-academic |
Warm editorial-academic palette |
| 经典论文 | classic-thesis |
LaTeX classicthesis |
| Tufte | tufte |
Edward Tufte's books |
| 期刊蓝 | ieee-journal |
IEEE journal format |
| 精装书 | elegant-book |
LaTeX ElegantBook |
| 中国红 | chinese-red |
Chinese formal documents |
| 水墨 | ink-wash |
水墨画 / ink wash painting |
| GitHub | github-light |
GitHub Markdown style |
| Nord | nord-frost |
Nord color scheme |
| 海洋 |
Установить lov-any2pdf в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл lov-any2pdf?
Convert Markdown to polished PDF with CJK typography, code, tables, images, covers, TOC, bookmarks, and reading themes. Trigger on md2pdf, Chinese report typesetting, or print-ready PDF requests.
Как установить скилл lov-any2pdf?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл lov-any2pdf запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
docx
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include…
от AnthropicUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple…
от Anthropicxlsx
Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing…
от Anthropicpptx
Use this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or…
от Anthropic