NVIDIA/auto-ontologyPublic

Auto Ontology is a Python framework for building semantic, graph-based reasoning layers over data. It enables deterministic query generation, better context retrieval, and more explainable AI for LLM and agent workflows.

AI summary: A Python framework for building semantic, graph-based reasoning layers over data.

Stars
17.7K
+2.7K today
Forks
1.6K
Watchers
73
Open issues
99
Open PRs
79
Contributors
~23
Commits
1.5K
Branches
145
Views (30d)
11

PythonApache-2.0Created Apr 27, 2026Last push 2d agoLatest release v1.3.0+3.5K stars this week+12.9K this month

Quick answers

What is auto-ontology?
A Python framework for building semantic, graph-based reasoning layers over data.
What does auto-ontology do?
Auto Ontology is a Python framework designed to build semantic reasoning layers. It leverages graph-based structures to enhance data interpretation and context retrieval. The tool enables deterministic query generation for more reliable data interactions. It provides explainable AI capabilities for LLM and agent workflows. This significantly improves the transparency and accuracy of complex AI systems.
Who is auto-ontology for?
Data scientists and AI engineers building complex, reasoning-driven LLM applications. It is particularly valuable for projects requiring high accuracy and explainability. Familiarity with Python, knowledge graphs, and semantic data is highly recommended.
How do I get started with auto-ontology?
git clone https://github.com/NVIDIA/auto-ontology
How popular is auto-ontology on GitHub?
NVIDIA/auto-ontology has 17,666 stars and 1,569 forks on GitHub, and gained 3,537 stars in the last 7 days.
What license does auto-ontology use?
NVIDIA/auto-ontology is released under the Apache-2.0 license.

Star history

since Nov 4, 2026
05K10K15KNov 2026Nov 2026Nov 2026Nov 2026
17.7K stars as of Nov 29, 2026. Measured daily since Nov 4, 2026; GitHub no longer exposes earlier star timestamps.

Contribution activity

commits per day, last 52 weeks
NovDecJanFebMarAprMayJunJulAugSepOctNovMonWedFri2025-11-30: 0 commits2025-12-01: 0 commits2025-12-02: 0 commits2025-12-03: 0 commits2025-12-04: 0 commits2025-12-05: 0 commits2025-12-06: 0 commits2025-12-07: 0 commits2025-12-08: 0 commits2025-12-09: 0 commits2025-12-10: 0 commits2025-12-11: 0 commits2025-12-12: 0 commits2025-12-13: 0 commits2025-12-14: 0 commits2025-12-15: 0 commits2025-12-16: 0 commits2025-12-17: 0 commits2025-12-18: 0 commits2025-12-19: 0 commits2025-12-20: 0 commits2025-12-21: 0 commits2025-12-22: 0 commits2025-12-23: 0 commits2025-12-24: 0 commits2025-12-25: 0 commits2025-12-26: 0 commits2025-12-27: 0 commits2025-12-28: 0 commits2025-12-29: 0 commits2025-12-30: 0 commits2025-12-31: 0 commits2026-01-01: 0 commits2026-01-02: 0 commits2026-01-03: 0 commits2026-01-04: 0 commits2026-01-05: 0 commits2026-01-06: 0 commits2026-01-07: 0 commits2026-01-08: 0 commits2026-01-09: 0 commits2026-01-10: 0 commits2026-01-11: 0 commits2026-01-12: 0 commits2026-01-13: 0 commits2026-01-14: 0 commits2026-01-15: 0 commits2026-01-16: 0 commits2026-01-17: 0 commits2026-01-18: 0 commits2026-01-19: 0 commits2026-01-20: 0 commits2026-01-21: 0 commits2026-01-22: 0 commits2026-01-23: 0 commits2026-01-24: 0 commits2026-01-25: 0 commits2026-01-26: 0 commits2026-01-27: 0 commits2026-01-28: 0 commits2026-01-29: 0 commits2026-01-30: 0 commits2026-01-31: 0 commits2026-02-01: 0 commits2026-02-02: 0 commits2026-02-03: 0 commits2026-02-04: 0 commits2026-02-05: 0 commits2026-02-06: 0 commits2026-02-07: 0 commits2026-02-08: 0 commits2026-02-09: 0 commits2026-02-10: 0 commits2026-02-11: 0 commits2026-02-12: 0 commits2026-02-13: 0 commits2026-02-14: 0 commits2026-02-15: 0 commits2026-02-16: 0 commits2026-02-17: 0 commits2026-02-18: 0 commits2026-02-19: 0 commits2026-02-20: 0 commits2026-02-21: 0 commits2026-02-22: 0 commits2026-02-23: 0 commits2026-02-24: 0 commits2026-02-25: 0 commits2026-02-26: 0 commits2026-02-27: 0 commits2026-02-28: 0 commits2026-03-01: 0 commits2026-03-02: 0 commits2026-03-03: 0 commits2026-03-04: 0 commits2026-03-05: 0 commits2026-03-06: 0 commits2026-03-07: 0 commits2026-03-08: 0 commits2026-03-09: 0 commits2026-03-10: 0 commits2026-03-11: 0 commits2026-03-12: 0 commits2026-03-13: 0 commits2026-03-14: 0 commits2026-03-15: 0 commits2026-03-16: 0 commits2026-03-17: 0 commits2026-03-18: 0 commits2026-03-19: 0 commits2026-03-20: 0 commits2026-03-21: 0 commits2026-03-22: 0 commits2026-03-23: 0 commits2026-03-24: 0 commits2026-03-25: 0 commits2026-03-26: 0 commits2026-03-27: 0 commits2026-03-28: 0 commits2026-03-29: 0 commits2026-03-30: 0 commits2026-03-31: 0 commits2026-04-01: 0 commits2026-04-02: 0 commits2026-04-03: 0 commits2026-04-04: 0 commits2026-04-05: 0 commits2026-04-06: 1 commit2026-04-07: 0 commits2026-04-08: 0 commits2026-04-09: 0 commits2026-04-10: 1 commit2026-04-11: 0 commits2026-04-12: 5 commits2026-04-13: 14 commits2026-04-14: 4 commits2026-04-15: 10 commits2026-04-16: 17 commits2026-04-17: 0 commits2026-04-18: 0 commits2026-04-19: 3 commits2026-04-20: 13 commits2026-04-21: 6 commits2026-04-22: 0 commits2026-04-23: 17 commits2026-04-24: 0 commits2026-04-25: 0 commits2026-04-26: 1 commit2026-04-27: 9 commits2026-04-28: 7 commits2026-04-29: 7 commits2026-04-30: 11 commits2026-05-01: 0 commits2026-05-02: 0 commits2026-05-03: 2 commits2026-05-04: 0 commits2026-05-05: 2 commits2026-05-06: 2 commits2026-05-07: 2 commits2026-05-08: 0 commits2026-05-09: 0 commits2026-05-10: 0 commits2026-05-11: 6 commits2026-05-12: 2 commits2026-05-13: 12 commits2026-05-14: 11 commits2026-05-15: 0 commits2026-05-16: 0 commits2026-05-17: 0 commits2026-05-18: 12 commits2026-05-19: 4 commits2026-05-20: 7 commits2026-05-21: 0 commits2026-05-22: 0 commits2026-05-23: 0 commits2026-05-24: 10 commits2026-05-25: 7 commits2026-05-26: 3 commits2026-05-27: 10 commits2026-05-28: 5 commits2026-05-29: 0 commits2026-05-30: 0 commits2026-05-31: 3 commits2026-06-01: 1 commit2026-06-02: 5 commits2026-06-03: 3 commits2026-06-04: 9 commits2026-06-05: 0 commits2026-06-06: 0 commits2026-06-07: 9 commits2026-06-08: 9 commits2026-06-09: 16 commits2026-06-10: 20 commits2026-06-11: 16 commits2026-06-12: 3 commits2026-06-13: 7 commits2026-06-14: 20 commits2026-06-15: 5 commits2026-06-16: 9 commits2026-06-17: 3 commits2026-06-18: 3 commits2026-06-19: 1 commit2026-06-20: 1 commit2026-06-21: 3 commits2026-06-22: 18 commits2026-06-23: 17 commits2026-06-24: 5 commits2026-06-25: 28 commits2026-06-26: 0 commits2026-06-27: 0 commits2026-06-28: 12 commits2026-06-29: 8 commits2026-06-30: 18 commits2026-07-01: 2 commits2026-07-02: 3 commits2026-07-03: 0 commits2026-07-04: 0 commits2026-07-05: 2 commits2026-07-06: 10 commits2026-07-07: 12 commits2026-07-08: 7 commits2026-07-09: 9 commits2026-07-10: 3 commits2026-07-11: 4 commits2026-07-12: 7 commits2026-07-13: 15 commits2026-07-14: 11 commits2026-07-15: 12 commits2026-07-16: 11 commits2026-07-17: 1 commit2026-07-18: 0 commits2026-07-19: 1 commit2026-07-20: 5 commits2026-07-21: 7 commits2026-07-22: 16 commits2026-07-23: 3 commits2026-07-24: 0 commits2026-07-25: 1 commit2026-07-26: 22 commits2026-07-27: 14 commits2026-07-28: 3 commits2026-07-29: 6 commits2026-07-30: 7 commits2026-07-31: 0 commits2026-08-01: 1 commit2026-08-02: 10 commits2026-08-03: 4 commits2026-08-04: 18 commits2026-08-05: 10 commits2026-08-06: 11 commits2026-08-07: 1 commit2026-08-08: 0 commits2026-08-09: 1 commit2026-08-10: 8 commits2026-08-11: 5 commits2026-08-12: 9 commits2026-08-13: 5 commits2026-08-14: 1 commit2026-08-15: 0 commits2026-08-16: 2 commits2026-08-17: 7 commits2026-08-18: 4 commits2026-08-19: 6 commits2026-08-20: 3 commits2026-08-21: 0 commits2026-08-22: 1 commit2026-08-23: 7 commits2026-08-24: 12 commits2026-08-25: 12 commits2026-08-26: 11 commits2026-08-27: 6 commits2026-08-28: 1 commit2026-08-29: 0 commits2026-08-30: 10 commits2026-08-31: 3 commits2026-09-01: 1 commit2026-09-02: 6 commits2026-09-03: 4 commits2026-09-04: 0 commits2026-09-05: 0 commits2026-09-06: 13 commits2026-09-07: 11 commits2026-09-08: 4 commits2026-09-09: 4 commits2026-09-10: 13 commits2026-09-11: 0 commits2026-09-12: 0 commits2026-09-13: 0 commits2026-09-14: 7 commits2026-09-15: 7 commits2026-09-16: 3 commits2026-09-17: 6 commits2026-09-18: 0 commits2026-09-19: 0 commits2026-09-20: 0 commits2026-09-21: 0 commits2026-09-22: 9 commits2026-09-23: 7 commits2026-09-24: 0 commits2026-09-25: 0 commits2026-09-26: 1 commit2026-09-27: 0 commits2026-09-28: 11 commits2026-09-29: 16 commits2026-09-30: 17 commits2026-10-01: 10 commits2026-10-02: 0 commits2026-10-03: 0 commits2026-10-04: 7 commits2026-10-05: 1 commit2026-10-06: 9 commits2026-10-07: 14 commits2026-10-08: 13 commits2026-10-09: 0 commits2026-10-10: 0 commits2026-10-11: 6 commits2026-10-12: 3 commits2026-10-13: 9 commits2026-10-14: 9 commits2026-10-15: 9 commits2026-10-16: 0 commits2026-10-17: 1 commit2026-10-18: 2 commits2026-10-19: 6 commits2026-10-20: 3 commits2026-10-21: 0 commits2026-10-22: 2 commits2026-10-23: 1 commit2026-10-24: 0 commits2026-10-25: 11 commits2026-10-26: 4 commits2026-10-27: 0 commits2026-10-28: 2 commits2026-10-29: 2 commits2026-10-30: 0 commits2026-10-31: 0 commits2026-11-01: 1 commit2026-11-02: 1 commit2026-11-03: 9 commits2026-11-04: 3 commits2026-11-05: 2 commits2026-11-06: 1 commit2026-11-07: 1 commit2026-11-08: 0 commits2026-11-09: 3 commits2026-11-10: 1 commit2026-11-11: 0 commits2026-11-12: 0 commits2026-11-13: 2 commits2026-11-14: 6 commits2026-11-15: 1 commit2026-11-16: 7 commits2026-11-17: 5 commits2026-11-18: 4 commits2026-11-19: 7 commits2026-11-20: 2 commits2026-11-21: 0 commits2026-11-22: 5 commits2026-11-23: 15 commits2026-11-24: 71 commits2026-11-25: 11 commits2026-11-26: 0 commits2026-11-27: 0 commits2026-11-28: 0 commits
1,260 commits in the last yearLessMore

Signals and awards

derived from tracked data
  • Widely adopted

    17,666 stars

  • Rising fast

    +3,537 stars this week

  • Very active

    1,260 commits in 52 weeks

  • Permissive license

    Apache-2.0

  • Continuous integration

    Automated checks passing

  • Repeat trending

    12 trending appearances

What auto-ontology does

Auto Ontology is a Python framework designed to build semantic reasoning layers. It leverages graph-based structures to enhance data interpretation and context retrieval. The tool enables deterministic query generation for more reliable data interactions. It provides explainable AI capabilities for LLM and agent workflows. This significantly improves the transparency and accuracy of complex AI systems.

Data scientists and AI engineers building complex, reasoning-driven LLM applications. It is particularly valuable for projects requiring high accuracy and explainability. Familiarity with Python, knowledge graphs, and semantic data is highly recommended.

  • Semantic reasoning: builds graph-based layers to improve data interpretation and context.
  • Deterministic querying: enables reliable and predictable query generation over structured data.
  • Explainable AI: provides transparency into the reasoning processes of LLM workflows.
  • Graph structures: utilizes knowledge graphs to represent complex semantic relationships.
  • Python framework: offers a comprehensive set of tools integrated into the Python ecosystem.

Where teams use it

Build reasoning layers

Implement semantic graphs to improve the context retrieval of AI agents.

Generate reliable queries

Use deterministic methods to query complex datasets with high accuracy.

Enhance LLM workflows

Add explainable reasoning capabilities to large language model applications.

Improve data context

Structure unstructured data into semantic graphs for better understanding.

Getting started: git clone https://github.com/NVIDIA/auto-ontology

README

main branch

Auto Ontology

#1 on the BEAVER leaderboard #1 on the BIRD-Interact leaderboard

Agents can retrieve documents and query databases, but reliability gates agentic analytics: a revenue metric answered faster is worth nothing if the number is wrong. Agents need context to answer accurately: what each business concept means, where it lives, how it connects, how to calculate it, where it comes from, and whether to trust it. An ontology holds that context: a shared, governed map from the concepts people ask about to the data behind them. NVIDIA Auto Ontology is an open library that builds that ontology automatically from enterprise metadata, reconciles definitions across systems, and exposes it to any agent harness through MCP, CLI, and API. It complements the semantic models customers already own, and Apache Ossie keeps it portable.

Auto Ontology leads on the BIRD-Interact and BEAVER benchmarks, which test the accuracy of text-to-SQL analytics question answering in interactive flows with ambiguous user inputs and on large-scale, messy databases.

It enables developers to:

  • Discover: generate enterprise ontologies from metadata; connect existing ontologies and semantic models; build AI-ready knowledge graphs.
  • Ground: give agents trusted business meaning for metrics, entities, and relationships; reconcile inconsistent definitions across systems.
  • Validate: test a draft with real questions before experts certify it; check generated queries against the catalog and the definitions retrieval surfaced; return the SQL and steps with every answer.
  • Expose: serve context to any agent harness through MCP, CLI, and API.
  • Learn: fold certified corrections and usage back into the ontology, so shared context improves with use.

An ontology matters most when:

  • questions are varied, open-ended, and ambiguous;
  • data spans many disparate sources with overlapping or conflicting definitions;
  • meanings must be reused and governed across runs, teams, and agents;
  • the model or its context budget can't hold the full documentation;
  • users ask in business terms and need routing to the right source and grain.

With one well-modeled source and a fixed set of questions, direct SQL may be enough.

Quickstart

This runs Auto Ontology with Docker Compose against Wide World Importers, Microsoft's sample sales database. You need Docker with Compose v2, uv, and an NVIDIA API key (nvapi-...) from build.nvidia.com.

  1. Clone the repository and create .env:

    git clone https://github.com/NVIDIA/auto-ontology.git && cd auto-ontology
    cp .env.example .env

    Then set these values in .env:

    DEFAULT_MODELS_API_KEY=nvapi-...
    AUTH_SECRET=<a long random string, e.g. from openssl rand -base64 32>
    APP_URL=http://localhost:3000
    POSTGRES_PASSWORD=<a new password>
    CONNECTION_STRINGS=postgresql://postgres:<the same password>@postgres:5432/wideworldimporters
    AUTO_ONTOLOGY_ADMIN_PASSWORD=<a new password>
    PGADMIN_PASSWORD=<a new password>

    Compose publishes Postgres, pgAdmin, and the web app on the host, so replace each default password before you start it. .env.example also sets an API key per model role: replace each nvapi-your-api-key-here with your key, or delete those lines so they fall back to DEFAULT_MODELS_API_KEY.

  2. Start Postgres and load the sample database. The seed script lives in auto-ontology-eval; pass it the Postgres password you set:

    docker compose up -d --wait postgres
    git clone https://github.com/NVIDIA/auto-ontology-eval.git ../auto-ontology-eval
    (cd ../auto-ontology-eval && uv sync && cp .env.example .env && \
      POSTGRES_PASSWORD='<the same password>' \
      uv run python scripts/seed/seed_wwi.py --database-name wideworldimporters --drop)
  3. Build and start the rest of the stack:

    docker compose up -d --build
  4. Open http://localhost:3000 and sign in with AUTO_ONTOLOGY_ADMIN_EMAIL and AUTO_ONTOLOGY_ADMIN_PASSWORD from .env. Go to Settings → Semantic Compilation and turn it on. Ingestion runs at startup; compilation starts immediately and reports Semantic compilation is ready when it finishes.

  5. Ask a question in Chat:

    What was revenue for the USB food flash drive - sushi roll in Pennsylvania in June 2015?

    The agent resolves revenue, product, and state to terms in the ontology, follows their relationships to the joins it needs, and runs the query. The answer comes back with its SQL and the steps that produced it, so you can check the result against the source:

    Answer:  Revenue for USB food flash drive - sushi roll in Pennsylvania in
             June 2015 was $588.80, from 3 invoice lines.
    
    SQL:     SELECT SUM(il.extendedprice) AS revenue, COUNT(*) AS invoice_lines
             FROM sales.invoicelines il
             JOIN sales.invoices i             ON il.invoiceid = i.invoiceid
             JOIN warehouse.stockitems si      ON il.stockitemid = si.stockitemid
             JOIN sales.customers c            ON i.customerid = c.customerid
             JOIN application.cities ct        ON c.deliverycityid = ct.cityid
             JOIN application.stateprovinces sp ON ct.stateprovinceid = sp.stateprovinceid
             WHERE si.stockitemname = 'USB food flash drive - sushi roll'
               AND sp.stateprovincename = 'Pennsylvania'
               AND i.invoicedate >= '2015-06-01' AND i.invoicedate < '2015-07-01'
    
    Steps:   Resolved terms: Invoice Line (revenue), Stock Item, State Province, Invoice
             Joined: invoice line -> invoice -> customer -> city -> state province
             Validated the filter values against the data, then executed
    
  6. Ask something the data can't answer. Wide World Importers has no advertising data, so a question about ad spend has nothing to resolve against. An agent connected through MCP checks answerability first and asks you to clarify:

    You:    What was return on ad spend for the sushi roll flash drive in June 2015?
    Agent:  check_answerable -> coverage 0.5; no term covers "ad spend"
    Agent:  I can find revenue for that product, but this data has no
            advertising spend, so I can't compute return on ad spend. Do you
            want June 2015 revenue instead, or is ad spend tracked in another
            source I should connect?
    

If the UI loads without its left navigation after a restart, the browser is holding a stale session cookie. Clear site data for localhost:3000 and sign in again. For other setup failures, see the setup skill's troubleshooting guide.

How it works

Auto Ontology works in two stages: it generates an ontology that people certify, and the agent answers questions from it.

The ontology answers six questions, each with its own element:

Question Element In Auto Ontology
What does it mean? Concept A term, such as Customer or Invoice Line, with a description and synonyms
Where is it? Mapping Column attributes tie each term to the tables and columns that hold it
What's connected? Relationship Joins between tables, including bridge tables: declared keys, plus inferred links confirmed against the data
How do I calculate it? Metric SQL attributes: reviewed SQL under a term, such as a margin, reused so answers compute each measure the same way
Where does it come from? Lineage Each term and attribute links to its source tables and columns, and each answer returns its SQL
Should I use it? Certification Experts certify names, descriptions, and attributes, and certified elements are marked as reviewed

Generate: the ingestion service builds a first draft from the source databases, and people refine it. Semantic compilation starts once you turn it on in Settings → Semantic Compilation.

  • Catalog ingest: read tables, columns, keys, views, and query history; tag PII if you turn on PII detection; embed tables and columns in pgvector.
  • Per table: profile values with SQL. A model finds foreign key candidates and junction tables, writes column descriptions, and names the terms.
  • Across tables: group copies of a schema into term families, and link foreign keys to the terms they reference, keeping an inferred link only when the data confirms it. A model attaches foreign key columns left unlinked, suggests SQL attributes from query history and for bridge tables, and describes each column attribute.
  • Output: the ontology in Postgres with embeddings in pgvector, which you can import or export as Ossie YAML.
  • Certify: test the draft with real questions in Chat, or with check_answerable and ask_question over MCP. Refine terms, descriptions, and SQL attributes in the UI or through the API, and certify them once they're correct. Edits are re-embedded right away, and the next compilation keeps them, except which semantic foreign key each join uses, which every compilation re-selects.

The Generate tool flow shows which steps call a model and which are SQL or rules.

The result is a semantic graph you can explore in the UI. In this example, one compilation of Wide World Importers produced 31 terms; selecting Order shows its description, related terms, mapped columns, and SQL attributes:

Semantic graph of the Wide World Importers ontology, with the Order term selected

Answer: the reasoning model answers each question in a loop, choosing one tool at a time:

  • retrieve: search the semantic layer by meaning and by name for business concepts, column meanings, and named calculations. Results come back as tables and columns with their descriptions and stored values, definitions with their SQL, and join paths. The model searches again whenever something is missing.
  • run_sql: look at stored values or test a draft. Before the query runs, table and column names are checked against the catalog, and tables against what retrieve showed.
  • submit: give the final query and an explanation. The query is checked and run, and an error goes back to the model to fix. A question about the data itself, such as which tables exist or what a term means, is answered in words: retrieve looks it up with purpose=information, and submit returns the answer without SQL.
  • Result: the answer comes back with its SQL and the steps it took, and a chart in Chat.

No tool calls a language model except predict, which answers predictive questions when KUMO_RFM_API_URL is set; see Predictions. If the model reaches its tool-call limit without an accepted query, the agent reports that the question can't be answered from this data. The Answer tool flow shows the loop, its tools, and its limits.

In Chat, each answer shows its SQL, and you can view the rows, download them as CSV, or read them as a chart:

Chat answering which products drive the most revenue and highest customer count, with the generated SQL and a revenue chart

Auto Ontology is compatible with Apache Ossie, the open standard for exchanging semantic models. Ossie includes a converter for Auto Ontology, which Auto Ontology uses to import and export model definitions as Ossie YAML. Use Settings → Import / Export, or POST /api/model/import and POST /api/model/export.

The services behind both stages, and how clients reach them:

flowchart LR
  subgraph clients["Clients"]
    direction TB
    ui["Browser: web UI"]
    rest["Scripts: REST API with API tokens"]
    mcpc["MCP clients: Cursor, Claude Desktop, agents"]
  end
  mcp["MCP server: read-only tools (FastMCP, port 3003)"]
  fe["Web app, auth, API gateway (Next.js, port 3000)"]
  subgraph private["Private network"]
    direction TB
    be["Backend: text-to-SQL agent, catalog and ontology APIs (FastAPI, port 3001)"]
    ing["Ingestion and semantic compilation (FastAPI, port 3002)"]
    pg[("Postgres + pgvector: app data, catalog, ontology, embeddings")]
  end
  src[("Source databases: 10 connectors")]
  models["Model endpoints: NVIDIA NIM or OpenAI-compatible (reasoning, non-reasoning, embed, rerank)"]
  vault["Vault (optional): connection credentials"]
  kumo["KumoRFM (optional): predictions"]
  ui --> fe
  rest --> fe
  mcpc --> mcp
  mcp -- "public API" --> fe
  fe --> be
  fe -- "users, sessions, settings" --> pg
  be -- "trigger ingest and compile" --> ing
  be --> pg
  ing --> pg
  be -- "run SQL" --> src
  ing -- "read schema, sample values" --> src
  be --> models
  ing --> models
  be -.-> vault
  ing -.-> vault
  be -.-> kumo
Loading
Component Technology Role Port
Frontend Next.js, Better Auth, Prisma Web UI for chat, catalog, analytics, and settings; auth and RBAC; public API gateway 3000
Backend FastAPI (Python 3.12+), LangChain Text-to-SQL agent, catalog, ontology APIs 3001
Ingestion service FastAPI (Python 3.12+) Ingestion and semantic compilation 3002
MCP server FastMCP Read-only agent tools over the public API 3003
Postgres + pgvector PostgreSQL 17 Catalog, ontology, app data, vector store 5432
HashiCorp Vault Optional Connection credential storage n/a

Browser and API clients go through the web app on port 3000, and MCP clients through the MCP server on port 3003, which calls the same public API. Keep ports 3001 and 3002 on a private network: FastAPI trusts the user identity the frontend forwards in the x-auto-ontology-user-id header, and the ingestion service's endpoints (ingest, delete, reset, compile) have no authentication of their own.

Full pipeline detail, with tool-flow diagrams for generating an ontology and answering a question: docs/architecture.md.

Use it from your agent

MCP server

The MCP server gives any MCP client read-only tools over the ontology. Each user signs in through Auto Ontology, and every call runs with that user's permissions.

Job Tools
Readiness check_readiness: can this deployment answer anything at all
Terms search_terms, get_term, get_term_columns, get_term_sql_attributes, get_sql_attribute, describe_table
Answerability check_answerable: does the ontology cover this question
Questions ask_question: the answer, the SQL, and the rows

Run the server against your deployment:

AUTO_ONTOLOGY_API_URL=http://localhost:3000 \
  uvx --from "git+https://github.com/NVIDIA/auto-ontology.git#subdirectory=mcp" auto-ontology-mcp

Cursor (~/.cursor/mcp.json):

{
  "mcpServers": {
    "auto-ontology": { "url": "http://localhost:3003/mcp" }
  }
}

Claude Desktop (claude_desktop_config.json), bridged with mcp-remote:

{
  "mcpServers": {
    "auto-ontology": {
      "command": "npx",
      "args": ["mcp-remote", "http://localhost:3003/mcp"]
    }
  }
}

Restart the client after editing its config, then sign in when it prompts. Sign-in, configuration, and troubleshooting are in docs/mcp.md.

Agent skills

Three skills teach a coding agent to work with Auto Ontology. Start at AGENTS.md.

Skill Covers
nvidia-ontology-setup Install, connect sources, compile, prove readiness
nvidia-ontology-management Inspect, model, certify, import/export, and publish
nvidia-ontology-query Ask questions and validate the SQL, rows, and answer

REST API

Ask a question with POST /api/chat/completions on the web app's origin. Mint an API token under the user menu → API Tokens. The response is a server-sent event stream: a result event carries the answer, and data: [DONE] ends the stream.

curl -N http://localhost:3000/api/chat/completions \
  -H "x-api-key: $AUTO_ONTOLOGY_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"question": "How many orders shipped last week?"}'
import json
import os

import requests

response = requests.post(
    "http://localhost:3000/api/chat/completions",
    headers={"x-api-key": os.environ["AUTO_ONTOLOGY_API_TOKEN"]},
    json={"question": "How many orders shipped last week?"},
    stream=True,
    timeout=900,
)
response.raise_for_status()

for line in response.iter_lines(decode_unicode=True):
    if not line or not line.startswith("data:"):
        continue
    payload = line.removeprefix("data:").strip()
    if payload == "[DONE]":
        break
    event = json.loads(payload)
    if event["type"] == "result":
        print(event["answer"]["response"])
        print(event["answer"]["sql_code"])
    elif event["type"] == "error":
        raise RuntimeError(event["message"])

Event types, multi-turn conversations, and the gateway trust boundary are in docs/conversation-api.md. Every other operation is in the OpenAPI spec.

Connectors, models, and predictions

Sources

Auto Ontology connects to eleven engines:

  • PostgreSQL
  • MySQL
  • Databricks
  • Snowflake
  • ClickHouse
  • Trino
  • Google BigQuery
  • Apache Kyuubi
  • HeavyDB
  • DuckDB
  • SQLite

Add connections under Settings → Connections, or list them in CONNECTION_STRINGS. DuckDB and SQLite are connection-string only. See docs/connections.md for URL schemes, scoping, and credential storage.

Models

Auto Ontology uses four model roles. With an nvapi- key, each defaults to an NVIDIA NIM on build.nvidia.com:

Role Default model What it does
REASONING nvidia/nemotron-3.5-lightning-30b-a3b Runs the answering agent and check_answerable, builds the ontology, and detects PII
NON_REASONING nvidia/nemotron-3.5-lightning-30b-a3b Rewrites follow-up questions, plans charts, writes PQL for predictions, and runs the quick steps of interactive analysis
EMBED nvidia/nemotron-3.5-embed-1b Indexes tables, columns, terms, and SQL attributes in pgvector, and matches each question to them
RERANK nvidia/nemotron-3.5-rerank-8b Picks the term that owns each bridge-table SQL attribute during compilation; not used to answer questions

To use self-hosted NIM or any OpenAI-compatible endpoint, set <ROLE>_ENDPOINT, <ROLE>_API_KEY, and <ROLE>_MODEL. Any field you leave unset falls back to DEFAULT_MODELS_<FIELD>, so the simplest setup fills in DEFAULT_MODELS_* and overrides only what differs; *_API_KEY also falls back to the legacy NVIDIA_API_KEY. Use models that support structured output, and keep the embedding model the same for ingestion and queries. .env.example documents every variable.

Predictions

Set KUMO_RFM_API_URL (and KUMO_RFM_API_KEY if your endpoint requires one) and the agent routes predictive questions to KumoRFM. KumoRFM is a hosted service: to answer, the agent uploads the connected tables to it, capped by KUMO_MAX_TABLES (20 by default) and KUMO_MAX_ROWS_PER_TABLE (unlimited unless set). Review what that sends, and complete your organization's data review, before you enable it.

Benchmarks

To run a text-to-SQL benchmark such as BIRD, refer to auto-ontology-eval, which scores the same model with and without the ontology on NeMo Gym.

Contributing

We welcome contributions: bug fixes, connectors, documentation, and examples. Please read the Contributing Guidelines before submitting pull requests.

To integrate an agent platform, application, or storage provider with Auto Ontology, open an integration request.

Reference

Topic Doc
Kubernetes deployment with Helm DEPLOYMENT.md
Architecture and pipeline steps docs/architecture.md
Connections, scoping, and Vault docs/connections.md
Authentication, SSO, and API tokens docs/authentication.md
Conversation API docs/conversation-api.md
MCP server docs/mcp.md
REST API docs/openapi/auto-ontology-api.json

License

Auto Ontology is licensed under the Apache License, Version 2.0. SPDX identifier: Apache-2.0.

Each NVIDIA-authored source file in this repository carries an SPDX header of the form:

SPDX-FileCopyrightText: Copyright (c) 2024-2026, NVIDIA CORPORATION & AFFILIATES.
All rights reserved.
SPDX-License-Identifier: Apache-2.0

Third-party open-source components used by Auto Ontology are enumerated, with their upstream licenses and project URLs, in THIRD_PARTY_NOTICES.md. Components added by the container images are listed separately in CONTAINER_THIRD_PARTY_NOTICES.md.

Notice and Disclaimer

NOTICE AND DISCLAIMER: This software automatically retrieves, accesses or interacts with external materials. Those retrieved materials are not distributed with this software and are governed solely by separate terms, conditions and licenses. You are solely responsible for finding, reviewing and complying with all applicable terms, conditions, and licenses, and for verifying the security, integrity and suitability of any retrieved materials for your specific use case. This software is provided "AS IS", without warranty of any kind. The author makes no representations or warranties regarding any retrieved materials, and assumes no liability for any losses, damages, liabilities or legal consequences from your use or inability to use this software or any retrieved materials. Use this software and the retrieved materials at your own risk.

External materials Auto Ontology interacts with at run time:

  • Model endpoints you configure, by default the NVIDIA API catalog (integrate.api.nvidia.com, ai.api.nvidia.com), under each provider's and model's terms.
  • The KumoRFM service, only when KUMO_RFM_API_URL is set, under Kumo's terms.
  • Your source databases, under your agreements for those systems.

Security

Report security vulnerabilities as described in SECURITY.md.

View on GitHub

Recent activity

commits and pull requests

Recent open issues

view all

Releases and announcements

1 total
  1. Auto Ontology 1.3.0v1.3.0Nov 24, 2026

    Auto Ontology 1.3.0 is published to the public NGC Catalog. These notes cover everything since 1.1.0 (October 2026), including the changes that first shipped in 1.2.0. ## 🚀 ReAct: a new text-to-SQL agent 1.3.0 replaces the LangGraph text-to-SQL implementation with a single **ReAct** agent. The change brings major improvements in runtime speed, token efficiency and output accuracy (#488). **Benchmark highlights (BEAVER, Claude Opus 5.5):** - **Accuracy:** up to **20%** higher - **Token consumption:** **4x** lower overall - **Cache hit rate:** **82%** of tokens served from cache - **Latency and volume:** **2x** fewer model calls and much shorter runtimes When this release was prepared, Auto Ontology ranked **first on [BEAVER](https://beaverbench.github.io/#leaderboard)**, and **first on both BIRD-Interact-A and BIRD-Interact-C** ([BIRD-Interact](https://bird-interact.github.io/)) (#521). **How it works** - **One loop.** The model calls tools until it submits an answer. It alone decides what to search, what to run and when it is done. The loop only enforces the budget, refuses repeated calls, and turns a submission into an answer once it runs cleanly (#488). - **One path for eve

Code frequency

additions and deletions
+140.3K-140.3KWeek of 2026-04-05: +11,341 linesWeek of 2026-04-05: -1 linesWeek of 2026-04-12: +17,686 linesWeek of 2026-04-12: -11,380 linesWeek of 2026-04-19: +15,826 linesWeek of 2026-04-19: -10,193 linesWeek of 2026-04-26: +14,760 linesWeek of 2026-04-26: -21,066 linesWeek of 2026-05-03: +114,126 linesWeek of 2026-05-03: -804 linesWeek of 2026-05-10: +8,305 linesWeek of 2026-05-10: -120,473 linesWeek of 2026-05-17: +3,683 linesWeek of 2026-05-17: -1,813 linesWeek of 2026-05-24: +5,794 linesWeek of 2026-05-24: -2,536 linesWeek of 2026-05-31: +3,481 linesWeek of 2026-05-31: -1,618 linesWeek of 2026-06-07: +10,023 linesWeek of 2026-06-07: -5,696 linesWeek of 2026-06-14: +2,531 linesWeek of 2026-06-14: -1,764 linesWeek of 2026-06-21: +11,885 linesWeek of 2026-06-21: -2,628 linesWeek of 2026-06-28: +10,468 linesWeek of 2026-06-28: -7,589 linesWeek of 2026-07-05: +8,154 linesWeek of 2026-07-05: -1,570 linesWeek of 2026-07-12: +15,359 linesWeek of 2026-07-12: -5,702 linesWeek of 2026-07-19: +8,552 linesWeek of 2026-07-19: -5,527 linesWeek of 2026-07-26: +12,707 linesWeek of 2026-07-26: -2,917 linesWeek of 2026-08-02: +10,403 linesWeek of 2026-08-02: -4,820 linesWeek of 2026-08-09: +39,195 linesWeek of 2026-08-09: -2,615 linesWeek of 2026-08-16: +25,951 linesWeek of 2026-08-16: -16,602 linesWeek of 2026-08-23: +11,551 linesWeek of 2026-08-23: -4,058 linesWeek of 2026-08-30: +115,671 linesWeek of 2026-08-30: -48,149 linesWeek of 2026-09-06: +29,771 linesWeek of 2026-09-06: -3,816 linesWeek of 2026-09-13: +4,801 linesWeek of 2026-09-13: -1,727 linesWeek of 2026-09-20: +140,339 linesWeek of 2026-09-20: -132,774 linesWeek of 2026-09-27: +17,529 linesWeek of 2026-09-27: -3,253 linesWeek of 2026-10-04: +12,810 linesWeek of 2026-10-04: -1,871 linesWeek of 2026-10-11: +13,232 linesWeek of 2026-10-11: -1,731 linesWeek of 2026-10-18: +15,914 linesWeek of 2026-10-18: -2,840 linesWeek of 2026-10-25: +5,959 linesWeek of 2026-10-25: -841 linesWeek of 2026-11-01: +1,887 linesWeek of 2026-11-01: -522 linesWeek of 2026-11-08: +7,828 linesWeek of 2026-11-08: -1,754 linesWeek of 2026-11-15: +16,913 linesWeek of 2026-11-15: -25,979 linesWeek of 2026-11-22: +14,092 linesWeek of 2026-11-22: -7,315 linesApr 5, 2026Nov 22, 2026
+758.5K lines added, -463.9K removed over the last year.

Commits per week

last 52 weeks
1020Week of 2025-11-30: 0 commitsWeek of 2025-12-07: 0 commitsWeek of 2025-12-14: 0 commitsWeek of 2025-12-21: 0 commitsWeek of 2025-12-28: 0 commitsWeek of 2026-01-04: 0 commitsWeek of 2026-01-11: 0 commitsWeek of 2026-01-18: 0 commitsWeek of 2026-01-25: 0 commitsWeek of 2026-02-01: 0 commitsWeek of 2026-02-08: 0 commitsWeek of 2026-02-15: 0 commitsWeek of 2026-02-22: 0 commitsWeek of 2026-03-01: 0 commitsWeek of 2026-03-08: 0 commitsWeek of 2026-03-15: 0 commitsWeek of 2026-03-22: 0 commitsWeek of 2026-03-29: 0 commitsWeek of 2026-04-05: 2 commitsWeek of 2026-04-12: 50 commitsWeek of 2026-04-19: 39 commitsWeek of 2026-04-26: 35 commitsWeek of 2026-05-03: 8 commitsWeek of 2026-05-10: 31 commitsWeek of 2026-05-17: 23 commitsWeek of 2026-05-24: 35 commitsWeek of 2026-05-31: 21 commitsWeek of 2026-06-07: 80 commitsWeek of 2026-06-14: 42 commitsWeek of 2026-06-21: 71 commitsWeek of 2026-06-28: 43 commitsWeek of 2026-07-05: 47 commitsWeek of 2026-07-12: 57 commitsWeek of 2026-07-19: 33 commitsWeek of 2026-07-26: 53 commitsWeek of 2026-08-02: 54 commitsWeek of 2026-08-09: 29 commitsWeek of 2026-08-16: 23 commitsWeek of 2026-08-23: 49 commitsWeek of 2026-08-30: 24 commitsWeek of 2026-09-06: 45 commitsWeek of 2026-09-13: 23 commitsWeek of 2026-09-20: 17 commitsWeek of 2026-09-27: 54 commitsWeek of 2026-10-04: 44 commitsWeek of 2026-10-11: 37 commitsWeek of 2026-10-18: 14 commitsWeek of 2026-10-25: 19 commitsWeek of 2026-11-01: 18 commitsWeek of 2026-11-08: 12 commitsWeek of 2026-11-15: 26 commitsWeek of 2026-11-22: 102 commitsNov 30, 2025Nov 22, 2026
1.3K commits in the last 52 weeks.

When work happens

weekday and hour
SunMonTueWedThuFriSat036912151821Sun 0:00 — 3 commitsSun 1:00 — 2 commitsSun 2:00 — 0 commitsSun 3:00 — 1 commitsSun 4:00 — 0 commitsSun 5:00 — 0 commitsSun 6:00 — 0 commitsSun 7:00 — 0 commitsSun 8:00 — 1 commitsSun 9:00 — 6 commitsSun 10:00 — 11 commitsSun 11:00 — 26 commitsSun 12:00 — 15 commitsSun 13:00 — 27 commitsSun 14:00 — 27 commitsSun 15:00 — 19 commitsSun 16:00 — 20 commitsSun 17:00 — 3 commitsSun 18:00 — 2 commitsSun 19:00 — 1 commitsSun 20:00 — 1 commitsSun 21:00 — 5 commitsSun 22:00 — 3 commitsSun 23:00 — 3 commitsMon 0:00 — 0 commitsMon 1:00 — 0 commitsMon 2:00 — 0 commitsMon 3:00 — 1 commitsMon 4:00 — 0 commitsMon 5:00 — 0 commitsMon 6:00 — 0 commitsMon 7:00 — 0 commitsMon 8:00 — 3 commitsMon 9:00 — 12 commitsMon 10:00 — 20 commitsMon 11:00 — 41 commitsMon 12:00 — 18 commitsMon 13:00 — 24 commitsMon 14:00 — 48 commitsMon 15:00 — 47 commitsMon 16:00 — 11 commitsMon 17:00 — 7 commitsMon 18:00 — 3 commitsMon 19:00 — 3 commitsMon 20:00 — 2 commitsMon 21:00 — 5 commitsMon 22:00 — 1 commitsMon 23:00 — 4 commitsTue 0:00 — 0 commitsTue 1:00 — 6 commitsTue 2:00 — 0 commitsTue 3:00 — 0 commitsTue 4:00 — 1 commitsTue 5:00 — 0 commitsTue 6:00 — 1 commitsTue 7:00 — 1 commitsTue 8:00 — 6 commitsTue 9:00 — 14 commitsTue 10:00 — 29 commitsTue 11:00 — 53 commitsTue 12:00 — 44 commitsTue 13:00 — 32 commitsTue 14:00 — 35 commitsTue 15:00 — 32 commitsTue 16:00 — 26 commitsTue 17:00 — 13 commitsTue 18:00 — 8 commitsTue 19:00 — 2 commitsTue 20:00 — 3 commitsTue 21:00 — 3 commitsTue 22:00 — 0 commitsTue 23:00 — 1 commitsWed 0:00 — 0 commitsWed 1:00 — 0 commitsWed 2:00 — 0 commitsWed 3:00 — 0 commitsWed 4:00 — 0 commitsWed 5:00 — 1 commitsWed 6:00 — 0 commitsWed 7:00 — 1 commitsWed 8:00 — 3 commitsWed 9:00 — 9 commitsWed 10:00 — 35 commitsWed 11:00 — 37 commitsWed 12:00 — 31 commitsWed 13:00 — 28 commitsWed 14:00 — 33 commitsWed 15:00 — 31 commitsWed 16:00 — 13 commitsWed 17:00 — 6 commitsWed 18:00 — 1 commitsWed 19:00 — 3 commitsWed 20:00 — 3 commitsWed 21:00 — 2 commitsWed 22:00 — 1 commitsWed 23:00 — 0 commitsThu 0:00 — 2 commitsThu 1:00 — 0 commitsThu 2:00 — 0 commitsThu 3:00 — 0 commitsThu 4:00 — 0 commitsThu 5:00 — 0 commitsThu 6:00 — 0 commitsThu 7:00 — 0 commitsThu 8:00 — 3 commitsThu 9:00 — 11 commitsThu 10:00 — 31 commitsThu 11:00 — 43 commitsThu 12:00 — 20 commitsThu 13:00 — 37 commitsThu 14:00 — 40 commitsThu 15:00 — 31 commitsThu 16:00 — 12 commitsThu 17:00 — 3 commitsThu 18:00 — 4 commitsThu 19:00 — 2 commitsThu 20:00 — 3 commitsThu 21:00 — 2 commitsThu 22:00 — 1 commitsThu 23:00 — 0 commitsFri 0:00 — 0 commitsFri 1:00 — 0 commitsFri 2:00 — 0 commitsFri 3:00 — 0 commitsFri 4:00 — 0 commitsFri 5:00 — 0 commitsFri 6:00 — 0 commitsFri 7:00 — 0 commitsFri 8:00 — 0 commitsFri 9:00 — 3 commitsFri 10:00 — 3 commitsFri 11:00 — 2 commitsFri 12:00 — 0 commitsFri 13:00 — 1 commitsFri 14:00 — 1 commitsFri 15:00 — 0 commitsFri 16:00 — 4 commitsFri 17:00 — 1 commitsFri 18:00 — 1 commitsFri 19:00 — 1 commitsFri 20:00 — 0 commitsFri 21:00 — 1 commitsFri 22:00 — 0 commitsFri 23:00 — 0 commitsSat 0:00 — 3 commitsSat 1:00 — 0 commitsSat 2:00 — 0 commitsSat 3:00 — 0 commitsSat 4:00 — 0 commitsSat 5:00 — 0 commitsSat 6:00 — 0 commitsSat 7:00 — 0 commitsSat 8:00 — 1 commitsSat 9:00 — 0 commitsSat 10:00 — 1 commitsSat 11:00 — 1 commitsSat 12:00 — 0 commitsSat 13:00 — 3 commitsSat 14:00 — 1 commitsSat 15:00 — 0 commitsSat 16:00 — 0 commitsSat 17:00 — 0 commitsSat 18:00 — 2 commitsSat 19:00 — 5 commitsSat 20:00 — 4 commitsSat 21:00 — 2 commitsSat 22:00 — 1 commitsSat 23:00 — 0 commits
Commit volume by weekday and hour (UTC). Larger dots mean more commits.
DateListRankStars gained
Nov 15, 2026weekly#5+4,108
Nov 14, 2026weekly#5+4,108
Nov 13, 2026weekly#5+5,802
Nov 12, 2026weekly#3+7,947
Nov 11, 2026weekly#1+9,621
Nov 10, 2026weekly#1+10,159
Nov 9, 2026weekly#1+9,327
Nov 8, 2026weekly#1+9,044
Nov 7, 2026daily#1+2,005
Nov 6, 2026daily#1+2,005
Nov 5, 2026daily#1+2,707
Nov 4, 2026daily#1+2,053