FailSlice
v0.1.1Shrink multi-table CSV/Parquet data to a small, FK-consistent, verified reproducer of a data bug.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
inspect_dataset
Inspect CSV / Parquet / DuckDB tables inside the root: exact row and NULL counts, schemas, declared-FK orphan counts, bounded previews, and a config template. Give `directory` (all files in it) or `tables` (name -> path).
| Parameter | Type | Description |
|---|---|---|
base_dir | ||
directory | ||
foreign_keys | ||
preview_rows | integer | |
tables |
suggest_relationships
Suggest primary and foreign keys for the files in `directory`, with evidence and a confidence label. These are suggestions to review, never facts. Returns the report and a failslice.yaml text with the suggestions commented out.
| Parameter | Type | Description |
|---|---|---|
directory * | string | |
full_scan | boolean | |
sample_rows | integer |
check_predicate
Validate a project (config_path to a failslice.yaml inside the root, or an inline `config`) and run the determinism check: the predicate must be TRUE on the full data four times with the same result. Runs in a supervised child process.
| Parameter | Type | Description |
|---|---|---|
base_dir | ||
config | ||
config_path |
reduce_failure
Reduce the data to a small configuration that keeps the predicate TRUE, export it under <root>/.failslice/runs/<run_id>, replay it in a fresh process and write the report, manifest, CSV and pytest bundle. Long-running: progress is reported; cancelling the request kills the run. Budgets may not exceed the server's ceilings.
| Parameter | Type | Description |
|---|---|---|
base_dir | ||
config | ||
config_path | ||
eval_timeout_s | ||
max_evals | ||
minimality | ||
seed | ||
wall_clock_s |
verify_reproducer
Replay a run (by run_id, or 'latest') in a fresh process from its exported files only: predicate TRUE and referential integrity.
| Parameter | Type | Description |
|---|---|---|
run_id * | string | |
timeout_s |
explain_reproducer
Observations on the rows that survived reduction (row and NULL counts, duplicated declared keys, per-FK join pairs per key). Observations, not a diagnosis.
| Parameter | Type | Description |
|---|---|---|
run_id * | string | |
limit | integer |
export_pytest
Re-verify a run and write a self-contained pytest bundle (needs only pytest and duckdb) under <root>/.failslice/exports/<run_id>/<name>. expect='fails': the test passes while the bug reproduces; expect='passes': it passes once the bug is gone.
| Parameter | Type | Description |
|---|---|---|
run_id * | string | |
expect | string | |
name | ||
timeout_s |