A revenue metric returned in 200 milliseconds is worth zero dollars if the underlying number is wrong.
As enterprise engineering shifts toward agentic analytics, systems architects are hitting a severe bottleneck. Large Language Models (LLMs) can generate syntactically valid SQL queries, but they lack the semantic context to know where data lives, what specific column definitions actually mean across disparate databases, whether a dataset is authorized for production use, or how business logic reconciles across legacy tables. Generating queries faster does not solve the fundamental issue of data correctness.
NVIDIA Auto Ontology solves this structural flaw. Distributed under the Apache License 2.0, it operates as an open Python framework designed to build a semantic, graph-based reasoning layer over raw data. It translates enterprise metadata into a unified context layer, reconciles contradictory definitions across systems, and exposes deterministic knowledge to agent harnesses through Model Context Protocol (MCP), CLI, and native APIs.
+-------------------------------------------------------------------+
| Agent Harness / User |
+-------------------------------------------------------------------+
|
(MCP / CLI / REST APIs)
v
+-------------------------------------------------------------------+
| NVIDIA Auto Ontology |
| +--------------+ +--------------+ +---------------------+ |
| | Discover | | Ground | | Validate | |
| +--------------+ +--------------+ +---------------------+ |
| | Expose | | Learn | | Postgres + pgvector | |
| +--------------+ +--------------+ +---------------------+ |
+-------------------------------------------------------------------+
|
(NVIDIA NIM: Nemotron & Llama Endpoints)
v
+-------------------------------------------------------------------+
| Relational Databases / Data Warehouse |
+-------------------------------------------------------------------+
The Five Primitives of Semantic Grounding
Auto Ontology acts as a middle-tier translation and governance engine. Rather than relying on simple prompt engineering or naive Retrieval-Augmented Generation (RAG), it establishes five core primitives to govern agent interaction with relational databases:
- Discover: Generates enterprise ontologies automatically from underlying database metadata, links existing semantic models, and builds an AI-ready knowledge graph.
- Ground: Assigns explicit business meaning to entities, metrics, and join relationships across disconnected databases, eliminating ambiguous column selections.
- Validate: Intercepts generated queries, checking them against certified metric definitions and data lineage before execution. Every response includes verifiable provenance.
- Expose: Serves unified context seamlessly to external agent frameworks using MCP, CLI tools, or HTTP endpoints.
- Learn: Implements a feedback loop that absorbs certified human corrections and runtime execution telemetry back into the graph, improving context accuracy over time.
Architectural Components and Tech Stack
Auto Ontology isolates its execution environments into dedicated services, ensuring scalability and strict boundary separation between administrative flows, API translation, and vector ingestion operations.
| Component | Technology Stack | Role / Function | Default Port |
|---|---|---|---|
| Frontend | Next.js 16 (React 19, TypeScript, Tailwind CSS 4), Better Auth, Prisma | Web UI for chat, catalog analytics, system settings, RBAC, and API gateway operations | 3000 |
| Backend | FastAPI (Python 3.12+), LangChain | Chat service, Natural Language to SQL translation, catalog engine, datasource APIs | 3001 |
| Ingestion Worker | FastAPI (Python 3.12+) | Async pipeline that ingests tabular sources and generates vector embeddings | 3002 |
| Postgres + pgvector | PostgreSQL with pgvector extension | System metadata database, semantic catalog, ontology graph storage, vector store | 5432 |
| HashiCorp Vault | Vault (Optional) | Secure store for encrypted database connection credentials | Direct Integration |
The Web UI provides a centralized interface for monitoring data catalog states, inspecting lineage, performing multi-agent chat interactions, and configuring platform role-based access control (RBAC) via Better Auth.
Model Triplet Orchestration via NVIDIA NIM
To execute natural-language-to-SQL (NL-to-SQL) translation and semantic entity resolution, Auto Ontology utilizes NVIDIA NIM inference microservices. The framework supports both hosted execution via the NVIDIA API catalog (integrate.api.nvidia.com) and self-hosted local NIM instances.
Instead of hardcoding a monolithic model for all tasks, Auto Ontology decouples model selection into functional roles governed by a flexible model triplet pattern.
[ DEFAULT_MODELS_* ] (Global System Fallback)
|
+-------------+-------------+-------------+
| | |
v v v
[ REASONING_* ] [ NON_REASONING_* ] [ EMBED_* / RERANK_* ]
(NL-to-SQL / Chat) (Entity Extraction) (Vector Ops)
Each functional role is configured using an environment variable triplet consisting of an endpoint URL, an API key, and a target model identifier:
DEFAULT_MODELS: The baseline configuration. Unset fields in specialized triplets automatically fall back to these values.REASONING: High-capacity models dedicated to main conversational logic and complex SQL query generation. Default model:nvidia/nemotron-3.5-lightning-30b-a3b.NON_REASONING: Lightweight, high-throughput models designed for rapid schema parsing and entity extraction.EMBED: Text embedding models responsible for vector index creation during ingestion and retrieval. Default model:nvidia/nemotron-3-embed-1b.RERANK: Specialized reranking models used to sort context retrieval candidates. Default model:nvidia/llama-nemotron-rerank-vl-1b-v2.
Environment Variable Fallback Mechanics
The fallback pattern allows engineering teams to deploy Auto Ontology using a minimal configuration or tune individual models based on operational cost and latency targets:
bash# Basic Setup: Single model family fallback DEFAULT_MODELS_ENDPOINT="https://integrate.api.nvidia.com/v1" DEFAULT_MODELS_API_KEY="nvapi-xxxx..." DEFAULT_MODELS_MODEL="nvidia/nemotron-3.5-lightning-30b-a3b" # Advanced Override: Dedicated Embeddings and Reranking configuration EMBED_MODEL="nvidia/nemotron-3-embed-1b" RERANK_MODEL="nvidia/llama-nemotron-rerank-vl-1b-v2"
If an individual API key variable such as REASONING_API_KEY is omitted, the runtime falls back to DEFAULT_MODELS_API_KEY. For legacy support, the environment loader also respects NVIDIA_API_KEY.
Query Execution and Benchmarking
When an agent executes an analytic query, Auto Ontology checks the request against the ontology layer stored within PostgreSQL. The schema definitions are mapped to business entities rather than raw table names. The FastAPI backend running LangChain constructs the grounded query, passes it to the configured REASONING NIM model, and verifies the generated SQL against pre-compiled schema logic.
To measure accuracy across complex multi-join schemas, developers can evaluate Auto Ontology using the text-to-SQL BIRD benchmark available in the project's SQL evaluation repository.
For quick deployment testing, the project includes sample configurations that run against Microsoft's Wide World Importers sales database:
bash# Clone and spin up the local development stack via Docker Compose git clone https://github.com/NVIDIA/auto-ontology.git cd auto-ontology # Launch core components: Next.js Frontend, FastAPI Services, and Postgres + pgvector docker compose up -d
For production deployments, a Helm chart is provided to deploy the system natively onto Kubernetes clusters.
Governance, Licensing, and Development Status
Auto Ontology provides a deterministic layer that prevents LLMs from guessing database structures. By standardizing metadata management in PostgreSQL alongside vector embeddings in pgvector, the framework creates an auditable bridge between unconstrained language models and enterprise data stores.
- License: Distributed under the Apache License 2.0. Third-party dependencies are documented in
THIRD_PARTY_NOTICES.md. - Contributions: NVIDIA explicitly maintains Auto Ontology as an open-source distribution but is currently not accepting external contributions to the repository.
Engineers looking to eliminate agentic hallucinations in corporate reporting pipelines can deploy Auto Ontology to govern, ground, and validate query translation before bad data impacts business decisions.
References
- https://github.com/NVIDIA/auto-ontology
- https://www.marktechpost.com/2026/11/01/nvidia-auto-ontology-open-source-semantic-layer-ai-agents/
- https://spec.edmcouncil.org/auto/
