office-document-router-skill
Skill7 starsChanged 56 days agoApache-2.0View on GitHub
Office and document router — one entry point for Word (.docx), Excel (.xlsx/.csv), PowerPoint (.pptx), and PDF tasks: creation, editing, extraction, forms, OCR, template pipelines, OOXML surgery, thumbnails, and the markitdown/docling extraction ladder. Routes each document task to the right specialist route.
In this repository85 other files it gives its agents.
- AGENTS.mdAGENTS.md
- accessibility-a11y-skillSkill
- agent-introspection-debugging-skillSkill
- amplify-nextjs-deployment-skillSkill
- architecture-review-skillSkill
- authentication-authorization-skillSkill
- autoresearch-skillSkill
- aws-iac-safety-skillSkill
- blast-radius-skillSkill
- browser-fallback-skillSkill
- cad-dxf-skillSkill
- cad-generation-skillSkill
- cad-implicit-skillSkill
- cad-redraw-skillSkill
- cad-specialist-skillSkill
- cad-viewer-skillSkill
- changelog-python-cliff-skillSkill
- civiltekk-api-spec-skillSkill
- civiltekk-coding-harness-setup-skillSkill
- civiltekk-context-optimization-skillSkill
- civiltekk-diagram-skillSkill
- civiltekk-documentation-inline-skillSkill
- civiltekk-documentation-sync-skillSkill
- civiltekk-git-commits-skillSkill
- civiltekk-nextjs-skillSkill
- referencesSkill
- civiltekk-opencode-creation-skillSkill
- civiltekk-opentofu-skillSkill
- civiltekk-ponytail-audit-skillSkill
- civiltekk-pr-workflow-skillSkill
- civiltekk-python-backend-skillSkill
- civiltekk-react-quality-skillSkill
- civiltekk-startup-docs-skillSkill
- civiltekk-test-generation-skillSkill
- civiltekk-zai-media-skillSkill
- code-principles-skillSkill
- code-review-inline-skillSkill
- construction-bd-skillSkill
- continuous-learning-skillSkill
- coverage-readme-workflow-skillSkill
- database-migration-skillSkill
- deprecated-code-cleanup-skillSkill
- docker-containerization-skillSkill
- domain-modeling-skillSkill
- email-drafter-skillSkill
- error-resolver-workflow-skillSkill
- eval-harness-skillSkill
- frontend-design-skillSkill
- gh-cli-setup-skillSkill
- grilling-skillSkill
- gsap-skillSkill
- horseshoe-paper-writing-skillSkill
- install-assistant-skillSkill
- language-linting-skillSkill
- language-review-checklists-skillSkill
- linting-inline-skillSkill
- linting-workflow-skillSkill
- logging-observability-skillSkill
- monorepo-management-skillSkill
- opencode-repo-setup-skillSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 74
Never fabricate chart numbers to pass validation (slides route): every value traces to a fetched source.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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.
Files
Office Document Router
One entry point for office-document tasks. Identify the deliverable, run only
the matched route's file, and follow it. All routes share one scripts/ tree;
the former per-skill copies were consolidated here (#680).
Provenance: routes consolidated from the former office-document skill family (2026-10, #680); per-route provenance lines live in the route files.
Routes (load exactly one)
| Task | Route | Read | Skip-when |
| Word document (.docx) create/read/edit | docx | references/routes/docx.md | spreadsheet → xlsx, PDF → pdf |
| Spreadsheet (.xlsx/.xlsm/.csv/.tsv) | xlsx | references/routes/xlsx.md | Word → docx, PDF → pdf |
| PDF: extract/forms/OCR/create | pdf | references/routes/pdf.md | fast text dump first → markitdown |
| Fill a PPTX template with JSON | slides | references/routes/slides.md | extract schema → template |
| Extract PPTX → template schema | template | references/routes/template.md | fill (slides) / extend (modifier) |
| Extend PPTX layouts (clone/promote) | modifier | references/routes/modifier.md | normal fill → slides |
| Fast local docs→Markdown (MCP) | markitdown | references/routes/markitdown.md | layout mangled → docling |
| Layout-aware extraction / scanned OCR | docling | references/routes/docling.md | markitdown sufficed → markitdown |
| Surgical OOXML edit (unpack/edit/repack) | ooxml | references/routes/ooxml.md | generation → slides/template |
| Office file → thumbnail grids / images | thumbnails | references/routes/thumbnails.md | text extraction → markitdown |
| Render docs to the shared HTML/DOCX standard | rendering | references/routes/rendering.md | spreadsheets (xlsx) / decks (pptx-specialist-subagent) |
Route files open with their own Load when / Skip when lines. Route detail
files (references/routes/<id>/) load when the route names them — never
preload.
Extraction ladder (spine)
- Plain text (.md/.txt/.json/code) → built-in
Read. Nothing else needed. - Born-digital office doc or text-selectable PDF → Route
markitdown(fast, local, ~1s/50 pages). - markitdown empty/garbage, complex tables, multi-column, or scanned →
Route
docling(layout-aware; CLI-on-demand with consent, or the persistent MCP pack). - Scanned/image-only and no docling →
pdftoppm→image-analyzer-subagent. - Structured PDF data (forms, fillable fields, OCR-as-purpose) → Route
pdf. - Visual understanding (charts, layout, "what does this look like") →
image-analyzer-subagent(not a route — a subagent).
Shared spine (all routes)
- Scripts run from this skill's directory:
scripts/<tool>as each route documents; the LibreOffice wrapper lives atscripts/soffice.py(handles sandboxed-VM AF_UNIX socket restrictions; auto-configures on first run). - Documents and spreadsheets must look designed, never generated: typographic or visual hierarchy, intentional color, styled headers — each route's aesthetics section has the specifics.
- Validate the artifact before handing it back (each route defines its validation pass); report assumptions and skipped checks.
- MCP packs (
markitdown,docling) ship disabled by default — enable via./deploy/setup.sh --enable-pack <name>with user consent; docling's CLI-on-demand path asks before installing (~3–4 GB). Never auto-install.
Hard rules
- Never fabricate chart numbers to pass validation (slides route): every value traces to a fetched source; the agent never touches real URLs (placeholders only).
- Template fill pipelines use user-supplied templates or the bundled default;
the base template is never written (modifier clones to
template_new.pptx). - Form filling follows the pdf route's ordered steps — never fill with unvalidated coordinates.
- Existing template conventions override house aesthetics when updating user files (xlsx route).
- Each route file owns its deep detail; this router never restates it.
Gates
- Zero-preload: only the matched route file (+ its named detail files) enters context.
- Report shape complete before declaring done: outputs, checks run/skipped, assumptions, risks.
- MCP/CLI enablement goes through the consent-gated pack flow above — never auto-install.
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
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.

