agentsclimarketplace

Pdf word converter

Skill publisher-skill/claude-skill/skills/pdf_word_converter

PDF与Word文档相互转换的skill,支持PDF转Word、Word转PDFFrom its SKILL.md

Install
npx -y skills add publisher-skill/claude-skill --skill pdf_word_converter

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

1.8 KB, 547 tokens by cl100k_base, as published. Nobody here has run it

PDF-Word Converter Skill

PDF与Word文档相互转换工具。

功能特性

  • PDF转Word (.pdf -> .docx)
  • Word转PDF (.docx/.doc -> .pdf)
  • 批量转换文件夹
  • 保留原始格式
  • 命令行支持

安装依赖

pip install pdf2docx docx2pdf python-docx

注意:Word转PDF需要Microsoft Word (Windows) 或 LibreOffice (Linux/Mac)。

使用方法

Python API

from claude_skills.pdf_word_converter import PdfWordConverter

converter = PdfWordConverter()

# PDF转Word
converter.pdf_to_word("input.pdf", "output.docx")

# Word转PDF
converter.word_to_pdf("input.docx", "output.pdf")

# 批量转换文件夹
converter.convert_folder("input_dir", "output_dir", "pdf2word")

命令行使用

# PDF转Word
python converter.py pdf2word input.pdf output.docx

# Word转PDF
python converter.py word2pdf input.docx output.pdf

# 批量转换
python converter.py folder input_dir output_dir --mode pdf2word

API 参考

PdfWordConverter类

__init__()

初始化转换器。

pdf_to_word(pdf_path, docx_path, start=0, end=None)

将PDF转换为Word文档。

参数:

  • pdf_path (str): 输入PDF文件路径
  • docx_path (str): 输出Word文件路径
  • start (int, optional): 起始页码(从0开始)
  • end (int, optional): 结束页码

word_to_pdf(docx_path, pdf_path)

将Word文档转换为PDF。

参数:

  • docx_path (str): 输入Word文件路径
  • pdf_path (str): 输出PDF文件路径

convert_folder(input_dir, output_dir, mode)

批量转换文件夹中的文档。

参数:

  • input_dir (str): 输入文件夹路径
  • output_dir (str): 输出文件夹路径
  • mode (str): 转换模式,'pdf2word' 或 'word2pdf'

What ships with it: 6 files

13.8 KB alongside SKILL.md, 4 of them executable

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.