Document Processing Capabilities of Claude Skills: The Complete Guide

Claude Skills provide reusable skill packages that enable end-to-end document processing for DOCX, PDF, XLSX, and PPTX formats, supporting content extraction, creation, editing, tracked changes, and validation through tools like pandoc, pypdf, openpyxl, and python-pptx.

The ComposioHQ/awesome-claude-skills repository exposes four distinct document skills that transform how Claude handles office documents. These skills encapsulate decision-tree workflows for reading, creating, and editing files while preserving formatting and metadata. Each skill provides self-contained documentation in SKILL.md files along with supporting Python scripts for low-level XML manipulation and validation.

DOCX Processing: Word Documents and Tracked Changes

The DOCX skill, documented in document-skills/docx/SKILL.md, provides comprehensive tools for working with Word documents at both high and low levels.

Extracting Content with Pandoc

Claude can convert DOCX files to markdown while preserving tracked changes using pandoc. This maintains revision history during content extraction.


# Convert to markdown with all tracked changes kept

pandoc --track-changes=all contract.docx -o contract.md

Source: The conversion workflow is defined in document-skills/docx/SKILL.md.

Creating New Documents

For generating new Word documents, the skill leverages docx-js (JavaScript/TypeScript) to build documents programmatically. This library constructs Document objects with Paragraph and TextRun elements, then serializes them via Packer.toBuffer().

Editing and Redlining Workflows

The "Redlining workflow" enables Claude to insert tracked changes directly into OOXML markup. This involves unpacking the DOCX archive, inserting <w:ins> and <w:del> tags with proper RSIDs (Revision Save IDs), and repacking the archive.

import xml.etree.ElementTree as ET
import subprocess
import pathlib

# Unpack the DOCX to access raw XML

subprocess.run(["python", "document-skills/docx/ooxml/scripts/unpack.py", "draft.docx", "tmp"])

# Load document.xml for editing

doc_xml = pathlib.Path("tmp/word/document.xml")
tree = ET.parse(doc_xml)
root = tree.getroot()

# Insert tracked change markup around specific text

ns = "{http://schemas.openxmlformats.org/wordprocessingml/2006/main}"
for run in root.iter(f"{ns}t"):
    if run.text == "30":
        parent = run.getparent()
        del_elem = ET.Element(f"{ns}del")
        ins_elem = ET.Element(f"{ns}ins")
        del_elem.append(parent)
        ins_elem.text = "60"
        parent.addnext(ins_elem)
        parent.addprevious(del_elem)

# Save and repack

tree.write(doc_xml, xml_declaration=True, encoding="utf-8")
subprocess.run(["python", "document-skills/docx/ooxml/scripts/pack.py", "tmp", "reviewed.docx"])

The high-level Document Python library (document-skills/docx/scripts/document.py) also handles insertions, deletions, and comment handling without manual XML manipulation.

PDF Processing: Text Extraction and Form Handling

The PDF skill in document-skills/pdf/SKILL.md supports both static content manipulation and interactive form operations.

Reading and Layout-Aware Extraction

Claude uses pypdf (PdfReader) to extract raw text via page.extract_text(). For layout-aware extraction preserving document structure, the skill employs pdfplumber.

Merging, Splitting, and Modifying

The pypdf library enables page-level operations including merging multiple documents, rotating pages, and adding watermarks.

from pypdf import PdfReader, PdfWriter

# Merge three PDFs into one

writer = PdfWriter()
for fname in ["intro.pdf", "chapter1.pdf", "appendix.pdf"]:
    reader = PdfReader(fname)
    for page in reader.pages:
        writer.add_page(page)

with open("full_document.pdf", "wb") as out:
    writer.write(out)

Interactive Form Creation and Filling

The skill provides full support for PDF AcroForms. Claude can read field definitions using extract_form_field_info.py and fill values using fill_fillable_fields.py.

from pypdf import PdfReader, PdfWriter

reader = PdfReader("application_form.pdf")
writer = PdfWriter()
writer.append_pages_from_reader(reader)

# Update form fields on first page

page = writer.pages[0]
page.update_page_form_field_values({"name": "Alice", "date": "2026-07-28"})

with open("filled_form.pdf", "wb") as f:
    writer.write(f)

XLSX Processing: Excel Workbooks and Formula Validation

The XLSX skill (document-skills/xlsx/SKILL.md) handles spreadsheet data analysis and validation through pandas and openpyxl integration.

Data Extraction with Pandas

Claude loads Excel data into DataFrames using pd.read_excel for analysis, or uses openpyxl (load_workbook(..., data_only=True)) to read calculated values rather than formulas.

Workbook Creation and Styling

New workbooks are constructed using openpyxl with full support for cell styling, formulas, and data validation.

from openpyxl import Workbook
from openpyxl.styles import Font, PatternFill, Alignment

wb = Workbook()
ws = wb.active
ws.title = "Summary"

# Add data and formulas

ws["A1"] = "Revenue"
ws["B1"] = "=SUM(B2:B10)"
ws["A2"] = "Q1"
ws["B2"] = 120_000

# Apply styling

ws["A1"].font = Font(bold=True, color="FF0000")
ws["A1"].fill = PatternFill("solid", start_color="FFFF00")
ws["A1"].alignment = Alignment(horizontal="center")

wb.save("financial_model.xlsx")

Formula Recalculation and Error Detection

The recalc.py script automates LibreOffice-based recalculation to detect formula errors like #REF! or #DIV/0!.

python document-skills/xlsx/recalc.py financial_model.xlsx 30

The script returns JSON output:

{
  "status": "errors_found",
  "total_errors": 2,
  "error_summary": {
    "#REF!": { "count": 2, "locations": ["Sheet1!B5", "Sheet1!C10"] }
  }
}

PPTX Processing: PowerPoint Presentations

The PPTX skill (document-skills/pptx/SKILL.md) enables slide deck generation and manipulation via python-pptx and raw OOXML access.

Slide Creation and Content Manipulation

Claude generates presentations using the python-pptx API, adding shapes, text frames, and images programmatically.

from pptx import Presentation
from pptx.util import Inches

prs = Presentation()
slide = prs.slides.add_slide(prs.slide_layouts[1])  # Title + Content layout

title = slide.shapes.title
title.text = "Quarterly Results"

body = slide.placeholders[1]
tf = body.text_frame
tf.text = "Revenue grew by 12% YoY."

# Insert image

slide.shapes.add_picture("chart.png", Inches(1), Inches(2), width=Inches(5))

prs.save("quarterly.pptx")

Low-Level XML Editing

For complex operations not supported by the high-level API, Claude unpacks the PPTX archive using document-skills/pptx/scripts/unpack.py to expose ppt/slides/*.xml for direct manipulation, then repacks with pack.py.

The Decision-Tree Workflow Pattern

Each document skill follows a standardized four-step decision tree:

  1. Determine intent – Identify whether the task requires reading, creating, or editing content.
  2. Select the appropriate tool – Choose between high-level libraries (python-pptx, openpyxl) or low-level XML manipulation based on complexity.
  3. Execute the minimal-step script – Run specific utilities like unpack.py, recalc.py, or fill_fillable_fields.py.
  4. Validate – Verify output integrity using format-specific validators like validate.py for OOXML well-formedness checks.

This pattern ensures Claude selects the most reliable tool for each operation while maintaining document integrity.

Summary

  • DOCX skills support tracked-change preservation via pandoc, redlining workflows with raw OOXML manipulation using unpack.py and pack.py, and document generation via docx-js.
  • PDF skills enable text extraction with pypdf/pdfplumber, document merging, and interactive form handling through extract_form_field_info.py and fill_fillable_fields.py.
  • XLSX skills provide DataFrame integration via pandas, workbook styling with openpyxl, and formula validation through recalc.py LibreOffice automation.
  • PPTX skills offer slide generation via python-pptx and low-level XML access through archive unpack/pack scripts.
  • All skills follow a decision-tree workflow that prioritizes validation and minimal-step execution.

Frequently Asked Questions

What document formats does Claude Skills support?

Claude Skills support the four major office document formats: DOCX (Word), PDF (Adobe), XLSX (Excel), and PPTX (PowerPoint). Each format has a dedicated skill package containing format-specific tools, workflows, and validation scripts.

How does Claude Skills handle tracked changes in Word documents?

For DOCX files, Claude uses pandoc with the --track-changes=all flag to preserve revision markup during markdown conversion. For editing, the skill implements a redlining workflow that inserts <w:ins> and <w:del> tags with proper RSIDs after unpacking the OOXML archive via ooxml/scripts/unpack.py, then repacks the document while maintaining change history.

Can Claude Skills fill PDF forms programmatically?

Yes. The PDF skill includes fill_fillable_fields.py, which uses pypdf to update AcroForm field values. Claude can read existing field definitions using extract_form_field_info.py, then populate fields programmatically and save the filled document without altering the form structure.

How are Excel formula errors detected and reported?

The XLSX skill includes recalc.py, a script that opens workbooks in LibreOffice (with a configurable timeout), recalculates all formulas, and returns a JSON summary of errors. It specifically identifies error types like #REF! or #DIV/0! and reports their cell locations, enabling automated validation of financial models and data sheets.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →