Choose the right path
How to pick one of the ten LEX AI modes from your intent, with disambiguation rules, worked examples, and the two cases where a mode redirects you.
Choose the right path
Pick the mode from what you are trying to do, not from tool names. This one decision determines the whole workflow, the guardrails, and the tools your assistant can see. There are ten modes and exactly one is visible at a time.
Intent → mode
What you want to do | Use |
|---|---|
Turn a rough idea into a written, agreed project contract |
|
Build a new Lex app from scratch |
|
Build only a small MVP quickly |
|
Finish, expand, or complete an existing MVP to full product |
|
Modify or add a feature to an existing app |
|
Review or audit an existing project |
|
Write the test suite for an existing app and prove it catches regressions |
|
Adapt an existing app to a changed input-data format |
|
Get an existing app running in a target environment |
|
Document or reverse-document existing code |
|
Start in brief when nothing is written down
brief is not an alternative to building — it is the mode that makes this decision for you. It interviews you topic by topic, writes .lex/contract.md, and finalize_brief names the next mode and its first tool. Ten build scenarios map onto the other nine modes, so the handoff comes out of the interview instead of being a second guess. Forward then reads the contract automatically and treats its statements as requirements, not assumptions.
Disambiguation rules
- "MVP" plus "complete / finish / expand / full product" →
mvp_completion. - "MVP" plus "just build the first version" →
mvp_generator. - Implementation changes on an existing repo without MVP-completion wording →
edit. - A changed data format — renamed columns, new delimiter, new encoding, a different row grain →
input, notedit. Lex ships no input parser: column names are string literals in hand-written parsing code, so a rename can import wrong data under a SUCCESS status without raising anything. - Configuring and running the app somewhere →
deploy. It changes configuration, not application code. - Never use
editfor MVP completion — that is whatmvp_completionexists for. - If intent genuinely matches two rows, ask exactly one clarifying question, then proceed.
Fast examples
- "I know roughly what I want but nothing is written down" →
brief - "Build a full new product from this contract" →
forward - "Generate an MVP for this idea" →
mvp_generator - "Please complete this MVP to production quality" →
mvp_completion - "Refactor this existing app and add OAuth" →
edit - "Run a code-quality or compliance audit" →
review - "Write tests and show me they catch a regression" →
test - "The supplier changed the CSV header row" →
input - "Get this running on the staging box" →
deploy - "Create business and technical docs from existing code" →
backward
When a mode redirects you
test will not open a session without a user-story document: an assertion derived from the implementation pins current behaviour, bugs included, and can never fail. It hands the project to backward and records the pending return so the test run resumes on the way back. Treat that, and the brief handoff, as the workflow working rather than as an error.
Important discipline
Never switch modes to get around an error. If a tool fails, resolve the underlying problem and retry the same tool. Switch only when the actual intent changes. See Mode chooser and Mode switching next.
Was this helpful?
Your feedback shapes what we write next.
