brain-pdf

Renders brain pages into publication-quality PDFs via the gstack make-pdf binary.

Updated Aug 17, 2026
One-click install
npx skills add https://github.com/AMC-JTC/gbrain-1 --skill brain-pdf-amc-jtc
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: brain-pdf
Source: https://github.com/AMC-JTC/gbrain-1/tree/main/plugin/skills/brain-pdf
Command: npx skills add https://github.com/AMC-JTC/gbrain-1 --skill brain-pdf-amc-jtc

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Turning a markdown brain page into a shareable, polished PDF normally requires manual cleanup of frontmatter, emoji, and layout. This Skill automates that rendering pipeline so a brain page can be delivered as a clean document with running headers and page numbers. ## Core Features & Use Cases - Frontmatter stripping and sanitization: Removes YAML frontmatter and sanitizes emoji before rendering so the PDF contains only clean body content. - Opinionated defaults: Renders without cover pages or tables of contents unless explicitly requested, with support for draft watermarks and custom title/author overrides. - Multi-channel delivery: Delivers the finished PDF via Telegram message attachments, email, or direct file paths, always linking back to the source brain page. - Use Case: After generating a personalized book mirror or strategic-reading playbook as a brain page, convert it to a clean PDF and send it to a recipient via Telegram in one flow. ## Quick Start Convert the brain page at slug media/books/this-book-personalized into a PDF and send it to me.

Frequently Asked Questions about brain-pdf

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I convert a markdown brain page to PDF?

Confirm the page exists with gbrain get, strip the YAML frontmatter with sed, then run the gstack make-pdf binary on the cleaned markdown. The output PDF is written to /tmp and delivered via your preferred channel.

How to add a draft watermark to a generated PDF?

Pass the --watermark DRAFT flag to the make-pdf generate command. Cover pages and tables of contents remain off by default and are only added with --cover and --toc when explicitly requested.

Does brain-pdf work without gstack installed?

No. The skill depends on the gstack make-pdf binary at $HOME/.claude/skills/gstack/make-pdf/dist/pdf and exits with an error if it is missing. A bundled fallback renderer is only planned for a future version.

Why do emoji show as boxes in the rendered PDF?

Emoji render as empty boxes when the rendering fonts lack glyph mappings. Install fonts-liberation and fonts-noto-cjk, and follow the skill's emoji sanitization step before rendering.

Why does the PDF's first page show raw YAML metadata?

This happens when frontmatter stripping is skipped. The renderer dumps the YAML block as plain text, so the skill always removes the opening and closing --- delimiters with sed before invoking make-pdf.