render-pdf-doc

render-pdf-doc is a skill for Claude Code from Aperivue/medsci-skills. It costs 138 tokens per session (2,719 once invoked), scanned B, original, MIT.

A tool for turning academic Markdown documents into publication-quality PDFs using Pandoc and XeLaTeX. It covers documents such as research proposals, briefing handouts, IRB materials, and reference tables.

In plain words
What is it for?
Use it to render English or Korean non-bibliography documents into PDFs with controlled tables and page layout.
Why use it?
It handles layout problems that commonly make academic PDFs hard to read, including multilingual fonts and badly sized table columns.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter; reads .claude/ paths.

Part of the medsci-presentation plugin — 5 skills shipped together

Good fit Use it to render English or Korean non-bibliography documents into PDFs with controlled tables and page layout.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/aperivue/medsci-skills/render-pdf-doc
Install

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.

Any agent
npx skills add Aperivue/medsci-skills --skill render-pdf-doc
Clone the repo
git clone --depth 1 https://github.com/Aperivue/medsci-skills

Made for: Claude Code.

Or install medsci-presentation, the plugin that ships this one along with the rest of its 5 skills.

Wrote 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.

agentmods badge for render-pdf-doc

README.md
[![agentmods](https://agentmods.dev/badge/skills/aperivue/medsci-skills/render-pdf-doc/github.svg)](https://agentmods.dev/skills/aperivue/medsci-skills/render-pdf-doc)
Your own site
<a href="https://agentmods.dev/skills/aperivue/medsci-skills/render-pdf-doc"><img src="https://agentmods.dev/badge/skills/aperivue/medsci-skills/render-pdf-doc/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.

agentmods 80×15 button for render-pdf-doc

Your own site · 80×15
<a href="https://agentmods.dev/skills/aperivue/medsci-skills/render-pdf-doc"><img src="https://agentmods.dev/badge/skills/aperivue/medsci-skills/render-pdf-doc.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 138 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,719 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Privilege Escalation · line 56
    Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
    Fix: Avoid sudo/root unless strictly required. Prefer least-privilege patterns. If elevation is needed, document the justification and scope.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00138 $0.02719
Opus 5 $0.00069 $0.01359
Sonnet 5 $0.00028 $0.00544
Haiku 4.5 $0.00014 $0.00272

Measured 3d ago against content hash cb3856e4b0ae, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade B, and why

render-pdf-doc scanned grade B with 1 finding 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 3d ago.

The scan reads SKILL.md. This mod also ships 7 executable files (scripts/check_deps.sh, scripts/infer_colwidths.py, scripts/render_pdf.sh, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

sudo apt-get install pandoc texlive-xetex texlive-lang-cjk fonts-noto-cjk
skills/render-pdf-doc/SKILL.md · 220 lines

How it starts

The opening of the file, as written. The whole thing — 220 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Render-PDF-Doc Skill

Markdown + frontmatter → publication-quality academic PDF (English or Korean).

Why This Skill Exists

In real circulation cycles for academic PDFs, two recurring failure patterns appear:

  1. v1 drafts: change-history, version numbers, and PI attribution leak into the attached PDF, confusing the first recipient.
  2. v2 drafts: pandoc pipe-table dash ratios are misjudged, narrowing the first column and forcing label wrapping that hurts readability.

Manual fixes work but the same pattern recurs across proposals, briefings, IRB covers, exemption applications. This skill focuses on layout (CJK fonts + table column widths). Bibliography and CSL are handled by /manage-refs.

Boundary (separation from other skills)

Task Skill
Manuscript + bibliography → DOCX/PDF /manage-refs scripts/render_pandoc.sh (CSL + .bib)
Filling an institutional .docx form /fill-protocol
ICMJE COI form /fill-icmje-coi
Figure / PPTX /make-figures, /present-paper
This skill: non-bib academic markdown → PDF (proposal, briefing, anchor doc, IRB cover) /render-pdf-doc

Core Principles

  1. Pipe table column widths must be inferred from content. No equal splitting. Size the first column (label) to the longest label, and distribute the remaining width content-proportionally across the data columns.
  2. Set the CJK font explicitlymainfont + CJKmainfont. The default fallback is OS-detected.
  3. For circulation PDFs, remove change history / version numbers / PI attribution (or split them into a supplementary). Use the frontmatter redact_internal: true option.
  4. No Quarto dependency — raw pandoc + xelatex. Quarto's tbl-colwidths has reported PDF regressions (issues 6089/9200).

Dependencies

Python 3 is required by the wrapper. FontTools is optional for the font-file coverage check (python3 -m pip install fonttools).

# macOS
brew install pandoc
brew install --cask mactex-no-gui          # xelatex + xeCJK (~5 GB)

# Linux
sudo apt-get install pandoc texlive-xetex texlive-lang-cjk fonts-noto-cjk

# Windows (PowerShell) — run in Git Bash afterwards
winget install --id JohnMacFarlane.Pandoc
winget install --id MiKTeX.MiKTeX          # xelatex; installs missing LaTeX packages on demand
# No CJK font download needed: Malgun Gothic ships with Windows 7+ and is the default here.

Read the full file on GitHub · 220 lines

Changes

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.

  1. 3d ago Changed · +23 lines cb3856e4b0ae
  2. 9d ago First seen · 197 lines · 138 tokens per session scan B 97af21fac95a

Subscribe to this mod's changes

render-pdf-doc is a skill published in the GitHub repository Aperivue/medsci-skills (290 stars, last pushed yesterday), licensed MIT. It adds 138 tokens to every session and 2,719 once invoked, about $0.0007 per session on Opus 5. A static security scan graded it B with 1 finding (asks for root). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

lit-pdf-zotero

A research workflow for finding academic papers, downloading their PDFs, adding them to Zotero, and creating visual summaries. Zotero is a tool for organising references and research papers.

qiaomiaojoe/ai-academic-workflow · 181 tokens

liteparse

Local document and PDF parsing that returns spatial text with bounding boxes. Use for extracting text from PDFs, DOCX, Office files, and images; running OCR on scans; producing layout-preserved JSON for RAG; batch-ingesting folders of papers; or rendering pages to PNG for multimodal agents. Distinguishing capabilities…

K-Dense-AI/scientific-agent-skills · 86 tokens

markitdown

Convert heterogeneous documents and selected URIs to Markdown with Microsoft MarkItDown for text analysis, search, and LLM/RAG ingestion. Covers safe local conversion, streams, Office/PDF/data formats, batch workflows, plugins, vision OCR, Azure extraction, and the official MCP server.

K-Dense-AI/scientific-agent-skills · 61 tokens

open-notebook

Self-hosted, open-source alternative to Google NotebookLM for AI-powered research and document analysis. Use when organizing research materials into notebooks, ingesting diverse content sources (PDFs, videos, audio, web pages, Office documents), generating AI-powered notes and summaries, creating multi-speaker…

K-Dense-AI/scientific-agent-skills · 123 tokens

pptx-posters

Create and audit editable scientific posters in macro-free PowerPoint (.pptx) from author-approved local content and assets. Use when the requested deliverable is a PowerPoint research/conference poster and exact physical, printer, accessibility, provenance, and package-security checks are required.

K-Dense-AI/scientific-agent-skills · 59 tokens

pdf

Use 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 PDFs into one, splitting PDFs apart, rotating pages, adding watermarks, creating new PDFs, filling PDF forms, encrypting/decrypting PDFs, extracting images, and…

K-Dense-AI/scientific-agent-skills · 92 tokens