SuperAPI AI Directory

soia-pkm-transform-obsidian-pdf

Office & productivity

View repository

Updated 10-16 08:40

About this skill

soia-pkm-transform-obsidian-pdf

Export archived or specified Markdown/vault articles to PDF, outputting to the same directory as the source file (or a user-specified directory).

It is the soia-pkm-transform PDF branch's standalone skill, connecting with clip-* .

Customer-readable description

What this skill can do

Export Markdown articles or archived vault notes to PDF, using Obsidian's native export (Creator: Chromium / Producer: Skia/PDF) to ensure correct Chinese rendering.

Customer wants Skill will do Customer can see
Complete the work covered by this skill Read the article, invoke Obsidian export or fall back to local rendering PDF path, page count, file size
Missing Obsidian / vault Suggest fallback options (pandoc / weasyprint) Fallback explanation and commands
Execution complete Verify the PDF opens and the page count is reasonable Completion receipt + verification result

How the customer uses it

  1. Specify the source: archived note path in the vault / X URL / web URL / local Markdown.
  2. Optional: specify the output directory (defaults to the same directory as the source file).
  3. For URL sources, first go through soia-pkm-clip-* archiving, then perform the PDF export.

Dependencies and installation

Install this skill:

npx skills add soia-team/soia-open-skills -g -a '*' -s soia-pkm-transform-obsidian-pdf -y
  • Hard dependencies: Obsidian (for articles in the vault) or pandoc/weasyprint (fallback outside the vault)
  • Optional:pdfinfo、pdftoppm(for acceptance)

Logs and completion receipt

完成:<一句话说明>。

日志摘要:
- source: <路径或 URL>
- provider: obsidian-native | pandoc | weasyprint
- output: <PDF 完整路径>
- pages: <页数>
- size: <文件大小>

验证:
- pdfinfo 确认页数、Creator、Producer
- 必要时渲染首页确认中文正常

问题与下一步:
- <无 / 降级原因 / 建议>

Boundaries

  • Source is a URL → first call soia-pkm-clip-* to archive as vault Markdown, then export PDF.
  • Source is local Markdown and not in the vault → fall back: pandoc → weasyprint → report failure.
  • No content rewriting, only format conversion (preserve mode).
  • The output directory defaults to the same directory as the source file; articles outside the vault are output to outputs/transform/<YYYY>/<stem>/。

Workflow

  1. Confirm the source (in vault / URL / local file).
  2. URL → soia-pkm-clip-* → get the vault Markdown path.
  3. Article in vault → open via Obsidian URI → File > 导出 PDF(osascript automation, refer to references/provider-soia-local.md)。
  4. Confirm the save path, move to the target directory.
  5. Acceptance:pdfinfo confirm page count > 0, Creator/Producer, file is non-empty; if necessary, render the first page to visually check Chinese.
  6. Receipt.

Acceptance gates (excerpted from quality-gates.md)

  • File exists and is non-empty (> 10KB)
  • pdfinfo readable, Pages ≥ 1
  • Creator: Chromium or Producer: Skia/PDF (Obsidian export markers)
  • First page visual check: Chinese renders correctly, no garbled text, no all-black page

See references/quality-gates.md。 references/provider-soia-local.md。