- Should I build or buy a text-to-SQL feature for my app?
- Building it means owning the whole stack — prompt construction, schema injection, a SQL validator so the model can't mutate data, a plan cache, and an eval harness to keep accuracy from regressing — forever, for a non-core feature. nlqdb is the buy answer: embed `<nlq-data>` or call `POST /v1/ask` and the pipeline is the API. The honest trade-off: it's hosted, not a library you vendor in.
- How do I add a natural-language query feature without writing the SQL generation myself?
- Embed the `<nlq-data goal="...">` web component in your UI, or call `POST /v1/ask` from your backend with the user's English question. nlqdb introspects the schema, compiles the goal to SQL, runs it, and returns the rows plus the SQL it ran. You write no prompt, no schema-injection glue, and no validator — that's all behind the endpoint.
- What stops the LLM from generating SQL that drops or corrupts a table?
- Two guardrails. The SQL validator allowlists the verbs the orchestrator may emit (`docs/features/sql-allowlist`), so destructive statements are rejected before execution; and every answer surfaces the compiled SQL under a trace toggle (`SK-WEB-005`) so you and your users can audit the grain before trusting it. Destructive DDL also requires a row-count diff and second confirmation (`SK-ONBOARD-004`).
- Can my users each query only their own data?
- For a handful of tenants, give each its own provisioned database — clean physical isolation. For many users in one shared database, per-user/agent row scoping (`app.agent_id` RLS) is in progress (E-03), not shipped; per-tenant RLS keyed on `app.tenant_id` is the shipped boundary today. So plan on a database or an RLS-scoped key per tenant, not one open database for everyone.