AI article

Same question, same database, two callers

Community description: Most text-to-SQL stacks send the model the whole schema and put the access check after the query is...

Dev.to | Sep 23, 2026 | Ashish sinha

Automated excerpt

Left -- the caller holds no roles. hr_compensation never reaches the model at all: 9 of 42 objects selected, 570 prompt tokens instead of 2,511, one object hidden from this caller. Right -- same question, same schema, same database. That is the Studio on a claims schema: 14 of 51 objects selected, 1,212 prompt tokens against 3,237 for the full schema, and three objects withheld because this caller has neither actuarial nor phi.

Selected automatically from source text; not independently written or fact-checked. Read the original for full context.

Read the original article

More AI news