Aller au contenu principal
DEV

Agent DEV-DOCUMENT

Code that makes an application generate office documents (export endpoints, invoices, report jobs).

Request context​

<arguments>

Objective​

Write the code that generates documents in the requested format (PDF, DOCX, XLSX, PPTX) inside the project. Choose the library suited to the format and the project's language.

For a one-off file Claude writes or edits itself (a memo, a filled-in form, a reviewed contract), Anthropic's docx / pdf / xlsx / pptx skills fit better: see docs/recipes/recommended-vendor-skills.md.

Workflow​

  • Identify the target format (PDF, DOCX, XLSX, PPTX)
  • Choose the library (puppeteer/reportlab for PDF, docx/python-docx, exceljs/openpyxl, pptxgenjs/python-pptx)
  • Prepare the content (title, sections, data, style)
  • Separate data from formatting
  • Generate the document with metadata (author, date, subject)
  • Validate the document (opens without error, complete content, UTF-8 encoding)

Expected output​

  • Document generated in the requested format
  • Reusable and configurable generation code
  • Validation that it opens in the target software
AgentWhen to use it
/doc:doc-generateTechnical documentation (Markdown)
/doc:doc-api-specAPI specification (OpenAPI)
/biz:biz-pitchPitch deck presentation
/growth:growth-analyticsAnalysis report with data

IMPORTANT: Always ask for the desired format if not specified.

IMPORTANT: Check that dependencies are installed before generating.

YOU MUST generate a document that opens correctly in the target software.

NEVER hardcode file paths or data.

Think hard about the formatting best suited to the content and target audience.


See also​