CREATE EXTENSION/neurondb

PostgreSQL AI Factory.

PostgreSQL AI extension for vector search, embeddings, ML inference, RAG pipelines, MCP server, and agentic AI runtime. Runs in-process with SQL functions.

psql
Quickstart
CREATE EXTENSION neurondb;
PostgreSQL 16 to 18Pure CGPU: CUDA / ROCm / Metal665+ SQL functions
NeuronDB Ecosystem
4 Products • Complete AI Stack
NeuronDB Ecosystem: NeuronDB, NeuronAgent, and NeuronMCP

NeuronDB Console

Manage your database and workflows from a unified interface

neurondb
console • demo
pg17healthy
Run vector + RAG queries in SQL
Execute queries, view data, and compose workflows directly from the console.
SQL
SQL Editordemo
-- Vector similarity search SELECT id, similarity, text FROM vector_search('embeddings', '[0.12, -0.45, 0.78, ...]'::vector(384), 5 );
Results5 rows
idsimilaritytext
10420.9134kubernetes helm chart with prometheus grafana jaeger observability stack…
9910.9011hnsw index build parameters and ef_search tuning for optimal performance…
8070.8876hugging face dataset loader inserts embeddings into vector(384) columns…
5230.8754background workers for async embedding generation and indexing tasks…
3890.8621GPU acceleration for batch vector operations with CUDA support enabled…
Performance
Query Time
8.42ms
Latency (P95)
12.5ms
QPS
8.2k
GPU Status
enabled78% util
Query Statistics
Execution
Rows Returned5
Cache Hit96%
PlanIndex Scan (HNSW)
Connection
Databaseneurondb
VersionPostgreSQL 17
Index TypeHNSW
Summary
Total Queries1,247
Success Rate99.8%
Vector Dim384

Trusted by teams building SQL-first AI — PostgreSQL-native vector search, ML inference, and RAG in one extension.

665+
SQL Functions
52
ML Algorithms
6
Vector Types
4
Background Workers

NeuronDB vs. Alternatives

Comparison of NeuronDB with other PostgreSQL AI and vector extensions

FeatureNeuronDBpgvectorpgvectorscalepgaiPostgresML
Index typesHNSW, IVF, PQ, hybrid, multi-vectorHNSW + IVFStreamingDiskANNUses pgvectorpgvector-based
ML InferenceONNX (C++)NoneNoneAPI callsPython ML libs
Embedding GenerationIn-database (ONNX)ExternalExternalExternal APIIn-database (Transformers)
Hybrid SearchNative (Vector+FTS)ManualManualManualManual
RerankingCross-encoder, LLM, ColBERT, MMRNoneNoneNoneNone
ML Algorithms52 algorithms: RF, XGBoost, LightGBM, CatBoost, SVM, KNN, DT, NB, NN, K-means, DBSCAN, GMM, PCA, etc.NoneNoneNoneXGBoost, LightGBM, sklearn suite, Linear/Logistic
Background Workers4 workers: neuranq, neuranmon, neurandefrag, neuranllmNoneNoneNoneNone
RAG PipelineComplete In-DBNoneNonePartial (API)Partial (Python)
QuantizationFP16, INT8, Binary (2x-32x)Binary onlyBinary onlyNoneNone
ImplementationPure CPure CPure CRust + SQLPython + C
GPU SupportCUDA + ROCm + Metal (native C/C++)NoneNoneNoneCUDA (via Python)
PostgreSQL Versions16, 17, 1812-1815-1816-1814-16
Vector Types6 types: vector, vectorp, vecmap, vgraph, rtext, sparse_vector1 type: vector1 type: vectorUses pgvectorUses pgvector
Distance Metrics10+ metrics: L2, Cosine, Inner Product, Manhattan, Hamming, Jaccard, etc.3 metrics: L2, Cosine, Inner Product3 metrics: L2, Cosine, Inner ProductUses pgvectorUses pgvector
SQL Functions665+ functions~20 functions~30 functions~15 functions~50 functions
Benchmark coverageRAGAS, MTEB, BEIR integratedManual setup requiredManual setup requiredManual setup requiredManual setup required
HNSW Index Build Performance606ms (50K, 128-dim L2, 10.1x), 583ms (50K, 128-dim Cosine, 8.8x), 146ms (10K, 768-dim L2, 27.1x), 1,208ms (100K, 128-dim L2, 13.0x)6,108ms (50K, 128-dim L2, baseline), 5,113ms (50K, 128-dim Cosine), 3,960ms (10K, 768-dim L2), 15,696ms (100K, 128-dim L2)Varies by configurationUses pgvectorUses pgvector
Performance (QPS)100K+ (with GPU)10K-50K50K-100KLimited (API overhead)5K-20K (Python overhead)
DependenciesZero (pure C, optional ONNX)Zero (pure C)Zero (pure C)Rust runtimePython + ML libraries

FAQ

Frequently asked questions

Quick answers about NeuronDB and the PostgreSQL AI stack.

NeuronDB is a PostgreSQL extension that adds vector search, machine learning inference, and RAG pipeline capabilities directly in your database. Implemented in pure C with zero dependencies.
NeuronDB extends PostgreSQL with 665+ SQL functions for vector operations, ML inference, and RAG workflows. It uses HNSW indexing for fast vector search and supports GPU acceleration for batch operations.
NeuronDB provides a complete AI stack in PostgreSQL: vector search, 52 ML algorithms, RAG pipelines, and agent infrastructure. No external services required. Everything runs in your database.
NeuronDB runs as a PostgreSQL extension on PostgreSQL 16, 17, and 18. Supports Linux, macOS, and Windows. GPU acceleration available for CUDA, ROCm, and Metal.
No. NeuronDB provides vector search, 52 ML algorithms, embedding generation, and a full RAG pipeline inside PostgreSQL. You can keep all data and logic in one database and optionally use NeuronMCP and NeuronAgent for MCP tools and agent runtime.

Get started

Build with SQL.

CREATE EXTENSION neurondb; then scale to production with Kubernetes and Helm. No external vector DB or ML service required.