Error Codes
Error Codes
datarelix.ai sorts errors into five classes for recovery UX:
- NO_RESULTS — the question was understood but produced no useful data.
- TIMEOUT — execution exceeded its time limit.
- PLAN_FAILURE — the LLM could not produce a valid plan.
- CONNECTION_FAILURE — the database could not be reached.
- INTERNAL — generated SQL/code was invalid, sandbox crashed, or the LLM returned malformed output.
Every error event in the run stream carries an error_code that maps to one class.
NO_RESULTS
| Code | Meaning | Recovery |
|---|---|---|
MISSING_TABLE | Generated SQL references a table not in scope | Add the missing table to scope and retry. |
MISSING_COLUMN | Generated SQL references a column that doesn’t exist | Check your table selection or rephrase. |
TYPE_MISMATCH | Implicit cast failed | Rephrase to avoid mixing incompatible types. |
The frontend surfaces these as “broaden your question” suggestions.
TIMEOUT
| Code | Meaning | Recovery |
|---|---|---|
SQL_TIMEOUT | Database query exceeded SQL_TIMEOUT (default 30s) | Add date filters or narrow scope. |
SANDBOX_TIMEOUT | Sandbox Python step exceeded the wall-clock cap | Simpler analysis or reduce data volume. |
PLAN_FAILURE
| Code | Meaning | Recovery |
|---|---|---|
NOT_ANSWERABLE | LLM determined the question can’t be resolved with available data | Rephrase or add context. |
AMBIGUOUS_QUERY | Multiple valid interpretations | Be more specific. |
The frontend offers an editable retry — your question stays in the input ready to revise.
CONNECTION_FAILURE
| Code | Meaning | Recovery |
|---|---|---|
CONNECTION_ERROR | Database unreachable | Test from sidebar; check credentials. |
The frontend’s recovery banner has a “test connection” button.
INTERNAL
| Code | Meaning |
|---|---|
SQL_SYNTAX | Generated SQL didn’t parse |
SQL_VALIDATION | Generated SQL failed our validation rules |
SQL_EXECUTION | Database returned an error |
SANDBOX_CODE_ERROR | Python in the sandbox raised |
SANDBOX_OOM | Python in the sandbox exceeded memory cap |
LLM_INVALID_OUTPUT | LLM returned malformed IR |
Most internals trigger an automatic repair attempt up to the configured budget. After the budget is exhausted you’ll see the underlying error.