LetX engineering · August 29, 2026
How Lexi Checks LaTeX Edits with the Compiler
Lexi reads the active project, edits source, compiles the result, returns the PDF or error log, and preserves project history.
By Shihab Shahriar Antor · Updated 2026-08-29
Lexi edits source inside a LetX project and runs the selected LaTeX compiler. The result is either a PDF or a compiler error that can guide the next edit.
Limits of chat-based LaTeX generation
A general chat model usually sees only the text pasted into the conversation. It may not see a document class, local macro, bibliography file, included chapter, image path, or the exact error emitted by pdfLaTeX, XeLaTeX, or LuaLaTeX. A response can therefore look correct while failing in the actual project.
Lexi operates inside the project boundary. The published product guide says it reads project files, bibliography, and the compile log; applies changes in place; invokes the compiler; and can use the resulting error to continue. The previous project version remains recoverable.
What compilation checks
A successful compile establishes a narrow but useful fact: the edited source was accepted by the chosen toolchain and produced an output. A failed compile gives a concrete error, file, and line context. Both are stronger signals than a model’s confidence.
Compilation still does not prove mathematical correctness, citation validity, originality, accessibility, or compliance with every journal rule. The tool loop reduces one important class of uncertainty; it does not turn generation into peer review.
The published command surface
As checked on 29 August 2026, LetX documents eighteen commands. They cover compile repair; tables, figures, diagrams, and Beamer slides; image and PDF conversion; citations; formatting and translation; shortening and cleaning; explanation, outlining, and scaffolding.
Each command works against an existing project. The source change, compiler result, and prior project version remain available for inspection.
Where Lexi belongs in a research workflow
Use it for mechanical work that benefits from compiler feedback: resolving an undefined command, constructing a table, converting a diagram into TikZ, reorganizing a section, or repairing a broken bibliography. Keep the author responsible for claims, evidence, mathematics, authorship, and final submission requirements.
The Shahriar Labs Lexi research page documents the loop, commands, limits, and primary sources. The canonical product guide remains letx.app/lexi.