Skip to content
The Daily Repo

Spemakqy10k / Schemagate

Text-to-SQL access control: schema selection that gives the LLM only the tables the caller is allowed to read. Row-level-security-aware table pruning for LangChain, MCP and any SQL agent. Postgres, Oracle, MySQL, SQL Server. 75% fewer prompt tokens.

ActiveLast commit yesterday4 contributors in 90 daysApache-2.0 licence, allows business use

Maintenance
Active
Last commit yesterday
Stars
38
On GitHub
Licence
Apache-2.0
Allows business use
Downloads for
None listed
No release files
Latest version
None yet
No releases
Built with
Python
80% of the code

What it does

Most text-to-SQL prompts carry the whole schema, and on a big database that is most of the prompt, on every question. schemagate sends the model only the tables the question needs: 91.1% fewer schema tokens (median) on databases with 50+ tables (benchmark). It filters by the caller's grants first, so restricted tables are absent from the prompt rather than ranked low. Works with LangChain, LlamaIndex, MCP, or any SQL agent, on Postgres, Oracle, MySQL, SQL Server and SQLite.

Get started

pip install schemagate

Is it looked after?

Contributors
4
Last 90 days
Issues
0% closed
2 still open
Pull requests
1 merged
1 waiting
Releases
None
Never published

Similar repos

Repos similar to this one
RepoStarsLast commitLicenceDownloads for
ashishsinha1602 / schemagate127yesterdayApache-2.0No downloads
agno-agi / dash2,2804 months agoApache-2.0No downloads
boxed-dev / cognidb2154 months agoMITNo downloads
sao-coding / locus185todayAGPL-3.0Windows
tidydesigns / tidy10116 days agoApache-2.0No downloads
QuackbackIO / quackback377yesterdayAGPL-3.0No downloads
More: languages, topics and project record

Languages

  • Python 80%
  • HTML 19%
  • Shell 1%
  • HCL 1%

Topics

  • database
  • llm
  • mcp
  • security
  • text-to-sql

Project record

  • JobOther AI tools
  • StatusNew to our list
  • Commits467
  • Forks12
  • Watching3
  • CreatedDec 1, 2026
  • First seen by usDec 2, 2026
  • CheckedDec 2, 2026

Type to search.

Try