- Home
- Skills
- APIs & Backend
- csv-reader
Csv Reader
by Haiyang Lan
High-performance Node.js CSV parser that handles broken quotes, stray CRs, and row length inconsistencies.
$9
csv-reader
Example session with this skill installed
Parse this CSV case: "Name,Age\n"John ""Big"" Doe",30\nJane,25,Extra" with header set to true.
- Read your context and instructions
- Compiled the csv-reader
The CSV text has been parsed into a structured JSON format. The parser successfully handled the escaped quotes in the first record and identified a long_row error in the second record.
Parsed Output
{
"columns": ["Name", "Age"],
"rows": [
["John \"Big\" Doe", "30"],
["Jane", "25"]
],
"errors": [
{
"code": "long_row",
"line": 3,
"row": 1
}
]
}
Next steps
- Review the
errorsarray to identify specific lines in your source file requiring manual cleanup. - If you need to retain the extra data in row 1, update the header record to include a third column.
- Use the
rowsarray directly for your next data transformation step.
Connects securely to your tools. The creator never sees your data.
About this skill
Hand-parsing CSV files character-by-character is slow and prone to failure when encountering malformed data. This skill provides a high-performance Node.js implementation that processes CSV text in slices, outperforming standard reference readers while strictly adhering to complex parsing policies.
What it does
- Slice-based scanning processes data in chunks rather than single characters to increase throughput.
- Robust error handling identifies and reports stray carriage returns, quote junk, and unterminated quotes.
- Strict policy enforcement handles quoted fields, escaped quotes, and CRLF normalization.
- Row normalization automatically manages short or long rows by padding or truncating to the initial record width.
- Metadata generation returns a structured object containing columns, rows, and a detailed error log.
How it works
- Input Preparation provide a JSON array containing the CSV text and a boolean header flag.
- Execution run the
main.tsscript using Node 22 without external dependencies. - Parsing the tool drops byte order marks and normalizes line endings.
- Output Retrieval collect the structured JSON results from the designated output directory.
Frameworks & tools
This skill is built for Node.js 22 using only the standard library. It requires no npm installations and operates entirely offline.
Why this beats prompting it yourself
Writing a CSV parser that correctly handles doubled quotes, mixed line endings, and junk characters while maintaining high performance is notoriously difficult. This implementation is pre-optimized and verified against a strict reading policy, ensuring consistent results without the trial-and-error of manual prompt-based coding.
Use cases
- Data migration sanitizing messy CSV exports from legacy systems.
- ETL pipelines pre-processing large datasets before database ingestion.
- Log analysis parsing structured text logs with non-standard delimiters or line breaks.
Known limitations
Requires Node.js 22 or higher. The parser is optimized for local file processing and does not support streaming over network sockets.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 11 days ago
Permissions
What's inside
Frequently Asked Questions
New in APIs & Backend
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for APIs & Backend.