The Open Context Layer for Data Agents
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
One-click editor setup isnβt available for this listing yet β we donβt have a confirmed install command, and weβd rather show nothing than point your editor at the wrong package or host. Follow the projectβs own setup instructions, linked above.
The context layer that lets AI agents query your data correctly.
Point canonic at your database and it builds the context an agent needs to answer data questions accurately: definitions, relationships, business meaning, and the guardrails that stop confidently-wrong answers. It keeps that context up to date as your data changes, and it never touches your warehouse beyond reading it.
π Full documentation: https://docs.getcanonic.app
Package and image names below show the shape of each install channel; exact names are confirmed per release.
An AI agent connected straight to your warehouse sees tables and columns, not meaning. It doesn't know that revenue lives in orders.amount but excludes refunds, or that "active customer" has a specific definition your finance team agreed on. So it guesses. Schema access makes an agent fluent. It doesn't make it correct.
Real output, captured from a live run against the ecommerce example:
This total includes two refunded orders ($260), a confident, well-formatted number that's off by 6.4%.
canonic resolves "revenue" to its canonical definition, compiles the guardrail into the SQL whether or not anyone asked for it, and returns the right number with the reasoning attached.
canonic is not a BI tool and not a chat interface: it's the layer that feeds the tools you already have (a BI dashboard, an agent, a notebook) correct, governed answers.
canonic's context lives in three committed surfaces: plain files in your git repo, reviewed like code.
| Layer | File | Answers | Owned by |
|---|---|---|---|
| Semantics | semantics/**/*.yaml | "How do I query this safely?" | auto-maintained |
| Knowledge | knowledge/**/*.md | "What does this mean to the business?" | auto-maintained |
| Contracts | contracts/**/*.yaml | "Which definition is canonical, and what must the answer obey?" | human-owned |
Changes how the SQL runs β semantics. A human needs it to trust the answer β knowledge. Governs which definition is authoritative β contracts. See Concepts: the three layers.
uv (dev machines, primary):
pip (fallback for environments without uv):
Docker (CI, headless, air-gapped):
Verify with canonic --version. Air-gapped install and offline wheels: see Installation.
The fastest path uses local connectors, no server, no network. Point at a SQLite .db or DuckDB .duckdb/CSV/Parquet file:

The wizard names your project, connects a source, optionally configures an LLM, drafts your semantics from the live schema, then runs a real query and shows the answer with its freshness and definition. Postgres or an LLM provider need a credential in an environment variable before you run canonic setup (canonic never stores secrets in canonic.yaml directly).
Don't have a database handy? examples/ ships 5 ready-to-run sample projects (dbt Jaffle Shop, e-commerce, vehicle rental, SaaS analytics, Dutch railway), see the guides.
You now have a working context layer committed to your repo:
canonic exposes its capabilities over a local, on-demand MCP server, verified with Claude Code, Cursor, and Codex:
GUI-launched clients (Claude Desktop, Cursor) don't source your shell profile, so pass connection credentials via the config's env field, not export. Every answer-producing tool of the 11 registered (query, run_sql, search_knowledge, ...) returns a metadata band: resolved definition, guardrails fired, freshness, trust_score. On ambiguity, the agent gets a structured reason, not a guess.
See Connecting your agent for remote/enterprise deployment (--transport http, per-client bearer tokens) and the tools reference.
Want a full example with a real identity provider, including role/tenant enforcement end-to-end? scripts/local_idp spins up a local Keycloak plus a dockerized canonic serving the marketplace example via OAuth 2.1, so you can log in as differently-scoped test users and see masking, run_sql gating, and tenancy scoping applied live. Full walkthrough: Marketplace with Keycloak.
canonic.yaml config schema.No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/canonic)<a href="https://allmcps.com/mcp/canonic"><img src="https://allmcps.com/api/badge/canonic?style=directory" alt="Canonic on AllMCPs" /></a>