一键导入
serena-lsp-tools
Navigate code semantically with LSP-backed symbol overview, symbol lookup, declaration/reference search, diagnostics, and guarded symbol edits.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Navigate code semantically with LSP-backed symbol overview, symbol lookup, declaration/reference search, diagnostics, and guarded symbol edits.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | serena-lsp-tools |
| description | Navigate code semantically with LSP-backed symbol overview, symbol lookup, declaration/reference search, diagnostics, and guarded symbol edits. |
Use this skill when code understanding or edits benefit from language-server semantics instead of plain text search. Prefer it for symbol discovery, definitions, references, diagnostics, and whole-symbol edits.
Run commands from the project root or a subdirectory:
serena-rs <command> ...
Use serena-rs <command> --help when argument format is unclear; command help includes examples for locations, symbol paths, and write confirmations.
doctor --file <file> when first checking a project or dependency setup.health --file <file> when a target file is known; otherwise use health.overview <file> before reading a large source file.symbol <name-or-path> [--file <file>] to locate definitions by semantic symbol name.declaration <file:line[:col]> and refs <file:line[:col]> for LSP-style navigation.diagnostics <file> before and after risky edits.rg_cross_check when present.explain-empty <command-id> when a successful command returns empty or confusing data.Read-only:
healthhealth --file <file>doctordoctor --file <file>statusoverview <file> [--depth N]symbol <name-or-path> [--file <file>] [--depth N]declaration <file:line[:col]>refs <file:line[:col]> [--include-declaration]diagnostics <file>locate "<file>@<symbol-path>"explain-empty <command-id>Lifecycle:
startstopcache clearserver logsserver logs --tail NWrite commands require explicit --apply; no dry-run is fabricated:
rename <file>@<symbol-path> <new-name> --applyreplace-body <file>@<symbol-path> --stdin --applyinsert-before <file>@<symbol-path> --stdin --applyinsert-after <file>@<symbol-path> --stdin --applyline and col. If col is omitted, function names are preferred on function definitions; nearby-line adjustments are reported in context and warnings. Pass :col when a line contains multiple identifiers.refs returns no semantic references, inspect rg_cross_check before assuming the symbol is unused.command_id for explain-empty; some outputs include parsed_data and context.health --file <file> succeeds for the relevant language.start, stop, cache clear, and write commands are project-exclusive.cache clear only runs when the recorded server is not alive; use stop first.Do not use this skill for file reads, shell execution, text search, or memory operations. Use normal agent tools for those.