Excel Report
Create formatted Excel report workbooks from CSV files using openpyxl. Use when the user provides or references a .csv file and asks to convert it to .xlsx,...
Latest: v1.0.0
- Initial release of excel-report skill.
- Converts CSV files to polished Excel (.xlsx) reports using openpyxl.
- Applies header styling, number formatting with thousands separators, and bold total rows.
- Automatically adds a simple bar chart for the first numeric column, and includes table formatting, filters, frozen headers, and autosized columns.
- Command-line usage with customizable worksheet name and output path.
- Requires openpyxl (not pandas) for conversion.
Full description
Create formatted Excel report workbooks from CSV files using openpyxl. Use when the user provides or references a .csv file and asks to convert it to .xlsx, make an Excel report, add header styling, comma number formats, numeric total rows, or a simple chart.
Excel Report
Convert CSV files into polished Excel .xlsx reports with the bundled openpyxl script.
Workflow
- Locate the input CSV file and decide an output
.xlsxpath. Default to the same basename beside the CSV unless the user specifies otherwise. - Use the bundled script:
python3 /home/ubuntu/.openclaw/workspace/skills/excel-report/scripts/csv_to_excel_report.py input.csv output.xlsx
- Verify the workbook was created. For important outputs, inspect the workbook with
openpyxlor run a quick file check. - Return the generated
.xlsxfile path, and attach it withMEDIA:<path>when replying in a channel that supports file delivery.
What the script does
- Reads CSV with UTF-8 BOM support and delimiter sniffing.
- Creates an Excel workbook with a
Reportsheet. - Styles the header row with a dark blue fill and white bold text.
- Converts numeric-looking cells to numbers and applies thousands separators.
- Adds a bold total row with
SUMformulas for numeric columns. - Adds a simple bar chart for the first numeric column using the first column as categories, limited to the first 10 data rows.
- Adds an Excel table, filters, frozen header row, and autosized columns.
Options
- Omit the output path to create
input.xlsxbeside the CSV. - Use
--sheet-name "Name"to set the worksheet title.
Dependency
The script requires openpyxl. If it is missing, install it in the active Python environment before running:
python3 -m pip install openpyxl
Do not use pandas for the core conversion unless the user explicitly asks; this skill is designed around openpyxl.
