The agent-first database

Built for agents. Not retrofitted for them. Relational, graph, vector, and document models with 50+ RAG pipeline functions and 17 MCP tools — designed for AI agents that need to understand, query, and act on structured data.

Four data models. One database.

Stop stitching together separate databases for each data paradigm. LoamDB unifies them on Postgres so your agents get a single, coherent data layer.

Relational

Drizzle ORM with full type safety. Normalized schemas for people, clients, deals, and compensation.

Drizzle + pgTyped

Graph

Org charts, reporting lines, and relationship networks. BFS traversal for manager hierarchies and team structures.

BFS traversal + adjacency

Vector

pgvector with HNSW indexing. Semantic search across all entity types. Embeddings generated at ingest time.

pgvector + HNSW

Document

JSONB columns with Schema.org-aligned metadata. Flexible storage for unstructured content alongside structured data.

JSONB + Schema.org

“Good soil doesn't get the credit. It just makes everything above it possible.”

How they compose

A single entity participates in all four models simultaneously. Query it relationally, traverse it as a graph, search it by meaning, or read its raw document.

// One person entity, four access patterns
relationalSELECT * FROM people WHERE email = 'alice@co.com'
graphtraverse(alice).reports().depth(3)
vectorsearch("engineering manager in platform")
documentalice.metadata.schema_org.jobTitle

50+ functions from ingestion to answer

A complete RAG pipeline built into the database layer. From chunking to embedding, retrieval to reranking, formatting to delivery.

01

Ingest

Analyze, map, deduplicate, and import with relationship inference.

02

Embed

Generate vector embeddings at ingest time. HNSW indexing for fast retrieval.

03

Retrieve

Multi-strategy retrieval: direct lookup (20ms), semantic search, or full RAG (600ms).

04

Rerank & Format

Rerank results by relevance, format for the consuming agent or LLM context window.

Performance by strategy

Direct lookup: ~20ms — exact match on known entities. Semantic search: ~150ms — vector similarity with reranking. Full RAG: ~600ms — multi-source retrieval with LLM synthesis.

17 MCP tools + 7 function-calling tools

Your agents interact with LoamDB autonomously. MCP tools for structured operations, function-calling tools for LLM-native integration.

MCP Tools

17 tools for structured data operations. Query entities, traverse graphs, manage imports, and administer permissions — all via the Model Context Protocol.

query_entitiestraverse_graphsearch_semanticimport_csvmanage_permissionsget_schema+11 more

Function-Calling Tools

7 tools designed for LLM function-calling. Optimized for token efficiency with latency benchmarks from direct lookup (20ms) to full RAG (600ms).

lookup_personsearch_knowledgeget_org_chartquery_pipelinecheck_permissionsget_clientgenerate_report

Powered by Postgres

LoamDB isn't a greenfield engine. It's a structured layer on top of the most trusted database in the world. Postgres extensions (pgvector, JSONB, CTEs) provide the foundation. Your data lives in a database you already know how to operate.

pgvector
HNSW indexing
JSONB
CTEs
Row-level security
Extensions

Ready to build with LoamDB?

Start free. Scale with usage. No credit card required.