The context layer for AI
AI tools guess what your columns mean, and the numbers come out wrong. Context teaches Claude, ChatGPT and Cursor what your data means, so they answer the way your team would.
€29/user/month · Pro plan, with Guard
intent: "revenue by active customer"
instructions: "Amounts are in cents. Use orders_v2, not orders."
definitions: [{ name: "active customer", sql: "last_order_at > now() - …" }]
tables: [{ name: "orders_v2",
columns: [{ name: "total", description: "Order total in cents, before VAT", synonyms: ["revenue"] }] }]
Every AI tool. Same answers.
Your team asks Claude, ChatGPT, Cursor, Claude Code, Windsurf or any other MCP client. Without context, each one guesses what your data means, and two people asking the same question get two numbers. With Context, every one of them reads the same context files, definitions and descriptions.
- Any MCP client
What an AI needs from your database
The schema says what exists. It doesn’t say what amounts are in, which of two tables is current, or what your team means by an active customer.
| The AI sees | It also needs to know | Where it goes |
|---|---|---|
| orders.total bigint | In cents, before VAT | Column description |
| orders, orders_v2 | Use orders_v2. orders is the old system | Context files |
| customers.last_order_at | An active customer bought in the last 90 days | Definition, with its SQL |
| acct_mgr_id | People say account manager or owner | Synonyms |
| COMMENT ON TABLE customers | Already written in the database | Read as it is |
How it works
- 1Write down what only your team knowsWhich table is current, what the amounts are in, what counts as an active customer. A sentence each, in the app or straight from a conversation with the AI.
Write down what only your team knows
Which table is current, what the amounts are in, what counts as an active customer. A sentence each, in the app or straight from a conversation with the AI.
- 2Every AI tool your team uses reads itClaude, ChatGPT, Cursor and Claude Code get the context that fits each question, so nobody has to explain the data again.
Every AI tool your team uses reads it
Claude, ChatGPT, Cursor and Claude Code get the context that fits each question, so nobody has to explain the data again.
- 3Comments in the database count tooTable and column comments in PostgreSQL, Redshift, MySQL, SQL Server, Oracle, BigQuery and ClickHouse come along. Where your team writes its own, that wins, and the database stays untouched.
Comments in the database count too
Table and column comments in PostgreSQL, Redshift, MySQL, SQL Server, Oracle, BigQuery and ClickHouse come along. Where your team writes its own, that wins, and the database stays untouched.
- SchemaWhat existsorders_v2.total bigint
- Database commentRead from the databaseOrder total
- SaturnSQLWritten by your teamOrder total in cents, before VAT
- What Claude readstotal bigint: "Order total in cents, before VAT"
Correct the AI once
When you tell the AI it got a column wrong, it can save the correction for everyone. The next person, and the next AI tool, gets it right without being told. Every change has a name on it.
Context layer vs semantic layer
Context is not a semantic layer, and doesn’t try to be. A semantic layer compiles governed metrics; Context tells an AI what your data means so it can write the SQL itself.
| SaturnSQL Context | Semantic layer | |
|---|---|---|
| What you build first | Nothing. Write context files as questions come up | Models, metrics and joins in YAML, LookML or views |
| How AI uses it | Reads the meaning, then writes SQL | Queries governed metrics through an API |
| Who maintains it | Anyone who knows the data, in plain language | Usually analytics engineers, in code |
| Same number every time | Guided by definitions, not guaranteed | Yes, metrics compile to the same SQL |
| Time to first answer | Minutes | Once the first models are written and deployed |
If finance needs revenue to match to the cent in every tool, model it in a semantic layer. For everything else, context gets AI answers right from day one. More in what is a context layer. See the best semantic layer tools and Atlan alternatives for the heavier options.
No lock-in
Start from the Apache Ossie model you already have, and take everything your team writes with you as Ossie or dbt YAML on every plan. If you adopt a semantic layer later, start from here.
How Apache Ossie import and export work
version: 0.3.0.dev0
name: prod_postgres
ai_context:
instructions: Amounts are in cents. Use orders_v2, not orders.
datasets:
- name: orders_v2
description: One row per paid order
fields:
- name: total
datatype: Integer
description: Order total in cents, before VAT
ai_context:
synonyms: [revenue, amount]
AI that understands your data and only sees what it should
Context and Guard come together on the Pro plan, and Guard’s rules apply to context too.
- Hidden tables stay hidden, in the schema and in the context.
- Masked columns stay masked in everything the AI reads.
- Turn AI off for a database, and its context goes dark too.
More on SaturnSQL Guard and database governance for MCP and AI.
Questions about Context
Connecting an AI tool? Start with the SaturnSQL MCP server.
Give your AI tools the meaning, not just the schema
Explain your data once, and every AI tool your team uses works from it.
€29/user/month
Pro plan: everything in Starter, plus
- Context: context files, definitions, and table and column descriptions every AI tool reads with the schema
- AI tool access per connection: off, shared queries only, read-only or same as the user
- Approvals: risky AI tool requests wait for a person, alerted in Slack or by email
- Limits on AI tool queries for each database or group: rows per query, queries a minute per person, timeout, BigQuery bytes
- Access rules per group: hide tables, hide or mask columns, filter rows
- Audit log of every query, from people and AI
- Query version history