xlsx-parsing
Read Microsoft Excel (.xlsx) files robustly with `openpyxl` (or `pandas`).
Skill by benchflow-ai
Chalk Labs
Need help deploying xlsx-parsing?
Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/benchflow-ai-xlsx-parsing
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: documents, spreadsheets, backend, data
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/xlsx-parsing
What's inside
- Skill name
xlsx-parsing- Description
- Read Microsoft Excel (.xlsx) files robustly with `openpyxl` (or `pandas`). Covers multi-sheet workbooks, header rows, empty cells, merged cells, comma-separated list cells, and converting a sheet to a list-of-dicts the rest of your code can consume. Use when a task input or reference document is an `.xlsx` file rather than JSON/CSV.
- License
- Apache-2.0
- Instructions
- 122 lines in SKILL.md · view on GitHub
Files (1)
- SKILL.md
SKILL.md (first lines)
# xlsx-parsing
Excel workbooks are the lingua franca of operational documents that nobody bothered to put in a database — playbooks, rate cards, deviation policies, finance models, SLAs. They show up in tasks with three properties that trip up naive readers:
1. **Multiple sheets**, only one of which is the data you actually want.
2. **Sparse cells** — a row that uses a column may sit next to a row that doesn't, leaving `None` cells. Empty is meaningful (the rule does not apply), not an error.
3. **Composite cells** — a single cell that contains a comma-separated list, a JSON blob, or a sentence rather than an atomic value.
Treat the workbook as a *typed table* with declared columns, not a free-form spreadsheet. Read every sheet you need, normalise it to `list[dict[str, Any]]`, then operate on that.
## Reading with `openpyxl` (pure Python, no compiled dependencies)
```python
import openpyxl
wb = openpyxl.load_workbook("workbook.xlsx", data_only=True, read_only=True)
print(wb.sheetnames) # e.g., ['Metadata', 'Definitions', 'Rules']
ws = wb["Rules"]
rows = ws.iter_rows(values_only=True)
header = [str(c).strip() if c else "" for c in next(rows)]
records = [dict(zip(header, row)) for row in rows if any(cell is not None for cell in row)]
```
Notes:
- `data_only=True` returns the cached value of formula cells instead of the formula expression. Without this you may get strings like `"=A1+B2"`.
- `read_only=True` is faster on big workbooks and avoids loading styles you don't need.
- The `any(cell is not None ...)` filter drops entirely-blank rows that Excel preserves at the bottom of a sheet.
- `dict(zip(header, row))` handles trailing empty columns gracefully when a row is shorter than the header.
## Reading with `pandas` (if it's installed)
```python
import pandas as pd
# Multi-sheet read returns a dict of DataFrames
sheets = pd.read_excel("workbook.xlsx", sheet_name=None, dtype=object)
rules_df = sheets["Rules"]
# Drop fully-empty rows; keep partial rows
rules_df = rules_df.dropna(how="all")
# Iterate as dicts; NaN becomes None
records = rules_df.where(rules_df.notna(), None).to_dict(orient="records")
```
`pandas` is heavier but useful when you want grouping, joins, or numeric aggregation. Either library is fine; do not mix them in the same module.
## Empty cells: `None` is the answer, not an error
A row that does not specify a numeric cap leaves that cell blank. The blank is part of the rule's shape — it means "no cap applies" or "this constraint is not engaged for this rule." Code defensively:
```python
def get(rec, key, default=None):
val = rec.get(key)
return default if val is None or (isinstance(val, str) and not val.strip()) else val
```
Compare against `is None` or call `.strip()` rather than truthiness — `0` and `False` are valid values that fail truthy tests.
## Composite cells
Authors often put list-valued data into a single cell. A cell containing `"Delaware, New York, California"` is one string, not three rows.
```python
def split_list_cell(value):
if value is None:
return []
return [item.strip() for item in str(value).split(",") if item.strip()]
```
If you see a cell with curly-brace text, it is probably an embedded JSON document; parse with `json.loads`. Try the simple split first.
## Merged cells
Merged cells appear once in the underlying data; only the top-left cell holds the value, and the rest are `None`. If a column is intentionally merged for a "section header" effect, fill the value down to recover row-wise records:
```python
last = None
for row in records:
if row["section"] is None:
row["section"] = last
else:
last = row["section"]
```
If you need to know whether a cell *is* in a merged range, `ws.merged_cells.ranges` gives you the list.
## Multiple sheets
Use the metadata sheet (often named `Metadata`, `Info`, or `README`) for workbook-level fields, and the data sheet(s) for per-record rows. Read all sheets you need before processing — do not assume the schema of one sheet is described inside another sheet you have not opened.
## Putting it together for a configuration-style workbook
```python
import openpyxl
def load_sheet_as_records(wb, sheet_name):
ws = wb[sheet_name]
rows = ws.iter_rows(values_only=True)
header = [str(c).strip() if c else "" for c in next(rows)]
return [
dict(zip(header, row))
for row in rows
if any(cell is not None for cell in row)
]
wb = openpyxl.load_workbook("workbook.xlsx", data_only=True, read_only=True)
metadata = {row[0]: row[1] for row in wb["Metadata"].iter_rows(min_row=2, values_only=True)}
defs = load_sheet_as_records(wb, "Definitions")
rules = load_sheet_as_records(wb, "Rules")
```
After this, `rules[0]["key"]`, `rules[0]["rule_type"]`, etc. are plain Python values you can branch on. The rest of your code does not need to know the input was Excel.
## When **not** to use this skill
- The file is `.csv` — use `csv.DictReader` directly.
- The file is `.json` or `.jsonl` — use `json.loads`.From benchflow-ai/skillsbench, Apache-2.0.
More from benchflow-ai/skillsbench
- 0.552score
hex-grid-spatial
benchflow-ai
Hex grid spatial utilities for offset coordinate systems.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
grpo
benchflow-ai
Reference for the GRPO (Group Relative Policy Optimization) algorithm.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
mesh-analysis
benchflow-ai
Analyzes 3D mesh files (STL) to calculate geometric properties (volume, components) and extract attribute data.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
task-review
benchflow-ai
SkillsBench task PR review — classifies the task track (standard / research / multimodal), runs static policy checks against the track-specific rubric…
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
civ6lib
benchflow-ai
Civilization 6 district mechanics library.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
d3-visualization
benchflow-ai
Build deterministic, verifiable data visualizations with D3.js (v6).
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
modal-gpu
benchflow-ai
Run Python code on cloud GPUs using Modal serverless platform.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
mhc-algorithm
benchflow-ai
Implement mHC (Manifold-Constrained Hyper-Connections) for stabilizing deep network training.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
transaction-concurrency-control-foundations
benchflow-ai
Provides database transaction concurrency-control background.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
search-accommodations
benchflow-ai
Lookup accommodations by city from the bundled dataset.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
search-attractions
benchflow-ai
Retrieve attractions by city from the bundled dataset.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
rl-post-training
benchflow-ai
Diagnostic guide for RL-based post-training of language models (GRPO, PPO, REINFORCE, DPO).
SkillCFreshness: C★ 1.9KClaude Code +9
Signals
- Stars
- 1,870
- Forks
- 372
- Open issues
- 50
- Last commit (this folder)
- Jun 11, 2026 (4 months ago)
- Last release
- Jun 14, 2026 (4 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- Apache-2.0
- Repository
- github.com/benchflow-ai/skillsbench
- Website
- www.skillsbench.ai
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from benchflow-ai
- 0.552score
modal-gpu
benchflow-ai
Run Python code on cloud GPUs using Modal serverless platform.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
task-review
benchflow-ai
SkillsBench task PR review — classifies the task track (standard / research / multimodal), runs static policy checks against the track-specific rubric…
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
transaction-concurrency-control-foundations
benchflow-ai
Provides database transaction concurrency-control background.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
search-attractions
benchflow-ai
Retrieve attractions by city from the bundled dataset.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
search-accommodations
benchflow-ai
Lookup accommodations by city from the bundled dataset.
SkillCFreshness: C★ 1.9KClaude Code +9 - 0.552score
mhc-algorithm
benchflow-ai
Implement mHC (Manifold-Constrained Hyper-Connections) for stabilizing deep network training.
SkillCFreshness: C★ 1.9KClaude Code +9
Done for you
Rather not set it up yourself?
Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.
See how we build AI agents →Read the case studies
Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.
- launches shipped
- 50+
- launches shipped
- media placements
- 500+
- media placements
- founders on every account
- 2
- founders on every account
Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block
Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.
Get xlsx-parsing running in your business
Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.
Cite this page
xlsx-parsing skill. Agent Mart. https://agentmart.dev/skills/benchflow-ai-xlsx-parsing (last updated 2026-10-24)