agentleFS
dleerdefidleerdefi/claude-code-construction/skills/sheet-splitter/SKILL.md

sheet-splitter

Skill43 starsChanged 56 days agoMITView on GitHub

Split a bound drawing set PDF into individual sheet PDFs. Extracts sheet numbers from title blocks via vision, renames files. Triggers: 'split drawings', 'break up the drawing set', 'separate sheets'. Run after /project-setup.

The file

Show its rules and text

We split this skill into the rules it gives an agent

16 rules. About 0 are common, 9 are distinctive, and 7 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈9

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Run after /project-setup identifies bound drawing sets.

    line 17
  2. Distinctive:

    Look for individual sheet PDFs.

    line 39
  3. Distinctive:

    If already split, report the count and skip.

    line 44
  4. Distinctive:

    Search the project directory for ALL PDFs that are drawings.

    line 48
  5. Distinctive:

    Look for PDFs > 2MB with keywords: "plan", "drawing", "bid set", "dwg", discipline names

    line 56
  6. Very specific:

    If the user specifies a single file (/sheet-splitter path/to/specific.pdf), process only that file.

    line 60
  7. Distinctive:

    Run the split script on each drawing PDF found:

    line 64
  8. Distinctive:

    After splitting, read each page to identify sheet numbers and titles:

    line 76
  9. Distinctive:

    Use vision on the rasterized title block: "Read the title block on this construction drawing.

    line 85
  10. Very specific:

    Update sheet_index.yaml with the identified sheet number, title, and discipline.

    line 89
  11. Very specific:

    After identifying all sheets, write {drawings_directory}/sheets/sheet_index.yaml (shown below).

    line 95
  12. Very specific:

    After splitting and identifying, update .construction/skills/project_context.yaml with:

    line 111
  13. Very specific:

    If AgentCM is present (.construction/project.yaml exists), write a graph entry:

    line 117
  14. Distinctive:

    When a project has multiple drawing set PDFs (e.g., Architectural, MEP, Civil as separate files), use the source PDF name as a subdirectory …

    line 130
  15. Very specific:

    Never overwrite existing split sheet PDFs.

    line 146
  16. Distinctive:

    Allowed scripts — exhaustive list: Only execute these scripts during this skill:

    line 152

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Sheet Splitter

Splits a bound drawing set PDF into individual page PDFs. Mirrors what spec-splitter does for specifications.

Pipeline Position

Run after /project-setup identifies bound drawing sets. Produces split PDFs and sheet_index.yaml consumed by /schedule-extractor and all drawing analysis skills.

This is valuable for:

  • Project teams: Navigate drawings by sheet number instead of scrolling a multi-page PDF
  • Other skills: schedule-extractor, tag-audit-and-takeoff, pe-review and every other drawing analysis skill work better with individual sheet files
  • AgentCM: Split files become the basis for per-sheet structured data

Workflow

Sheet Split Progress:
- [ ] Step 1: Check if drawings are already split
- [ ] Step 2: Locate the bound drawing set
- [ ] Step 3: Split into individual page PDFs
- [ ] Step 4: Extract sheet numbers from title blocks
- [ ] Step 5: Rename files with sheet number + title
- [ ] Step 6: Update project context
- [ ] Step 7: Write graph entry (AgentCM only)

Step 1: Check if Drawings Are Already Split

Look for individual sheet PDFs. Drawings are already split if:

  • AgentCM: .construction/index/sheet_index.yaml exists with individual sheet entries and file paths point to split PDFs
  • Multiple PDFs exist with sheet number patterns in filenames (e.g., A-1.1 - FLOOR PLAN.pdf)
  • A sheet_index.yaml exists in the drawings directory

If already split, report the count and skip. If AgentCM has the sheet index but files haven't been physically split on disk, offer to split using the existing metadata for naming.

Step 2: Find ALL Drawing PDFs

Search the project directory for ALL PDFs that are drawings. Many projects have multiple drawing PDFs:

  • Multi-part sets: Part1.pdf, Part2.pdf, Part3.pdf (split by file size)
  • Discipline sets: Architectural.pdf, Civil.pdf, Electrical.pdf, Mechanical.pdf
  • Single combined: one large PDF with all sheets

Search in:

  • Folders named drawings/, plans/, 01 - Drawings/, or similar (case-insensitive)
  • The project root (some projects have no folder structure)
  • Look for PDFs > 2MB with keywords: "plan", "drawing", "bid set", "dwg", discipline names

Process EACH PDF found. All split pages go to the same sheets/ output directory.

If the user specifies a single file (/sheet-splitter path/to/specific.pdf), process only that file.

Step 3: Split Pages

Run the split script on each drawing PDF found:

"${CLAUDE_PLUGIN_ROOT}/bin/construction-python" "${CLAUDE_SKILL_DIR}/scripts/split_drawing_set.py" \
  "{drawing_set.pdf}" \
  --output-dir "{drawings_directory}/sheets"

The script splits each page into its own PDF: page_001.pdf, page_002.pdf, etc. It does NOT attempt to read sheet numbers — that's unreliable across different title block formats.

Step 4: Identify Sheets via Vision

After splitting, read each page to identify sheet numbers and titles:

Use PDF bookmarks and the title-block text layer only as candidates — they are often abbreviated or stale (e.g. a bookmark "Site Grading Plan" on a sheet printed "Proposed Site Plan"). The printed title block wins. Read the title block by vision whenever there is no candidate, the candidate disagrees with the title-block text, or the sheet number carries a suffix (e.g. C9.04H, K-1.1).

  1. Rasterize the title block region of each page:
"${CLAUDE_PLUGIN_ROOT}/bin/construction-python" "${CLAUDE_PLUGIN_ROOT}/scripts/pdf/rasterize_page.py" "page_NNN.pdf" 1 --dpi 200 --output tb.png
  1. Use vision on the rasterized title block: "Read the title block on this construction drawing. What is the sheet number and sheet title?"
  2. Rename the file: page_001.pdf → A-1.1 - FLOOR PLAN.pdf
  3. Update sheet_index.yaml with the identified sheet number, title, and discipline. When a bookmark title differs from the printed title, keep it as bookmark_title.

Title blocks vary significantly across firms — they can be on the east side, south side, or bottom-center. Some use VA standard forms, some use firm-specific formats. Vision handles all these variations.

Step 5: Write Sheet Index

After identifying all sheets, write {drawings_directory}/sheets/sheet_index.yaml (shown below). Never write .construction/index/ — that folder belongs to AgentCM; only read it.

Output

sheets/
  A-1.1 - FLOOR PLAN.pdf         ← renamed by Claude via vision
  A-2.1 - ELEVATIONS.pdf
  S-1.1 - FOUNDATION PLAN.pdf
  page_006.pdf                    ← could not read title block
  ...
  sheet_index.yaml

Step 6: Update Project Context

After splitting and identifying, update .construction/skills/project_context.yaml with:

  • documents.drawing_count: number of sheets
  • documents.disciplines: list of unique discipline prefixes found

Step 7: Write Graph Entry (AgentCM only)

If AgentCM is present (.construction/project.yaml exists), write a graph entry:

"${CLAUDE_PLUGIN_ROOT}/bin/construction-python" "${CLAUDE_PLUGIN_ROOT}/scripts/graph/write_finding.py" \
  --type "drawings_split" \
  --title "Drawing set split: {N} sheets from {source_pdf}" \
  --data '{"sheet_count": N, "source_pdf": "...", "identified_count": M, "unidentified_count": K, "disciplines": ["A","S","M","E"]}'

Without AgentCM, skip — the sheet_index.yaml serves as the local record.

Multi-Set Projects

When a project has multiple drawing set PDFs (e.g., Architectural, MEP, Civil as separate files), use the source PDF name as a subdirectory to avoid filename collisions:

sheets/
  Architectural_Bid_Set/
    page_001.pdf ... page_050.pdf
  MEP_Bid_Set/
    page_001.pdf ... page_030.pdf
  sheet_index.yaml  ← merged from all sets

Pass --output-dir "{drawings_directory}/sheets/{source_pdf_stem}" to the split script for each set. The sheet_index.yaml merge logic combines entries from all subdirectories into a single index.

Report to user: number of pages split, how many identified via vision, output location.

File Safety

Never overwrite existing split sheet PDFs. If sheets/ directory already contains files, check for conflicts before writing. The sheet_index.yaml merge uses additive logic — existing entries are preserved.


Allowed Scripts

Allowed scripts — exhaustive list. Only execute these scripts during this skill:

  • scripts/split_drawing_set.py — split bound PDF into per-page PDFs
  • ${CLAUDE_PLUGIN_ROOT}/scripts/pdf/rasterize_page.py — rasterize PDF pages for vision identification
  • ${CLAUDE_PLUGIN_ROOT}/scripts/graph/write_finding.py — graph entry (Step 7)

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.