Token导航 LogoToken导航

Agent Skill · 研究检索

pdf-generator(PDF 生成器)

pdf-generator 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

pdf-generator 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为操作浏览器;许可证为 MIT,暂无第三方扫描结果,按安装量在研究检索类的 73,675 个 Skill 里排第 8,502。

总安装 16,216周安装 390GitHub Stars 公开资料未说明下载 2,814核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:pdf-generator(PDF 生成器)
来源仓库:https://github.com/eddiebe147/claude-settings
仓库路径:skills/pdf-generator
安装命令:
npx skills add eddiebe147/claude-settings --skill "pdf-generator"
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

AgentSkills.tonpx skills
npx skills add eddiebe147/claude-settings --skill "pdf-generator"

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

发现并推荐适用于 Claude Code 生态系统的技能插件资源。适合在 Codex、Claude、Cursor 等宿主环境中快速增强自动化能力。通过 npx 命令一键安装社区贡献的各类实用技能模块。使用前请评估技能维护频率与安全审计情况,防范潜在风险。

部分技能可能需要 API 密钥或其他认证配置,请参照 README 操作。

来源仓库内路径:skills/pdf-generator

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add eddiebe147/claude-settings --skill "pdf-generator";命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要操作浏览器,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

pdf-generator 怎么安装?

在终端执行 npx skills add eddiebe147/claude-settings --skill "pdf-generator"。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

pdf-generator 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

pdf-generator 需要什么权限?

权限级别是操作浏览器。该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

pdf-generator 是免费的吗?

来源标注的许可证是 MIT。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

pdf-generator 用的人多吗?

公开数据是累计安装 16,216 次,近一周安装 390 次,下载 2,814 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

pdf-generator 安全吗?

没有查到第三方扫描结果,安全性无法从公开资料判断,安装前请自行审查源码、依赖和命令行为。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 许可证明确为 MIT,商用和分发边界好判断。

先想清楚的地方

  • 没有第三方扫描结果,安全性只能靠自己读源码判断。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 要求有安全扫描结论才肯安装的团队。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
pdf-generator

PDF 生成器 · 本页

16,216—操作浏览器MIT未收录

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

name
PDF Generator
slug
pdf-generator
description
Create and manipulate professional PDF documents with formatting, images, and metadata
category
document-creation
complexity
complex
version
1.0.0
author
ID8Labs
triggers
tags

PDF Generator

The PDF Generator skill enables creation of professional PDF documents from various sources including Markdown, HTML, plain text, and structured data. It handles formatting, images, metadata, watermarks, and multi-page layouts. This skill leverages Node.js libraries like puppeteer, pdfkit, or jsPDF for comprehensive PDF generation capabilities.

Whether you need to convert documentation to PDF, generate reports with charts, create printable forms, or produce client deliverables, this skill provides the tools and workflows to create publication-quality PDFs programmatically.

Core Workflows

Workflow 1: Convert Markdown to PDF

Purpose: Transform Markdown files into formatted PDF documents with styling

Steps:

  1. Read the source Markdown file
  2. Parse Markdown to HTML using a library like marked
  3. Apply CSS styling for professional appearance
  4. Use Puppeteer to render HTML as PDF with proper page breaks
  5. Add metadata (title, author, creation date)
  6. Save to specified output path

Implementation:

const puppeteer = require('puppeteer');
const marked = require('marked');
const fs = require('fs');

async function markdownToPdf(mdPath, outputPath, options = {}) {
  const markdown = fs.readFileSync(mdPath, 'utf8');
  const html = marked.parse(markdown);

  const styledHtml = `
    <!DOCTYPE html>
    <html>
    <head>
      <style>
        body { font-family: 'Helvetica', sans-serif; margin: 40px; line-height: 1.6; }
        h1 { color: #2c3e50; border-bottom: 2px solid #3498db; padding-bottom: 10px; }
        h2 { color: #34495e; margin-top: 30px; }
        code { background: #f4f4f4; padding: 2px 6px; border-radius: 3px; }
        pre { background: #f4f4f4; padding: 15px; border-radius: 5px; overflow-x: auto; }
        blockquote { border-left: 4px solid #3498db; padding-left: 20px; color: #7f8c8d; }
      </style>
    </head>
    <body>${html}</body>
    </html>
  `;

  const browser = await puppeteer.launch();
  const page = await browser.newPage();
  await page.setContent(styledHtml);
  await page.pdf({
    path: outputPath,
    format: 'A4',
    margin: { top: '20mm', right: '20mm', bottom: '20mm', left: '20mm' },
    printBackground: true,
    ...options
  });
  await browser.close();
}

Workflow 2: Generate Multi-Page PDF Report

Purpose: Create structured reports with headers, footers, page numbers, and sections

Steps:

  1. Define report structure (cover page, TOC, sections, appendix)
  2. Create PDFKit document instance
  3. Add cover page with title, logo, date
  4. Generate table of contents with page references
  5. Add sections with consistent formatting
  6. Include headers and footers on each page
  7. Add page numbers and finalize

Implementation:

const PDFDocument = require('pdfkit');
const fs = require('fs');

function generateReport(data, outputPath) {
  const doc = new PDFDocument({
    size: 'A4',
    margins: { top: 50, bottom: 50, left: 50, right: 50 }
  });

  const stream = fs.createWriteStream(outputPath);
  doc.pipe(stream);

  // Cover page
  doc.fontSize(28)
     .text(data.title, { align: 'center' })
     .moveDown(2)
     .fontSize(14)
     .text(`Generated: ${new Date().toLocaleDateString()}`, { align: 'center' });

  doc.addPage();

  // Table of contents
  doc.fontSize(20).text('Table of Contents', { underline: true });
  doc.moveDown();
  data.sections.forEach((section, idx) => {
    doc.fontSize(12)
       .fillColor('blue')
       .text(`${idx + 1}. ${section.title}`, { link: `#section${idx}` })
       .fillColor('black');
  });

  // Sections
  data.sections.forEach((section, idx) => {
    doc.addPage();
    doc.fontSize(18)
       .fillColor('black')
       .text(section.title, { destination: `section${idx}` });
    doc.moveDown();
    doc.fontSize(11).text(section.content, { align: 'justify' });
  });

  // Add page numbers
  const pages = doc.bufferedPageRange();
  for (let i = 0; i < pages.count; i++) {
    doc.switchToPage(i);
    doc.fontSize(10)
       .text(`Page ${i + 1} of ${pages.count}`,
             50, doc.page.height - 50,
             { align: 'center' });
  }

  doc.end();
}

Workflow 3: Batch Convert HTML to PDF

Purpose: Convert multiple HTML files to PDFs in a single operation

Steps:

  1. Scan directory for HTML files or accept file list
  2. Set up Puppeteer browser instance (reuse for efficiency)
  3. For each HTML file:

- Load HTML content - Apply standard styling - Render to PDF with consistent settings - Save with corresponding filename

  1. Close browser and report results

Workflow 4: Add Watermark to Existing PDF

Purpose: Apply text or image watermarks to PDF documents

Steps:

  1. Load existing PDF using pdf-lib
  2. Get all pages
  3. For each page:

- Draw watermark text (diagonal, semi-transparent) - OR overlay watermark image

  1. Save modified PDF
  2. Preserve original metadata

Implementation:

const { PDFDocument, rgb, degrees } = require('pdf-lib');
const fs = require('fs');

async function addWatermark(inputPath, outputPath, watermarkText) {
  const existingPdfBytes = fs.readFileSync(inputPath);
  const pdfDoc = await PDFDocument.load(existingPdfBytes);
  const pages = pdfDoc.getPages();

  pages.forEach(page => {
    const { width, height } = page.getSize();
    page.drawText(watermarkText, {
      x: width / 2 - 100,
      y: height / 2,
      size: 48,
      color: rgb(0.75, 0.75, 0.75),
      opacity: 0.3,
      rotate: degrees(-45)
    });
  });

  const pdfBytes = await pdfDoc.save();
  fs.writeFileSync(outputPath, pdfBytes);
}

Workflow 5: Merge Multiple PDFs

Purpose: Combine multiple PDF documents into a single file

Steps:

  1. Create new PDF document
  2. Load each source PDF
  3. Copy all pages from each source
  4. Append to new document
  5. Save merged PDF with combined metadata

Quick Reference

ActionCommand/Trigger
Convert Markdown to PDF"convert [file.md] to pdf"
Generate report from data"create pdf report from [data]"
Batch convert HTML"convert all html files to pdf"
Add watermark"add watermark [text] to [file.pdf]"
Merge PDFs"merge [file1.pdf] and [file2.pdf]"
Extract pages"extract pages 1-5 from [file.pdf]"
Compress PDF"compress [file.pdf]"
Add metadata"set pdf metadata for [file.pdf]"

Best Practices

  • Page Sizing: Always specify format ('A4', 'Letter') and orientation for consistency
  • Margins: Use minimum 15mm margins for printability
  • Fonts: Embed fonts or use standard PDF fonts (Helvetica, Times, Courier) for compatibility
  • Images: Compress images before embedding to reduce file size
  • File Size: Monitor PDF size; use compression for files over 5MB
  • Accessibility: Include document structure tags for screen readers when possible
  • Metadata: Always set title, author, and creation date metadata
  • Page Breaks: Use CSS page-break-before or page-break-after for controlled pagination
  • Testing: Test PDFs in multiple viewers (Adobe, Preview, browsers)
  • Security: Offer password protection and permission settings for sensitive documents
  • Validation: Verify PDF/A compliance if archival quality is required
  • Batch Operations: Reuse browser instances when converting multiple files

Common Patterns

Documentation Export:

// Convert project README to PDF with styling
await markdownToPdf('./README.md', './docs/README.pdf', {
  headerTemplate: '<div style="font-size:10px; text-align:center;">Project Documentation</div>',
  footerTemplate: '<div style="font-size:10px; text-align:center;">Page <span class="pageNumber"></span></div>',
  displayHeaderFooter: true
});

Invoice Generation:

// Create PDF invoice from template
const doc = new PDFDocument();
doc.pipe(fs.createWriteStream('invoice.pdf'));
doc.fontSize(20).text('INVOICE', { align: 'center' });
doc.fontSize(12).text(`Invoice #: ${invoiceNumber}`);
doc.text(`Date: ${date}`);
// ... add line items, totals, etc.
doc.end();

Dependencies

Install required packages:

npm install puppeteer pdfkit pdf-lib marked

Error Handling

  • File Not Found: Verify source file paths before processing
  • Memory Issues: For large PDFs, use streaming and chunk processing
  • Font Errors: Fallback to standard fonts if custom fonts fail to load
  • Rendering Timeout: Increase Puppeteer timeout for complex pages
  • Permissions: Handle read/write permission errors gracefully

Performance Tips

  • Reuse Puppeteer browser instances for batch operations
  • Use PDF compression for files with many images
  • Cache rendered HTML for repeated conversions
  • Process large PDFs page-by-page rather than loading entirely into memory
  • Use worker threads for parallel PDF generation

平台分布

Claude Code

30.84%
按下载量换算868

OpenCode

20.99%
按下载量换算591

Gemini CLI

15.81%
按下载量换算445

Antigravity

11.43%
按下载量换算322

Cursor

7.23%
按下载量换算203

windsurf

3.31%
按下载量换算93

安全审计

暂无安全审计结果可展示。

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills