zpq - a ridiculously fast zero-dependency parquet engine, cli, and library in Zig
What it is zpq is a companion to tools like DuckDB, Polars, or your typical Spark/jvm stack for working with Parquet files, whether locally or in object storage.
It's for anyone who works with Parquet whether you're using it through something else like StarRocks, DuckDB, Athena, Spark, etc. as there's a good chance zpq can speed up whatever you're doing in multiple places, whether reading, writing, querying, filtering, or aggregating.
What makes it special is it doesn't try to be a general-purpose, fully SQL-compliant querying engine; instead it's laser-focused on the Parquet format itself and how to read and write that as quickly as possible, utilizing dozens of advanced hardware-level optimizations, many of which are novel.
This doesn't mean it's faster than anything else at everything, but for a large variety of use-cases, it can be significantly faster. The latest version line, 0.6.x, includes a special kind of join support which offers a new way to get certain kinds of performance gains which I'm not sure have ever been possible before.
How I built it It's been in development for about a year now, with agentic engineering practices designing, performance testing, and correctness testing happening on a wide variety of hardware and from many different models and agent harnesses participating in an ever-evolving software factory, with me at the helm the entire time - proposing new styles of testing, new Zig features and programming techniques to try, asking questions about and learning about all sorts of hardware tricks like how the best existing tools leverage the most advanced CPU features, system memory capabilities, network request parallelization and request pipelining, and more.
I also heavily utilize my private inference services including Qwen 3.8 27B in conjunction with cloud-based frontier models often helping with the planning.
What surprised me or went wrong The most surprising thing to me is how capable the best current agentic harnesses are at continuing very long self-directed campaigns of work now if you have the right guardrails in place for how to test, what to try, and how to thread together new pieces of functionality.
The hard part remains deciding how much I need to understand every last line of code vs. trusting the process, results, and instrumentation. I'm confident along with many others that this is the next frontier of software development.
Can you expand on this? How does this join work and how does that get the performance gains?
Ya, happy to!
Lots more detail about them here too, btw: https://zpq.chicagobuss.dev/joins.html
But the gist of it is that these joins are first of all, not comprehensive - there are certain sql operations that you won't be able to do at all with this.
However, for the majority of 'data shoveling' types of joins out there, what zpq can do is filter what you'll need to consider from the statistics and only read the necessary parts of every parquet file involved to perform the join.
This isn't completely unique to zpq, but zpq is already tuned for this sort of workload when working with single files, so the effect compounds the more files involved.
I like to think of it this way - almost every other tool that works with Parquet has to think about full sql compliance first, and file formats second. zpq flips this - the file format is first and sql support is only best-effort.
Happy to answer any more specific questions though!
Super interesting, yeah I can see how relaxing SQL requirements could lead to some pretty big wins!