weflow-cli 1.16.0 → 1.17.0

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 (97) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/README.md +16 -4
  3. package/bin/weflow-cli.ts +348 -6
  4. package/dist/bin/weflow-cli.js +381 -8
  5. package/dist/bin/weflow-cli.js.map +1 -1
  6. package/dist/src/core/ntCore.d.ts +47 -0
  7. package/dist/src/core/ntCore.d.ts.map +1 -1
  8. package/dist/src/core/ntCore.js +24 -0
  9. package/dist/src/core/ntCore.js.map +1 -1
  10. package/dist/src/services/assistantService.d.ts +8 -1
  11. package/dist/src/services/assistantService.d.ts.map +1 -1
  12. package/dist/src/services/assistantService.js +47 -8
  13. package/dist/src/services/assistantService.js.map +1 -1
  14. package/dist/src/services/assistantTools.d.ts +8 -0
  15. package/dist/src/services/assistantTools.d.ts.map +1 -1
  16. package/dist/src/services/assistantTools.js +67 -11
  17. package/dist/src/services/assistantTools.js.map +1 -1
  18. package/dist/src/services/configService.d.ts.map +1 -1
  19. package/dist/src/services/configService.js +3 -2
  20. package/dist/src/services/configService.js.map +1 -1
  21. package/dist/src/services/cursorProbe.d.ts +44 -0
  22. package/dist/src/services/cursorProbe.d.ts.map +1 -0
  23. package/dist/src/services/cursorProbe.js +183 -0
  24. package/dist/src/services/cursorProbe.js.map +1 -0
  25. package/dist/src/services/qchatImport.d.ts +89 -0
  26. package/dist/src/services/qchatImport.d.ts.map +1 -0
  27. package/dist/src/services/qchatImport.js +273 -0
  28. package/dist/src/services/qchatImport.js.map +1 -0
  29. package/dist/src/services/setupVenv.d.ts +43 -0
  30. package/dist/src/services/setupVenv.d.ts.map +1 -0
  31. package/dist/src/services/setupVenv.js +198 -0
  32. package/dist/src/services/setupVenv.js.map +1 -0
  33. package/dist/src/utils/python.d.ts +10 -0
  34. package/dist/src/utils/python.d.ts.map +1 -1
  35. package/dist/src/utils/python.js +27 -4
  36. package/dist/src/utils/python.js.map +1 -1
  37. package/docs/DATA_CONTRACT.md +25 -0
  38. package/docs/DECISIONS.md +92 -30
  39. package/docs/FUNCTIONAL-IMPROVEMENT-SPEC.md +365 -365
  40. package/docs/HEALTH-CHECK.md +104 -104
  41. package/docs/JEV/345/272/224/347/224/250/346/226/275/345/267/245/346/226/207/346/241/243.md +310 -310
  42. package/docs/NEXT_ACTIONS.md +236 -236
  43. package/docs/NPM-PUBLISH.md +130 -130
  44. package/docs/POSITIONING.md +68 -68
  45. package/docs/PROJECT_STATE.md +6 -3
  46. package/docs/REPLAY.md +169 -0
  47. package/docs/SYNC_CONTRACT.md +197 -180
  48. package/package.json +89 -88
  49. package/requirements-3x.txt +4 -4
  50. package/requirements-voice.txt +15 -15
  51. package/resources/js/graph3d/NOTICE.txt +35 -35
  52. package/resources/js/graph3d/d3-binarytree.min.js +2 -2
  53. package/resources/js/graph3d/d3-dispatch.min.js +2 -2
  54. package/resources/js/graph3d/d3-force-3d.min.js +2 -2
  55. package/resources/js/graph3d/d3-octree.min.js +2 -2
  56. package/resources/js/graph3d/d3-quadtree.min.js +2 -2
  57. package/resources/js/graph3d/d3-timer.min.js +2 -2
  58. package/resources/js/graph3d/three.min.js +6 -6
  59. package/resources/js/graph3d/viewer2d.js +550 -448
  60. package/resources/panel/quick-menu.cjs +197 -197
  61. package/scripts/_utils.py +1338 -1338
  62. package/scripts/article_notes.py +423 -423
  63. package/scripts/chat_notes.py +86 -3
  64. package/scripts/check_readme_commands.py +427 -426
  65. package/scripts/contact_schema.py +339 -339
  66. package/scripts/create_reading_notes.py +11 -11
  67. package/scripts/daily_task.ps1 +213 -213
  68. package/scripts/fav_notes.py +321 -321
  69. package/scripts/graph_2d.py +156 -151
  70. package/scripts/graph_3d.py +672 -646
  71. package/scripts/health_check.py +473 -473
  72. package/scripts/imported_chats.py +68 -0
  73. package/scripts/install_tasks.ps1 +105 -105
  74. package/scripts/leads.py +179 -179
  75. package/scripts/network.py +206 -206
  76. package/scripts/nt_decrypt.py +135 -1
  77. package/scripts/on_this_day.py +178 -178
  78. package/scripts/opinion_timeline.py +138 -138
  79. package/scripts/promises.py +185 -185
  80. package/scripts/replay.py +803 -0
  81. package/scripts/run_hidden.vbs +25 -0
  82. package/scripts/semantic_search.py +73 -5
  83. package/scripts/user_notes.py +315 -315
  84. package/scripts/voice_transcribe.py +139 -139
  85. package/scripts/watch_issues.py +212 -212
  86. package/scripts/watch_mail.py +131 -131
  87. package/src/core/ntCore.ts +59 -0
  88. package/src/services/assistantService.ts +48 -8
  89. package/src/services/assistantTools.ts +73 -10
  90. package/src/services/configService.ts +3 -2
  91. package/src/services/cursorProbe.ts +222 -0
  92. package/src/services/qchatImport.ts +327 -0
  93. package/src/services/setupVenv.ts +238 -0
  94. package/src/services/syncService.ts +363 -363
  95. package/src/services/syncState.ts +275 -275
  96. package/src/services/wechatMedia.ts +166 -166
  97. package/src/utils/python.ts +33 -4
@@ -1,130 +1,130 @@
1
- # npm 发布 — 速查与故障对照
2
-
3
- 只讲 npm 这一侧。**流程清单**在 [RELEASING.md](RELEASING.md),这里只解决
4
- 「命令跑完了,现在到底算成功没有」。
5
-
6
- 单个环节按需查,不必通读。
7
-
8
- ## 0. 省上下文(先看这条)
9
-
10
- 发布命令会打印几百行 `Tarball Contents`。**永远加过滤**,否则整个文件清单
11
- 会灌进上下文,既没用又挤掉真正要看的信息:
12
-
13
- ```bash
14
- npm publish --registry=https://registry.npmjs.org 2>&1 \
15
- | grep -vE "^npm notice [0-9.]+[kMB]+ |^npm notice [0-9.]+B " | tail -25
16
- ```
17
-
18
- `npm pack --dry-run` 同理。要看文件清单时**输出到文件再 grep**,不要直接打印:
19
-
20
- ```bash
21
- npm pack --dry-run 2>&1 | grep "npm notice [0-9]" > /tmp/packlist.txt
22
- grep -c " dist/" /tmp/packlist.txt # 注意: 行首是体积, 不是路径
23
- ```
24
-
25
- ## 1. 唯一可靠的判据
26
-
27
- **别信命令的输出,信 registry 的 `versions` 表:**
28
-
29
- 下面用 `X.Y.Z` 代表这次要发的版本,**照抄时换成实际版本号**——写死在这里的版本
30
- 过几天就是错的。
31
-
32
- ```bash
33
- V=X.Y.Z
34
- curl -s "https://registry.npmjs.org/weflow-cli?nocache=$RANDOM" --max-time 30 \
35
- | python -c "
36
- import json,sys,os
37
- d=json.load(sys.stdin)
38
- print('latest:', d['dist-tags']['latest'])
39
- print('目标版本存在:', os.environ['V'] in d['versions'])" V="$V"
40
- ```
41
-
42
- - `目标版本存在: True` → **发布成功**,剩下只是传播
43
- - `False` → 没发出去,看第 2 节
44
-
45
- `npm view` 会读到客户端缓存,`--prefer-online` 或上面的 `nocache` 才准。
46
-
47
- ## 2. 症状 → 含义 → 动作
48
-
49
- | 现象 | 含义 | 动作 |
50
- | --- | --- | --- |
51
- | `+ weflow-cli@X.Y.Z` | 已被接受 | 继续,等传播 |
52
- | `being processed and may take a few minutes` | 正常提示 | 等,别重发 |
53
- | `npm view` 仍是旧版本 | CDN 传播中 | **不是失败**,等 2–5 分钟 |
54
- | 重发报 `409 Conflict - Cannot publish over previously staged version` | **已经发布成功了** | 别再发,去等传播 |
55
- | tarball `404`(`/-/weflow-cli-X.Y.Z.tgz`) | 元数据已发布,tarball 还在传播 | 等,不是失败 |
56
- | `install` 报 `ETARGET No matching version` | 客户端缓存了旧 packument | 加 `--prefer-online` 重试 |
57
- | `install` 报 `404` | 元数据在、tarball 未到 | 等传播 |
58
- | `403 ... bypass 2fa enabled is required` | token 没勾 Bypass 2FA | 重新生成 token(见第 3 节) |
59
- | `E404` 发布时 | 包名或权限问题 | 查 `npm whoami` |
60
-
61
- > **404 / 409 / ETARGET 在发布后的几分钟内都是传播现象,不是错误。**
62
- > 唯一例外:`403` 和发布时的 `E404`。
63
-
64
- ## 3. 凭据自检
65
-
66
- 不打印 token 本身:
67
-
68
- ```bash
69
- npm whoami --registry=https://registry.npmjs.org
70
-
71
- TOKEN=$(sed -n 's/.*_authToken=//p' ~/.npmrc | tr -d '\r\n')
72
- curl -s -H "Authorization: Bearer $TOKEN" \
73
- "https://registry.npmjs.org/-/npm/v1/tokens" --max-time 30 \
74
- | python -c "
75
- import json,sys
76
- for t in (json.load(sys.stdin).get('objects') or []):
77
- print(t.get('tokenId','')[:12], 'bypass_2fa=', t.get('bypass2fa'), 'created=', t.get('created'))"
78
- ```
79
-
80
- `bypass_2fa` 必须是 `True`,否则发布会要 OTP。
81
-
82
- ## 4. 触发国内镜像同步
83
-
84
- ```bash
85
- curl -s -X PUT "https://registry.npmmirror.com/-/package/weflow-cli/syncs" --max-time 40
86
- ```
87
-
88
- `{"ok":true,...,"state":"waiting"}` 即受理,**约 5 分钟**生效。
89
-
90
- 两个源不一致时,先怀疑镜像同步,不要怀疑包:
91
-
92
- ```bash
93
- npm view weflow-cli version --registry=https://registry.npmjs.org
94
- npm view weflow-cli version --registry=https://registry.npmmirror.com
95
- ```
96
-
97
- ## 5. 装一份下来验(最终确认)
98
-
99
- ```bash
100
- mkdir -p /tmp/verify && cd /tmp/verify && npm init -y >/dev/null
101
- npm install weflow-cli@X.Y.Z --registry=https://registry.npmjs.org --prefer-online --no-audit --no-fund
102
- node -e "console.log(require('./node_modules/weflow-cli/package.json').version)"
103
- ```
104
-
105
- 装不上但第 1 节显示版本存在 → 就是 tarball 传播中,等。
106
-
107
- ## 6. 打包安全检查(发布前,不能跳)
108
-
109
- ```bash
110
- npm pack --dry-run 2>&1 | grep "npm notice [0-9]" > /tmp/packlist.txt
111
- grep -E "output/|models/|node_modules|\.env|\.db$|\.dat$|_env\.json|secret|credential|\.key$|\.pem$" /tmp/packlist.txt
112
- ```
113
-
114
- **这条必须没有输出。** 有输出就停下查。
115
-
116
- 再确认新增文件确实**在**包里(`files` 白名单按目录配,容易漏):
117
-
118
- ```bash
119
- for f in scripts/health_check.py docs/HEALTH-CHECK.md cli.cjs; do
120
- grep -qF "$f" /tmp/packlist.txt && echo "✓ $f" || echo "✗ 缺失 $f"
121
- done
122
- ```
123
-
124
- ## 已知坑
125
-
126
- - **`bin` 会被 npm 改写**:`"bin": {"weflow-cli": "./cli.cjs"}` 发布时报
127
- `script name cli.cjs was invalid and removed`,同时 `repository.url` 被规范化。
128
- 是 warning,不影响发布结果,但要知道它每次都出现,不是本次引入的问题。
129
- - **`.gitignore` 里 `*.md` 默认忽略、逐个放行**:新增文档必须同时加
130
- `!docs/<名字>.md`,否则 `git add` 会被挡。
1
+ # npm 发布 — 速查与故障对照
2
+
3
+ 只讲 npm 这一侧。**流程清单**在 [RELEASING.md](RELEASING.md),这里只解决
4
+ 「命令跑完了,现在到底算成功没有」。
5
+
6
+ 单个环节按需查,不必通读。
7
+
8
+ ## 0. 省上下文(先看这条)
9
+
10
+ 发布命令会打印几百行 `Tarball Contents`。**永远加过滤**,否则整个文件清单
11
+ 会灌进上下文,既没用又挤掉真正要看的信息:
12
+
13
+ ```bash
14
+ npm publish --registry=https://registry.npmjs.org 2>&1 \
15
+ | grep -vE "^npm notice [0-9.]+[kMB]+ |^npm notice [0-9.]+B " | tail -25
16
+ ```
17
+
18
+ `npm pack --dry-run` 同理。要看文件清单时**输出到文件再 grep**,不要直接打印:
19
+
20
+ ```bash
21
+ npm pack --dry-run 2>&1 | grep "npm notice [0-9]" > /tmp/packlist.txt
22
+ grep -c " dist/" /tmp/packlist.txt # 注意: 行首是体积, 不是路径
23
+ ```
24
+
25
+ ## 1. 唯一可靠的判据
26
+
27
+ **别信命令的输出,信 registry 的 `versions` 表:**
28
+
29
+ 下面用 `X.Y.Z` 代表这次要发的版本,**照抄时换成实际版本号**——写死在这里的版本
30
+ 过几天就是错的。
31
+
32
+ ```bash
33
+ V=X.Y.Z
34
+ curl -s "https://registry.npmjs.org/weflow-cli?nocache=$RANDOM" --max-time 30 \
35
+ | python -c "
36
+ import json,sys,os
37
+ d=json.load(sys.stdin)
38
+ print('latest:', d['dist-tags']['latest'])
39
+ print('目标版本存在:', os.environ['V'] in d['versions'])" V="$V"
40
+ ```
41
+
42
+ - `目标版本存在: True` → **发布成功**,剩下只是传播
43
+ - `False` → 没发出去,看第 2 节
44
+
45
+ `npm view` 会读到客户端缓存,`--prefer-online` 或上面的 `nocache` 才准。
46
+
47
+ ## 2. 症状 → 含义 → 动作
48
+
49
+ | 现象 | 含义 | 动作 |
50
+ | --- | --- | --- |
51
+ | `+ weflow-cli@X.Y.Z` | 已被接受 | 继续,等传播 |
52
+ | `being processed and may take a few minutes` | 正常提示 | 等,别重发 |
53
+ | `npm view` 仍是旧版本 | CDN 传播中 | **不是失败**,等 2–5 分钟 |
54
+ | 重发报 `409 Conflict - Cannot publish over previously staged version` | **已经发布成功了** | 别再发,去等传播 |
55
+ | tarball `404`(`/-/weflow-cli-X.Y.Z.tgz`) | 元数据已发布,tarball 还在传播 | 等,不是失败 |
56
+ | `install` 报 `ETARGET No matching version` | 客户端缓存了旧 packument | 加 `--prefer-online` 重试 |
57
+ | `install` 报 `404` | 元数据在、tarball 未到 | 等传播 |
58
+ | `403 ... bypass 2fa enabled is required` | token 没勾 Bypass 2FA | 重新生成 token(见第 3 节) |
59
+ | `E404` 发布时 | 包名或权限问题 | 查 `npm whoami` |
60
+
61
+ > **404 / 409 / ETARGET 在发布后的几分钟内都是传播现象,不是错误。**
62
+ > 唯一例外:`403` 和发布时的 `E404`。
63
+
64
+ ## 3. 凭据自检
65
+
66
+ 不打印 token 本身:
67
+
68
+ ```bash
69
+ npm whoami --registry=https://registry.npmjs.org
70
+
71
+ TOKEN=$(sed -n 's/.*_authToken=//p' ~/.npmrc | tr -d '\r\n')
72
+ curl -s -H "Authorization: Bearer $TOKEN" \
73
+ "https://registry.npmjs.org/-/npm/v1/tokens" --max-time 30 \
74
+ | python -c "
75
+ import json,sys
76
+ for t in (json.load(sys.stdin).get('objects') or []):
77
+ print(t.get('tokenId','')[:12], 'bypass_2fa=', t.get('bypass2fa'), 'created=', t.get('created'))"
78
+ ```
79
+
80
+ `bypass_2fa` 必须是 `True`,否则发布会要 OTP。
81
+
82
+ ## 4. 触发国内镜像同步
83
+
84
+ ```bash
85
+ curl -s -X PUT "https://registry.npmmirror.com/-/package/weflow-cli/syncs" --max-time 40
86
+ ```
87
+
88
+ `{"ok":true,...,"state":"waiting"}` 即受理,**约 5 分钟**生效。
89
+
90
+ 两个源不一致时,先怀疑镜像同步,不要怀疑包:
91
+
92
+ ```bash
93
+ npm view weflow-cli version --registry=https://registry.npmjs.org
94
+ npm view weflow-cli version --registry=https://registry.npmmirror.com
95
+ ```
96
+
97
+ ## 5. 装一份下来验(最终确认)
98
+
99
+ ```bash
100
+ mkdir -p /tmp/verify && cd /tmp/verify && npm init -y >/dev/null
101
+ npm install weflow-cli@X.Y.Z --registry=https://registry.npmjs.org --prefer-online --no-audit --no-fund
102
+ node -e "console.log(require('./node_modules/weflow-cli/package.json').version)"
103
+ ```
104
+
105
+ 装不上但第 1 节显示版本存在 → 就是 tarball 传播中,等。
106
+
107
+ ## 6. 打包安全检查(发布前,不能跳)
108
+
109
+ ```bash
110
+ npm pack --dry-run 2>&1 | grep "npm notice [0-9]" > /tmp/packlist.txt
111
+ grep -E "output/|models/|node_modules|\.env|\.db$|\.dat$|_env\.json|secret|credential|\.key$|\.pem$" /tmp/packlist.txt
112
+ ```
113
+
114
+ **这条必须没有输出。** 有输出就停下查。
115
+
116
+ 再确认新增文件确实**在**包里(`files` 白名单按目录配,容易漏):
117
+
118
+ ```bash
119
+ for f in scripts/health_check.py docs/HEALTH-CHECK.md cli.cjs; do
120
+ grep -qF "$f" /tmp/packlist.txt && echo "✓ $f" || echo "✗ 缺失 $f"
121
+ done
122
+ ```
123
+
124
+ ## 已知坑
125
+
126
+ - **`bin` 会被 npm 改写**:`"bin": {"weflow-cli": "./cli.cjs"}` 发布时报
127
+ `script name cli.cjs was invalid and removed`,同时 `repository.url` 被规范化。
128
+ 是 warning,不影响发布结果,但要知道它每次都出现,不是本次引入的问题。
129
+ - **`.gitignore` 里 `*.md` 默认忽略、逐个放行**:新增文档必须同时加
130
+ `!docs/<名字>.md`,否则 `git add` 会被挡。
@@ -1,68 +1,68 @@
1
- # 这个项目靠什么活着(定位与护城河)
2
-
3
- > 写于 2026-10-19,起因是微信 4.1.15 把「问 AI 总结文件和公众号文章」做进了客户端。
4
- > 这个问题值得认真回答,因为答案决定了后面所有功能该不该做:**如果价值只是"用 AI 把微信里
5
- > 已有的内容处理一遍",那微信自己会做,而且做得更顺(右键就有)。**
6
-
7
- ## 一句话
8
-
9
- **不是"更好用的微信",是"能被带走、能被追问、能穿越时间的个人历史"。**
10
-
11
- 判据只有一个:**能不能回答微信回答不了的问题。** 答不了,就只是给微信套了一层 AI,别人没有理由换。
12
-
13
- ## 微信最近做了什么(2026-09-15,4.1.15 Win/Mac)
14
-
15
- 官方只承认两条,实测多出四条([IT之家](https://www.ithome.com/1/003/287.htm)):
16
-
17
- | 更新 | 影响 |
18
- | --- | --- |
19
- | **文件和公众号文章支持「问 AI」** | ⚠️ 直接撞在我们"AI 读内容"的一半上 |
20
- | 双人语音/视频通话可邀请他人加入 | 通话功能,与数据无关 |
21
- | 群通话可邀请不在群里的人 | 同上 |
22
- | 侧边栏新增「发现」 | UI 收敛 |
23
- | 群免打扰可设「仍通知」(@我/@所有人/群公告 + 4 个成员) | 消息管理 |
24
- | 聊天旁三栏浏览区,可独立窗口/吸附 | 阅读体验 |
25
-
26
- `.53` / `.56` 这类构建**没有公开更新日志**(官网日志仍停在 4.1.15 / 09-15,GitHub 归档只到 `.53`)。
27
- 从安装目录看,变动集中在 `RadiumWMPF.bin`(412 MB,小程序/浏览器内核)、`WeChatOcr.bin`、
28
- `XFilesOfficeReader`、`WePlayer` 这些组件——热修通常动内核,不动产品形态。
29
-
30
- **要盯的方向**:微信正在把 AI 往"单文件/单文章"上做。它越做,越说明"跨内容、跨时间"那层是空白。
31
-
32
- ## 五条护城河(按"腾讯为什么不会做"排序)
33
-
34
- | 护城河 | 微信不做/做不到的原因 | 我们的证据(可复验) |
35
- | --- | --- | --- |
36
- | **数据出口** | 微信从不提供导出聊天/朋友圈/收藏;"迁移"只到手机。4.1.15 六条更新里**没有一条**开放数据 | `export` 输出 HTML/md/json/xlsx + 图片与文件本体;issue #11 已修 |
37
- | **纵向时间** | 微信的搜索只服务"找那条消息",不做"这个人三个月的变化""这件事我答应过几次" | 欠话台账、关系温度(`bonds`)、承诺追踪(`todos`)、日报归档(372 天) |
38
- | **跨库联合** | 微信是产品不是平台:不会读你的 Obsidian、代码仓库、订阅源 | 语义索引 ~16k 条(聊天 5.2k + 文章 10.7k),实测 recall@10 **0.95**;原样定位(FTS5);Vault 概念页 |
39
- | **本地/隐私** | 微信的 AI 必走它自己的云;承诺"不出本机"等于砍掉它的商业模型 | 支持 Ollama/LM Studio;`judgeProvider=chat` 必须尊重 `aiEngine=local`(D-124) |
40
- | **可溯源** | 微信的「问 AI」给你一段总结,**点不回原句** | 每条命中带 `id`/`sourceFile`/原文链接,能回到那两个字节 |
41
-
42
- ## 会被立刻吃掉的功能(别把力气花在这里)
43
-
44
- - 单篇文章/单个文件摘要 —— 4.1.15 已做;
45
- - 会话内关键词搜索 —— 微信自带(虽然不全);
46
- - 通用"和 AI 聊微信记录" —— 门槛极低,人人能做;
47
- - 任何"把微信 UI 做得更顺手"的尝试。
48
-
49
- ## 四个能验的问题(产品自测题)
50
-
51
- 只要这四类问题答得比微信好,这个项目就成立:
52
-
53
- 1. **"我三个月前答应过谁什么,兑现了吗"** —— 跨时间 + 承诺追踪。
54
- 2. **"我和谁的关系在变淡,还救得回来吗"** —— 纵向聚合;微信只给当下。
55
- 3. **"这个号今年发了几篇,观点怎么变的"** —— 跨文章统计;微信只给单篇。
56
- 4. **"那句话他原样写过吗,哪天"** —— 原样定位;微信搜不到三个月前的群聊。
57
-
58
- ## 因此,产品的三个"不做"
59
-
60
- 1. **不追微信的新功能**(右键问 AI、发现页、三栏阅读)——那是它的产品节奏,追不上也没意义。
61
- 2. **不做纯 UI 替代品** —— 用户没有理由因为"更好看的聊天窗口"而迁移。
62
- 3. **不把 AI 摘要当成卖点** —— 摘要人人能做;**能溯源、能跨时间、能带走**才是。
63
-
64
- ## 这个判断会过期的情形
65
-
66
- 如果哪天微信真的开放了"导出全部聊天记录"或"本地数据 API",第一条护城河会塌一半——
67
- 到那时要立刻重估:**是不是该转向"分析层"(纵向/跨库/证据链),而不是"读取层"**。
68
- 这件事目前没有任何迹象,但要盯住更新日志里出现 `export` / `开放平台` / `本地数据库` 这类字眼。
1
+ # 这个项目靠什么活着(定位与护城河)
2
+
3
+ > 写于 2026-10-19,起因是微信 4.1.15 把「问 AI 总结文件和公众号文章」做进了客户端。
4
+ > 这个问题值得认真回答,因为答案决定了后面所有功能该不该做:**如果价值只是"用 AI 把微信里
5
+ > 已有的内容处理一遍",那微信自己会做,而且做得更顺(右键就有)。**
6
+
7
+ ## 一句话
8
+
9
+ **不是"更好用的微信",是"能被带走、能被追问、能穿越时间的个人历史"。**
10
+
11
+ 判据只有一个:**能不能回答微信回答不了的问题。** 答不了,就只是给微信套了一层 AI,别人没有理由换。
12
+
13
+ ## 微信最近做了什么(2026-09-15,4.1.15 Win/Mac)
14
+
15
+ 官方只承认两条,实测多出四条([IT之家](https://www.ithome.com/1/003/287.htm)):
16
+
17
+ | 更新 | 影响 |
18
+ | --- | --- |
19
+ | **文件和公众号文章支持「问 AI」** | ⚠️ 直接撞在我们"AI 读内容"的一半上 |
20
+ | 双人语音/视频通话可邀请他人加入 | 通话功能,与数据无关 |
21
+ | 群通话可邀请不在群里的人 | 同上 |
22
+ | 侧边栏新增「发现」 | UI 收敛 |
23
+ | 群免打扰可设「仍通知」(@我/@所有人/群公告 + 4 个成员) | 消息管理 |
24
+ | 聊天旁三栏浏览区,可独立窗口/吸附 | 阅读体验 |
25
+
26
+ `.53` / `.56` 这类构建**没有公开更新日志**(官网日志仍停在 4.1.15 / 09-15,GitHub 归档只到 `.53`)。
27
+ 从安装目录看,变动集中在 `RadiumWMPF.bin`(412 MB,小程序/浏览器内核)、`WeChatOcr.bin`、
28
+ `XFilesOfficeReader`、`WePlayer` 这些组件——热修通常动内核,不动产品形态。
29
+
30
+ **要盯的方向**:微信正在把 AI 往"单文件/单文章"上做。它越做,越说明"跨内容、跨时间"那层是空白。
31
+
32
+ ## 五条护城河(按"腾讯为什么不会做"排序)
33
+
34
+ | 护城河 | 微信不做/做不到的原因 | 我们的证据(可复验) |
35
+ | --- | --- | --- |
36
+ | **数据出口** | 微信从不提供导出聊天/朋友圈/收藏;"迁移"只到手机。4.1.15 六条更新里**没有一条**开放数据 | `export` 输出 HTML/md/json/xlsx + 图片与文件本体;issue #11 已修 |
37
+ | **纵向时间** | 微信的搜索只服务"找那条消息",不做"这个人三个月的变化""这件事我答应过几次" | 欠话台账、关系温度(`bonds`)、承诺追踪(`todos`)、日报归档(372 天) |
38
+ | **跨库联合** | 微信是产品不是平台:不会读你的 Obsidian、代码仓库、订阅源 | 语义索引 ~16k 条(聊天 5.2k + 文章 10.7k),实测 recall@10 **0.95**;原样定位(FTS5);Vault 概念页 |
39
+ | **本地/隐私** | 微信的 AI 必走它自己的云;承诺"不出本机"等于砍掉它的商业模型 | 支持 Ollama/LM Studio;`judgeProvider=chat` 必须尊重 `aiEngine=local`(D-124) |
40
+ | **可溯源** | 微信的「问 AI」给你一段总结,**点不回原句** | 每条命中带 `id`/`sourceFile`/原文链接,能回到那两个字节 |
41
+
42
+ ## 会被立刻吃掉的功能(别把力气花在这里)
43
+
44
+ - 单篇文章/单个文件摘要 —— 4.1.15 已做;
45
+ - 会话内关键词搜索 —— 微信自带(虽然不全);
46
+ - 通用"和 AI 聊微信记录" —— 门槛极低,人人能做;
47
+ - 任何"把微信 UI 做得更顺手"的尝试。
48
+
49
+ ## 四个能验的问题(产品自测题)
50
+
51
+ 只要这四类问题答得比微信好,这个项目就成立:
52
+
53
+ 1. **"我三个月前答应过谁什么,兑现了吗"** —— 跨时间 + 承诺追踪。
54
+ 2. **"我和谁的关系在变淡,还救得回来吗"** —— 纵向聚合;微信只给当下。
55
+ 3. **"这个号今年发了几篇,观点怎么变的"** —— 跨文章统计;微信只给单篇。
56
+ 4. **"那句话他原样写过吗,哪天"** —— 原样定位;微信搜不到三个月前的群聊。
57
+
58
+ ## 因此,产品的三个"不做"
59
+
60
+ 1. **不追微信的新功能**(右键问 AI、发现页、三栏阅读)——那是它的产品节奏,追不上也没意义。
61
+ 2. **不做纯 UI 替代品** —— 用户没有理由因为"更好看的聊天窗口"而迁移。
62
+ 3. **不把 AI 摘要当成卖点** —— 摘要人人能做;**能溯源、能跨时间、能带走**才是。
63
+
64
+ ## 这个判断会过期的情形
65
+
66
+ 如果哪天微信真的开放了"导出全部聊天记录"或"本地数据 API",第一条护城河会塌一半——
67
+ 到那时要立刻重估:**是不是该转向"分析层"(纵向/跨库/证据链),而不是"读取层"**。
68
+ 这件事目前没有任何迹象,但要盯住更新日志里出现 `export` / `开放平台` / `本地数据库` 这类字眼。
@@ -40,7 +40,7 @@ WeFlow CLI is a local-first command-line tool and MCP server for user-authorized
40
40
  | Area | Current state | Main entry points |
41
41
  | --- | --- | --- |
42
42
  | Local chat data | Query sessions, contacts, messages, favorites, Moments cache, and exports. HTML chat exports decode NT compressed media records, locally cached WeChat 4.x V2 image containers, entity-escaped emoji XML, and remote emoticons; app cards preserve links and embed available公众号/Bilibili covers. Media matching prefers server-message resources, exact local-message-ID plus timestamp pairs, and a unique local-ID fallback; high-bit encoded image rows are resolved through the same conversation cache. | `sessions`, `contacts`, `messages`, `export`, `fav`, `sns` |
43
- | Initialization | Verify and reuse existing local database access by default; refresh only when needed. Missing-key tests can run without changing saved configuration. Data-root discovery asks the **running client** first (its command line carries `--wechat-files-path`; the other two routes guess from the folder name) and reports which source won; a hint still has to pass the same structural check. | `init`, `init --refresh`, `init --test-missing-keys`, `config forget-keys`, `check` |
43
+ | Initialization | Verify and reuse existing local database access by default; refresh only when needed. Missing-key tests can run without changing saved configuration. Data-root discovery asks the **running client** first (its command line carries `--wechat-files-path`; the other two routes guess from the folder name) and reports which source won; a hint still has to pass the same structural check. **`weflow-cli setup` (2026-10-23)** builds a managed venv at `~/.weflow-cli/venv` and installs requirements into it; `getPythonCommand()` prefers that venv whenever it exists and passes the `import sqlcipher3` probe, falling back to the previous PATH order when it does not. On Windows the source package `sqlcipher3` is substituted with the prebuilt `sqlcipher3-wheels` (same import name; `sqlcipher3-binary` has **no Windows wheels at all** - measured 2026-10-23, pip reports `No matching distribution`). Two-phase like everything mutating (`--dry-run` plan, `--yes` to execute), pip retried once on transient network failure, and the run verifies `import sqlcipher3` plus that the runtime actually prefers the venv. End-to-end verified on this machine in a redirected HOME (2026-10-23): create venv → 8 packages → import OK → `getPythonCommand()` points at the venv. | `init`, `init --refresh`, `init --test-missing-keys`, `config forget-keys`, `check`, `setup` |
44
44
  | Environment / diagnosis | `check` (and the scheduled `health_check`) reports the **WeChat build actually loaded**, read from the live process's `--user-lib-dir` and - since 4.1.15.53 launches the main process with no switches (D-125) - falling back to the `Weixin.dll` that process actually has mapped, rather than to the version literal inside `Weixin.exe` (that one is only a fallback - D-107). It flags version directories that cannot work (no `Weixin.dll`). When the client is not running it says *unknown*, and a missing field counts as a failure so a stale build cannot pass. Verified on this machine: `4.1.15.53` loaded (2026-10-18, after updating from 4.1.15.13), `4.1.15.11\` (one file) flagged as a leftover. `--report` renders the same facts as a **paste-ready, redacted verdict** (environment, client, key presence, then "what is broken and the next command"), so a user can hand an AI or an issue something better than a description of the symptom (D-126). | `check`, `check --json`, `check --report`, `scripts/health_check.py` |
45
45
  | Relationship temperature | Who is going quiet, who is heating up, and who is reachable **only** here. Reads the local message database directly: read-only, no model, no network (D-062). Three groups - `cooling` (substantial history then silence, ranked by messages x silent days), `heating` (last 7 days at least twice the long-run daily rate), `only-wechat` (no phone/email/meeting-up ever appears in the history). Only 1:1 chats, only text messages, and only accounts whose **id shape** is a person: anything with `@` (`@chatroom`/`@openim`/`@weclaw`), `filehelper` or `gh_` is out - ranking by volume alone produced no information, and the first irreplaceability rule was inverted (it is trivially true of bots, so it put a coffee-shop bot first). Accounts that look like a person but whose name reads as a shop are **flagged, not dropped**, and every exclusion is printed with its reason. Deliberately **not** in the assistant or MCP tool tables: its output is an inference about third parties. | `bonds` |
46
46
  | Official-account daily | Filter configured sources, preserve source categories, backfill incomplete yesterday output before an unqualified today run, fetch articles, classify them, create summaries, generate a local HTML reader, and synchronize reader favorites into local files. Topic (6-way), relevance (3-level) and "does this belong in today's report" (yes/no) are decided by TypeSafe's Jev when `typesafeApiKey` is configured - concurrently, before the serial summary loop (12 articles in 3.3s at 6 workers against ~12s one at a time), and by the previous LLM-parse path otherwise; `--classifier llm` forces the latter. The report's admission rule is applied on both loader paths and can be bypassed with `--include-all`. Two flags exist for the unattended case: **`--yesterday`** (a scheduled run wants *the previous day*, since accounts publish until midnight, and "yesterday" is time-insensitive - the same data whenever the machine wakes up) and **`--prefetch-bodies [n]`** (default off; warms the body cache concurrently *before* the serial, deliberately throttled fetch phase, which then runs entirely from cache - the upstream request count is unchanged, only the window it is spread over). | `daily`, `daily favorites`, `daily-stats`, `daily-server` |
@@ -77,6 +77,7 @@ pair, so `AI 长出"手脚"` read back as `AI 长出"手脚`; `wiki_lint` then s
77
77
  parser had already unwrapped. One character, silently, for any frontmatter list or scalar whose value ends in a quote.
78
78
  Both now unwrap a matched pair only. Measured afterwards: **28 orphan pages → 1** (that one, `DESIGN`, is mentioned by
79
79
  no card at all) and still 0 broken links. | `wiki`, `vault`, `search`, `chat`, `weread`, `review` |
80
+ | QQ chat imports | `weflow-cli import qchat <path>` reads a qchat-cli JSON export (`qce export --format json`) and lands it in `output/imports/qq/sessions/` (`weflow-import/qq-v1`; field semantics aligned with `weflow-message/v1`, mapping table in `docs/DATA_CONTRACT.md`). Two-phase (`--dry-run` / `--yes`), merge-on-reimport keyed on the globally-unique QQ `messageId` (added/updated/unchanged counted separately), foreign JSON rejected with a reason. Downstream, both opt-in: `chat-notes --source qq\|all` emits QQ knowledge cards (`QQ-` name prefix, same card shape and same wiki consumer as WeChat; `all` degrades to QQ-only with a warning when the WeChat DB is unavailable) and `search-index --include-imports` adds QQ sessions to the semantic index (ids carry `chat:qq:`; build works on a machine with no WeChat config at all - end-to-end tested with stubbed embeddings, `test/qchat_import_test.py`). qchat-cli itself is not modified; the boundary is the file contract, not process coupling (D-129). **Validated on real data end-to-end (2026-10-25)**: NapCat.Shell v4.18.1 + QQ NT 9.9.33 (winget) on this machine, OneBot HTTP on 127.0.0.1:3000; two private chats exported via `qce export --format json` (12 messages) landed through `import qchat --own-id` (2 sessions, read-back via `import list/show` verified), `chat-notes --source qq --dry-run` saw both sessions (12 messages / 352 chars), and the index collector turned the 12 messages into 7 records (5 dropped by the same ≥10-char threshold the WeChat side applies). The real export shape matches the parser field-for-field; one observed detail: qchat's `session.type` is `friend` (not `private` as the synthetic fixtures assumed - the field passes through, so no code change). NapCat pitfall recorded for reproduction: on first login it creates an **account-specific** `onebot11_<qq>.json` with EMPTY `httpServers`, silently overriding any pre-seeded `onebot11_1.json` template - the 3000 server only starts after that file is fixed. Group export failed inside qchat-cli itself (`fetchMessages`) and was not exercised here. Querying QQ sessions through `sessions`/`messages` is deliberately not in this round. | `import qchat`, `import list`, `import show`, `chat-notes --source qq`, `search-index --include-imports` |
80
81
  | Incremental read | `sync run` reads a time window, deduplicates against the previous checkpoint and writes coverage state; `sync status` reports it without touching the database; `sync verify` re-reads the recorded window and compares bounds and counts. Every run reports `coverage` as `complete`, `unverified` or `partial`, and a partial run never advances `lastSuccessfulRun`. The window lower bound is offered to the NT backend as a pushdown hint (`messages --from`), but `syncService` still applies the window itself, so backends without range support stay correct - the pushdown is asymptotic, and it measured no faster on a 925-message conversation. It does **not** offer a stable cursor - see D-027. | `sync run`, `sync status`, `sync verify` |
81
82
  | Calibration | `scripts/quality_eval.py` samples real articles, scores each through the production path, and writes a three-field labelling file (`topic`/`relevance`/`include`); `score` reports topic agreement (Jev vs the stored labels), relevance agreement plus mean-level error, a calibration table by probability bucket, and **two** threshold sweeps (the inclusion cut and the relevance cuts - both were guessed, and both are now older than the first labelled set). The printed sheet is **blind**: it does not show Jev's answers, because seeing them first inflates agreement by an unmeasurable amount. `consistency` is the half that needs **no** labels: it reports how often the two questions answer the same thing two ways. Labels stay in `~/.weflow-cli/labels/`. A **dry-run** label file made by the assistant exists in that directory (`DRYRUN-by-claude-*.json`) so the scoring path could be exercised before any human label existed; its numbers are **not accuracy** - annotator and model are the same kind of model, and nothing in the data separates agreement-because-right from agreement-because-kin. Do not treat it as a baseline. | `python scripts/quality_eval.py sample`, `score <file>`, `consistency <file>` |
82
83
  | Criteria A/B | `python scripts/jev_probe.py --criteria-ab --limit 24 --yes` asks the same articles twice - current criteria (Chinese, abstract score bins) vs an English variant whose score bins are concrete scenes, following `jev-chat-jarvis`'s two stated rules. It measures **what a wording change would move**, not whether it improves anything. Measured locally (24 + 12 articles): topic agreement 79% / 67%, relevance raw-score mean absolute difference 0.17 / 0.24, and the disagreements concentrate on the **AI↔学术** and **文学↔新闻** boundaries. | `python scripts/jev_probe.py --criteria-ab` |
@@ -117,7 +118,7 @@ called `get_messages` and refused without ever reaching for `draft_reply`, so an
117
118
  ['draft_reply']` (the first version of that case) would have failed on the first run and sent someone chasing a
118
119
  defect that does not exist; asserting the **outcome** instead is what the memory cases already argued for
119
120
  (`memory-recall` judges "was it used", not "was `save_memory` called"). Two of the ten are **out of scope here by design**: `fetch_article` and `search_public` leave the machine, and the harness rejects any egress other than the model call ("a second exit means something leaked"). `get_concepts` and `get_review` were in that gap too and are now covered (see below), which required the harness to be able to lay down fixture files and set the environment variables that point the tools at them. The write cases also brought a new floor, `neverSucceeds`: if the named tool was called at all, that call must have produced nothing (read from the trace), so both "asked the user instead of writing" and "called the tool and was refused" pass while an actual write fails - the first live run of `todo-ambiguous-refused` failed because the expectation first written was too narrow (`mustCall: set_todo_status`), and the model had done the better thing (asked which of the two todos to mark). One case (`ambiguous-contact`) runs over its efficiency budget of 3 most times - measured over four runs on 2026-09-30 it used **6, 6, 2 and 4** tool calls, so it varies rather than having shifted once (the earlier note that "a single run cannot say" is now answered by those four runs). The floors pass every time and the traces show it **re-querying the same thing** (`list_sessions` two or three times) rather than failing, so this is a routing-efficiency question, not a broken promise. **A fixture gap found the same day did not explain it**: `listContacts` had never been stubbed, so `list_contacts` in the eval hit the real service against a temp home with no contacts and always came back empty - two cases were therefore running on "the real service happens to find nothing" while this entry claims synthetic data, and a change in that service would have moved the eval silently. The stub was added (contacts derive from the case's own sessions), and four more runs of the case gave **2, 6, 2 and 2** - the spread is unchanged, so the extra calls are the model exploring routes, not the fixture (the slow runs also reach for `search_chats`). Recorded as a negative result rather than a fix and asserts floor conditions: was the tool that could answer actually called, and were tools avoided when none was needed; did tool usage stay bounded; **is a failing tool reported as failing** (exit code 2 produces a reply quoting the error and offering an alternative, not "no one is waiting"); is an unknown contact ever given invented content; is memory judged by the fact landing in long-term memory rather than by whether `save_memory` was called; does an ambiguous contact name get a question back instead of a guess; are two asks in one message both served; and is a refused fetch (an internal address in favourites) reported as a refusal rather than summarised. Synthetic data, temporary home directory (the real audit and memory files stay untouched - a second writer would clobber the daemon's), and only the model call may leave the process. The expectations are the author's, **not human labels**, so this measures floors and not quality; a first green run proves little (cases and behaviour share an author) and the value is in re-running it after a change. Assertions must key off the tool's own diagnostics, never the model's wording - this suite's own first version asserted "查不到" and produced two false failures on "查不了". The criterion that follows from it, applied once more in `todos-never-extracted`: an expectation that moves with the model's phrasing is a budget, not a floor. That case first asserted "the reply mentions extraction" as a hard floor and passed three clean runs; putting the old tool behaviour back (mutation) still passed once before failing once - the model has its own ways of saying it - so the assertion now rides the soft channel, and the deterministic guard for the distinction lives in `test/assistant-tools-branches.test.ts`. Not in `npm test`: it needs network and money. | `npm run eval:assistant`, `--only=<case>`, `--json` |
120
- | Graph pages (3D / 2D) | `weflow-cli wiki graph` renders the concept graph as a **self-contained** HTML page - on this machine 49,956 concepts / 145,794 links / 9.05 MB (2026-10-02). The libraries, the data and the coordinates are all inlined, so it opens by double-click with **no server and no network**: a `file://` page cannot `fetch` its data (CORS), and a CDN reference would make a local-first feature depend on the network. The layout (250 ticks - the slow part, measured at ~55 s for half this size) is computed at build time by Node and cached under `output/.graph3d-cache/`, so changing only the rendering does not recompute it. The vendored three.js r147 and six d3 modules live in `resources/js/graph3d/` with versions and licences in `NOTICE.txt` beside them. It can be filtered to the structure that matters: `--min-degree N` keeps only concepts whose **whole-graph** degree is at least N (measured: 3,825 of the 49,956 have 10 or more links, and the filtered page is 1.09 MB against the full page's 9.05 MB), and `--line wiki|chat` draws one corpus at a time (48k article concepts vs 1,527 chat ones - different vocabularies that hide each other's structure when merged). Links pointing at removed nodes are dropped with them, because a dangling link makes the force layout fail with "node not found"; the layout cache is keyed by a hash of the data so building the small page no longer evicts the 50k-node coordinates. `test/graph-3d-cli.test.ts` pins that the emitted page carries **no** external reference, that the two library lists (`graph_3d.py` / `layout.mjs`) agree, that `--dry-run` writes nothing, that the filters change the counts and drop dangling links, that the CLI declares **and** forwards both flags, and that a hand-run without the CLI's `PYTHONIOENCODING` still prints readable UTF-8 (this machine's console is GBK). **`--flat` adds a 2D canvas page** (`output/knowledge-graph-2d.html`): the layout is a *separate* build-time solve rather than a flattening of the 3D coordinates - the z axis carries structure, so dropping it stacks unrelated clusters on top of each other - and it is much cheaper (3,825 nodes / 250 ticks in **2.4 s**, against ~55 s for the 3D solve at 25k), so the page is 0.71 MB and needs **no libraries at all** (the layout is precomputed; the renderer is plain canvas, so not even three.js is inlined). Interaction is drag-to-pan, wheel-to-zoom, hover for a name, click to dim everything but a concept and its neighbours, and a search box; `--min-degree` / `--line` apply unchanged, and the 2D and 3D coordinates cache separately (the digest includes the dimension). `test/graph-2d-cli.test.ts` carries a **render smoke test**: it runs the viewer over a fake canvas context and counts the `arc` / `lineTo` / `fillText` calls, because a JS error in a viewer yields a blank page with no failing assertion anywhere. **Performance was then measured in a real headless Edge over CDP** (Node built-in WebSocket, no puppeteer): one `draw()` at 49,956 nodes cost 12.78 ms, of which 50,000 `arc` calls were 9.0 ms against 3.4 ms for the same number of `rect` calls - so sub-2px dots are now squares and interaction redraws are coalesced to one per frame (the handlers used to redraw on every `pointermove`, which is what actually felt laggy). After: 7.6 ms per frame and a 200-event drag storm in 6.9 ms instead of ~2.6 s. Labels are capped and de-overlapped, because at 50k the top-degree concepts are all hubs in the middle and eighty names landed on top of each other. **The 2D solve uses its own force parameters** (stronger repulsion, longer links): the 3D numbers in one dimension fewer pack everything into a featureless disc. The layout cache key covers the data, the dimensions, the tick count **and** those parameters - it used to cover the data only, which silently served stale coordinates after a parameter change (`test/graph_layout_key_test.py`). At 50k a 2D force layout is still a texture rather than a map; the `--min-degree 10` page (3,825 nodes) is the one that reads as structure. |
121
+ | Graph pages (3D / 2D) | `weflow-cli wiki graph` renders the concept graph as a **self-contained** HTML page - on this machine 49,956 concepts / 145,794 links / 9.05 MB (2026-10-02). The libraries, the data and the coordinates are all inlined, so it opens by double-click with **no server and no network**: a `file://` page cannot `fetch` its data (CORS), and a CDN reference would make a local-first feature depend on the network. The layout (250 ticks - the slow part, measured at ~55 s for half this size) is computed at build time by Node and cached under `output/.graph3d-cache/`, so changing only the rendering does not recompute it. The vendored three.js r147 and six d3 modules live in `resources/js/graph3d/` with versions and licences in `NOTICE.txt` beside them. It can be filtered to the structure that matters: `--min-degree N` keeps only concepts whose **whole-graph** degree is at least N (measured: 3,825 of the 49,956 have 10 or more links, and the filtered page is 1.09 MB against the full page's 9.05 MB), and `--line wiki|chat` draws one corpus at a time (48k article concepts vs 1,527 chat ones - different vocabularies that hide each other's structure when merged). Links pointing at removed nodes are dropped with them, because a dangling link makes the force layout fail with "node not found"; the layout cache is keyed by a hash of the data so building the small page no longer evicts the 50k-node coordinates. `test/graph-3d-cli.test.ts` pins that the emitted page carries **no** external reference, that the two library lists (`graph_3d.py` / `layout.mjs`) agree, that `--dry-run` writes nothing, that the filters change the counts and drop dangling links, that the CLI declares **and** forwards both flags, and that a hand-run without the CLI's `PYTHONIOENCODING` still prints readable UTF-8 (this machine's console is GBK). **`--flat` adds a 2D canvas page** (`output/knowledge-graph-2d.html`): the layout is a *separate* build-time solve rather than a flattening of the 3D coordinates - the z axis carries structure, so dropping it stacks unrelated clusters on top of each other - and it is much cheaper (3,825 nodes / 250 ticks in **2.4 s**, against ~55 s for the 3D solve at 25k), so the page is 0.71 MB and needs **no libraries at all** (the layout is precomputed; the renderer is plain canvas, so not even three.js is inlined). Interaction is drag-to-pan, wheel-to-zoom, hover for a name, click to dim everything but a concept and its neighbours, and a search box; `--min-degree` / `--line` apply unchanged, and the 2D and 3D coordinates cache separately (the digest includes the dimension). `test/graph-2d-cli.test.ts` carries a **render smoke test**: it runs the viewer over a fake canvas context and counts the `arc` / `lineTo` / `fillText` calls, because a JS error in a viewer yields a blank page with no failing assertion anywhere. **Performance was then measured in a real headless Edge over CDP** (Node built-in WebSocket, no puppeteer): one `draw()` at 49,956 nodes cost 12.78 ms, of which 50,000 `arc` calls were 9.0 ms against 3.4 ms for the same number of `rect` calls - so sub-2px dots are now squares and interaction redraws are coalesced to one per frame (the handlers used to redraw on every `pointermove`, which is what actually felt laggy). After: 7.6 ms per frame and a 200-event drag storm in 6.9 ms instead of ~2.6 s. Labels are capped and de-overlapped, because at 50k the top-degree concepts are all hubs in the middle and eighty names landed on top of each other. **The 2D solve uses its own force parameters** (stronger repulsion, longer links): the 3D numbers in one dimension fewer pack everything into a featureless disc. The layout cache key covers the data, the dimensions, the tick count **and** those parameters - it used to cover the data only, which silently served stale coordinates after a parameter change (`test/graph_layout_key_test.py`). At 50k a 2D force layout is still a texture rather than a map; the `--min-degree 10` page (3,825 nodes) is the one that reads as structure. **The 2D page answers "why are these two connected" (2026-10-23)**: `build_graph(with_evidence=True)` computes, per edge, the intersection of the two pages' `## 来源` card lists - the shared sources that made the link - and the page carries it as `edgeEvidence` (`键 = 排序后的 id|id;值 = [共同来源数, 最多 2 个名字]`); edges with no shared source are deliberately absent from the map and the viewer says so honestly ("来自页面正文里的 [[链接]]"), rather than implying an empty check. Clicking near an edge (when no node is hit, edges only, tolerance 5px, same visibility gate as drawing) dims the rest, highlights it, and lists the evidence - D-033's "every judgement shown to a person carries its evidence" applied to the graph's edges. Bounded by design: at most 2 names per edge, and the evidence rides only the page payload - the layout cache key is unchanged (`data` stays nodes+links), so existing cached coordinates are NOT invalidated. 3D does not carry evidence (raycast-picking lines is a bigger lift and was not promised). Tests: the build side (shared source present / absent, key shape, `evidenceEdges` count), the viewer side (midpoint hit, empty-space miss, both evidence wordings, focused-edge redraw) in `test/graph-2d-cli.test.ts`. |
121
122
  | Assistant | Optional WeChat Bot-channel assistant: 31 local tools (12 originally; plus chat search, reply debt, semantic search and chat export, with export in html/txt/json/excel, Moments "who posts most", favourites without a keyword, and drafted replies). The single write tool (`export_chat`) can only create a new directory under `output/exports/` - the model supplies no path and an existing name gets a numeric suffix, so "never overwrite" is enforced in code. `draft_reply` writes nothing and **sends nothing** (D-047). `evidence-review`, `vault promote`, sending messages and every configuration change are deliberately **not** reachable from a chat message: the first two have their own human-facing confirm gates, sending is irreversible, and configuration is meant to be changed on the machine. 31 local tools, three-layer memory (working window / rolling summary / long-term facts), PII redaction before any cloud call, and a 100-message/day quota. It denies **every** sender until an allowlist is configured. The **single-round fast path** (D-035) is shipped but **off by default** (`assistantFastRoute` = `off` | `log` | `on`): it resolves "needs local data? which capability?" in one decision call and pre-dispatches that tool, so the loop's first request already sees the result (two round trips become one). Only the six tools with closed or empty arguments are routable; everything else falls back, and falling back is byte-identical to the previous behaviour. Measured on 17 questions against the real decision layer: 0 wrong routes, 10 routed concretely, ~1.33 s per decision, 2 fell back (`scripts/assistant_route_probe.ts`; those expectations are the author's, not human labels). Covered by synthetic harnesses (stubbed `callLLM`, stubbed `chatService`/`wereadService` singletons, a replaced `fetch`, a stubbed message channel, an injected route decider, temp `HOME`): per-message logic, **all 31 tool branches** (2026-09-29: the last uncovered one, `get_daily_report`, got the `WEFLOW_ASSISTANT_BIZ_DAILY_DIR` injection point its own coverage note had been asking for - read per call, so a test can swap fixtures; it is now asserted against a fixture instead of a "there may or may not be data" shape check), the resident loop itself - who is denied, the three group controls, the serial queue, the 100/day quota with its date rollover - the **privacy wiring** (which `aiEngine` values count as local inference, where `engineConfig` sends the request, and `reviewEvidence` refusing to send chat text to the cloud without `--allow-cloud`), and the fast path (correct / wrong / uncertain / log-only / no dispatch without the audit line). `get_todos` is executed through `pythonBridge`'s injectable runner (empty list, urgency and deadline rendering, the 15-row cap, a classified failure whose `stderr` is redacted, and "no JSON" not being read as "no todos"). It also keeps "no pending todos" apart from "extraction has never been run" (D-044): the emptiness has a cause of its own on a machine where `todos extract` was never invoked, so the tool names that cause and the command that would fill the list instead of reporting "nothing to do". The list is extracted from chat logs only by an explicit, confirmed command; nothing schedules it. Note on that claim's history: an earlier revision of this line - and the commit message for the `pythonBridge` refactor - asserted this coverage before any such test existed; it was written in prose only, and the file's own header comment said the opposite. The tests are real as of this revision. The assistant is time-aware: the system prompt opens with the current local date and weekday, and `get_messages` takes `since`/`until` (a date or `3d`/`2w`/`12h`) so a specific past day is reachable - before this, a day far enough back could not be fetched at all. An identical tool call repeated within one turn is answered with a note instead of being re-executed. The tool list is built per machine: a tool whose prerequisite is missing (semantic search without `dashscopeApiKey`, WeRead without `wereadApiKey`) is not offered at all, and the fast path - which dispatches directly - checks the same predicate; the filter only drops tools that *cannot* run, never ones that merely have no data yet. Name resolution searches the recent sessions first and then falls back to the contact book (remark / display name / nickname / alias), refusing anything that is not unique - measured on 378 real contacts outside the recent sessions: 362 resolved, 0 resolved to the wrong person. | `login-wechat`, `assistant` |
122
123
  | 本机面板 (local panel) | A second entrance to the same assistant, for when logging into the Bot channel is not worth it: `weflow-cli panel` opens an always-on-top window (Electron) or a chromeless Edge/Chrome `--app` window when Electron is absent. **The window is only a client** - every turn goes through the daemon's own `runTurn`, so the allowlist path, the 100/day quota counter, the serial queue and the memory file all stay single-writer (D-045). The daemon exposes a **loopback-only** HTTP endpoint (`127.0.0.1:8766`, not configurable) that is deliberately stricter than the daily reader: **every** request needs a per-run token (including `/api/status`), Origin is a second gate, POSTs must be JSON, and only one turn may be in flight (a second one gets 429 rather than being queued, because queueing means it will run and spend quota). The token lives in `~/.weflow-cli/assistant_endpoint.json` (atomic write; readers probe `kill(pid,0)` and verify `service` + `startedAt`, because SIGTERM leaves the file behind) and never reaches a command line: the Electron shell reads it itself and installs it as an `HttpOnly` cookie, while the browser fallback uses a one-time 60-second code from `/api/pair`. The memory bucket decides whether the panel is the same brain as WeChat - it resolves to the single allowlisted id, else it says on screen that it uses a separate bucket (`assistantPanelUser` pins it). **The panel can show what the assistant remembers** (2026-10-03): a `记忆` button in the bubble header fetches `GET /api/memory` and renders a **read-only** list of the long-term facts, each with the time it was recorded and the quote it came from, so a wrong memory can be traced back to the sentence that produced it. The bucket is decided **server-side** (the same `memoryBucket` the panel already reports) and a query parameter cannot steer it - otherwise the route would be a way to read another memory bucket. **That payload never goes to a model**: it exists for the user to audit what the assistant believes about them, and it is deliberately separate from the fact injection in `buildSystemPrompt`, which has its own budget and redaction. Facts are capped at 30 (`FACTS_MAX`), so the view is bounded by construction; the page renders with `textContent` only, and a test feeds in a memory shaped like an `<img onerror=…>` tag to prove it shows up as text. Verified live: the browser fallback opened, the pair-code flow returned the page with an `HttpOnly` cookie, a replayed code 401s, and a real question through the endpoint answered from local data while the shared quota counter went 0 -> 3. The floating ball was verified on Windows 11 with Electron 42 (76x76, no caption, always-on-top, renderer authenticated via the cookie, ball visible on screen); with Electron absent the same command falls back to a chromeless Edge/Chrome window and says it cannot give the ball. Ball-to-chat resize and the global hotkey were then exercised **without a click** (DevTools protocol; a differential registration test), which is how two bugs surfaced that a screenshot could not have shown - a non-resizable window ignoring `setSize` on Windows (collapse left it at the expanded size) and a `ready-to-show` listener attached too late (the window sometimes stayed hidden). **Right-clicking in the panel opens a quick-reply menu listing the contacts in `quickReplyContacts` (a config key added for it; the list rides on `/api/status`, which the page already polls every 30 seconds, so no new endpoint and no new IPC). Picking a name asks the assistant to draft for that person through the existing `/api/ask`, so quota, the serial queue, memory and the copy button all come along unchanged. The menu states its own cost (drafting sends that conversation to two cloud models), an empty list shows the command to run instead of an empty box, and the menu is a **native** one (built in the main process from `quick-menu.cjs`) so it draws outside the window - the ball is 96x96 and never has to expand, which is what the first attempt got wrong; the browser fallback does not take over right-click at all, because the native menu's Copy belongs to the user there. That menu's **last item hides the ball** (the only item in it that reaches no model), and it is the one item still present when the list is empty - otherwise a user who never configured the key would get a menu of two grey lines with nothing clickable, including no way to dismiss the ball. It hides rather than quits, so it is deliberately reversible, and the label names the way back (`关闭悬浮球(托盘图标能再打开)`) because the ball runs with `setSkipTaskbar(true)` and would leave nothing on the taskbar to click; the exit actions stay in the tray menu, which already separates them from show/expand (no test ever drives a real right-click, so the menu's *contents* are covered by executing every item's callback in `test/panel-quick-menu.test.ts`). Dragging the ball used to **grow the window by the drag distance** whenever it happened in the chat window: `dragMove` re-read the current size and wrote it back, and that read lags (measured with a probe driving the same IPC sequence: 0 drift with `resizable: false`, exactly the drag delta with `resizable: true`). The extra width showed up as a gap between the ball and the bubble, and expanding re-asserted the exact size - which is why clicking the ball appeared to reset it. The size is now captured once at `dragStart`. **Pressing the ball switches it to a second, closed-eyes face, and releasing reverts it immediately** (a 900ms hold after release was tried first and the user called it stuck; the generated face is composited in only inside an eye-shaped mask, because the endpoint repainted the whole canvas and returned no alpha). The ball stays put and the conversation unfolds beside it** - clicking it opens a bubble to its left (flipping to the right when there is no room, top-aligning when the bubble would run off the top of the work area) and clicking it again closes it; the ball is a toggle and never fades out. The window is "ball + gap + bubble" as one piece (508x560), with the ball pinned to its own corner so it does not move at all; `bubbleLayout` and `ballRectInWindow` in `ball-position.cjs` compute that geometry (pure, tested with synthetic displays, including a round-trip that expand-then-collapse returns the ball to where it started). The mode has one source of truth (the main process announces `{mode, side, anchorY}`; the page only requests), so the ball, the collapse button, the tray and the hotkey take the same path, and `prefers-reduced-motion` stops both halves. Measured on a real window with the real page at 150% scaling: the ball's offset inside the window is exactly 0 at every sample and its screen position varies by at most 1px across a whole expand and collapse (23 and 30 samples), with identical resting positions before and after. Two bugs came out of that measurement rather than out of reading the code: the tween rounded each edge independently so the edge the ball hangs on wobbled 1-2px (since fixed by pinning the corner), and collapsing placed the ball at the window's top-left instead of the corner it sits on, which would have made it jump to the bubble's opposite corner. The platform wrinkle behind some of this: at 150% scaling a request for a 76x76 window yields a ~79px client width (Windows enforces a minimum), which is why the remembered position is the window's, not the ball's visual edge. That arithmetic is a pure module tested against **synthetic** monitor layouts (negative-x second displays, a removed display, a rect larger than the work area) - this machine has one display, so a real second monitor remains unperformed. **The ball's coloured halo is gone entirely** (2026-09-29): the element, the three state rules and the `--hue` / `drift` / `breathe` drivers were all deleted, and `test/panel-packaging.test.ts` forbids reintroducing any of them (the user raised the same complaint twice, so the answer was removal rather than "draw less"). **Pressing the ball plays a twelve-frame "picked up by the scruff" animation**: six frames up while it is held (`mascot-lift-up-1..6.png`) and six back down on release (`mascot-lift-down-1..6.png`, then the resting frame `mascot-base.png`), hard cuts about 60 ms apart, the first frame synchronous so a press never shows an empty ball, and no tail after release. The twelve frames are **generated art** (`gpt-image-2-ca` via `/images/edits`; pipeline and contract in `scripts/panel_frames.py`) normalized to: 256x256 RGBA, 0 solid pixels past r=128, farthest solid distance under 0.98 x 128 **measured from the canvas centre with solid = alpha >= 128**, the apex anchored to the resting frame, and the scale taken from **the cat's own bounding box** (`170 x s`) rather than the canvas - the canvas also carries the speech bubble and the shock marks, and letting those set the scale would make a decoration decide the character's size. The silhouette is asserted rather than assumed: the first generation drew the hood as a pointed cone with no ears, moved the cat's aspect ratio from 0.794 to 0.650, and **every geometry assertion still passed**, so the suite now pins the largest connected component's width and aspect ratio. `prefers-reduced-motion` plays no animation and keeps the squint face, which is now that face's only role. **Running the pointer across the ball makes it squirm as if tickled** (2026-10-02): four generated poses (`mascot-tickle-1..4.png`, normalized at scale 1.0 - a tickle must not change the ball's size) cycle every 110 ms, and there is **no tilt** any more (2026-10-02, D-066): the 4-degree rotation that used to be computed in the renderer from the pointer speed was removed because it shared one `rotate` on `#ball` with the lift, which made a casual sweep look like a small take-off - rotation belongs to the lift alone now, and 260 ms without movement settles the poses back. The rotation is about the ball's centre, which is what makes it safe under the circular clip - rotation preserves every pixel's distance from the centre, so the ears cannot be rotated out of the circle (translation would). It is skipped under `prefers-reduced-motion` and while the ball is peek-hidden (that artwork has a straight cut edge that a rotation would open into a seam), and a press settles it so the lift owns the ball. **Not yet verified live** - geometry, wiring and the sequence are covered by `test/panel-lift-frames.test.ts` and `test/panel-lift-sequence.test.ts`, but nobody has watched the animation on a real window yet. The test was **rewritten to the new contract, not weakened**: the first version searched the whole stylesheet for each `body.<state> #ball .glow`, which also matches that state's separate `animation: none` rule, so removing a state from the gradient selector still passed - caught by a mutation check, and the assertion now requires the state to appear in the selector of the rule that actually carries the `radial-gradient`. **The right-click menu now has a second section of eight one-click functions** (谁在等我回话 / 待办 / 日报 / 统计 / 阅读统计 / 会话 / 朋友圈 / 微信读书), admitted by a single rule: the action must be completable by **one fixed sentence**, because a native menu cannot collect input - so search/export/read-one-message are excluded rather than shipped as items that do nothing. Each prompt names its tool, which is a request to the model and **not a hard binding** (the assistant still chooses from 19 tools; forcing it is a decision for when a wrong pick is actually observed). The prompt travels with the menu item and the page keeps no id→prompt table (two tables drift into "the menu says A, clicking does B", silently - a test asserts `renderer.js` contains no action id); the cost line is **derived** from the action list rather than written down, because a stale cost warning is worse than none, and it now names which items are cloud calls and which are local reads. The pick payload is `{kind:'contact'|'action', …}` and the page ignores anything else, so a menu from the previous version cannot be dispatched as a draft nobody asked for. All of it verified by executing every item's callback and by two mutation checks (dispatching an action as a draft, and the page keeping its own id table). **The ball's eyes now follow the mouse** (D-059): the main process samples `screen.getCursorScreenPoint()` every 120 ms and pushes the position **only when it changes**, the page eases toward it and stops its rAF loop once it settles. The renderer cannot see the cursor itself - the ball is 96x96 and the pointer is outside it almost always - which is why this needs the main process at all. The ball's face is now **two layers**: `mascot-base.png` (the same art with the iris region repainted as sclera) plus `mascot-iris.png` (the iris, pupil and highlight), composited at zero offset **pixel-identical** to `mascot.png` - a test decodes all three PNGs and asserts that, because same-size / whitelisted / listed-in-`PANEL_FILES` all stay green if the layers are re-cut one pixel off, and a misalignment is visible only to a person. Travel is clamped to an **ellipse** (about 2.6 px sideways, 0.8 up, 2.6 down at the 96 px ball) because those are the measured sclera margins - past them the iris separates from the rim and the eye reads as a sticker sliding. The iris layer is hidden on `busy` / `offline` / `quota` / `ball-happy`, whose faces have their eyes baked in (otherwise there would be two pupils). `prefers-reduced-motion` leaves the eyes still. The cursor position is in-process only, narrowed in `preload.cjs`, never logged and never sent anywhere. **Not yet verified live** - the wiring and the pixel identity are covered by the suite, but the effect has not been run on a real window. **The ball can also be pushed to a screen edge to hide behind it**: drag it until it touches a monitor's left or right edge and let go, and it swaps to a dedicated drawing of the cat **peeking out from behind that edge** - head and front paws out, body hidden, the drawing's left side being a straight cut that lands exactly on the screen edge (`mascot-peek.png`; the right edge reuses it mirrored). The window stays **fully on screen**, flush against the edge - the illusion comes from the artwork, so nothing goes off-screen, the whole ball stays clickable, and a restart simply puts the ball back at the edge rather than losing it. The first click (or drag) brings the normal ball back, and that click deliberately does **not** expand the conversation - on a hidden ball a click means "come back", not "let's talk". Only left and right: top and bottom fight the taskbar and Windows' edge snapping. Two rules carry the effect and both are pinned by tests because everything else stays green without them: the ball's circular clip must be off in this state (a circle would slice the straight cut into an arc) and hover-zoom must be off as well (scale 1.02 lifts the cut 1px off the edge - a visible seam). The snap threshold is deliberately below the normal 24px edge margin, so a ball merely parked is never mistaken for one being pushed off; a test pins that boundary, because raising it past the margin would hide the ball on every release while every other test stayed green. | `panel`, `panel --status`, `panel --ask` |
123
124
 
@@ -130,6 +131,8 @@ The daily workflow supports `dailyAiEnabled=false` for a persistent no-AI mode,
130
131
 
131
132
  Date-bounded message exports and `wechat.export_messages` page through the selected conversation before applying the result limit. Older matching dates are therefore not hidden by a newer, nonmatching first page. Versioned envelopes report requested bounds, returned count, and conservative `mayHaveMore` metadata. `sync` adds a local checkpoint on top of the same overlapping-window approach, but **a stable incremental cursor is still not exposed** - it must be supported by every relevant database backend before it is advertised (D-027), and `capabilities --json` reports `stableCursor: false` for both.
132
133
 
134
+ **The path from `false` to `true` is visible now, not just the verdict** (2026-10-23): `capabilities --json` 的 `read.exports.incrementalRead` 多了 `cursorReadiness`(五条判据 × 四个后端的代码事实,及指向探针的 `probe:` 命令串——`check_readme_commands.py` 把 `probe:` 与 `cli:`/`preview:` 一起校验),`sync cursor-probe --json` 实测 NT 数据侧:schema 检查**全量**(每张消息表的锚点列),身份检查**有界采样**(每分片取 5 张表、每表两端各 500 行,结果自带 `exhaustive: false`),server_id 以字符串上报(int64 过 2^53 会丢精度)。本机实测(2026-10-23):4 个分片全开、211 张表 0 缺列、采样 5,398 行**全部**带非零 server_id 且 0 重复——**数据侧判据在这台机器上已满足**;`stableCursor` 仍为 false,剩下的两块是读取器侧(合并顺序键 `(createTime, localId)` 的 localId 不跨分片可比)与其余三个后端(raw-4x / wcdb / 3x 无下推无覆盖报告)。探针不翻结论,只摊开路径。
135
+
133
136
  ## Not Verified (and what closing it would take)
134
137
 
135
138
  Same shape as the launcher reverse-engineering report's closing section ("what we could not do, and why"): an
@@ -185,7 +188,7 @@ Documentation was synchronized with the current source baseline on 2026-09-19. C
185
188
  - The article body is **not** available locally, so fetching cannot be skipped: a 公众号 message in the local database carries title, digest, URL and metadata, and stripping its XML tags leaves 0 Chinese characters (the ~5-12 KB that remains is URLs, base64 and ids).
186
189
  - The OC Bot channel is separate from a personal WeChat message stream. `send` can only reply through an already established Bot-channel conversation with a valid context token; it cannot initiate messages to existing personal contacts, post as the user's personal account, or send into ordinary personal WeChat groups.
187
190
  - The current official OC/iLink payload model has not been verified to support group events or group invitations. The project does not implement client automation or protocol bypasses to add a bot to groups.
188
- - Inbound media on the OC Bot channel (image / voice / file / video) is downloaded **only when `wechatMediaDownload` is `true`** (`false` by default, so a default install makes no such request). When it is on, each item is decrypted locally (AES-128-ECB, the same scheme as the local image files) and written under `output/wechat-media/` (directory overridable with `WEFLOW_WECHAT_MEDIA_DIR`). Names are decided locally - a server-supplied name is reduced to a sanitised basename - and each item is capped at 25 MB; a download that fails, comes back empty or exceeds the cap leaves `filePath` empty and writes one log line naming the reason, never a partial file. The field and key order follow the vendor implementation (`third-party/WeKnora/internal/im/wechat/longpoll.go`): images use `image_item.aeskey` (hex) before `media.aes_key` (base64). **Verified on a real inbound message** (2026-10-10, after a fresh `login-wechat`): a text message arrived and was answered, then a real image arrived - 27,637 bytes, PNG magic, and **PIL opened it at 798x513 RGB**, which is what separates "decryption is right" from "some bytes landed". The log showed `忽略非文本消息 (image)` on the same message, i.e. the assistant keeps ignoring non-text for its reply. **And no consumer reads the saved path yet**: `components[].filePath` is populated and the file really is on disk, but the only reader of an inbound message (`assistantService`) takes `messageStr` + `messageKind` and carries the full object along unread - so the assistant still knows only "an image arrived", not where it landed. Letting a model look at that file would be a new class of egress and is deliberately left as its own decision (D-042 set the precedent for local images). **And it downloads from any sender, not just the allowlist**: the download happens while parsing the polled message, one layer earlier than "should the assistant answer this", so the allowlist governs replies and not downloads - anyone who can message the bot gets their media written to disk here.
191
+ - Inbound media on the OC Bot channel (image / voice / file / video) is downloaded **only when `wechatMediaDownload` is `true`** (`false` by default, so a default install makes no such request). When it is on, each item is decrypted locally (AES-128-ECB, the same scheme as the local image files) and written under `output/wechat-media/` (directory overridable with `WEFLOW_WECHAT_MEDIA_DIR`). Names are decided locally - a server-supplied name is reduced to a sanitised basename - and each item is capped at 25 MB; a download that fails, comes back empty or exceeds the cap leaves `filePath` empty and writes one log line naming the reason, never a partial file. The field and key order follow the vendor implementation (`third-party/WeKnora/internal/im/wechat/longpoll.go`): images use `image_item.aeskey` (hex) before `media.aes_key` (base64). **Verified on a real inbound message** (2026-10-10, after a fresh `login-wechat`): a text message arrived and was answered, then a real image arrived - 27,637 bytes, PNG magic, and **PIL opened it at 798x513 RGB**, which is what separates "decryption is right" from "some bytes landed". The log showed `忽略非文本消息 (image)` on the same message, i.e. the assistant keeps ignoring non-text for its reply. **The image half of that gap is closed (2026-10-23, D-128)**: an inbound image with a downloaded `filePath` now becomes a turn (placeholder text `(发来一张图片)`, whitelist + quota unchanged), and `look_at_image` accepts a `#信N` handle that reads the landed file directly - same two-layer gate as D-042 (strict refuses at the tool AND at `toApiMessages`), same `MAX_IMAGES_PER_TURN` budget, mime sniffed from magic bytes, no rescaling and a 4 MB cap (evidence-shaped file). The handle is only shown when viewing is possible (same rule as `get_messages`' `#N`), and images without a landed file are still ignored - behaviour unchanged. **Still not consumed: voice / video / file components** - each is its own egress decision (D-128 names none of them), and `assistantService` still only knows "an X arrived" for those. **And it downloads from any sender, not just the allowlist**: the download happens while parsing the polled message, one layer earlier than "should the assistant answer this", so the allowlist governs replies and not downloads - anyone who can message the bot gets their media written to disk here.
189
192
  - Cloud AI workflows may transmit user-selected, privacy-filtered input to the configured provider. Local inference avoids that network transfer.
190
193
  - `vault promote ideas` and `vault promote all` run without AI by default. AI generation requires explicit `--with-ai` and an API key. CLI execution also requires preview and confirmation. `vault init` creates both the existing article-sync folders and the structured directories required by promotion workflows.
191
194
  - `vault init`, semantic-index construction, the knowledge pipeline, and report generators require preview and confirmation for machine execution. Preview JSON contains counts and behavior flags but omits local paths, conversation names, and generated content.