AI Chat
Choose a Provider Key, model, and DB contexts for each request, then review Tool activity, SQL cards, and execution results in one place.
Panel and conversations
Open the AI panel and manage conversations from the project screen.
Open the AI panel
Use the AI button or Ctrl/Cmd+I, and pin the panel when needed.
Choose a conversation
Start a new conversation or open one from history.
Choose a model
Select a Provider Key and model available for the current project type.
Send a message
Review context and send. Provider Key and context can change for every message.
Select DB contexts
Selected contexts are the complete database-access allowlist for that request.
- Search Connections and Schemas, and use Select all or Clear all.
- Select Schemas from multiple Connections in one request.
- The AI cannot discover unselected Connections or access them with DB Tools.
- With zero contexts, general questions and copy-only SQL examples work, but DB Tools, DB-bound SQL execution, and Open Editor are unavailable.
- A project default Database and Schema is only an initial selection for a new Chat and can be changed before sending.

Each SQL statement needs an unambiguous Connection, Database, and Schema route.
Ask AI about a SQL execution error
Prepare a failed SQL statement and its error message as an AI Chat question from supported error areas in the SQL Editor.
AI must be enabled for the target Connection, and the Database and Schema used for execution must still be valid. You cannot prepare an error question while an AI response is being generated.
Right-click the error area
Right-click a query-result or Explain error, or an error dialog opened by Run Script or result editing. The menu is not available for server-filtered or server-sorted refreshes, external MCP executions, or result-editing failures where NeoSQL cannot identify an individual SQL statement.
Choose AI: Ask about SQL Error
AI Chat opens with an attachment containing SQL displayed with bound values substituted, SQLSTATE, and the error message, plus the Connection, Database, and Schema used for execution. No AI request is sent yet.
Review and send the question
Edit the default question, review the attachment and target context, and then send it.
- SQL, SQLSTATE, and the error message are read-only; only the question text is editable.
- Previously selected contexts are cleared, leaving only the error target Connection, Database, and Schema. This context cannot be removed while the error draft exists, but you can add other contexts.
- A question you were writing, or a pending Query Tuning or Sample Data attachment, is replaced by the error question draft.
- Choosing the AI question from a Run Script or result-editing error dialog handles the dialog as Stop, so remaining statements do not run. To continue, fix the error and choose Retry, or choose Skip when it is available.
- When multiple result-editing statements fail, the failed SQL statements and error messages are combined, and only the first error's SQLSTATE is shown.
- The error menu can copy the error message, SQL, or all error details to the clipboard.
- Select X on the attachment to remove the entire error draft, including the question. The context is unlocked but stays selected, so remove it yourself if you no longer need it.

Tool Activity and approvals
When the AI checks database information, Chat shows its activity and a result summary.
- Connections within the selected scope
- Table and View search
- Table details, columns, keys, indexes, and relationships
- Estimated plans on supported DBMSs
- Read-only SELECT limited to 10 rows and 30 seconds
Note: Only SELECT that reads actual rows requires approval. Allow this lookup, or choose Approve subsequent lookups when available.

SQL cards and results
AI-generated SQL appears as an inline card for each statement.
- Each statement provides Run, Open Editor, and Copy.
- Open Editor creates an editable copy in the regular SQL Editor, not a separate AI editor.
- SQL without an execution route is copy-only.
- Results show up to 100 preview rows, returned or affected rows, duration, errors, and truncation.
- SQL execution results and detailed Tool results are not saved in conversation history.

Caution: Automatic execution and confirmation follow Project AI Settings for the target Connection.
Conversation history
Storage and retention depend on the project type.
- Account-project conversations are stored for the user account.
- Local-project conversations stay on the device, with the 30 most recent kept per project.
- Rename, Cmd/Ctrl multi-select, Shift range-select, and permanent deletion are supported.
- Messages and Tool and approval summaries are restored.
- Detailed Tool data, approval-card state, SQL execution results, and in-progress state are not restored.

Deleted conversations cannot be recovered.