Sign inSign up

vishva123/postgres-for-ai

By vishva123

•Updated 8 months ago

A production-ready PostgreSQL Docker image designed for AI workloads—all in one database.

Image
Machine learning & AI
Data science
Databases & storage
0

1.9K

vishva123/postgres-for-ai repository overview

⁠🧠 PostgreSQL for AI

PostgreSQL with pgvector, Apache AGE, and AI-ready extensions

A production-ready PostgreSQL Docker image designed for AI, RAG, vector search, and graph workloads—all in one database.


⁠🚀 What’s Included

  • PostgreSQL
  • **pgvector ** – vector embeddings & similarity search
  • **Apache AGE ** – graph database (Cypher)
  • pg_cron – scheduled jobs inside PostgreSQL
  • pg_stat_statements – query performance monitoring
  • AI-friendly search_path (ag_catalog, public)
  • LightRAG-compatible (public.vector)

⁠📦 Docker Image

docker pull vishva123/postgres-for-ai:latest

⁠▶️ Quick Run

docker run -d \
  --name postgres-ai \
  -e POSTGRES_USER=admin \
  -e POSTGRES_PASSWORD=admin \
  -e POSTGRES_DB=ai \
  -p 5432:5432 \
  vishva123/postgres-for-ai:18.2

PostgreSQL will be available at:

localhost:5432

⁠🧩 Enabled Extensions

ExtensionPurpose
pgvectorVector search
ageGraph queries (Cypher)
pg_cronScheduled jobs
pg_stat_statementsQuery analytics
pg_trgmText similarity
uuid-osspUUID generation

⁠🧠 AI Use Cases

  • Retrieval-Augmented Generation (RAG)
  • Vector similarity search
  • Hybrid Graph + Vector querying
  • LLM memory & embeddings
  • AI metadata & analytics pipelines

⁠🧪 Verify Installation

SELECT * FROM pg_extension;

Expected:

vector, age, pg_cron, pg_stat_statements, pg_trgm, uuid-ossp

⁠🧬 Vector Example

CREATE TABLE embeddings (
  id SERIAL PRIMARY KEY,
  content TEXT,
  embedding VECTOR(768)
);

⁠🕸️ Graph Example (Apache AGE)

SELECT * FROM cypher('graph', $$
  MATCH (n) RETURN n
$$) AS (n agtype);

⁠🔗 Source Code

GitHub repository: 👉 https://github.com/vishvaRam/Postgres-For-AI⁠


⁠👤 Maintainer

Vishva Ram AI Engineer | Generative AI | RAG | Graph + Vector Systems


⭐ If this image helps your AI project, consider starring the GitHub repo!

Tag summary

Content type

Image

Digest

sha256:c6f83e9c8…

Size

598.6 MB

Last updated

8 months ago

docker pull vishva123/postgres-for-ai:17.2