Files
deepseek-harness/packages/lsp/README.zh.md
Tianyi Cui d488330ba4 fix(rebase): migrate the replayed E2B branch onto the rebased parent
The linear replay carried old-lineage content over parent-owned files;
this checkpoint restores them and adapts the branch to the parent's
post-rebase seam:

- restore all pty/lsp/subprocess/code-runtime surfaces to the parent's
  exact content (this branch claims none of them) and drop the net-zero
  code-runtime-e2b/pty-e2b/lsp-e2b residue and its registrations
- widen serializeRemoteEnvironment to the seam's NodeJS.ProcessEnv
  tombstone contract: an explicit undefined removes an ambient entry
- migrate the two E2B fixture Agent stubs to the Inbox-model interface
  and Session.create
- re-apply the branch's gen-doc-graphs roles, THIRD_PARTY_NOTICES e2b
  row, and packages/README group row (trimmed to the doc budget);
  regenerate catalogs and re-record bilingual pairings
2026-08-08 22:19:13 +08:00

1.4 KiB
Raw Blame History

lsp/ - LSP 能力家族

English | 中文

语言服务器能力 seam抽象 LSP 接口、通用 stdio 提供方,以及面向模型的 lsp 工具。这些全是产品 包。

职责 ctx key
lsp/ 抽象 LSP seam按品牌化 id + 扩展名映射组织的提供方注册表、逐查询选择、词汇、LspError ctx.lsp
lsp-local/ 基于 ctx.fsctx.subprocess 的通用多服务器 stdio 后端JSON-RPC、临时打开查询 (在 ctx.lsp 上注册提供方)
tool-lsp/ 面向模型的 lsp 工具(四种操作、从 1 开始的 UTF-16 光标坐标) (注册到 ctx.tools

接口位于 lsp/lsp/。该 seam 恰好公开四种语义操作:goToDefinitionfindReferencesgoToImplementationhover,且不提供通用 JSON-RPC 逃生口;因此,替换提供方不会改变模型请求导航的方式,也不会让协议载荷或未经评审的修改进入模型契约。提供方注册的是能力 而非工具;tool-lsp 是面向模型名称、schema、提示词指引和呈现的唯一 owner。

设计原理见 LSP 能力 seam Agent Note其中也解释了文档为何在每次查询时临时打开、stdio 主机为何使用共享的文件系统/子进程执行环境,以及扩展名归属为何在同一运行时内互斥。