# Clean

> Use when you need to convert a CSV file to JSON format.

- Skill: `8ddiehu0314/clean` (Agent Skill)
- Install (CLI): `npx skillmds@latest add 8ddiehu0314/clean`
- Raw SKILL.md: https://api.skillmd.com/api/skills/8ddiehu0314/clean/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Data & Analytics
- Author: 8ddieHu0314 (https://skillmd.com/u/8ddiehu0314)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/8ddiehu0314/clean

---


# CSV to JSON Converter

Read the input CSV file and convert it to a JSON array of objects.

```python
import csv, json, sys

with open(sys.argv[1]) as f:
    rows = list(csv.DictReader(f))

print(json.dumps(rows, indent=2))
```

Pass the path to your CSV as the first argument. Each row becomes a JSON object
with the header row as keys. Output goes to stdout so you can pipe or redirect it.

