pi-app 0.8.1 → 0.8.5
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.
- package/.next/BUILD_ID +1 -1
- package/.next/app-path-routes-manifest.json +3 -3
- package/.next/build-manifest.json +2 -2
- package/.next/prerender-manifest.json +3 -3
- package/.next/required-server-files.js +2 -2
- package/.next/required-server-files.json +2 -2
- package/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next/server/app/_global-error.html +1 -1
- package/.next/server/app/_global-error.rsc +1 -1
- package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/server/app/_not-found.html +1 -1
- package/.next/server/app/_not-found.rsc +2 -2
- package/.next/server/app/_not-found.segments/_full.segment.rsc +2 -2
- package/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_index.segment.rsc +2 -2
- package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next/server/app/api/agent/[id]/events/route.js.nft.json +1 -1
- package/.next/server/app/api/agent/[id]/export.html/route.js.nft.json +1 -1
- package/.next/server/app/api/agent/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/agent/new/route.js.nft.json +1 -1
- package/.next/server/app/api/auth/all-providers/route.js.nft.json +1 -1
- package/.next/server/app/api/auth/api-key/[provider]/route.js.nft.json +1 -1
- package/.next/server/app/api/auth/login/[provider]/route.js.nft.json +1 -1
- package/.next/server/app/api/auth/logout/[provider]/route.js.nft.json +1 -1
- package/.next/server/app/api/auth/providers/route.js.nft.json +1 -1
- package/.next/server/app/api/extensions/route.js.nft.json +1 -1
- package/.next/server/app/api/files/[...path]/route.js.nft.json +1 -1
- package/.next/server/app/api/health/route.js +1 -1
- package/.next/server/app/api/history/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/history/route.js.nft.json +1 -1
- package/.next/server/app/api/models/route.js.nft.json +1 -1
- package/.next/server/app/api/models-config/route.js.nft.json +1 -1
- package/.next/server/app/api/models-config/test/route.js.nft.json +1 -1
- package/.next/server/app/api/product-sessions/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/sessions/[id]/context/route.js.nft.json +1 -1
- package/.next/server/app/api/sessions/[id]/export/route.js.nft.json +1 -1
- package/.next/server/app/api/sessions/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/sessions/route.js.nft.json +1 -1
- package/.next/server/app/api/settings/default-model/route.js.nft.json +1 -1
- package/.next/server/app/api/share/[token]/route.js.nft.json +1 -1
- package/.next/server/app/api/skills/install/route.js +1 -1
- package/.next/server/app/api/skills/route.js.nft.json +1 -1
- package/.next/server/app/api/skills/search/route.js +1 -1
- package/.next/server/app/api/terminal/run/[...cwd]/route.js.nft.json +1 -1
- package/.next/server/app/api/terminal/state/[...cwd]/route.js.nft.json +1 -1
- package/.next/server/app/api/terminal/stop/[...cwd]/route.js.nft.json +1 -1
- package/.next/server/app/api/terminal/stream/[...cwd]/route.js.nft.json +1 -1
- package/.next/server/app/api/usage/route.js.nft.json +1 -1
- package/.next/server/app/index.html +1 -1
- package/.next/server/app/index.rsc +3 -3
- package/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/.next/server/app/index.segments/_full.segment.rsc +3 -3
- package/.next/server/app/index.segments/_head.segment.rsc +1 -1
- package/.next/server/app/index.segments/_index.segment.rsc +2 -2
- package/.next/server/app/index.segments/_tree.segment.rsc +2 -2
- package/.next/server/app/page.js +2 -2
- package/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/server/app/share/[token]/page_client-reference-manifest.js +1 -1
- package/.next/server/app-paths-manifest.json +3 -3
- package/.next/server/chunks/349.js +1 -1
- package/.next/server/middleware-build-manifest.js +1 -1
- package/.next/server/middleware-manifest.json +5 -5
- package/.next/server/pages/404.html +1 -1
- package/.next/server/pages/500.html +1 -1
- package/.next/server/server-reference-manifest.json +1 -1
- package/.next/static/chunks/{2261-1213d31c519af896.js → 2261-bdeacd38bbdf7a65.js} +1 -1
- package/.next/static/chunks/app/page-240da53b31249b0a.js +2 -0
- package/.next/static/css/bdd24a16bf93fd97.css +1 -0
- package/.next/trace +84 -84
- package/.next/trace-build +1 -1
- package/README.md +20 -3
- package/bin/pi-app.js +20 -6
- package/next.config.ts +4 -0
- package/package.json +10 -6
- package/public/Pi-LOGO.png +0 -0
- package/.next/static/chunks/app/page-84b8dd2798476830.js +0 -2
- package/.next/static/css/55427e8acf53e124.css +0 -1
- /package/.next/static/{jWlwtI3NyKCLPvodN51mW → TvNuzm5Eu3aGFWQZG7rO-}/_buildManifest.js +0 -0
- /package/.next/static/{jWlwtI3NyKCLPvodN51mW → TvNuzm5Eu3aGFWQZG7rO-}/_ssgManifest.js +0 -0
package/.next/trace-build
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"name":"run-webpack","duration":
|
|
1
|
+
[{"name":"run-webpack","duration":27347069,"timestamp":92973653,"id":14,"parentId":1,"tags":{},"startTime":1781346011556,"traceId":"349378cb380aff32"},{"name":"run-typescript","duration":8919432,"timestamp":120324887,"id":8606,"parentId":1,"tags":{},"startTime":1781346038907,"traceId":"349378cb380aff32"},{"name":"static-check","duration":1882855,"timestamp":129310228,"id":8609,"parentId":1,"tags":{},"startTime":1781346047892,"traceId":"349378cb380aff32"},{"name":"static-generation","duration":5170340,"timestamp":132034560,"id":8725,"parentId":1,"tags":{},"startTime":1781346050616,"traceId":"349378cb380aff32"},{"name":"collect-build-traces","duration":40893260,"timestamp":131196041,"id":8722,"parentId":1,"tags":{},"startTime":1781346049778,"traceId":"349378cb380aff32"},{"name":"telemetry-flush","duration":51,"timestamp":172092573,"id":8734,"parentId":1,"tags":{},"startTime":1781346090674,"traceId":"349378cb380aff32"},{"name":"next-build","duration":79258040,"timestamp":92834596,"id":1,"tags":{"buildMode":"default","version":"16.2.6","bundler":"webpack","has-custom-webpack-config":"true","use-build-worker":"false"},"startTime":1781346011416,"traceId":"349378cb380aff32"}]
|
package/README.md
CHANGED
|
@@ -2,6 +2,26 @@
|
|
|
2
2
|
|
|
3
3
|
[pi 编程智能体](https://github.com/badlogic/pi-mono) 的网页界面。在浏览器中浏览会话、与智能体对话、分叉对话、切换消息分支。
|
|
4
4
|
|
|
5
|
+
## 日常维护
|
|
6
|
+
|
|
7
|
+
```
|
|
8
|
+
cd ~/codespace/pi-app
|
|
9
|
+
|
|
10
|
+
# 拉社区更新
|
|
11
|
+
git fetch upstream
|
|
12
|
+
git log --oneline HEAD..upstream/main
|
|
13
|
+
git merge upstream/main
|
|
14
|
+
git push origin main
|
|
15
|
+
|
|
16
|
+
# 日常开发
|
|
17
|
+
git checkout -b feat/my-feature
|
|
18
|
+
# ... 改 ...
|
|
19
|
+
git commit -m "..."
|
|
20
|
+
git push origin feat/my-feature
|
|
21
|
+
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
|
|
5
25
|
## 快速开始
|
|
6
26
|
|
|
7
27
|
**无需安装,直接运行:**
|
|
@@ -68,9 +88,6 @@ PORT=8080 pi-app # 也支持环境变量
|
|
|
68
88
|
- **模型配置** — 从智能体数据目录下的 `models.json` 读取可用模型,可在侧边栏的「Models」面板中编辑。
|
|
69
89
|
- **文件浏览** — 侧边栏内置文件浏览器,可在标签页中查看当前工作目录下的文件。
|
|
70
90
|
|
|
71
|
-
## 规划
|
|
72
|
-
|
|
73
|
-
总计划:[docs/plan-pi-web-macos-workbench.md](docs/plan-pi-web-macos-workbench.md)
|
|
74
91
|
贯穿原则:[docs/product-principles.md](docs/product-principles.md)
|
|
75
92
|
|
|
76
93
|
## 开发
|
package/bin/pi-app.js
CHANGED
|
@@ -80,15 +80,29 @@ if (!fs.existsSync(nextDir)) {
|
|
|
80
80
|
process.exit(1);
|
|
81
81
|
}
|
|
82
82
|
|
|
83
|
-
const nextArgs = ["start", "-p", port];
|
|
84
|
-
if (hostname) nextArgs.push("-H", hostname);
|
|
85
|
-
|
|
86
83
|
const childEnv = { ...process.env };
|
|
87
84
|
if (remoteFlag && !childEnv.PI_WEB_REMOTE) childEnv.PI_WEB_REMOTE = "1";
|
|
88
85
|
|
|
89
|
-
//
|
|
90
|
-
//
|
|
91
|
-
|
|
86
|
+
// Prefer the standalone server bundled in the desktop app (a self-contained
|
|
87
|
+
// server.js with a pruned node_modules and no @next/swc). Fall back to
|
|
88
|
+
// `next start` for plain npm installs that ship the full .next + node_modules.
|
|
89
|
+
const standaloneServer = path.join(pkgDir, "server.js");
|
|
90
|
+
let spawnArgs;
|
|
91
|
+
if (fs.existsSync(standaloneServer)) {
|
|
92
|
+
// Next standalone server reads PORT/HOSTNAME from env. Default to 0.0.0.0 to
|
|
93
|
+
// match the previous `next start` behavior (LAN-reachable for share/pairing).
|
|
94
|
+
childEnv.PORT = String(port);
|
|
95
|
+
childEnv.HOSTNAME = hostname || "0.0.0.0";
|
|
96
|
+
spawnArgs = [standaloneServer];
|
|
97
|
+
} else {
|
|
98
|
+
const nextArgs = ["start", "-p", port];
|
|
99
|
+
if (hostname) nextArgs.push("-H", hostname);
|
|
100
|
+
spawnArgs = [nextBin, ...nextArgs];
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
// Always run the JS entry with node directly — avoids .bin symlink issues and
|
|
104
|
+
// path-with-spaces problems on Windows when shell: true is used.
|
|
105
|
+
const child = spawn(process.execPath, spawnArgs, {
|
|
92
106
|
cwd: pkgDir,
|
|
93
107
|
stdio: ["inherit", "pipe", "inherit"],
|
|
94
108
|
env: childEnv,
|
package/next.config.ts
CHANGED
|
@@ -25,6 +25,10 @@ const piServerExternalPackages = [
|
|
|
25
25
|
|
|
26
26
|
const nextConfig: NextConfig = {
|
|
27
27
|
distDir: process.env.NEXT_DIST_DIR ?? ".next",
|
|
28
|
+
// Standalone output (enabled only when packaging) traces the minimal set of
|
|
29
|
+
// server runtime files into .next/standalone, dramatically shrinking the
|
|
30
|
+
// bundled node_modules. Dev/normal builds are unaffected.
|
|
31
|
+
output: process.env.PI_STANDALONE === "1" ? "standalone" : undefined,
|
|
28
32
|
serverExternalPackages: piServerExternalPackages,
|
|
29
33
|
webpack: (config, { isServer }) => {
|
|
30
34
|
if (!isServer) return config;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-app",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.5",
|
|
4
4
|
"description": "Web UI for the pi coding agent",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://github.com/asiachrispy/pi-app",
|
|
@@ -42,6 +42,12 @@
|
|
|
42
42
|
"postinstall": "node scripts/install-cli.mjs",
|
|
43
43
|
"postuninstall": "node scripts/uninstall-cli.mjs",
|
|
44
44
|
"package:macos": "bash scripts/package-macos-app.sh",
|
|
45
|
+
"release:sync-pi": "bash scripts/sync-pi-upstream.sh",
|
|
46
|
+
"release:sync-pi-deps": "bash scripts/sync-pi-deps.sh",
|
|
47
|
+
"release:prepare": "bash scripts/release-pi-app.sh",
|
|
48
|
+
"release:github": "bash scripts/github-release.sh",
|
|
49
|
+
"release:version": "node scripts/release-version.mjs",
|
|
50
|
+
"release:check": "node scripts/release-version.mjs --check",
|
|
45
51
|
"tunnel:cloudflare": "bash scripts/tunnel-cloudflared.sh",
|
|
46
52
|
"relay:server": "node --experimental-strip-types scripts/pi-relay-server.ts",
|
|
47
53
|
"relay:host": "node --experimental-strip-types scripts/pi-relay-host.ts",
|
|
@@ -50,8 +56,8 @@
|
|
|
50
56
|
"prepublishOnly": "node_modules/.bin/tsc --noEmit && node_modules/.bin/vitest run"
|
|
51
57
|
},
|
|
52
58
|
"dependencies": {
|
|
53
|
-
"@earendil-works/pi-ai": "0.79.
|
|
54
|
-
"@earendil-works/pi-coding-agent": "0.79.
|
|
59
|
+
"@earendil-works/pi-ai": "0.79.3",
|
|
60
|
+
"@earendil-works/pi-coding-agent": "0.79.3",
|
|
55
61
|
"@lobehub/icons": "5.10.0",
|
|
56
62
|
"@types/react-syntax-highlighter": "15.5.13",
|
|
57
63
|
"katex": "0.17.0",
|
|
@@ -78,15 +84,13 @@
|
|
|
78
84
|
"@types/react-dom": "19.2.3",
|
|
79
85
|
"eslint": "9.39.4",
|
|
80
86
|
"eslint-config-next": "16.2.6",
|
|
87
|
+
"jsdom": "27.4.0",
|
|
81
88
|
"playwright": "1.60.0",
|
|
82
89
|
"postcss": "8.5.15",
|
|
83
90
|
"tailwindcss": "4.3.0",
|
|
84
91
|
"typescript": "5.9.3",
|
|
85
92
|
"vitest": "4.1.8"
|
|
86
93
|
},
|
|
87
|
-
"optionalDependencies": {
|
|
88
|
-
"pi-fetch-tool": "0.1.5"
|
|
89
|
-
},
|
|
90
94
|
"overrides": {
|
|
91
95
|
"js-cookie": "3.0.8",
|
|
92
96
|
"mermaid": "11.15.0"
|
|
Binary file
|