Connect a database
schemagate reads the schema only — names, types and foreign keys. No rows are read unless you ask, and nothing leaves this machine.
Not ready?
Connected
Add a description to each object? One sentence per table is what turns “what does each person get paid” into the pay table, which matching names alone cannot do. Selection works without it.
schemagate, running entirely in this browser tab on six
invented example schemas. It is not connected to any database and does not call any AI model.
The real thing is pip install schemagate, which runs on your own database.
Answer
the SQL it wrote
cat.describe(...) generates these for real.
Schema
Selected objects
What the model receives
Hidden from this caller
These exist in the catalog but never reach the prompt for this identity. Not de-ranked — absent.
Backup and staging copies demoted
A copy carries the same name words in a shorter document, and cosine similarity rewards exactly that. These are ranked below the object they shadow — unless you name them outright.
Use it from Python
pip install schemagate
from schemagate import Catalog, Principal
cat = Catalog().bootstrap("postgresql://localhost/app")
cat.select("revenue by month",
principal=Principal("okta:jdoe", roles={"finance"}))Use it from Cursor, Windsurf, any MCP client
pip install 'schemagate[mcp]' SCHEMAGATE_DATABASE_URL=postgresql://localhost/app \ python -m schemagate.mcp_server
Run this studio on your own database
pip install schemagate schemagate studio --url postgresql://localhost/app
Same page, your schema, nothing leaves your machine. github.com/ashishsinha1602/schemagate · Apache-2.0 · Ashish Sinha