PostgresML brings machine learning and AI directly into PostgreSQL, so you can train, deploy and query models with SQL instead of shipping data to a separate ML service. It adds GPU-accelerated training and inference — including transformer models and vector search — to the database most teams already run. The project has earned about 6,800 stars on GitHub, is MIT licensed, and is actively developed.
PostgresML is a PostgreSQL extension that turns the database into an ML platform. Classical algorithms from XGBoost, LightGBM and scikit-learn can be trained with a single SQL command on tables in place, with GPUs used automatically when available. For modern AI workloads it adds Hugging Face transformer inference inside SQL queries, text embedding generation, and high-performance vector search for RAG applications — alongside pgvector-style similarity queries. Because models live where the data lives, applications can score, classify, forecast or embed in one query with no network hop and no separate feature store or model server to operate. The team also runs PostgresML Cloud, a managed service with serverless GPUs, for teams that want the same features without operating the database themselves.
Freemium. The PostgresML extension is free and open source under the MIT license for self-hosting; PostgresML Cloud offers paid managed databases with GPU capacity.
Backend and data teams who already use PostgreSQL and want predictions, embeddings and retrieval-augmented generation in SQL — without building and maintaining a separate ML serving stack.