Features

SQL Lab

A full query editor for exploring your data sources directly — Monaco-powered, multi-tab, with a live schema browser, cancellable execution, and inline AI. Open it from Lab in the sidebar.

Editor

The editor is Monaco — the same editor that powers VS Code — so syntax highlighting, multiple cursors, and inline errors work exactly as you’d expect.

Keyboard shortcuts

ActionShortcut
Run queryCtrl/Cmd + Enter
Format SQLCtrl/Cmd + Shift + F
Comment lineCtrl/Cmd + /
FindCtrl/Cmd + F
Go to lineCtrl/Cmd + G

Autocomplete & the schema browser

Monaco autocompletes SQL keywords out of the box. Table and column names come from the schema browser on the left: select a database to load its tables, then expand a table to pull in its columns. Once loaded, those names feed autocomplete as you type.

Multi-tab sessions

Every query runs in its own tab. Open more with the + button in the tab bar; each tab keeps its own query text and results for the session.

Tabs are not persisted across page reloads. Use Save Query to keep a query across sessions — saved queries live in your history with their source database attached.

Selecting a database

The database selector in the toolbar lists every active data source. Pick one before running a query and the schema browser updates to match. If nothing is selected, the editor falls back to the metadata database (where the demo datasets live) — so you can always explore the platform’s own metadata without wiring up a source first.

Running queries

Kaveon exposes two execution endpoints. The Run button always uses the cancellable one.

Cancellable execution (the Run button)

POST /api/v1/lab/query — used by the primary Run button for every query you execute. The backend runs the query in an executor thread and polls for client disconnect every 500 ms. If you close the tab or navigate away, it sends a cancel signal to the database cursor (cursor.cancel()) and returns 204 No Content. Executed queries are also recorded in Query History.

Synchronous helper

POST /api/v1/lab/execute — a plain synchronous endpoint used internally for side queries such as row-count estimates. It returns columns, rows, and a row count in one response and deliberately does not write to Query History. It is not an auto-selected fast path for the Run button.

This is why abandoned queries don’t pile up on your warehouse — Kaveon actively cancels the cursor when the client goes away, instead of letting long-running work accumulate server-side.

Execution response

json
{
  "success": true,
  "columns": ["order_id", "total", "region"],
  "rows": [
    [1001, 249.90, "West"],
    [1002, 88.00,  "East"]
  ],
  "rowCount": 2,
  "executionTime": 0.143
}

Fields are camelCase; executionTime is reported in seconds (the UI formats sub-second timings as milliseconds).

Saving & history

Save Query stores the SQL plus its source database so you can reopen it later. Every executed query is also written to Query History — a per-user audit trail you can search, re-run, or promote into a saved query. Both live under /lab/queries.

Inline AI

Press the ✦ wand in the toolbar, describe what you want in plain English, and the generated SQL is injected straight into the active tab — ready to review and run. For the full natural-language flow (dataset detection, pattern matching, automatic charts) see AI · NL→SQL.