pi-web-ui 0.114.1 → 0.114.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/README.md +187 -187
  3. package/README.zh-CN.md +227 -227
  4. package/README.zh-TW.md +227 -227
  5. package/bin/device-hub-cli.mjs +577 -577
  6. package/bin/frp-manager.mjs +1573 -1573
  7. package/bin/pi-device-hub.mjs +9 -9
  8. package/bin/pi-web-ui.mjs +4081 -4081
  9. package/deploy/nginx-subpath.conf +100 -100
  10. package/deploy/pi-web-ui.service +36 -36
  11. package/dist/server/agent-service.js +59 -10
  12. package/dist/server/attachments.js +6 -6
  13. package/dist/server/canvas/canvas-orchestrator.js +3 -3
  14. package/dist/server/communicate-tool.js +37 -11
  15. package/dist/server/compaction-instructions.js +8 -8
  16. package/dist/server/device-center/desktop-page.js +228 -228
  17. package/dist/server/device-center/hub-page.js +64 -64
  18. package/dist/server/device-center/native-desktop/macos.js +190 -190
  19. package/dist/server/device-center/native-desktop/windows.js +116 -116
  20. package/dist/server/dsh/runtime/cordis.yml +1 -1
  21. package/dist/server/dsh/runtime/custom-prompt.mjs +33 -33
  22. package/dist/server/dsh/runtime/goal-rpc.mjs +1309 -1309
  23. package/dist/server/dsh/runtime/launcher.mjs +235 -235
  24. package/dist/server/dsh/runtime/override.patch.yml +89 -89
  25. package/dist/server/dsh/runtime/runtime-root.mjs +405 -405
  26. package/dist/server/durable/durable-event-projector.js +19 -3
  27. package/dist/server/durable/durable-models.js +134 -65
  28. package/dist/server/eval-tool.js +135 -135
  29. package/dist/server/model-resolver.js +4 -1
  30. package/dist/server/patch-bash-process.js +89 -89
  31. package/dist/server/patch-tool.js +9 -9
  32. package/dist/server/patch-turn-end-boundary.js +3 -3
  33. package/dist/server/persona-chain.js +8 -8
  34. package/dist/server/remote-ssh-service.js +39 -39
  35. package/dist/server/schedule-agent-tool.js +11 -6
  36. package/dist/server/scheduler-tasks.js +84 -2
  37. package/dist/server/scm-commitmsg.js +10 -10
  38. package/dist/server/setup-page.js +620 -620
  39. package/dist/server/universal/universal-session.js +19 -18
  40. package/dist/server/vision-bridge.js +18 -18
  41. package/docs/device-center.md +148 -148
  42. package/docs/device-desktop.md +48 -48
  43. package/docs/dsh-engine.md +493 -493
  44. package/extensions/webui.ts +335 -335
  45. package/package.json +1 -1
  46. package/plugin-sdk/README.md +174 -174
  47. package/plugin-sdk/client-utils.mjs +279 -279
  48. package/plugin-sdk/import-check.mjs +210 -210
  49. package/plugin-sdk/index.d.ts +698 -698
  50. package/plugin-sdk/index.mjs +696 -696
  51. package/plugin-sdk/package.json +13 -13
  52. package/plugin-sdk/ssh-host-trust.mjs +225 -225
  53. package/themes/aetheris.css +501 -501
  54. package/themes/ayu-light.css +116 -116
  55. package/themes/bases/flow-base.css +1357 -1357
  56. package/themes/bases/obsidian-base.css +895 -895
  57. package/themes/bases/statusbar-flat-base.css +112 -112
  58. package/themes/bases/zhujian-base.css +688 -688
  59. package/themes/bases/zhupi-base.css +660 -660
  60. package/themes/catppuccin-latte.css +119 -119
  61. package/themes/catppuccin.css +116 -116
  62. package/themes/claude-code-dark.css +147 -147
  63. package/themes/codex.css +114 -114
  64. package/themes/cyberpunk.css +50 -50
  65. package/themes/dark-teal.css +264 -264
  66. package/themes/dazzle.css +38 -38
  67. package/themes/everforest-light.css +115 -115
  68. package/themes/flow-light.css +164 -164
  69. package/themes/flow.css +161 -161
  70. package/themes/geist.css +114 -114
  71. package/themes/gruvbox-light.css +115 -115
  72. package/themes/kanagawa-lotus.css +115 -115
  73. package/themes/md-preview.css +24 -24
  74. package/themes/mist.css +166 -166
  75. package/themes/nord.css +107 -107
  76. package/themes/one-dark.css +106 -106
  77. package/themes/paper.css +174 -174
  78. package/themes/rose-pine-dawn.css +114 -114
  79. package/themes/sakura.css +166 -166
  80. package/themes/solarized-light.css +114 -114
  81. package/themes/tokyo-night.css +115 -115
  82. package/themes/translucent.css +85 -85
  83. package/themes/transparent.css +116 -116
  84. package/themes/vs-code-dark.css +147 -147
  85. package/themes/wallpaper-flow.css +382 -382
  86. package/themes/wallpaper-obsidian.css +74 -74
  87. package/themes/white.css +164 -164
  88. package/themes/zhujian-dark.css +115 -115
  89. package/themes/zhujian.css +114 -114
  90. package/themes/zhupi-dark.css +115 -115
  91. package/themes/zhupi.css +114 -114
  92. package/web/dist/.build-assets.json +1 -1
  93. package/web/dist/assets/{BgTasksModal-BcXJ20RO.js → BgTasksModal-BIlQ89vr.js} +1 -1
  94. package/web/dist/assets/{BgTasksModal-DjQmiKnE.js → BgTasksModal-Ck2sjlPM.js} +1 -1
  95. package/web/dist/assets/{CanvasStudio-PI9pid0Y.js → CanvasStudio-B3W6b_rA.js} +1 -1
  96. package/web/dist/assets/{CanvasStudio-nf5-HxLM.js → CanvasStudio-Csv1Sj1-.js} +1 -1
  97. package/web/dist/assets/{DeviceCenter-CYttJw2a.js → DeviceCenter-BQdDcO8A.js} +1 -1
  98. package/web/dist/assets/{DeviceCenter-DPe4sz74.js → DeviceCenter-CHRKL0Vy.js} +1 -1
  99. package/web/dist/assets/{FilePreview-C9Ut4Lq6.js → FilePreview-B9xoU6ON.js} +1 -1
  100. package/web/dist/assets/{FilePreview-CvK3ZzX5.js → FilePreview-DUQpVZkH.js} +1 -1
  101. package/web/dist/assets/{GlobalSearchModal-C5e-OCw2.js → GlobalSearchModal-BXEGvUZq.js} +1 -1
  102. package/web/dist/assets/{GlobalSearchModal-H7pFK2UC.js → GlobalSearchModal-CnVPmfOI.js} +1 -1
  103. package/web/dist/assets/{GroupConversation-C2wNM0dQ.js → GroupConversation-CyIpQzDd.js} +1 -1
  104. package/web/dist/assets/{GroupConversation-ChN3TWQK.js → GroupConversation-DgYV3uYS.js} +1 -1
  105. package/web/dist/assets/{SCMPanel-buTGziDB.js → SCMPanel-imYI2Ecw.js} +1 -1
  106. package/web/dist/assets/{SCMPanel-kx-SCL2s.js → SCMPanel-sVZcV7dR.js} +1 -1
  107. package/web/dist/assets/{SettingsModal-BsUF8jqr.js → SettingsModal-Xw1Yoi3_.js} +1 -1
  108. package/web/dist/assets/{SettingsModal-D357Ky7P.js → SettingsModal-mb4e34-0.js} +1 -1
  109. package/web/dist/assets/{TerminalPanel-BBuM_Sez.js → TerminalPanel-CLkJJvxg.js} +1 -1
  110. package/web/dist/assets/{TerminalPanel-D6x6xz8Q.js → TerminalPanel-DpcIellm.js} +1 -1
  111. package/web/dist/assets/{TuiOverlayModal-CdbGV3Za.js → TuiOverlayModal-4-fFAZe7.js} +1 -1
  112. package/web/dist/assets/{TuiOverlayModal-d6x9u25n.js → TuiOverlayModal-DCu01lks.js} +1 -1
  113. package/web/dist/assets/{index-D6u8xH0o.js → index-Cdh3sibd.js} +4 -4
  114. package/web/dist/assets/{index-BPvpea8t.js → index-DWw_SxRq.js} +4 -4
  115. package/web/dist/index.html +29 -29
  116. package/web/dist/sw.js +179 -179
  117. package/web/public/sw.js +179 -179
package/CHANGELOG.md CHANGED
@@ -12,6 +12,23 @@
12
12
 
13
13
  暂无未发布内容。
14
14
 
15
+ ## [0.114.2] — 2026-10-31
16
+
17
+ ### Added
18
+
19
+ - 无。
20
+
21
+ ### Fixed
22
+
23
+ - **工具参数兼容性(#803)**:`communicate` 使用顶层对象参数,兼容 OpenAI、Anthropic 与 Google 的工具声明转换,同时保留各操作的执行前参数校验。
24
+ - **Durable 模型配置(#802)**:支持已有的 Vertex 协议,地址和模型覆盖保留内置目录、认证、动态发现与非聊天模型能力,并按实际协议发送请求。
25
+ - **流式消息与工具状态(#800、#801)**:Durable 工具输出不再混入助手正文;多步思考保持时间顺序,已完成工具在回合结束前显示结果,避免快照与增量交替引起滚动抖动。
26
+ - **重问时撤销任务(#799)**:编辑重问或重新发送时,撤销被丢弃历史中创建且尚未开始的定时任务;保留已开始、其他会话及缺少创建来源的历史任务。写入失败会停止重问并报告错误。
27
+
28
+ ### Changed
29
+
30
+ - 增加真实 SDK 请求、Durable 事件投影、浏览器滚动与工具状态,以及定时任务持久化和失败恢复回归验证。
31
+
15
32
  ## [0.114.1] — 2026-10-31
16
33
 
17
34
  ### Added
package/README.md CHANGED
@@ -1,187 +1,187 @@
1
- <div align="center">
2
-
3
- # pi-web-ui
4
-
5
- A browser and desktop workspace for AI coding agents.
6
-
7
- **English** · [简体中文](./README.zh-CN.md) · [繁體中文](./README.zh-TW.md)
8
-
9
- [Website](https://xing-shuyin.github.io/pi-web-ui-site/) · [Documentation](https://xing-shuyin.github.io/pi-web-ui-site/docs.html) · [Downloads](https://github.com/xing-shuyin/pi-web-ui/releases/latest)
10
-
11
- [![npm version](https://img.shields.io/npm/v/pi-web-ui)](https://www.npmjs.com/package/pi-web-ui)
12
- [![Node version](https://img.shields.io/node/v/pi-web-ui)](https://nodejs.org/)
13
- [![License: MIT](https://img.shields.io/badge/license-MIT-blue)](./LICENSE)
14
-
15
- </div>
16
-
17
- pi-web-ui brings chat, files, terminals, Git and agent workflows into one workspace. Run it locally in a browser, use the Electron desktop app, or connect to remote SSH projects. The pi SDK and DeepSeek Harness (DSH) have different capabilities; choose the engine and model that suit your task.
18
-
19
- ## Quick start
20
-
21
- For the command-line version, install **Node.js 22.19.0 or newer**. Desktop installers include their runtime. Git and shell availability affect terminal and repository features.
22
-
23
- ```bash
24
- npm install -g pi-web-ui@latest
25
- cd /path/to/your/project
26
- pi-web-ui
27
- ```
28
-
29
- Open `http://127.0.0.1:8787` if the browser does not open automatically. Configure a model provider and its credentials in workspace settings, select a model, and send your first task. Stop a foreground process with Ctrl+C.
30
-
31
- For a first try without a global installation:
32
-
33
- ```bash
34
- npx pi-web-ui@latest
35
- ```
36
-
37
- If npm blocks native dependency scripts, follow the installed npm version's script-approval instructions. See the [installation guide](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#installation) for platform dependencies and troubleshooting.
38
-
39
- ## Choose an installation
40
-
41
- | Method | When to use it | Instructions |
42
- | -------------------- | --------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
43
- | npm / npx | Local development or a server with Node.js | Commands above; [complete guide](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#npm-install) |
44
- | Desktop installers | A desktop app with an included runtime | Download the matching Windows, macOS or Linux asset from [Releases](https://github.com/xing-shuyin/pi-web-ui/releases/latest) |
45
- | Windows portable ZIP | Keep the app and portable data together | Extract `pi-web-ui-desktop-<version>-portable.zip`; follow its included launcher instructions. Bundled Git/Node depend on the build; see [portable details](./desktop/README.md) |
46
- | Docker Compose | Container deployment built from source | See the commands below |
47
- | Android / Termux | Browser access from an Android terminal environment | [Termux prerequisites and commands](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#termux-install) |
48
- | Source checkout | Contributing or testing local changes | [Development](#development) |
49
-
50
- On Linux, native dependency compilation may require Python, make and a C++ compiler. On Windows, install Git for Windows when Bash-based workflows are needed. Portable data placement does not guarantee that the operating system, browser or external tools leave no traces.
51
-
52
- ### Run as a background service
53
-
54
- After global npm installation, install **and start** the service with explicit project and data paths. Stop any foreground process already using the port first.
55
-
56
- ```bash
57
- pi-web-ui server install --cwd "/path/to/project" --data-dir "/path/to/pi-data" --port 8787
58
- pi-web-ui server status
59
- ```
60
-
61
- Windows PowerShell example:
62
-
63
- ```powershell
64
- pi-web-ui server install --cwd "D:\Projects\app" --data-dir "D:\pi-data" --port 8787
65
- pi-web-ui server status
66
- ```
67
-
68
- Visit `http://127.0.0.1:8787` and verify the project and a model response. macOS uses a user launchd agent, Linux systemd, and Windows the current user's login Run key. Linux installation may require elevated privileges; Windows login autostart is not a system-level Windows Service.
69
-
70
- ```bash
71
- pi-web-ui server stop
72
- pi-web-ui server start
73
- pi-web-ui server restart
74
- pi-web-ui server status
75
- pi-web-ui server shortcut
76
- # Remove the service only when it is no longer needed:
77
- pi-web-ui server uninstall
78
- ```
79
-
80
- Use `--name my-pi` consistently when installing and managing named services. Services may not inherit interactive-shell credentials or PATH. See [service configuration](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#daemon-service).
81
-
82
- ### Common startup options
83
-
84
- ```bash
85
- pi-web-ui --cwd "/path/to/project" --port 9000 --no-browser
86
- pi-web-ui --host 0.0.0.0 --port 9000 --cwd "/path/to/project"
87
- pi-web-ui --help
88
- ```
89
-
90
- | Flag | Environment | Purpose / default |
91
- | -------------------- | --------------------- | ---------------------------------------------------------------------------------- |
92
- | `--cwd <dir>` | `PI_WEB_CWD` | Workspace: current directory in foreground; `~/pi-web-ui` for service installation |
93
- | `--port <n>` | `PI_WEB_PORT` | HTTP and WebSocket port; 8787 |
94
- | `--host <addr>` | `PI_WEB_HOST` | Listen address; 127.0.0.1 is local-only |
95
- | `--data-dir <dir>` | `PI_WEB_DATA_DIR` | Service data; `~/.pi-web` under the running account |
96
- | `--agent-dir <dir>` | `PI_CODING_AGENT_DIR` | pi agent configuration; `~/.pi/agent` |
97
- | `--engine <pi\|dsh>` | `PI_WEB_ENGINE` | Execution engine; pi |
98
- | `--no-browser` | — | Do not automatically open a browser |
99
-
100
- Paths with spaces need quoting. `0.0.0.0` is a listen address; other devices connect using the server's actual IP or domain. Configure authentication and appropriate network protection before sharing access. [Full startup reference](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#cli-and-env).
101
-
102
- ### Local `/setup` page
103
-
104
- Open **`http://127.0.0.1:8787/setup` on the server's machine**, substituting the actual port. This page configures server access and networking; API keys and models belong in workspace settings.
105
-
106
- - Set or generate an access token, then **save**. Token changes apply immediately; an empty saved token disables token authentication.
107
- - Configure listen address, port, Host allowlist and extra Origins; these require a restart.
108
- - Check the displayed `<dataDir>/server-config.json` path. Startup flags and environment take precedence over saved settings on restart.
109
- - LAN and proxy access to `/setup` is restricted. A remote server can be reached through an SSH local port forward; see the [step-by-step setup guide](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#setup-page).
110
-
111
- ### Docker from source
112
-
113
- ```bash
114
- git clone https://github.com/xing-shuyin/pi-web-ui.git
115
- cd pi-web-ui
116
- # Review docker-compose.yml: authentication, ports, project and credential mounts.
117
- docker compose up -d --build
118
- docker compose logs -f
119
- ```
120
-
121
- The repository Compose configuration builds the image locally. Persist service data at **`/app/.pi-web`** in the container. Mount projects and credentials deliberately; container paths differ from host paths. Do not assume a published container port satisfies `/setup`'s loopback checks. See [container installation](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#docker-source-install) and [deployment](./docs/deployment.md).
122
-
123
- ### Update and remove
124
-
125
- ```bash
126
- npm install -g pi-web-ui@latest
127
- pi-web-ui server restart # For an installed service; restart foreground processes yourself.
128
- ```
129
-
130
- Desktop and portable users should follow the matching package's update instructions and retain their actual data directories. Before removal, back up needed conversations, settings and credentials. For npm users, uninstall the service first if installed, then run `npm uninstall -g pi-web-ui`. Removing the package does not remove separately stored user data.
131
-
132
- ## What you can do
133
-
134
- - **Chat and context:** streaming responses, tool outputs, attachments, file references, structured questions and multiple conversations.
135
- - **Work on projects:** file browsing and previews, uploads, integrated terminals, Git diffs, staging and commits. Remote SSH capabilities depend on the engine, host tools and connection configuration.
136
- - **Organize agent work:** planning, goal review/execution, delegated work and subagents. File claims coordinate parallel edits through advisory notices; they are not edit locks.
137
- - **Extend the workspace:** plugins, MCP tools, skills, configuration presets and customizable layouts and themes. Availability depends on installed components and permissions.
138
-
139
- Approval controls, task modes and isolated project directories have specific implementation boundaries; they are not universal operating-system security sandboxes. See [approval and security](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#approval-and-security).
140
-
141
- ## See the workspace
142
-
143
- | Chat | Terminal |
144
- | --------------------------------------------- | ---------------------------------------------- |
145
- | ![Chat workspace](./assets/chat-prompts.jpeg) | ![Integrated terminal](./assets/terminal.jpeg) |
146
-
147
- | Git | Settings |
148
- | --------------------------------- | ------------------------------------------------------- |
149
- | ![Git changes](./assets/git.jpeg) | ![Model and workspace settings](./assets/settings.jpeg) |
150
-
151
- ## Plugins and documentation
152
-
153
- Browse plugins in the workspace or install from a repository:
154
-
155
- ```bash
156
- pi-web-ui install owner/repo
157
- pi-web-ui plugins
158
- pi-web-ui plugin create my-plugin
159
- ```
160
-
161
- Plugin permissions and external-service requirements vary. For submissions, follow the [community registry](https://github.com/xing-shuyin/pi-web-ui-plugins); automation is governed by that repository's current checks and policies.
162
-
163
- - [Getting started and installation](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#installation)
164
- - [Remote SSH projects](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#remote-ssh-projects)
165
- - [Plan, goal and review workflows](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#modes-guide)
166
- - [MCP and browser tools](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#mcp-and-browser)
167
- - [Plugin SDK](./plugin-sdk/README.md) · [Desktop](./desktop/README.md) · [Windows portable launcher](./launcher/README.md)
168
- - [Environment variables](./docs/env-vars.md) · [Deployment](./docs/deployment.md) · [Architecture](./docs/architecture-core.md)
169
-
170
- ## Development
171
-
172
- ```bash
173
- git clone https://github.com/xing-shuyin/pi-web-ui.git
174
- cd pi-web-ui
175
- npm ci
176
- npm run dev
177
- ```
178
-
179
- Node.js 22.19.0+ and the platform's native build dependencies are required. The dev frontend is normally on port 5173 and the backend on 8788. For a production checkout, run `npm run build`, then `npm start`.
180
-
181
- Before submitting a change, follow [development guidelines](./docs/development.md) and run the applicable formatting, type, lint and test checks. Desktop build details live in [desktop/README.md](./desktop/README.md).
182
-
183
- ## Community and license
184
-
185
- [Issues](https://github.com/xing-shuyin/pi-web-ui/issues) · [Discussions](https://github.com/xing-shuyin/pi-web-ui/discussions) · QQ group: `1126050727` · [dsh-ui-tools](https://github.com/xing-shuyin/dsh-ui-tools)
186
-
187
- [MIT License](./LICENSE)
1
+ <div align="center">
2
+
3
+ # pi-web-ui
4
+
5
+ A browser and desktop workspace for AI coding agents.
6
+
7
+ **English** · [简体中文](./README.zh-CN.md) · [繁體中文](./README.zh-TW.md)
8
+
9
+ [Website](https://xing-shuyin.github.io/pi-web-ui-site/) · [Documentation](https://xing-shuyin.github.io/pi-web-ui-site/docs.html) · [Downloads](https://github.com/xing-shuyin/pi-web-ui/releases/latest)
10
+
11
+ [![npm version](https://img.shields.io/npm/v/pi-web-ui)](https://www.npmjs.com/package/pi-web-ui)
12
+ [![Node version](https://img.shields.io/node/v/pi-web-ui)](https://nodejs.org/)
13
+ [![License: MIT](https://img.shields.io/badge/license-MIT-blue)](./LICENSE)
14
+
15
+ </div>
16
+
17
+ pi-web-ui brings chat, files, terminals, Git and agent workflows into one workspace. Run it locally in a browser, use the Electron desktop app, or connect to remote SSH projects. The pi SDK and DeepSeek Harness (DSH) have different capabilities; choose the engine and model that suit your task.
18
+
19
+ ## Quick start
20
+
21
+ For the command-line version, install **Node.js 22.19.0 or newer**. Desktop installers include their runtime. Git and shell availability affect terminal and repository features.
22
+
23
+ ```bash
24
+ npm install -g pi-web-ui@latest
25
+ cd /path/to/your/project
26
+ pi-web-ui
27
+ ```
28
+
29
+ Open `http://127.0.0.1:8787` if the browser does not open automatically. Configure a model provider and its credentials in workspace settings, select a model, and send your first task. Stop a foreground process with Ctrl+C.
30
+
31
+ For a first try without a global installation:
32
+
33
+ ```bash
34
+ npx pi-web-ui@latest
35
+ ```
36
+
37
+ If npm blocks native dependency scripts, follow the installed npm version's script-approval instructions. See the [installation guide](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#installation) for platform dependencies and troubleshooting.
38
+
39
+ ## Choose an installation
40
+
41
+ | Method | When to use it | Instructions |
42
+ | -------------------- | --------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
43
+ | npm / npx | Local development or a server with Node.js | Commands above; [complete guide](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#npm-install) |
44
+ | Desktop installers | A desktop app with an included runtime | Download the matching Windows, macOS or Linux asset from [Releases](https://github.com/xing-shuyin/pi-web-ui/releases/latest) |
45
+ | Windows portable ZIP | Keep the app and portable data together | Extract `pi-web-ui-desktop-<version>-portable.zip`; follow its included launcher instructions. Bundled Git/Node depend on the build; see [portable details](./desktop/README.md) |
46
+ | Docker Compose | Container deployment built from source | See the commands below |
47
+ | Android / Termux | Browser access from an Android terminal environment | [Termux prerequisites and commands](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#termux-install) |
48
+ | Source checkout | Contributing or testing local changes | [Development](#development) |
49
+
50
+ On Linux, native dependency compilation may require Python, make and a C++ compiler. On Windows, install Git for Windows when Bash-based workflows are needed. Portable data placement does not guarantee that the operating system, browser or external tools leave no traces.
51
+
52
+ ### Run as a background service
53
+
54
+ After global npm installation, install **and start** the service with explicit project and data paths. Stop any foreground process already using the port first.
55
+
56
+ ```bash
57
+ pi-web-ui server install --cwd "/path/to/project" --data-dir "/path/to/pi-data" --port 8787
58
+ pi-web-ui server status
59
+ ```
60
+
61
+ Windows PowerShell example:
62
+
63
+ ```powershell
64
+ pi-web-ui server install --cwd "D:\Projects\app" --data-dir "D:\pi-data" --port 8787
65
+ pi-web-ui server status
66
+ ```
67
+
68
+ Visit `http://127.0.0.1:8787` and verify the project and a model response. macOS uses a user launchd agent, Linux systemd, and Windows the current user's login Run key. Linux installation may require elevated privileges; Windows login autostart is not a system-level Windows Service.
69
+
70
+ ```bash
71
+ pi-web-ui server stop
72
+ pi-web-ui server start
73
+ pi-web-ui server restart
74
+ pi-web-ui server status
75
+ pi-web-ui server shortcut
76
+ # Remove the service only when it is no longer needed:
77
+ pi-web-ui server uninstall
78
+ ```
79
+
80
+ Use `--name my-pi` consistently when installing and managing named services. Services may not inherit interactive-shell credentials or PATH. See [service configuration](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#daemon-service).
81
+
82
+ ### Common startup options
83
+
84
+ ```bash
85
+ pi-web-ui --cwd "/path/to/project" --port 9000 --no-browser
86
+ pi-web-ui --host 0.0.0.0 --port 9000 --cwd "/path/to/project"
87
+ pi-web-ui --help
88
+ ```
89
+
90
+ | Flag | Environment | Purpose / default |
91
+ | -------------------- | --------------------- | ---------------------------------------------------------------------------------- |
92
+ | `--cwd <dir>` | `PI_WEB_CWD` | Workspace: current directory in foreground; `~/pi-web-ui` for service installation |
93
+ | `--port <n>` | `PI_WEB_PORT` | HTTP and WebSocket port; 8787 |
94
+ | `--host <addr>` | `PI_WEB_HOST` | Listen address; 127.0.0.1 is local-only |
95
+ | `--data-dir <dir>` | `PI_WEB_DATA_DIR` | Service data; `~/.pi-web` under the running account |
96
+ | `--agent-dir <dir>` | `PI_CODING_AGENT_DIR` | pi agent configuration; `~/.pi/agent` |
97
+ | `--engine <pi\|dsh>` | `PI_WEB_ENGINE` | Execution engine; pi |
98
+ | `--no-browser` | — | Do not automatically open a browser |
99
+
100
+ Paths with spaces need quoting. `0.0.0.0` is a listen address; other devices connect using the server's actual IP or domain. Configure authentication and appropriate network protection before sharing access. [Full startup reference](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#cli-and-env).
101
+
102
+ ### Local `/setup` page
103
+
104
+ Open **`http://127.0.0.1:8787/setup` on the server's machine**, substituting the actual port. This page configures server access and networking; API keys and models belong in workspace settings.
105
+
106
+ - Set or generate an access token, then **save**. Token changes apply immediately; an empty saved token disables token authentication.
107
+ - Configure listen address, port, Host allowlist and extra Origins; these require a restart.
108
+ - Check the displayed `<dataDir>/server-config.json` path. Startup flags and environment take precedence over saved settings on restart.
109
+ - LAN and proxy access to `/setup` is restricted. A remote server can be reached through an SSH local port forward; see the [step-by-step setup guide](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#setup-page).
110
+
111
+ ### Docker from source
112
+
113
+ ```bash
114
+ git clone https://github.com/xing-shuyin/pi-web-ui.git
115
+ cd pi-web-ui
116
+ # Review docker-compose.yml: authentication, ports, project and credential mounts.
117
+ docker compose up -d --build
118
+ docker compose logs -f
119
+ ```
120
+
121
+ The repository Compose configuration builds the image locally. Persist service data at **`/app/.pi-web`** in the container. Mount projects and credentials deliberately; container paths differ from host paths. Do not assume a published container port satisfies `/setup`'s loopback checks. See [container installation](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#docker-source-install) and [deployment](./docs/deployment.md).
122
+
123
+ ### Update and remove
124
+
125
+ ```bash
126
+ npm install -g pi-web-ui@latest
127
+ pi-web-ui server restart # For an installed service; restart foreground processes yourself.
128
+ ```
129
+
130
+ Desktop and portable users should follow the matching package's update instructions and retain their actual data directories. Before removal, back up needed conversations, settings and credentials. For npm users, uninstall the service first if installed, then run `npm uninstall -g pi-web-ui`. Removing the package does not remove separately stored user data.
131
+
132
+ ## What you can do
133
+
134
+ - **Chat and context:** streaming responses, tool outputs, attachments, file references, structured questions and multiple conversations.
135
+ - **Work on projects:** file browsing and previews, uploads, integrated terminals, Git diffs, staging and commits. Remote SSH capabilities depend on the engine, host tools and connection configuration.
136
+ - **Organize agent work:** planning, goal review/execution, delegated work and subagents. File claims coordinate parallel edits through advisory notices; they are not edit locks.
137
+ - **Extend the workspace:** plugins, MCP tools, skills, configuration presets and customizable layouts and themes. Availability depends on installed components and permissions.
138
+
139
+ Approval controls, task modes and isolated project directories have specific implementation boundaries; they are not universal operating-system security sandboxes. See [approval and security](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#approval-and-security).
140
+
141
+ ## See the workspace
142
+
143
+ | Chat | Terminal |
144
+ | --------------------------------------------- | ---------------------------------------------- |
145
+ | ![Chat workspace](./assets/chat-prompts.jpeg) | ![Integrated terminal](./assets/terminal.jpeg) |
146
+
147
+ | Git | Settings |
148
+ | --------------------------------- | ------------------------------------------------------- |
149
+ | ![Git changes](./assets/git.jpeg) | ![Model and workspace settings](./assets/settings.jpeg) |
150
+
151
+ ## Plugins and documentation
152
+
153
+ Browse plugins in the workspace or install from a repository:
154
+
155
+ ```bash
156
+ pi-web-ui install owner/repo
157
+ pi-web-ui plugins
158
+ pi-web-ui plugin create my-plugin
159
+ ```
160
+
161
+ Plugin permissions and external-service requirements vary. For submissions, follow the [community registry](https://github.com/xing-shuyin/pi-web-ui-plugins); automation is governed by that repository's current checks and policies.
162
+
163
+ - [Getting started and installation](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#installation)
164
+ - [Remote SSH projects](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#remote-ssh-projects)
165
+ - [Plan, goal and review workflows](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#modes-guide)
166
+ - [MCP and browser tools](https://xing-shuyin.github.io/pi-web-ui-site/docs.html#mcp-and-browser)
167
+ - [Plugin SDK](./plugin-sdk/README.md) · [Desktop](./desktop/README.md) · [Windows portable launcher](./launcher/README.md)
168
+ - [Environment variables](./docs/env-vars.md) · [Deployment](./docs/deployment.md) · [Architecture](./docs/architecture-core.md)
169
+
170
+ ## Development
171
+
172
+ ```bash
173
+ git clone https://github.com/xing-shuyin/pi-web-ui.git
174
+ cd pi-web-ui
175
+ npm ci
176
+ npm run dev
177
+ ```
178
+
179
+ Node.js 22.19.0+ and the platform's native build dependencies are required. The dev frontend is normally on port 5173 and the backend on 8788. For a production checkout, run `npm run build`, then `npm start`.
180
+
181
+ Before submitting a change, follow [development guidelines](./docs/development.md) and run the applicable formatting, type, lint and test checks. Desktop build details live in [desktop/README.md](./desktop/README.md).
182
+
183
+ ## Community and license
184
+
185
+ [Issues](https://github.com/xing-shuyin/pi-web-ui/issues) · [Discussions](https://github.com/xing-shuyin/pi-web-ui/discussions) · QQ group: `1126050727` · [dsh-ui-tools](https://github.com/xing-shuyin/dsh-ui-tools)
186
+
187
+ [MIT License](./LICENSE)