[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75MB49EP224KV3FMG3B4G4N":3,"skill-same:01M75MB49EP224KV3FMG3B4G4N":57},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":30,"commitSha":31,"skillDirectory":32,"forksCount":13,"repositoryHtmlUrl":33,"repositoryHomepageUrl":34,"ownerHtmlUrl":35,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":36,"install":37,"resources":50},"01M75MB49EP224KV3FMG3B4G4N","brain-pdf",null,"Generate a publication-quality PDF from any brain page via the gstack make-pdf binary. Strips YAML frontmatter, sanitizes emoji, applies running headers and page numbers. Brain page is always the source of truth; PDF is a rendering.","Sigmacodeat\u002FSigmabrain","Sigmacodeat","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F220578687?v=4","01M75M8ZBH9439AFP2NTF8K98S","01M75M8ZC680S4377SFWSKP0D1",0,"MIT","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Fskills\u002Fbrain-pdf\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: brain-pdf\nversion: 0.1.0\ndescription: Generate a publication-quality PDF from any brain page via the gstack make-pdf binary. Strips YAML frontmatter, sanitizes emoji, applies running headers and page numbers. Brain page is always the source of truth; PDF is a rendering.\ntriggers:\n  - \"make pdf from brain\"\n  - \"brain pdf\"\n  - \"convert brain page to pdf\"\n  - \"publish this page as pdf\"\n  - \"export brain page\"\n---\n\n# brain-pdf — Render a Brain Page to Publication-Quality PDF\n\n> **Convention:** see [conventions\u002Fquality.md](..\u002Fconventions\u002Fquality.md) for\n> output rules. The PDF is a rendering — never the primary artifact. If a\n> PDF exists, the source brain page exists behind it.\n\n## The rule\n\nThe brain page is ALWAYS the source of truth. The PDF is a rendering of\nit, never a standalone artifact. If a PDF exists somewhere, the brain\npage must exist behind it.\n\n## What this does\n\nRenders a brain page (markdown with frontmatter) into a\npublication-quality PDF using the gstack `make-pdf` binary. Output is\nsuitable for:\n\n- Sharing a personalized book mirror via email or Telegram\n- Delivering a strategic-reading playbook as a clean read\n- Producing a briefing or report with running headers and page numbers\n- Archiving a long-form essay in a portable format\n\n## Prerequisite: gstack make-pdf\n\nThis skill depends on the gstack `make-pdf` binary at:\n\n```\n$HOME\u002F.claude\u002Fskills\u002Fgstack\u002Fmake-pdf\u002Fdist\u002Fpdf\n```\n\nThe user must have gstack co-installed. If absent, the skill cannot run.\nA future v0.26+ may bundle a fallback PDF renderer; for v0.25.1 gstack\nis a soft prereq.\n\nVerify it exists before invoking:\n\n```bash\nP=\"$HOME\u002F.claude\u002Fskills\u002Fgstack\u002Fmake-pdf\u002Fdist\u002Fpdf\"\n[ -x \"$P\" ] || { echo \"make-pdf not installed; install gstack\" >&2; exit 1; }\n```\n\n## Workflow\n\n```\n1. RESOLVE  → Confirm the brain page exists (gbrain get \u003Cslug>).\n2. STRIP    → Remove YAML frontmatter — the renderer would otherwise\n              dump it as a full page of raw metadata text.\n3. RENDER   → Invoke make-pdf with sane defaults (no --cover, no --toc).\n4. DELIVER  → Hand the PDF to the requester via the agent's preferred\n              channel (do not use raw `MEDIA:` tags on Telegram —\n              they fail silently).\n```\n\n## Invocation\n\n```bash\nSLUG=\"path\u002Fto\u002Fpage\"\nP=\"$HOME\u002F.claude\u002Fskills\u002Fgstack\u002Fmake-pdf\u002Fdist\u002Fpdf\"\n\n# 1. Confirm the page exists.\ngbrain get \"$SLUG\" > \u002Fdev\u002Fnull || { echo \"Page $SLUG not found\" >&2; exit 1; }\n\n# 2. Get the raw markdown. Two paths: read from the brain repo (if user\n#    syncs locally) OR ask gbrain for the body via the API.\nBRAIN_DIR=$(gbrain config get sync.repo_path 2>\u002Fdev\u002Fnull || echo)\nif [ -n \"$BRAIN_DIR\" ] && [ -f \"$BRAIN_DIR\u002F$SLUG.md\" ]; then\n  RAW=\"$BRAIN_DIR\u002F$SLUG.md\"\nelse\n  RAW=$(mktemp \u002Ftmp\u002Fbrain-page-XXXXXX.md)\n  gbrain get \"$SLUG\" --raw > \"$RAW\"   # whatever flag exposes raw body\nfi\n\n# 3. Strip YAML frontmatter — sed: skip the opening '---' through the\n#    closing '---' (lines 1..N), then keep everything after.\nCLEAN=$(mktemp \u002Ftmp\u002Fbrain-page-clean-XXXXXX.md)\nsed '1{\u002F^---$\u002F!q}; \u002F^---$\u002F,\u002F^---$\u002Fd' \"$RAW\" > \"$CLEAN\"\n\n# 4. Render. NO --cover, NO --toc by default — they look corporate\n#    and waste space. Add them only if explicitly requested.\nOUT=\"\u002Ftmp\u002F$(basename \"$SLUG\").pdf\"\nCONTAINER=1 \"$P\" generate \"$CLEAN\" \"$OUT\"\n\necho \"Rendered: $OUT\"\n```\n\n`CONTAINER=1` is mandatory in containerized environments — it tells\nPlaywright to skip Chromium sandboxing. Harmless on bare-metal.\n\n## Common patterns\n\n```bash\n# Default — clean PDF, no cover, no TOC\nbrain-pdf \u003Cslug>\n\n# Draft watermark for in-progress work\nCONTAINER=1 \"$P\" generate --watermark DRAFT \"$CLEAN\" \"$OUT\"\n\n# Optional cover + TOC if the user explicitly asks\nCONTAINER=1 \"$P\" generate --cover --toc \"$CLEAN\" \"$OUT\"\n\n# Custom title + author override (otherwise pulled from frontmatter)\nCONTAINER=1 \"$P\" generate --title \"Custom Title\" --author \"Custom Author\" \"$CLEAN\" \"$OUT\"\n```\n\n## Defaults: NO cover, NO TOC\n\nThese flags are off by default because they look corporate and waste\nspace on most personal-knowledge content. Only add them when the user\nexplicitly asks for \"formal\" output (e.g., something they're sending to\na board or printing as a deliverable).\n\n## Font requirements\n\nThe renderer needs:\n\n- `fonts-liberation` (Helvetica\u002FArial substitute)\n- `fonts-noto-cjk` (Chinese\u002FJapanese\u002FKorean characters)\n- Minimum body font size: 10pt (page chrome 9pt)\n- Body text: 11pt\n\nIf running in an environment without these fonts, install them via the\nhost's package manager (`apt install fonts-liberation fonts-noto-cjk` on\nDebian\u002FUbuntu containers).\n\n## Delivery\n\nAfter rendering, deliver via the agent's preferred channel:\n\n- **Telegram:** use the `message` tool with `filePath=\"\u002Ftmp\u002F\u003Cslug>.pdf\"`\n  attachment. NEVER use raw `MEDIA:` tags — they fail silently.\n- **Email:** attach via the host's email tool.\n- **Direct file response:** print the PDF path; the user can pull it\n  manually.\n\nAlways include the brain page link in the delivery message so the user\ncan also see it on GitHub \u002F locally. The PDF is a rendering; the source\nis the artifact.\n\n## Anti-Patterns\n\n- ❌ Generating a PDF without first confirming the brain page exists.\n  No source = no PDF.\n- ❌ Skipping the frontmatter strip. The renderer dumps frontmatter as\n  raw text on the first page; ugly.\n- ❌ Skipping emoji sanitization. Emoji that don't map to the rendering\n  font show up as `□` boxes.\n- ❌ Adding `--cover` or `--toc` by default. Off unless asked.\n- ❌ Using raw `MEDIA:` tags for Telegram delivery. Use the `message`\n  tool with `filePath`.\n\n## Related skills\n\n- `skills\u002Fbook-mirror\u002FSKILL.md` — produces a brain page that's a\n  natural input to brain-pdf (chapter-by-chapter personalized analysis).\n- `skills\u002Fstrategic-reading\u002FSKILL.md` — same shape, problem-lens variant.\n- `skills\u002Fpublish\u002FSKILL.md` — share brain pages as password-protected\n  HTML (different rendering target).\n\n\n## Contract\n\nThis skill guarantees:\n\n- Routing matches the canonical triggers in the frontmatter.\n- Output written under the directories listed in `writes_to:` (when applicable).\n- Conventions referenced (`quality.md`, `brain-first.md`, `_brain-filing-rules.md`) are followed.\n- Privacy contract preserved: no real names, no fork-specific filesystem path literals, no upstream-fork references.\n\nThe full behavior contract is documented in the body sections above; this section exists for the conformance test.\n\n## Output Format\n\nThe skill's output shape is documented inline in the body sections above (see \"Output\", \"Brain page format\", or equivalent). The literal section header here exists for the conformance test (`test\u002Fskills-conformance.test.ts`).\n","# brain-pdf — Render a Brain Page to Publication-Quality PDF\n\n> **Convention:** see [conventions\u002Fquality.md](..\u002Fconventions\u002Fquality.md) for\n> output rules. The PDF is a rendering — never the primary artifact. If a\n> PDF exists, the source brain page exists behind it.\n\n## The rule\n\nThe brain page is ALWAYS the source of truth. The PDF is a rendering of\nit, never a standalone artifact. If a PDF exists somewhere, the brain\npage must exist behind it.\n\n## What this does\n\nRenders a brain page (markdown with frontmatter) into a\npublication-quality PDF using the gstack `make-pdf` binary. Output is\nsuitable for:\n\n- Sharing a personalized book mirror via email or Telegram\n- Delivering a strategic-reading playbook as a clean read\n- Producing a briefing or report with running headers and page numbers\n- Archiving a long-form essay in a portable format\n\n## Prerequisite: gstack make-pdf\n\nThis skill depends on the gstack `make-pdf` binary at:\n\n```\n$HOME\u002F.claude\u002Fskills\u002Fgstack\u002Fmake-pdf\u002Fdist\u002Fpdf\n```\n\nThe user must have gstack co-installed. If absent, the skill cannot run.\nA future v0.26+ may bundle a fallback PDF renderer; for v0.25.1 gstack\nis a soft prereq.\n\nVerify it exists before invoking:\n\n```bash\nP=\"$HOME\u002F.claude\u002Fskills\u002Fgstack\u002Fmake-pdf\u002Fdist\u002Fpdf\"\n[ -x \"$P\" ] || { echo \"make-pdf not installed; install gstack\" >&2; exit 1; }\n```\n\n## Workflow\n\n```\n1. RESOLVE  → Confirm the brain page exists (gbrain get \u003Cslug>).\n2. STRIP    → Remove YAML frontmatter — the renderer would otherwise\n              dump it as a full page of raw metadata text.\n3. RENDER   → Invoke make-pdf with sane defaults (no --cover, no --toc).\n4. DELIVER  → Hand the PDF to the requester via the agent's preferred\n              channel (do not use raw `MEDIA:` tags on Telegram —\n              they fail silently).\n```\n\n## Invocation\n\n```bash\nSLUG=\"path\u002Fto\u002Fpage\"\nP=\"$HOME\u002F.claude\u002Fskills\u002Fgstack\u002Fmake-pdf\u002Fdist\u002Fpdf\"\n\n# 1. Confirm the page exists.\ngbrain get \"$SLUG\" > \u002Fdev\u002Fnull || { echo \"Page $SLUG not found\" >&2; exit 1; }\n\n# 2. Get the raw markdown. Two paths: read from the brain repo (if user\n#    syncs locally) OR ask gbrain for the body via the API.\nBRAIN_DIR=$(gbrain config get sync.repo_path 2>\u002Fdev\u002Fnull || echo)\nif [ -n \"$BRAIN_DIR\" ] && [ -f \"$BRAIN_DIR\u002F$SLUG.md\" ]; then\n  RAW=\"$BRAIN_DIR\u002F$SLUG.md\"\nelse\n  RAW=$(mktemp \u002Ftmp\u002Fbrain-page-XXXXXX.md)\n  gbrain get \"$SLUG\" --raw > \"$RAW\"   # whatever flag exposes raw body\nfi\n\n# 3. Strip YAML frontmatter — sed: skip the opening '---' through the\n#    closing '---' (lines 1..N), then keep everything after.\nCLEAN=$(mktemp \u002Ftmp\u002Fbrain-page-clean-XXXXXX.md)\nsed '1{\u002F^---$\u002F!q}; \u002F^---$\u002F,\u002F^---$\u002Fd' \"$RAW\" > \"$CLEAN\"\n\n# 4. Render. NO --cover, NO --toc by default — they look corporate\n#    and waste space. Add them only if explicitly requested.\nOUT=\"\u002Ftmp\u002F$(basename \"$SLUG\").pdf\"\nCONTAINER=1 \"$P\" generate \"$CLEAN\" \"$OUT\"\n\necho \"Rendered: $OUT\"\n```\n\n`CONTAINER=1` is mandatory in containerized environments — it tells\nPlaywright to skip Chromium sandboxing. Harmless on bare-metal.\n\n## Common patterns\n\n```bash\n# Default — clean PDF, no cover, no TOC\nbrain-pdf \u003Cslug>\n\n# Draft watermark for in-progress work\nCONTAINER=1 \"$P\" generate --watermark DRAFT \"$CLEAN\" \"$OUT\"\n\n# Optional cover + TOC if the user explicitly asks\nCONTAINER=1 \"$P\" generate --cover --toc \"$CLEAN\" \"$OUT\"\n\n# Custom title + author override (otherwise pulled from frontmatter)\nCONTAINER=1 \"$P\" generate --title \"Custom Title\" --author \"Custom Author\" \"$CLEAN\" \"$OUT\"\n```\n\n## Defaults: NO cover, NO TOC\n\nThese flags are off by default because they look corporate and waste\nspace on most personal-knowledge content. Only add them when the user\nexplicitly asks for \"formal\" output (e.g., something they're sending to\na board or printing as a deliverable).\n\n## Font requirements\n\nThe renderer needs:\n\n- `fonts-liberation` (Helvetica\u002FArial substitute)\n- `fonts-noto-cjk` (Chinese\u002FJapanese\u002FKorean characters)\n- Minimum body font size: 10pt (page chrome 9pt)\n- Body text: 11pt\n\nIf running in an environment without these fonts, install them via the\nhost's package manager (`apt install fonts-liberation fonts-noto-cjk` on\nDebian\u002FUbuntu containers).\n\n## Delivery\n\nAfter rendering, deliver via the agent's preferred channel:\n\n- **Telegram:** use the `message` tool with `filePath=\"\u002Ftmp\u002F\u003Cslug>.pdf\"`\n  attachment. NEVER use raw `MEDIA:` tags — they fail silently.\n- **Email:** attach via the host's email tool.\n- **Direct file response:** print the PDF path; the user can pull it\n  manually.\n\nAlways include the brain page link in the delivery message so the user\ncan also see it on GitHub \u002F locally. The PDF is a rendering; the source\nis the artifact.\n\n## Anti-Patterns\n\n- ❌ Generating a PDF without first confirming the brain page exists.\n  No source = no PDF.\n- ❌ Skipping the frontmatter strip. The renderer dumps frontmatter as\n  raw text on the first page; ugly.\n- ❌ Skipping emoji sanitization. Emoji that don't map to the rendering\n  font show up as `□` boxes.\n- ❌ Adding `--cover` or `--toc` by default. Off unless asked.\n- ❌ Using raw `MEDIA:` tags for Telegram delivery. Use the `message`\n  tool with `filePath`.\n\n## Related skills\n\n- `skills\u002Fbook-mirror\u002FSKILL.md` — produces a brain page that's a\n  natural input to brain-pdf (chapter-by-chapter personalized analysis).\n- `skills\u002Fstrategic-reading\u002FSKILL.md` — same shape, problem-lens variant.\n- `skills\u002Fpublish\u002FSKILL.md` — share brain pages as password-protected\n  HTML (different rendering target).\n\n\n## Contract\n\nThis skill guarantees:\n\n- Routing matches the canonical triggers in the frontmatter.\n- Output written under the directories listed in `writes_to:` (when applicable).\n- Conventions referenced (`quality.md`, `brain-first.md`, `_brain-filing-rules.md`) are followed.\n- Privacy contract preserved: no real names, no fork-specific filesystem path literals, no upstream-fork references.\n\nThe full behavior contract is documented in the body sections above; this section exists for the conformance test.\n\n## Output Format\n\nThe skill's output shape is documented inline in the body sections above (see \"Output\", \"Brain page format\", or equivalent). The literal section header here exists for the conformance test (`test\u002Fskills-conformance.test.ts`).\n",{"name":5,"version":23,"triggers":24,"description":7},"0.1.0",[25,26,27,28,29],"make pdf from brain","brain pdf","convert brain page to pdf","publish this page as pdf","export brain page","main","b8e699fc7cff8641b94a51ac9d4aa599fcc03ae5","server\u002Fskills\u002Fbrain-pdf","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain","https:\u002F\u002Fsigmabrain.vercel.app","https:\u002F\u002Fgithub.com\u002FSigmacodeat","2026-07-09 09:21:55",{"source":8,"skillName":5,"commands":38,"prompt":48,"zipAvailable":49},[39,42,45],{"tool":40,"command":41},"npx","npx skills add Sigmacodeat\u002FSigmabrain --skill brain-pdf",{"tool":43,"command":44},"bunx","bunx skills add Sigmacodeat\u002FSigmabrain --skill brain-pdf",{"tool":46,"command":47},"pnpm","pnpm dlx skills add Sigmacodeat\u002FSigmabrain --skill brain-pdf","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Fskills\u002Fbrain-pdf\u002FSKILL.md",true,[51],{"path":52,"resourceType":53,"resourceTypeDesc":54,"sizeBytes":55,"sourceHtmlUrl":56},"routing-eval.jsonl","OTHER","其他",589,"https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Fskills\u002Fbrain-pdf\u002Frouting-eval.jsonl",[58,64,70,77,84,91],{"skillNo":59,"name":60,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":61,"categories":62,"keywords":63,"publishedAt":18},"01M75MW3405DES0348DPKVF20G","query-helper","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Ftest\u002Ffixtures\u002Fskill-catalog\u002Fskills\u002Fquery-helper\u002FSKILL.md",[],[],{"skillNo":65,"name":66,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":67,"categories":68,"keywords":69,"publishedAt":18},"01M75MW29T3N856QPT2SK467A3","broken","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Ftest\u002Ffixtures\u002Fskill-catalog\u002Fskills\u002Fbroken\u002FSKILL.md",[],[],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":74,"categories":75,"keywords":76,"publishedAt":18},"01M75MVZV51CX9W3Y602M0GJR9","brain-ops","Read, enrich, and write brain pages with source attribution.","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Ftest\u002Ffixtures\u002Fskill-catalog\u002Fskills\u002Fbrain-ops\u002FSKILL.md",[],[],{"skillNo":78,"name":79,"nameZh":6,"description":80,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":81,"categories":82,"keywords":83,"publishedAt":18},"01M75MVXQAQBVNQBZPKPEBPRHV","signal-detector","Always-on ambient signal capture for the OpenClaw reference fixture.","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Ftest\u002Ffixtures\u002Fopenclaw-reference-minimal\u002Fskills\u002Fsignal-detector\u002FSKILL.md",[],[],{"skillNo":85,"name":86,"nameZh":6,"description":87,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":88,"categories":89,"keywords":90,"publishedAt":18},"01M75MVWJN0EV5EFW6JMMC73XC","query","Look up brain pages in the OpenClaw reference fixture.","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Ftest\u002Ffixtures\u002Fopenclaw-reference-minimal\u002Fskills\u002Fquery\u002FSKILL.md",[],[],{"skillNo":92,"name":93,"nameZh":6,"description":94,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":95,"categories":96,"keywords":97,"publishedAt":18},"01M75MVVA7Q6PMDBTPQGT49M6M","context-now","ALWAYS-ON time-sensitivity discipline for the OpenClaw reference fixture.","https:\u002F\u002Fgithub.com\u002FSigmacodeat\u002FSigmabrain\u002Fblob\u002Fmain\u002Fserver\u002Ftest\u002Ffixtures\u002Fopenclaw-reference-minimal\u002Fskills\u002Fcontext-now\u002FSKILL.md",[],[]]