LazyCodex
LazyCodexv0.2.2

lsp

Language-server diagnostics, definitions, references, symbols, and safe renames for Codex.

The lsp skill gives LazyCodex (LZX) language-server precision inside the Codex workspace. Instead of grepping for a symbol or guessing at a type error, Codex queries a real language server for diagnostics, definitions, references, document symbols, and rename safety. It ships in the OmO (oh-my-openagent) plugin that LazyCodex installs into Codex.

TL;DR

Use lsp when Codex needs ground-truth answers about code: what's wrong after an edit, where a symbol is defined, who uses it, and whether a rename is safe. The lsp.* names are MCP tool calls invoked through the tool interface — they are not shell commands.

Tools

ToolPurpose
lsp.statusList configured, installed, missing, disabled, and active language servers.
lsp.diagnosticsCheck one file or directory for diagnostics. Prefer severity: "error" after edits.
lsp.goto_definitionLocate a symbol definition from file, line, and character.
lsp.find_referencesFind usages of a symbol across the workspace.
lsp.symbolsInspect document symbols or search workspace symbols.
lsp.prepare_renameCheck whether a rename is valid at a position.
lsp.renameApply a language-server workspace edit for a rename.

Typical flow

Check the servers

If diagnostics report a missing language server, run lsp.status first to see what is configured, installed, or disabled.

Verify after editing

After an apply_patch, run lsp.diagnostics with severity: "error" on the touched file to confirm the change compiles cleanly.

Use lsp.goto_definition and lsp.find_references to understand impact, then lsp.prepare_rename followed by lsp.rename to apply a workspace-wide rename through the server's own edit.

Configuration

Project config lives at .codex/lsp-client.json; user config lives at ~/.codex/lsp-client.json.

{
  "lsp": {
    "typescript": {
      "command": ["typescript-language-server", "--stdio"],
      "extensions": [".ts", ".tsx", ".js", ".jsx"]
    }
  }
}

When a server is reported missing, lsp.status tells you whether the binary is uninstalled, disabled, or simply not configured.

For structural search and rewrite (matching code by shape rather than text), see the refactor skill, which drives ast_grep_search / ast_grep_replace.

On this page