Skip to content

v1.0.4

Choose a tag to compare

@ct-jyjntc ct-jyjntc released this 02 Aug 12:04
· 58 commits to main since this release

中文

基于 v1.0.3..v1.0.4 的提交整理。

新增

  • 系统托盘(System Tray)

    • Windows / Linux / macOS 托盘支持
    • 关闭窗口可最小化到托盘(跨平台 hide-on-close)
    • 托盘点击恢复窗口;托盘菜单退出
    • 适配菜单栏图标尺寸
  • Electron 启动闪屏

    • Splash 直至 AppShell 发出 ui-ready
    • 侧边栏优先加载,ChatWindow 延后挂载
    • Windows 冷启动参数与更快的就绪探测
    • /api/health 轻量健康检查
  • Lean Mode(可选精益模式)

    • 产品级防膨胀策略:会话启动注入 portable anti-bloat policy
    • 强度档位:off / review / hard(默认 off)
    • 编辑后 high-signal lean review(/api/lean-review + LeanReviewCard
    • Hard 强度:大文件净增行硬门禁(edit growth gate)
    • 审查范围限定为本次 touched paths(避免脏工作区误报)
    • 手动「检查精简度」入口移入 composer 溢出菜单
    • 项目级 .pi-web.json 覆盖 UI + /api/lean-project
    • leanMode 变更时重置空闲 RPC 会话
    • 客户端安全 defaults(lean-mode-settings,无 Node fs)
    • smoke-lean-mode 验收脚手架
  • 内置扩展预打包

    • first-party 扩展(todo / ask-user)纯模块注册
    • 重型扩展(permission / subagents / mcp-adapter)预打包为 .pi-web-bundle
    • 迁移遗留 packages 设置并 prewarm factories
    • bundle:extensions + Electron 打包复制 prebundle
    • 避免启动时 jiti / 运行时 npm 安装
  • 薄 RPC 注册表

    • rpc-registry / rpc-running / rpc-session-start / rpc-session-wrapper 拆分
    • 列表/running API 不再强拉完整 SDK 图
    • 迟到 agent 事件保留;provider 凭据存储加固

修复

  • 扩展包根路径避免动态 require.resolve(Turbopack 友好,resolve-npm-package-root
  • Lean Mode 默认值客户端安全(不把 Node fs 打进浏览器包)
  • esbuild JS API + CLI 回退;Windows 原生二进制与 shell 解析
  • 迟到 agent 事件不丢;provider credentials 持久化
  • Lean Hard 文案与实际 edit gate 行为对齐

重构 / 改进

  • 巨型 UI 模块化

    • AppShell / ChatInput / ChatWindow / MessageView / ModelsConfig / SessionSidebar / SettingsPage 拆分为子模块
    • 消息块、composer 菜单、extension panels、process rail 等独立文件
    • 统一 Icon 组件替换内联 SVG
  • Agent 会话热路径拆分

    • useAgentSession 事件/流式/合并/扩展 UI 抽到 agent-session-* 模块
    • 共享类型与 model cost 工具归一
  • AI 编码约束与 declutter 蓝图文档(AGENTS.md + superpowers specs)

内部调整

  • 新增:lean-*builtin-extensionsfirst-party/*rpc-registryrpc-runningrpc-session-*resolve-npm-package-rootIcontray.jsLeanReviewCard
  • package.json 增加 bundle:extensionsbuild:electron 先打包扩展
  • 版本:@ct-jyjntc/pi-web@1.0.4

安装说明(本 Release 附件)

macOS

  • 附件:Pi-Web-1.0.4-arm64.dmg(Apple Silicon)
  • 签名:electron-builder 真实 ad-hocidentity: "-" Apple 公证)
  • 若 Gatekeeper 拦截:
# 方式 1:右键 App → 打开 → 打开
# 方式 2:
xattr -cr "/Applications/Pi Web.app"
open "/Applications/Pi Web.app"

Windows

  • 附件:Pi-Web-1.0.4-x64.exe(Windows x64 NSIS 安装包)
  • 双击安装,可自定义安装目录;安装后会创建桌面与开始菜单快捷方式。
  • 如 SmartScreen 提示「Windows 已保护你的电脑」:点击「更多信息」→「仍要运行」。

English

Prepared from commits in v1.0.3..v1.0.4.

Added

  • System tray

    • Tray support on Windows / Linux / macOS
    • Close-to-tray hide across platforms
    • Click tray to restore; quit from tray menu
    • Menu-bar-appropriate icon sizes
  • Electron splash screen

    • Splash until AppShell signals ui-ready
    • Eager sidebar, deferred ChatWindow mount
    • Windows cold-start flags + faster readiness probing
    • Lightweight /api/health
  • Lean Mode (opt-in anti-bloat)

    • Portable anti-bloat policy inject on session start
    • Intensities: off / review / hard (default off)
    • High-signal post-edit lean review (/api/lean-review + LeanReviewCard)
    • Hard intensity large-file net-growth edit gate
    • Review scoped to touched paths only
    • Manual “Check leanness” in composer overflow menu
    • Per-project .pi-web.json override UI + /api/lean-project
    • Reset idle RPC sessions when leanMode changes
    • Client-safe defaults (lean-mode-settings, no Node fs)
    • smoke-lean-mode acceptance scaffolding
  • Bundled builtin extensions

    • First-party todo / ask-user pure modules
    • Heavy extensions prebundled as .pi-web-bundle
    • Legacy packages migration + factory prewarm
    • bundle:extensions + Electron packaging copies
    • No runtime jiti / npm install at session start
  • Thin RPC registry

    • Split rpc-registry / rpc-running / rpc-session-start / rpc-session-wrapper
    • List/running APIs avoid pulling full SDK graph
    • Preserve late agent events; stronger provider credential storage

Fixed

  • Extension package roots without dynamic require.resolve (resolve-npm-package-root)
  • Lean Mode defaults stay client-safe (no fs in browser bundle)
  • esbuild JS API + CLI fallback; Windows binary/shell resolution
  • Late agent events preserved; provider credentials persisted
  • Lean Hard copy matches live edit-gate behavior

Refactors / Improvements

  • Giant UI modularization

    • AppShell / ChatInput / ChatWindow / MessageView / ModelsConfig / SessionSidebar / SettingsPage split into focused modules
    • Message blocks, composer menus, extension panels, process rail extracted
    • Shared Icon component replaces inline SVGs
  • Agent session hot-path split

    • Event/stream/merge/extension UI moved into agent-session-* modules
    • Shared types + model cost utility normalization
  • AI coding constraints + declutter blueprint docs

Internal

  • New modules: lean-*, builtin-extensions, first-party/*, rpc-registry, rpc-running, rpc-session-*, resolve-npm-package-root, Icon, tray.js, LeanReviewCard, etc.
  • bundle:extensions script; build:electron bundles extensions first
  • Version: @ct-jyjntc/pi-web@1.0.4

Install Notes

macOS

  • Asset: Pi-Web-1.0.4-arm64.dmg (Apple Silicon)
  • Signing: electron-builder real ad-hoc (identity: "-", not Apple notarized)
  • If Gatekeeper blocks:
xattr -cr "/Applications/Pi Web.app"
open "/Applications/Pi Web.app"

Windows

  • Asset: Pi-Web-1.0.4-x64.exe (Windows x64 NSIS installer)
  • Run the installer; you can choose the install directory. Desktop and Start Menu shortcuts are created.
  • If SmartScreen says "Windows protected your PC": click "More info" → "Run anyway".