agentleFS
LouLouLibsLouLouLibs/claude-skills/skills/dtdiff/SKILL.md

dtdiff

Skill1 starsChanged 59 days agoMITView on GitHub

Use when the user asks to compare, diff, or find differences between two tabular data files (CSV, TSV, Parquet, Arrow, JSON, NDJSON, Excel). Also use when the user mentions data diff, file comparison, or wants to know what changed between two data files of the same format.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 0 are distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Positional (default, no --key): Every column defines identity.

    line 47
  2. Very specific:

    Use --key if rows have a natural identity column (ID, date, etc.)

    line 74
  3. Very specific:

    Use --tolerance for financial/scientific data with float rounding

    line 75
  4. Very specific:

    Use --json for structured output, default text for quick review

    line 76

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

dtdiff — Tabular Data Comparison

Compare two tabular data files of the same format and report added, removed, and modified rows.

Quick Reference

# Compare two CSV files (positional mode)
dtdiff old.csv new.csv

# Compare by key column
dtdiff old.parquet new.parquet --key ID

# Composite key
dtdiff old.csv new.csv --key Date,Ticker

# Float tolerance (differences <= 0.01 treated as equal)
dtdiff old.csv new.csv --key ID --tolerance 0.01

# JSON output for structured processing
dtdiff old.csv new.csv --key ID --json

# CSV output
dtdiff old.csv new.csv --key ID --csv

# Compare Excel sheets
dtdiff old.xlsx new.xlsx --sheet Revenue --key ID

# Override format (e.g., .txt files that are CSV)
dtdiff a.txt b.txt --format csv

# Disable color
dtdiff old.csv new.csv --no-color

Same-Format Requirement

Both files must be the same format. CSV and TSV are treated as the same family and can be compared. Comparing a CSV to a Parquet will error.

Diff Modes

Positional (default, no --key): Every column defines identity. Rows match exactly or differ. Reports added/removed only.

Key-based (--key specified): Match rows by key columns, compare remaining columns cell by cell. Reports added, removed, and modified with per-cell old/new values.

Flags

FlagDefaultPurpose
--format <fmt>autoOverride format detection (applies to both files)
--sheet <name|idx>firstSelect sheet (Excel only)
--key <cols>(none)Key columns for matching (comma-separated names)
--tolerance <f>1e-10Float comparison tolerance
--jsonfalseOutput as JSON
--csvfalseOutput as CSV
--no-colorfalseDisable ANSI colors

Exit Codes (diff convention)

CodeMeaning
0No differences
1Differences found
2Error

Workflow

  1. Identify the two files to compare (must be same format)
  2. Use --key if rows have a natural identity column (ID, date, etc.)
  3. Use --tolerance for financial/scientific data with float rounding
  4. Use --json for structured output, default text for quick review

Common Patterns

What changed between versions:

dtdiff old.csv new.csv --key ID

Ignore small rounding differences:

dtdiff old.parquet new.parquet --key ID --tolerance 0.001

Pipe structured results for processing:

dtdiff a.csv b.csv --key ID --json | jq '.modified'

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.