Skip to content

退役 Pi/Bun,完成原生 Agent 收尾 - #361

Closed
taekchef wants to merge 6 commits into
mainfrom
codex/pi-removal
Closed

taekchef wants to merge 6 commits into
mainfrom
codex/pi-removal

Conversation

@taekchef

Copy link
Copy Markdown
Collaborator

结论

魏碑只保留 Swift 原生 Agent。删除 Pi/Bun 二进制、协议、依赖、认证旁路和构建发布链;不保留无真实用户依据的旧数据兼容层。

主要改动

  • 删除内置 Pi/Bun 运行时、LGPL 重链接材料、准备脚本和 Node Agent 依赖。
  • 账号与设置只展示原生运行时真正支持的提供商;API Key 继续绑定自定义端点,凭据仍由 NativeAgentCredentialStore 独占。
  • 修复自定义兼容端点取错凭据、Anthropic 认证类型和无效引导登录。
  • 将 WeiBeiPiCheck 改名为 WeiBeiNativeCheck;无参数执行改为失败,构建脚本只运行有意义的认证状态检查。
  • 删除无入口的 interactiveVisualizationsEnabled 持久化开关;visualize 工具与可移植课程导出能力均保留。
  • 更新当前法律说明、构建说明和历史文档状态;历史对拍记录不改写。

验证

  • swift build
  • swift run WeiBeiSelfCheck
  • swift run WeiBeiNativeCheck --authentication-status
  • npm run typecheck:tools
  • 三份构建脚本 bash 语法检查
  • ci_changed_scopes.sh --self-check
  • WeiBeiNativeCheck 无参数返回码为 2

本机 Swift 测试目标仍受工具链环境限制:XCTest 模块不可用,未把环境失败误记为代码失败。

未执行

  • 未合并
  • 未发布
  • 未安装正式 App
  • 未做真实账号或真实窗口验收

codex and others added 6 commits August 23, 2026 16:11
…te/NativeEventDispatch/NativeMiddlewareDecision/NativeMiddleware/NativeDisposableStore)
- WorkspaceStore+NativeAgent: dispatch 只走 executeNativeStudyAgentRequest,删除 executePiStudyAgentRequest 分支与 piRuntime.cancel
- NativeAgentBackendSelection 整体删除(WEIBEI_AGENT_BACKEND 环境变量分支、persistedDebugBackend、debugDefaultsKey)
- AgentSettingsView 的 nativeBackendDebugCard(W6 验收临时设施)与 SettingsView 的 @AppStorage 接线删除
- StudyAgentBackend 删除 case pi(0 用户,decodeLossy 容错旧存档);全部 .pi 产生点翻转为 .native
- NativeAgentSelfChecks 的后端选择检查改为防复活断言(pi 不再可解码)
- 删 PiAgentRuntime/PiRPCProtocol/PiOAuthService/PiManagementProtocol 与 pi 扩展(extension.ts/session-title.ts)
- PiAgentResources 拆为独立文件(skills 加载器,Native 复用)
- 新增 AgentAccountService:接管设置页全部账号职责——目录静态化(NativeProviderRouting 默认模型+手输兜底)、凭据走 NativeAgentCredentialStore、OpenAI 订阅登录走 NativeOpenAIOAuth 浏览器流程、旧 PiAgent/auth.json 一次性迁移(已登录账号免重登)
- UI 观察点替换(SettingsView/AgentSetupPromptCard/AgentProviderReadiness);删 pi 登录中途问答 UI
- WorkspaceStore:piRuntime 成员/构造/关停/会话清理全删,catch 改纯 CancellationError
- StudyAgentRuntime:删 pi 错误映射;WeiBeiPiCheck:删 pi live 检查/management-protocol/订阅探针/基线夹具/DeepSeek pi 对拍,保留 native 五入口
- 能力面变化:订阅 OAuth 登录暂仅 OpenAI(native 只实现了它),anthropic/copilot/radius 请用 API Key;Azure endpoint 绑定校验暂缺
@taekchef

Copy link
Copy Markdown
Collaborator Author

最终实现已由 #375 完整整合并合入 main;关闭此旧草稿,避免重复合并旧代码。

@taekchef taekchef closed this Aug 24, 2026
@taekchef
taekchef deleted the codex/pi-removal branch September 13, 2026 10:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant