Analysis updated 2026-07-08 · repo last pushed 2025-04-09
Run a machine learning model on your database data using a simple SQL query.
Classify customer support tickets directly inside your DuckDB data pipeline without writing separate Python scripts.
Apply an ONNX model to multiply or transform input values and return results as part of a standard query.
| loloxwg/duckdb-onnx | aerl-official/aerl-c-framework | bong-water-water-bong/npu-gpu-cpu | |
|---|---|---|---|
| Stars | 4 | 4 | 3 |
| Language | C++ | C++ | C++ |
| Last pushed | 2025-04-09 | — | — |
| Maintenance | Stale | — | — |
| Setup difficulty | hard | easy | hard |
| Complexity | 4/5 | 2/5 | 5/5 |
| Audience | data | developer | researcher |
Figures from each repo's GitHub metadata at analysis time.
Requires building a C++ DuckDB extension from source using VCPKG for dependency management, which needs a configured C++ build environment.
This project is an extension for DuckDB (a fast, embeddable data analysis tool) that lets you run ONNX models directly inside your database queries. ONNX is a standard format for machine learning models. The core idea is that instead of exporting your data out of the database to run it through a separate machine learning tool, you can feed data through a model using a simple SQL function. The repository is currently in an early, template-like stage, and the README leaves the broader project goals blank, but it includes a working example where a model multiplies input values. At a high level, the extension adds a custom function called onnx() to DuckDB. You call this function in a SQL query and pass it two things: the file path to an ONNX model, and a set of input values structured with shapes and numbers. In the provided example, passing in a list of numbers through a sample model returns the squared values of those numbers. The function handles passing the data to the model and returning the model's output directly as query results. This tool would be useful for data analysts, data scientists, or developers who already use DuckDB to slice and filter large datasets and want to layer in machine learning predictions. For example, if you have a model trained to classify customer support tickets, you could theoretically use this extension to score incoming tickets right inside your database pipeline without writing a separate Python script. The project is built using C++ and uses a system called VCPKG to manage its dependencies. It is explicitly based on DuckDB's official extension template, meaning the creator used a starter scaffold provided by DuckDB to build this functionality. Because it is still using placeholder text in its documentation, it appears to be a work in progress or an experimental project rather than a finished product ready for production use.
A DuckDB extension that lets you run ONNX machine learning models directly inside SQL queries, so you can get predictions without exporting your data to a separate tool.
Mainly C++. The stack also includes C++, DuckDB, ONNX.
Stale — no commits in 1-2 years (last push 2025-04-09).
Setup difficulty is rated hard, with roughly 1h+ to a first successful run.
Mainly data.
This repo across BitVibe Labs
Verify against the repo before relying on details.