Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

compara

CI Crates.io PyPI License: MIT Documentation

Extremely fast table comparison: two tables on a composite key, with counts, per-column statistics and a self-contained HTML report. One tool for every recurring comparison: a nightly export against yesterday’s, a CSV against the Parquet a warehouse emits, a migration’s source against its target.

Faster software for a better planet — less energy, less compute, more time for life.

  • Reads CSV, TSV, JSON (newline-delimited or one array of objects) and Parquet, and the two sides need not be in the same format.
  • Ten million rows × 20 columns of CSV in about a second on GitHub’s 4-core runner with the files cached, where the fastest of DuckDB, Polars, qsv and ClickHouse takes about 10 s; on Parquet as Polars or DuckDB write it, about twice as fast as the fastest of them (1.7–2.2 s vs 3.9–4.7 s); from a cold disk, little more than the time to read the files (CSV 9.3 s vs 8.6 s to read) (benchmarks).
  • Reads and writes object storage and the web directly (s3://, gs://, az://, https://), with each cloud’s own credentials, and fetches only the Parquet columns it compares (object storage).
  • One static binary, and a distroless container image; the report is a single HTML file with nothing to host.
  • Exit codes made for pipelines: 0 identical, 1 differences, 2 error, 3 duplicate keys (with --fail-on-dups).

Start

  • Install: Every way to install compara: prebuilt binaries, package managers and the container image.
  • Quick start: Two example exports compared, from the counts to the HTML report.
  • Everyday comparisons: The comparisons people run most, and what compare writes and when.

Guides

Concepts

  • Engines and formats: The three engines and their shared result contract, and how each input format is read.

Reference

Agents

  • For AI agents: What an agent gets: a JSON result, exit codes it can branch on, a read-only default, and these docs as markdown.
  • Skill: The guide compara skill gives an agent, as this version prints it.

Benchmarks

  • Results: compara against DuckDB and Polars on the same comparisons, local and on object storage, each number with its CI run.
  • Where compara is not ahead: Each measure on which another tool beat compara in the same run.

Project

  • Changelog: What changed in each release, and what is on the way.
  • Contributing: How to build, test and benchmark compara, and the performance gate every change passes.
  • Security: What compara protects and how, and how to report a problem.

Built from commit c2d955a, 81 commits after v0.8.0, of 2026-11-25; compara --version says compara 0.9.0. These docs are ahead of the 0.8.0 release: what the changelog lists under Unreleased is not in 0.8.0 yet.