Installation
ACENLY Bench requires Python 3.9+ and PyYAML. Download the two files from GitHub and drop them into your project root:
cp acenly_bench/bench.py acenly_bench/bench_db.py your_project/
pip install pyyaml
Or download directly without git:
curl -O https://raw.githubusercontent.com/YannWeiler/acenly_bench/main/bench_db.py
pip install pyyaml
Configuration
Create acenly.yml in your project root. Copy from acenly.example.yml as a starting point:
benchmark: track: - file: src/api.py function: deduplicate_users - file: src/search.py function: build_index # warn if 10% slower, block push if 25% slower regression_warn: 0.10 regression_block: 0.25 noise_floor: 0.05 trials: 5 warmup: 2
Config options
track— list of functions to benchmark, each withfileandfunctionregression_warn— warn but allow push if this much slower (e.g. 0.10 = 10%)regression_block— block push entirely if this much slower (e.g. 0.25 = 25%)noise_floor— ignore changes smaller than this (filters measurement noise)trials/warmup— number of timed runs and warmup runs per function
Running
Benchmark all tracked functions:
Benchmark one specific function:
View history across commits:
High-precision mode — batch timing, 3-second measurement window:
Git Hooks
Install a pre-push hook that runs benchmarks automatically before every push:
If a function regresses past regression_block, the push is stopped. To override once:
Remove the hook:
Optimizer — Coming Soon
Once the benchmark finds something slow, the ACENLY Optimizer rewrites it algorithmically — O(n²) to O(n), correctness-verified, pure Python output. No new dependencies.
The optimizer is currently in private beta. We're onboarding a small group early.