Language models
Call a model directly from the editor: chat in a buffer, ask about any text with a vim operator, review every edit, and control exactly what is sent.
| Topic | What it covers | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Language models | The LLM layer from start to finish. Setup, chat, asking about text from any buffer, context, tools with review, MCP servers, profiles, watching and stopping requests, the privacy model, and how it differs from the agent integrations. | ||||||||||
| llm | llm: configure the LLM layer. Layers, the llm.* options, profiles, project config and what a project may not set, keys. | ||||||||||
| llm-chat-mode | llm-chat-mode: a chat with a language model in its own buffer — a read-only transcript with an editable prompt. CR sends, C-j newlines, C-c interrupts, gb forks, gq closes; :llm-retry asks again; :llm-save / :llm-resume keep a chat, :llm-export writes it out. | ||||||||||
| llm-mode | llm-mode: ask a language model about any text, from any buffer, or have it rewrite text. | llm-tools-mode | llm-tools-mode: tools for llm chats beyond lattice's own, from MCP servers ([llm.mcp. | llm-system-mode | llm-system-mode: the system prompt in an ordinary buffer. :w applies it to the session and closes the buffer, :q! discards. Nothing is written to disk. | llm-context-mode | llm-context-mode: llm-context, what requests from a buffer carry and where each item stands now. dd on a row removes it. Read-only; updates itself. | llm-inspect-mode | llm-inspect-mode: llm-inspect, a request exactly as it goes to the provider — address, headers, body, every exchange of it — with the key shown as | llm-requests-mode | llm-requests-mode: llm-requests, every LLM request since the editor started, running first, with state, model, start time, how long it took and destination. dd on a row stops it; | |