Optional AI assistance

The last mile of translation with focused AI help

SQL Tran's core translation remains deterministic and non-LLM. When enabled, the AI Assistant works on a selected object and its translation context, helping with documentation, target rewrites, and marked manual-rewrite sections.

Deterministic by default

AI is a separate assist layer, not the translation engine.

SQL Tran parses source code into its typed internal representation and performs the main translation without an LLM. The optional assistant is available for selected workspace actions when a migration needs interpretation or a targeted rewrite.

Optional by design
  • Use the assistant from the AI Assistant panel on a selected workspace object.
  • Review the result in the same source and target workflow as the rest of the migration.
  • Keep SQL Tran's parser, analysis, and target-database checks as the system of record.

Three actions in the workspace

Assistance that maps to real migration tasks.

The current SQL Tran implementation keeps the AI surface deliberately narrow. Each action has a defined input, output, and place in the translation workflow.

01

Analyze

Analyze the selected source object for intent, behavior, code quality, and side effects. SQL Tran includes the objects it depends on and saves the returned markdown documentation to the object.

02

Rewrite

Give the assistant the source DDL, related object definitions, the automatic target translation, and both dialects. It returns target DDL only, then SQL Tran checks it against the target database.

03

Fill the gaps

Choose the scope of the rewrite: update only the minimal parts that need attention, or ask for a full rewrite of the target object when broader changes are needed.

Context and boundaries

The request is built from the object you are working on.

SQL Tran does not send a generic question. The backend builds a request from the selected object, its dependencies, and, for translation actions, the current target result.

Context included

  • Source DDL for the selected object.
  • For rewrite actions, the current target DDL plus the source and target dialects.
  • Context around related objects that helps the assistant understand the surrounding codebase.
  • Additional context provided by SQL Tran's deterministic static analysis engine.

Focused on the object in front of you

Each action starts with a selected workspace object and the context needed to work on it. That keeps the result tied to a real source definition, its dependencies, and, where relevant, the current target translation.

The result stays close to the code you are reviewing, so it can support a concrete migration decision instead of creating another disconnected answer.

Validation behavior

Syntax is the first gate. Correctness comes next.

For Rewrite and Fill the gaps, SQL Tran sends the returned target DDL through its target-side syntax checks. A result with syntax errors is shown but not applied. A result that passes those checks is saved as the target override and marked AI generated, but it is not migration-ready yet. The AI-updated translation must still pass the full correctness-test workflow, with test scope and generated inputs informed by SQL Tran's deterministic static analysis engine.

AI OUTPUT Target translation CREATE PROCEDURE ... Generated DDL
GATE 01 Syntax check ✓ Target parser Invalid output is not applied
GATE 02 Correctness harness ✓ Source ↔ target behavior
RESULT Correctness evidence ✓ AI changes applied

Common questions

Is AI required to use SQL Tran? +

No. The main SQL Tran translation workflow is separate from the optional AI Assistant.

Who can use the AI actions? +

The API requires an authenticated workspace user with Workspace.Analysis access and a Pro or BYOL plan. AI must also be configured with a Claude API key.

What happens when a rewrite has errors? +

SQL Tran returns the target DDL and the syntax errors in the AI panel, but does not save that result as the target override.

Use AI where the translation needs a closer look

See how SQL Tran's optional AI Assistant fits alongside deterministic translation, dependency analysis, target creation, and correctness testing.