Skip to main content

Type

file_generation

Formats

JSON, CSV, PDF, TXT, Markdown
Purpose: The File Generation skill enables agents to create formatted files from structured data, supporting various output formats for reports, exports, and documentation.

Common Use Cases

Creating reports and documentsGenerate PDF reports, executive summaries, and formatted documents

Exporting data to different formatsConvert data to CSV for spreadsheets, JSON for APIs

Generating configuration filesCreate YAML, JSON, or INI configuration files from templates

Template-based file creationUse Jinja2 or custom templates to generate dynamic content

Supported Formats

Format Selection: Use CSV for data exports (fast, small), PDF for formatted reports (professional), JSON for API/config (structured).

Configuration

Example Configuration:

Quick Start

View Complete Examples

See full template usage, PDF generation patterns, and multi-format export examples

Template Usage

Jinja2 Templates

Create reusable templates for consistent file generation: Template File (/opt/templates/report.md.j2):
Agent Usage:

Security Best Practices

Always specify output_directory to limit where files can be written.
Use allowed_formats to control which file types can be generated.
Sanitize data before passing to templates to prevent injection attacks.
Performance Tip: For large data exports, use CSV instead of PDF for better performance and smaller file sizes.

Solutions:
  • Verify template_directory path is correct
  • Check template file exists: ls /opt/templates/
  • Ensure worker has read permissions on template directory
Solutions:
  • Install required PDF library: pip install reportlab or pip install weasyprint
  • Verify font files are available if using custom fonts
  • Check PDF engine configuration matches installed library
Solutions:
  • Verify output_directory exists: mkdir -p /opt/generated
  • Check worker user has write permissions
  • Ensure disk space is available: df -h

File System Skill

Read template files and manage output

Python Skill

Process data before file generation

Data Visualization

Create visual diagrams and charts

View All Skills

Return to built-in skills overview