lsp-edit-export
Safe workflow for editing exported symbols or public APIs.
Skill by blackwell-systems
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/blackwell-systems-lsp-edit-export
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: writing, productivity
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/lsp-edit-export
Tools it pre-approves 8
From allowed-tools in SKILL.md: the agent may use these without asking you each time.
mcp__lsp__go_to_symbolmcp__lsp__open_documentmcp__lsp__find_referencesmcp__lsp__get_diagnosticsmcp__lsp__run_buildmcp__lsp__replace_symbol_bodyEditWrite
What's inside
- Skill name
lsp-edit-export- Description
- Safe workflow for editing exported symbols or public APIs. Use when changing a function signature, modifying a public type, or altering any symbol used outside its own package — finds all callers first so nothing breaks silently.
- License
- MIT
- Compatibility
- Requires the agent-lsp MCP server (github.com/blackwell-systems/agent-lsp)
- Allowed tools
- mcp__lsp__go_to_symbol, mcp__lsp__open_document, mcp__lsp__find_references, mcp__lsp__get_diagnostics, mcp__lsp__run_build, mcp__lsp__replace_symbol_body, Edit, Write
- Metadata
- optional-capabilities: workspaceSymbolProvider · required-capabilities: referencesProvider
- Instructions
- 214 lines in SKILL.md · view on GitHub
Files (2)
- SKILL.md
- patterns.md · references/
SKILL.md (first lines)
> Requires the agent-lsp MCP server.
# lsp-edit-export
Safe workflow for editing exported symbols. Always discovers all callers before
touching any code, then verifies the change is clean.
## When to Use
Use this skill whenever you intend to change the signature, name, or behavior of
an **exported symbol**: a symbol visible outside its defining package or module.
**Language-specific definitions:**
| Language | Exported means... |
|------------|------------------------------------------------------------------------|
| Go | Identifier starts with an uppercase letter (e.g. `MyFunc`, `MyType`) |
| TypeScript | Has `export` keyword; or is a public class member (no `private`) |
| Python | Not prefixed with `_`; or explicitly listed in `__all__` |
| Java/C# | Has `public` or `protected` visibility modifier |
| Rust | Has `pub` keyword |
If you are unsure whether a symbol is exported, treat it as exported and run
this workflow anyway. The cost is a few extra tool calls; the benefit is never
breaking a hidden caller.
**Do NOT skip this workflow** even when you believe there are zero callers.
The confirmation gate in step 3 exists precisely for that case.
## Workflow
**If LSP is not yet initialized**, call `mcp__lsp__start_lsp` with the
workspace root first. (agent-lsp supports auto-inference from file paths, so
explicit start is only required when switching workspaces or on a cold session.)
### Step 1 — Locate the symbol
Use `go_to_symbol` to find the symbol's definition by name, without needing to
know its file path or line number in advance:
```
mcp__lsp__go_to_symbol({
"symbol_path": "PackageName.ExportedFunction",
"workspace_root": "/abs/path/to/repo" // optional, narrows scope
})
```
`symbol_path` uses dot notation. For a top-level function `Encode` in package
`codec`, use `"codec.Encode"`. For a method `Reset` on type `Buffer`, use
`"Buffer.Reset"`. The last component is the leaf name; any prefix is used to
disambiguate when multiple symbols share the same leaf.
The tool returns a `FormattedLocation` with the definition file and 1-indexed
line/column. Record this position — you will need it in step 2.
### Step 2 — Discover all callers
Call `find_references` using the `position_pattern` field to express the cursor
position as a readable text pattern rather than raw coordinates. The `@@` marker
indicates exactly where the cursor sits (the character immediately after `@@`):
```
mcp__lsp__find_references({
"file_path": "<definition file from step 1>",
"position_pattern": "func @@ExportedFunction(",
"include_declaration": false
})
```
The `@@` must immediately precede the first character of the symbol name.
Examples:
- `"func @@Encode("` — Go function declaration
- `"type @@Buffer struct"` — Go type declaration
- `"export function @@parse("` — TypeScript function
- `"class @@Parser:"` — Python class
- `"pub fn @@process("` — Rust function
If `position_pattern` is unavailable on your MCP client, fall back to the
`line` and `column` fields from the location returned in step 1.
The tool returns a list of reference locations across the codebase.
### Step 3 — Confirmation gate (REQUIRED — never skip)
Before making any change, present the impact summary to the user and ask for
explicit confirmation. This gate is mandatory even when the caller count is zero.
Format the gate as follows:
```
## Impact Check: <SymbolName>
- Definition: <file>:<line>
- Callers found: N reference(s) in M file(s)
Files with callers:
- <file1>
- <file2>
...
Proceed with the edit? [y/n]
```
If the user answers **n**, stop. Do not make any edits.
If the user answers **y**, proceed to step 4.
**Why this gate exists even for 0 callers:** the LSP index may be incomplete
(e.g. files not yet saved, workspace not fully loaded). Zero callers is a data
point, not a guarantee.
### Step 4 — Make the edit
Apply your intended change using `Edit` or `Write`. When replacing a complete
function or method body, `replace_symbol_body` is an option that resolves the
symbol by name and replaces its full range without position math:
```From blackwell-systems/agent-lsp, MIT.
More from blackwell-systems/agent-lsp
- 0.791score
lsp-dead-code
blackwell-systems
Enumerate exported symbols in a file and surface those with zero references across the workspace.
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-understand
blackwell-systems
Deep-dive exploration of unfamiliar code — given a symbol or file, builds a complete Code Map showing type info, implementations, call hierarchy (2-level…
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-simulate
blackwell-systems
Speculative code editing session — simulate changes in memory before touching disk.
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-rename
blackwell-systems
Two-phase safe rename across the entire workspace.
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-impact
blackwell-systems
Blast-radius analysis for a symbol or file — shows all callers, type supertypes/subtypes, and reference count before you change it.
SkillAFreshness: A★ 164Claude Code +9 - 0.787score
lsp-safe-edit
blackwell-systems
Wrap any code edit with before/after diagnostic comparison.
SkillAFreshness: A★ 164Claude Code +9 - 0.787score
lsp-explore
blackwell-systems
"Tell me about this symbol": hover + implementations + call hierarchy + references in one pass — for navigating unfamiliar code.
SkillAFreshness: A★ 164Claude Code +9 - 0.787score
lsp-extract-function
blackwell-systems
Extract a selected code block into a named function.
SkillAFreshness: A★ 164Claude Code +9 - 0.787score
lsp-fix-all
blackwell-systems
Apply available quick-fix code actions for all current diagnostics in a file, one at a time with re-collection between each fix.
SkillAFreshness: A★ 164Claude Code +9 - 0.787score
lsp-generate
blackwell-systems
Trigger language server code generation — implement interface stubs, generate test skeletons, add missing methods, generate mock types.
SkillAFreshness: A★ 164Claude Code +9 - 0.787score
lsp-refactor
blackwell-systems
End-to-end safe refactor workflow — blast-radius analysis, speculative preview, apply to disk, verify build, run affected tests.
SkillAFreshness: A★ 164Claude Code +9 - 0.785score
lsp-inspect
blackwell-systems
Full code quality audit for a file, package, or directory.
SkillAFreshness: A★ 164Claude Code +9
Signals
- Stars
- 164
- Forks
- 20
- Open issues
- 5
- Contributors
- 9
- Last commit (this folder)
- May 10, 2026 (5 months ago)
- Last release
- Oct 24, 2026 (4 days ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/blackwell-systems/agent-lsp
- Website
- www.agent-lsp.com/
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from blackwell-systems
- 0.791score
lsp-rename
blackwell-systems
Two-phase safe rename across the entire workspace.
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-understand
blackwell-systems
Deep-dive exploration of unfamiliar code — given a symbol or file, builds a complete Code Map showing type info, implementations, call hierarchy (2-level…
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-impact
blackwell-systems
Blast-radius analysis for a symbol or file — shows all callers, type supertypes/subtypes, and reference count before you change it.
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-dead-code
blackwell-systems
Enumerate exported symbols in a file and surface those with zero references across the workspace.
SkillAFreshness: A★ 164Claude Code +9 - 0.791score
lsp-simulate
blackwell-systems
Speculative code editing session — simulate changes in memory before touching disk.
SkillAFreshness: A★ 164Claude Code +9 - 0.787score
lsp-fix-all
blackwell-systems
Apply available quick-fix code actions for all current diagnostics in a file, one at a time with re-collection between each fix.
SkillAFreshness: A★ 164Claude Code +9
Cite this page
lsp-edit-export skill. Agent Mart. https://agentmart.dev/skills/blackwell-systems-lsp-edit-export (last updated 2026-10-24)