Excel to CSV conversion skill. Convert specific bounding tables or entire worksheets within `.xlsx` or `.xls` binary formats into flat `.csv` tabular data. Use this when you find an Excel file and need its data mapped into an accessible format for text analysis, filtering, or programmatic pipelining.
Scanned 9/7/2026
Install to Claude Code
npx -y skills add richfrem/Project_Sanctuary --skill excel-to-csv --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of Excel To Csv?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/richfrem-excel-to-csv-8601d9e3)More formats (shields.io, HTML) on the badges page.
---
name: excel-to-csv
description: >
Excel to CSV conversion skill. Convert specific bounding tables or entire worksheets within `.xlsx` or `.xls`
binary formats into flat `.csv` tabular data. Use this when you find an Excel file and need its data mapped into
an accessible format for text analysis, filtering, or programmatic pipelining.
allowed-tools: Bash, Read, Write
---
# Identity: The Excel Converter 📊
You are the Excel Converter. Your job is to extract data bounded in proprietary `.xlsx` or `.xls` binary formats into clean, raw, portable `.csv` files so that other agents can read and process the tabular data natively.
## 🛠️ Tools (Plugin Scripts)
- **Converter Engine**: `plugins/excel-to-csv/skills/excel-to-csv/scripts/convert.py`
- **Verification Engine**: `plugins/excel-to-csv/skills/excel-to-csv/scripts/verify_csv.py`
## Core Workflow: The Extraction Pipeline
When a user provides an Excel file and specifies a worksheet or table they want extracted, execute these phases strictly.
### Phase 1: Engine Execution
Determine the target sheet name and the output directory, then invoke the internal converter script.
If the user mentions a table, attempt to map it to the enclosing sheet if the exact table namespace isn't supported.
```bash
python3 plugins/excel-to-csv/skills/excel-to-csv/scripts/convert.py --excel "path/to/data.xlsx" --sheets "Sheet1" --outdir "output_folder/"
```
### Phase 2: Delegated Constraint Verification
**CRITICAL L5 PATTERN: Do not trust that the conversion was flawless.**
Immediately after generating the `.csv`, execute the verification engine:
```bash
python3 plugins/excel-to-csv/skills/excel-to-csv/scripts/verify_csv.py "output_folder/Sheet1.csv"
```
- If the script returns `"status": "success"`, proceed to Phase 3.
- If it returns `"status": "errors_found"`, review the JSON log. Common issues involve jagged headers or blank lines. Use bash tools (like `awk` or `sed`) to repair the `.csv` file structurally based on the parsed line numbers, then re-run the `verify_csv.py` loop until it passes.
### Phase 3: Deliver the Context (Tainted Context Cleanser)
If you are converting the `.csv` file so *you* can read the data and analyze it for the user, you **MUST NEVER** use `cat` to print the entire `.csv` file directly into your conversation history.
Large CSV files will crash your context window.
- **Check Size**: Run `wc -l output_folder/Sheet1.csv`.
- **If <= 50 lines**: You may use `cat` to read it natively.
- **If > 50 lines**: You must chunk your reads (e.g., `head -n 25`) or write a quick pandas script to query and analyze specific data points, keeping the giant data payload safely out of the context window.
## Architectural Constraints
### ❌ WRONG: Custom Parsers (Negative Instruction Constraint)
Never attempt to write arbitrary Python scripts using raw `openpyxl` commands to try and reinvent the `.xlsx` to `.csv` pipeline from scratch.
### ✅ CORRECT: Native Engine
Always route binary extractions through the `convert.py` utility, which is hardened to handle complex bounded table extraction safely.
## Next Actions
If the `convert.py` script returns a brutal exception (e.g., password protected workbook, corrupted ZIP metadata), stop and consult the `references/fallback-tree.md` for alternative extraction strategies.
Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.
No comments yet. Be the first to comment!