Repository navigation
docs(contracts): 官方 SDK 一节和函数协议版本说明对齐现状 - #1650
Merged
Merged
Conversation
- Rust SDK 已实现插件函数协议 3 及宿主服务,删掉「只实现协议 1 和 2」的过时说法 - Node SDK 说明从「litheBuild 1」改为宿主服务、litheBuild 和 VCS 提供方(SDK 已支持 litheBuild 1–6) - Java SDK 补充它实现的范围:宿主服务和 litheBuild,不含 VCS 提供方 - Rust Core 实现的插件函数协议版本从 1、2 改为 1 到 3(与 SUPPORTED_VERSIONS 一致) - AGENTS.md 的两仓库同步说明改为三个官方 SDK(Node、Java、Rust)
- capability 的官方后端 SDK 从 Node、Java 改为 Node、Java 与 Rust - verification 加上 Rust SDK 的 cargo test,以及 sdk-e2e 运行的 plugin_sdk_rust 场景 - notes 说明 Rust SDK 的范围:函数协议及其宿主服务,不含构建与 VCS Provider
xiaoyumuxi
marked this pull request as ready for review
November 2, 2026 04:20
lithe-plugin-docs#10 让该场景除凭据外,还服务工作区、文件监视和窗口 请求,投递命令与上下文变化,并检查取消会转发给宿主。
与契约 README 一致:lithe-plugin-docs#10 的 Rust 示例后端场景还覆盖 工作区、文件监视订阅、窗口消息、过期上下文、取消转发,以及命令与 工作区变化通知。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
背景
Lithe-IDEA/lithe-plugin-docs#10 把三个官方插件后端 SDK 都升级到插件函数协议 3(Node 0.2.0、Java 0.2.0、Rust 0.1.0),CI 全部通过。本仓库契约里描述 SDK 和 Core 实现范围的几句话已经过时,而 lithe-plugin-docs 的
contract/v1/只能通过node scripts/contract.mjs sync从这里逐字节同步,不能手改,所以先在这里修正。改动
只改文档和平台能力记录,不涉及代码、schema 或 fixture。
shared/contracts/plugins/v1/README.mdOfficial backend SDK 一节
litheBuild1litheBuild, and VCS providerslitheBuild, but not VCS providerscredentialshost service, but neither build nor VCS providersBUILD_VERSION都已经是 6,所以「litheBuild1」也已过时。Plugin functions 一节
rust/lithe-core/src/lsp/interface/plugin_function.rs的SUPPORTED_VERSIONS: [1, 2, 3]一致。SDK 端到端一段
AGENTS.md(插件契约的两仓库同步)scripts/sdk-e2e.mjs已经同时跑 Node、Java 和 Rust 的示例后端。shared/platform-feature-matrix/features/plugin-functions.jsonshared/contracts属于能力矩阵门禁的平台路径。这条记录描述的也是同一件事,而且同样过时,所以一并更新,没有用matrix-exempt:cargo +1.87 test --locked --manifest-path sdk/rust/Cargo.toml。sdk-e2e.mjs运行的场景从plugin_sdk_node、plugin_sdk_java加上plugin_sdk_rust,并说明 Rust 示例后端覆盖的内容:packaged 启动、函数结果/进度/失败/取消、测试扮演宿主应答 hostRequest(凭据,以及协议 3 的工作区、文件监视订阅、窗口消息、过期上下文和取消转发)、命令与工作区变化通知、重启恢复状态、未授权时的拒绝。不改的内容
.agents/notes/implemented/architecture/里的2026-10-20-plugin-backend-sdk.md和2026-10-23-plugin-contract-publishing.md是当时的决策记录,保留原文。验证
./scripts/architecture/verify-shared-contracts.sh通过(共享翻译完整、debug v1 baseline、JSON fixture 有效)。./scripts/platform-feature-matrix/verify-platform-feature-matrix-change.sh origin/preview HEAD通过。./scripts/platform-feature-matrix/verify-platform-feature-matrix.sh通过(231 条能力记录)。node scripts/sdk-e2e.mjs(589116e 和 [Feature] 适配其他语言系 尤其是前端部分 #11 同步后的 ca9ca96 都是 6 项全部通过)。合并顺序
lithe-plugin-docs#10 已合并。SDK 端到端一段和能力矩阵的 verification 描述的是 lithe-plugin-docs#12 合并后的状态,两边最好一起合并。后两个提交的说明里写成了 lithe-plugin-docs#10,实际是 #12。
合并后
在 lithe-plugin-docs 运行
node scripts/contract.mjs sync --revision <本 PR 合并后的 preview 提交>,把contract/v1/同步过去。