ParetoStack 0.4.3 documentation
ParetoStack is an AI-enabled optimizer for whole code bases: it explores combinations of optimizations, measures every candidate on real hardware and keeps a change only when it is verified against your program's outputs (byte for byte, or a tolerance you declare). This is the documentation of version 0.4.3 (2026-10-27).
- Glossary: plain-language meaning of contract, bit-exact, tolerance, PGO, LTO, SIMD, speed-up, p-value and every other term used here.
- Install: Windows, Linux, DGX.
- Command line reference: every command and option.
- Optimizations: what can change in your code, and what the output guarantee is.
- Examples, the assistant (
pareto), the web console and dashboard and Benchmarks. - OpenCV rules.
- What changed in this version and the history of all versions.
Words used
Contract. The rule a changed program's output must meet before its speed-up counts. The default is identical output (byte for byte). Where small differences are expected (rounding, fixed-point arithmetic, an FFT), the contract is a tolerance you declare: a numeric error, PSNR or SSIM for images, or a task metric. A change that does not meet its contract is rejected, whatever its speed.
More terms (PGO, LTO, tolerance, SIMD, p-value and others) are explained in the Glossary.
Planned, not built yet
Database access optimization (ParetoStack-cloud). The N+1 round-trip problem that monitoring tools only detect: a query inside a loop becomes one batched query (WHERE id IN, executemany, batch_get_item, a Redis pipeline, a Mongo bulk_write); row-by-row work on the client becomes one server-side aggregation (SQL window functions and CTEs, Mongo aggregation pipelines); a connection per call becomes a module-level pool or proxy; SELECT * and unbounded fetches become column lists and pagination. First targets: PostgreSQL and MySQL (psycopg, SQLAlchemy), DynamoDB (boto3), Redis and MongoDB. The contract is the result rows, byte for byte, measured against a local test database (SQLite or a container), so the samples need no cloud account. Nothing of this is built yet.
Quick start
paretostack examples list the example projects
paretostack examples run word_filter --yes optimize one (runs its program several times, in a copy)
paretostack plan ./myproject what would change in your code (nothing is run)
paretostack run ./myproject --yes optimize, verify, report
Your original files are never changed: the result is a patch (paretostack apply ./myproject --patch FILE).