csv-surgeon

csv-surgeon is a skill for Claude Code, Codex from microsoft/aibast-agents-library. It costs 49 tokens per session (9,464 once invoked), scanned A, original, MIT.

A command-line tool for profiling and checking CSV files, which are text tables separated by commas. It reports column types, empty-value rates, distinct-value counts, ranges, malformed rows, duplicate headers, mixed types, duplicate records, and selected rows.

In plain words
What is it for?
Use it to profile a CSV, find malformed or inconsistent records, detect duplicates, or filter a slice of rows without opening the file in a spreadsheet.
Why use it?
CSV files can look correct while containing missing values, inconsistent rows, duplicate records, or columns with unexpected data. The checks identify these problems by row or column before they cause failures elsewhere.

Skill for Claude CodeCodex ✓ vendor

Written for no agent in particular: nothing here depends on one.

Good fit Use it to profile a CSV, find malformed or inconsistent records, detect duplicates, or filter a slice of rows without opening the file in a spreadsheet.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/microsoft/aibast-agents-library/csv_surgeon
About the project

AIBAST Agents Library is a collection of industry-focused AI agent templates accompanied by a local server that connects agents to GitHub Copilot for language-model inference. It helps developers create and run tool-using agents and isolated project environments, with an optional cloud-backed path for persistent memory. The catalogue entries provide the repository's agents, skills, commands, hooks, and instructions.

microsoft/aibast-agents-library · 8 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add microsoft/aibast-agents-library --skill csv_surgeon
Clone the repo
git clone --depth 1 https://github.com/microsoft/aibast-agents-library

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for csv-surgeon

README.md
[![agentmods](https://agentmods.dev/badge/skills/microsoft/aibast-agents-library/csv_surgeon/github.svg)](https://agentmods.dev/skills/microsoft/aibast-agents-library/csv_surgeon)
Your own site
<a href="https://agentmods.dev/skills/microsoft/aibast-agents-library/csv_surgeon"><img src="https://agentmods.dev/badge/skills/microsoft/aibast-agents-library/csv_surgeon/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for csv-surgeon

Your own site · 80×15
<a href="https://agentmods.dev/skills/microsoft/aibast-agents-library/csv_surgeon"><img src="https://agentmods.dev/badge/skills/microsoft/aibast-agents-library/csv_surgeon.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 49 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 9,464 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00049 $0.09464
Opus 5.5 $0.00020 $0.03786
Sonnet 5.5 $0.00010 $0.01893
Haiku 4.5 $0.00005 $0.00946

Measured 2d ago against content hash ac1399027168, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

csv-surgeon scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (csv_surgeon_agent.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

beta/store/csv_surgeon/SKILL.md · 210 lines

How it starts

The opening of the file, as written. The whole thing — 210 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CSV Surgeon — profile a CSV and find the rows that will break something.

profile   per-column type, null rate, cardinality, min/max, sample values
issues    ragged rows, duplicate headers, mixed types, whitespace-padded keys
dupes     duplicate records, by whole row or by chosen key columns
slice     head/tail/filter rows without loading the file into a spreadsheet

Pure stdlib csv, no pandas, no network, no credentials.

WHY IT LEADS WITH NULL RATE AND CARDINALITY

Those two numbers explain most CSV surprises. A column that is 40% empty will break a join you thought was safe. A column with cardinality 1 is a constant someone forgot to remove. A column with cardinality == row count is an id, and joining on anything else is probably a mistake. None of that is visible by looking at the first ten rows, which is what everyone does.

WHY RAGGED ROWS GET THEIR OWN CHECK

A row with the wrong number of fields is the single most common CSV defect, and most tools silently pad or truncate it. The data then looks fine and is wrong. This reports the row number so you can go and look at it.

WHY WHITESPACE IN HEADERS IS A FINDING

"name" and "name " are different keys in every downstream consumer, and the difference is invisible in every viewer. It produces bugs that read as impossible.

Parameters

The typed contract this capability answers to (JSON Schema — the deterministic layer):

{
  "type": "object",
  "properties": {
    "action": {
      "type": "string",
      "enum": [
        "profile",
        "issues",
        "dupes",
        "slice"
      ],
      "description": "What to do."
    },
    "path": {
      "type": "string",
      "description": "Path to the .csv file."
    },
    "keys": {
      "type": "string",
      "description": "For dupes: comma-separated column names to match on. Default: the whole row."
    },
    "limit": {
      "type": "integer",
      "description": "For slice: how many rows. Default 10."
    }
  },
  "required": [
    "action",
    "path"
  ]
}

Read the full file on GitHub · 210 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 210 lines · 49 tokens per session scan A ac1399027168

Subscribe to this mod's changes

csv-surgeon is a skill published in the GitHub repository microsoft/aibast-agents-library (8 stars, last pushed yesterday), licensed MIT. It adds 49 tokens to every session and 9,464 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-06.

Related

csv-surgeon compared with skills from other repositories

csv-surgeon next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
csv-surgeonmicrosoft/aibast-agents-librarySkill8yesterdayMITA49Claude Code, Codex
systematic-debuggingopen-metadata/OpenMetadataSkill16ktodayApache-2.0A37Claude Code
log-error-digestzebbern/claude-code-guideSkill4.7kyesterdayMITA71Claude Code, Codex
cwv-optimizeradobe/skillsSkill321todayApache-2.0A112Claude Code
ci-fixersipyourdrink-ltd/bernsteinSkill1.2ktodayApache-2.0A15Claude Code, Codex
incident-response-incident-responsermyndharis/antigravity-skillsSkill2.0kyesterdayMITA36Claude Code, Codex
diagnosing-missing-recordingsPostHog/posthogSkill41ktodaynoneA76Claude Code, Codex