Fitment is an open-source validator for ACES 4.2 catalog exports (with read support for 4.0 and 4.1) in the automotive aftermarket. I built it to catch structural and reference-data problems before files reach distributors and PIM systems—without tying validation to a single vendor toolchain.
The CLI streams large XML files, loads AutoCare reference data into a local DuckDB database, and reports findings in formats that work in terminals and CI (human, JSON, NDJSON, SARIF).
Status: v0.1 — ACES 4.2 only. This is a focused subset validator, not a full replacement for commercial tools yet.
Aftermarket catalogs are large, rules are easy to get wrong, and reference data changes on a schedule. I wanted something that:
- Runs on Linux, macOS, and Windows from a single static binary
- Validates multi‑million application files in minutes, not hours
- Separates structural checks from VCdb / PCdb / Qdb checks
- Emits SARIF and JSON for pipelines, not only human-readable logs
- Keeps AutoCare data out of the repository (you import your own member drops)
| Area | Rules | Description |
|---|---|---|
| Structure | FIT001 | ACES 4.2 XSD subset (no libxml2): version, required elements, app actions |
| Catalog hygiene | FIT002–004 | Duplicate apps, overlaps, CNC (configuration notes conflict) |
| VCdb | FIT005–006 | Base vehicle exists; vehicle attribute combinations match reference rows |
| PCdb | FIT007 | Part type, position, and part-type/position pairs |
| Qdb | FIT008 | Qualifier IDs |
| Diff | — | Stable app identity and net-change report between two ACES files |
Suppressions are supported via .fitment-ignore. See docs/cli.md for flags and rule details.
On a real-world export (~1.29M applications, ~460MB XML), on Apple Silicon:
| Configuration | Typical time |
|---|---|
| Structural checks only (no refdb) | ~2 minutes |
| Full validation with imported refdb | ~40–45 seconds |
Reference lookups use an in-memory index loaded once per run; the refdb is not queried per application row. Importing VCdb/PCdb/Qdb from AutoCare ASCII is a separate, offline step.
Match your imported VCdb drop to the VcdbVersionDate (and related dates) in the ACES header. If the catalog was built against a newer VCdb than you imported, you will see FIT005 (unknown base vehicle) and duplicate FIT006 noise for the same apps.
- Rust 1.78+ (see
rust-toolchain.toml) - AutoCare member ASCII drops for reference validation (VCdb, PCdb, Qdb)
- An ACES 4.2 XML file to validate
Fitment does not ship AutoCare reference data.
git clone https://github.com/fitment-validator/fitment.git
cd fitment
cargo build --release -p fitment-cli
# binary: target/release/fitmentOr install from the workspace:
cargo install --path crates/fitment-cliPoint each command at the extracted AutoCare ASCII folder (e.g. AutoCare_VCdb_NA_LDMDHDPS_enUS_ASCII_20260129/). Fitment discovers dated filenames such as 20260129_BaseVehicle.txt.
export REFDB="$HOME/fitment-refdb.duckdb"
fitment import-vcdb /path/to/AutoCare_VCdb_NA_..._ASCII_YYYYMMDD --to "$REFDB"
fitment import-pcdb /path/to/AutoCare_PCdb_enUS_ASCII_YYYYMMDD --to "$REFDB"
fitment import-qdb /path/to/AutoCare_Qdb_enUS_ASCII_YYYYMMDD --to "$REFDB"See docs/refdb.md for supported tables and layout.
fitment validate catalog.xml --refdb "$REFDB"
fitment validate catalog.xml --refdb "$REFDB" --severity error
fitment validate catalog.xml --refdb "$REFDB" --format sarif > results.sarifExit code 1 when any error-severity finding remains (after suppressions).
fitment diff previous.xml current.xml
fitment diff previous.xml current.xml --format json| Format | Use case |
|---|---|
human |
Local debugging (default, colorized) |
json |
Single document with summary and all findings |
ndjson |
One finding per line for streaming |
sarif |
GitHub, Azure DevOps, and other SARIF 2.1.0 consumers |
SARIF shape and rule help URIs are documented in docs/sarif.md.
crates/fitment-core — parser, model, checks, diff
crates/fitment-refdb — DuckDB schema, ASCII importers, lookups
crates/fitment-report — formatters
crates/fitment-cli — fitment binary
fixtures/ — synthetic ACES and mini refdb (no AutoCare data)
docs/ — CLI, refdb, SARIF, architecture
Quality is gated locally (not via GitHub Actions CI, to avoid cloud cost):
cargo run -p xtask -- checkThat is equivalent to:
cargo fmt --all -- --check
cargo clippy --workspace --exclude fitment-desktop --all-targets -- -D warnings
cargo test --workspace --exclude fitment-desktopOther helpers:
cargo run -p xtask -- generate-fixturesContributing: CONTRIBUTING.md. Agent-oriented notes: AGENTS.md.
Planned directions (not committed timelines):
- HTTP API for CI and PIM integration
- Declarative rule configuration (YAML)
- VCdb coverage and cross-file analytics
- Clearer reporting when FIT005 and FIT006 overlap
- PIES validation
- Desktop UI (Tauri) — see docs/desktop.md
Design notes: docs/architecture.md.
Licensed under the MIT License.
ACES and AutoCare database names refer to standards and products of the AutoCare Association. Fitment is an independent project and is not endorsed by AutoCare.