How it works

STYD turns natural language questions into reliable database answers through a controlled and validated execution pipeline.

From question to answer

When you ask a question about a database, STYD does not send it straight to your data. It first reads your question together with what it knows about your database, writes one read-only query, checks that query, and only then runs it.

On Odoo there is no SQL: STYD reads the matching records through Odoo itself (the STYD Bridge or an Odoo API key), with the same read-only rules. Questions about your uploaded documents are answered from passages of those files, and the answer cites its sources. A question that needs no data, such as a definition, runs no query: it is answered from general knowledge and labelled General knowledge.

The execution pipeline

1. Your question and your context
STYD reads your question together with your AI Guide: the tables and columns you are allowed to use (tables hidden from you are left out), your confirmed descriptions, and your business terms.
2. One read-only query, with its assumptions
STYD writes a single SELECT and states any assumption it made, for example which date column it used. Periods such as “last month” are computed by STYD’s code, in your business timezone, not guessed by the model.
3. Safety check
The query is checked against strict rules: read-only, known columns only, no hidden tables. If it fails, STYD gets a limited number of retries; a safety refusal is final.
4. Execution
The query runs in a read-only transaction, with a time limit (15 seconds by default) and a result-size limit.
5. Answer from the rows
A second step writes the answer in your language. The numbers in the text are checked against the returned rows; if they do not match, STYD shows the rows as the code rendered them instead. You can open how the answer was calculated.

After an answer from your data or your documents, STYD can add a short part labelled General knowledge, after a divider: an interpretation, likely causes or advice. Its figures come only from the answer above it. A plain lookup gets no general part.

Why this approach matters

The model never runs anything itself. Code checks the query, computes the periods and verifies the numbers, so a wrong or unsafe query is stopped before it reaches your data.

It can still be wrong: the answer depends on your schema and descriptions, and on how clearly the question is asked. Review important answers.

Read-only execution, always
Queries checked before they run
Periods computed by code
Numbers checked against the rows

Built for trust

Every answer from your data can show how it was calculated, so a result can be reviewed rather than taken on faith.

This is what makes STYD suitable for real-world business use cases, where accuracy and security are critical.