Docs

Built-in tools›Files and search

Code navigation

lsp
Group
Files and search
Turned on by
Its own switch on the Tools page of Conversation settings.
Approval
Not reviewed: runs without asking, within the limits on this page.
Profile key
tool.lsp.description

Asks a language server about code: where a symbol is defined, where it is used, what type it has, and what calls what.

Which server answers depends on the file's extension. You set servers up as described in Code navigation.

When it asks you

Normally a call counts as reading filePath, like read. If the workspace has its own .mework/lsp.json, every call asks under Manual and Accept edits, because that file comes with the project and names the command Mework starts. Servers from your own ~/.mework/lsp.json, or built into Mework, never trigger this.

Limits

Files over 10 MB are not sent to the server, and a request waits at most 30 seconds for an answer.

Good to know

You can change a recorded lsp call in the timeline and run it again with Rerun.

Parameters

ParameterTypeDetails
character required
Character
integerThe character offset (1-based, as shown in editors)
filePath required
File path
stringThe absolute or relative path to the file
line required
Line
integerThe line number (1-based, as shown in editors)
operation required
Operation
stringThe LSP operation to perform
"goToDefinition" "findReferences" "hover" "documentSymbol" "workspaceSymbol" "goToImplementation" "prepareCallHierarchy" "incomingCalls" "outgoingCalls"
query
Query
stringThe symbol name or partial name to search for (workspaceSymbol only). Most language servers return no results for an empty query, so always provide it when using workspaceSymbol.

Edit this page on GitHub