@geminilight/mindos 0.5.9 → 0.5.11

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 (63) hide show
  1. package/README.md +1 -1
  2. package/app/app/api/settings/test-key/route.ts +111 -0
  3. package/app/app/api/skills/route.ts +1 -1
  4. package/app/app/api/sync/route.ts +16 -31
  5. package/app/app/globals.css +10 -2
  6. package/app/app/login/page.tsx +1 -1
  7. package/app/app/view/[...path]/ViewPageClient.tsx +6 -1
  8. package/app/app/view/[...path]/not-found.tsx +1 -1
  9. package/app/components/AskModal.tsx +4 -4
  10. package/app/components/Breadcrumb.tsx +2 -2
  11. package/app/components/DirView.tsx +6 -6
  12. package/app/components/FileTree.tsx +2 -2
  13. package/app/components/HomeContent.tsx +7 -7
  14. package/app/components/OnboardingView.tsx +1 -1
  15. package/app/components/SearchModal.tsx +1 -1
  16. package/app/components/SettingsModal.tsx +2 -2
  17. package/app/components/SetupWizard.tsx +1 -1400
  18. package/app/components/Sidebar.tsx +4 -4
  19. package/app/components/SidebarLayout.tsx +9 -0
  20. package/app/components/SyncStatusBar.tsx +3 -3
  21. package/app/components/TableOfContents.tsx +1 -1
  22. package/app/components/UpdateBanner.tsx +1 -1
  23. package/app/components/ask/FileChip.tsx +1 -1
  24. package/app/components/ask/MentionPopover.tsx +4 -4
  25. package/app/components/ask/MessageList.tsx +1 -1
  26. package/app/components/ask/SessionHistory.tsx +2 -2
  27. package/app/components/renderers/config/ConfigRenderer.tsx +1 -1
  28. package/app/components/renderers/csv/BoardView.tsx +2 -2
  29. package/app/components/renderers/csv/ConfigPanel.tsx +5 -5
  30. package/app/components/renderers/csv/GalleryView.tsx +1 -1
  31. package/app/components/renderers/graph/GraphRenderer.tsx +1 -1
  32. package/app/components/renderers/summary/SummaryRenderer.tsx +1 -1
  33. package/app/components/renderers/workflow/WorkflowRenderer.tsx +2 -2
  34. package/app/components/settings/AiTab.tsx +120 -2
  35. package/app/components/settings/KnowledgeTab.tsx +1 -1
  36. package/app/components/settings/McpTab.tsx +27 -23
  37. package/app/components/settings/PluginsTab.tsx +4 -4
  38. package/app/components/settings/Primitives.tsx +1 -1
  39. package/app/components/settings/SyncTab.tsx +8 -8
  40. package/app/components/setup/StepAI.tsx +67 -0
  41. package/app/components/setup/StepAgents.tsx +237 -0
  42. package/app/components/setup/StepDots.tsx +39 -0
  43. package/app/components/setup/StepKB.tsx +237 -0
  44. package/app/components/setup/StepPorts.tsx +121 -0
  45. package/app/components/setup/StepReview.tsx +211 -0
  46. package/app/components/setup/StepSecurity.tsx +78 -0
  47. package/app/components/setup/constants.tsx +13 -0
  48. package/app/components/setup/index.tsx +464 -0
  49. package/app/components/setup/types.ts +53 -0
  50. package/app/instrumentation.ts +19 -0
  51. package/app/lib/i18n.ts +22 -4
  52. package/app/next.config.ts +1 -1
  53. package/bin/cli.js +8 -1
  54. package/bin/lib/sync.js +61 -11
  55. package/package.json +4 -2
  56. package/skills/project-wiki/SKILL.md +92 -63
  57. package/assets/images/demo-flow-dark.png +0 -0
  58. package/assets/images/demo-flow-light.png +0 -0
  59. package/assets/images/demo-flow-zh-dark.png +0 -0
  60. package/assets/images/demo-flow-zh-light.png +0 -0
  61. package/assets/images/gui-sync-cv.png +0 -0
  62. package/assets/images/wechat-qr.png +0 -0
  63. package/mcp/package-lock.json +0 -1717
package/bin/lib/sync.js CHANGED
@@ -1,6 +1,7 @@
1
1
  import { execSync } from 'node:child_process';
2
2
  import { existsSync, readFileSync, writeFileSync, mkdirSync } from 'node:fs';
3
3
  import { resolve } from 'node:path';
4
+ import { homedir } from 'node:os';
4
5
  import { CONFIG_PATH, MINDOS_DIR } from './constants.js';
5
6
  import { bold, dim, cyan, green, red, yellow } from './colors.js';
6
7
 
@@ -129,12 +130,24 @@ function autoPull(mindRoot) {
129
130
  }
130
131
  }
131
132
  }
133
+
134
+ // Retry any pending pushes (handles previous push failures)
135
+ try {
136
+ const unpushed = gitExec('git rev-list --count @{u}..HEAD', mindRoot);
137
+ if (parseInt(unpushed) > 0) {
138
+ execSync('git push', { cwd: mindRoot, stdio: 'pipe' });
139
+ saveSyncState({ ...loadSyncState(), lastSync: new Date().toISOString(), lastError: null });
140
+ }
141
+ } catch {
142
+ // No upstream tracking or push failed — ignore silently, autoCommitAndPush handles primary pushes
143
+ }
132
144
  }
133
145
 
134
146
  // ── Exported API ────────────────────────────────────────────────────────────
135
147
 
136
148
  let activeWatcher = null;
137
149
  let activePullInterval = null;
150
+ let activeShutdownHandler = null;
138
151
 
139
152
  /**
140
153
  * Interactive sync init — configure remote git repo
@@ -187,18 +200,43 @@ export async function initSync(mindRoot, opts = {}) {
187
200
  try { execSync('git checkout -b main', { cwd: mindRoot, stdio: 'pipe' }); } catch {}
188
201
  }
189
202
 
203
+ // 1b. Ensure .gitignore exists
204
+ const gitignorePath = resolve(mindRoot, '.gitignore');
205
+ if (!existsSync(gitignorePath)) {
206
+ writeFileSync(gitignorePath, [
207
+ '# MindOS auto-generated',
208
+ '.DS_Store',
209
+ 'Thumbs.db',
210
+ '*.tmp',
211
+ '*.bak',
212
+ '*.swp',
213
+ '*.sync-conflict',
214
+ 'node_modules/',
215
+ '.obsidian/',
216
+ '',
217
+ ].join('\n'), 'utf-8');
218
+ }
219
+
190
220
  // Handle token for HTTPS
191
221
  if (token && remoteUrl.startsWith('https://')) {
192
222
  const urlObj = new URL(remoteUrl);
193
- urlObj.username = 'oauth2';
194
- urlObj.password = token;
195
- // Configure credential helper
196
- try { execSync(`git config credential.helper store`, { cwd: mindRoot, stdio: 'pipe' }); } catch {}
197
- // Store the credential
223
+ // Choose credential helper by platform
224
+ const platform = process.platform;
225
+ let helper;
226
+ if (platform === 'darwin') helper = 'osxkeychain';
227
+ else if (platform === 'win32') helper = 'manager';
228
+ else helper = 'store';
229
+ try { execSync(`git config credential.helper '${helper}'`, { cwd: mindRoot, stdio: 'pipe' }); } catch {}
230
+ // Store the credential via git credential approve
198
231
  try {
199
232
  const credInput = `protocol=${urlObj.protocol.replace(':', '')}\nhost=${urlObj.host}\nusername=oauth2\npassword=${token}\n\n`;
200
233
  execSync('git credential approve', { cwd: mindRoot, input: credInput, stdio: 'pipe' });
201
234
  } catch {}
235
+ // For 'store' helper, restrict file permissions AFTER credential file is created
236
+ if (helper === 'store') {
237
+ const credFile = resolve(process.env.HOME || homedir(), '.git-credentials');
238
+ try { execSync(`chmod 600 "${credFile}"`, { stdio: 'pipe' }); } catch {}
239
+ }
202
240
  }
203
241
 
204
242
  // 4. Set remote
@@ -257,6 +295,7 @@ export async function initSync(mindRoot, opts = {}) {
257
295
  * Start file watcher + periodic pull
258
296
  */
259
297
  export async function startSyncDaemon(mindRoot) {
298
+ if (activeWatcher) return null; // already running — idempotent guard
260
299
  const config = loadSyncConfig();
261
300
  if (!config.enabled) return null;
262
301
  if (!mindRoot || !isGitRepo(mindRoot)) return null;
@@ -281,10 +320,20 @@ export async function startSyncDaemon(mindRoot) {
281
320
  // Pull on startup
282
321
  autoPull(mindRoot);
283
322
 
323
+ // Graceful shutdown: flush pending changes before exit
324
+ const gracefulShutdown = () => {
325
+ if (commitTimer) { clearTimeout(commitTimer); commitTimer = null; }
326
+ try { autoCommitAndPush(mindRoot); } catch {}
327
+ stopSyncDaemon();
328
+ };
329
+ process.on('SIGTERM', gracefulShutdown);
330
+ process.on('SIGINT', gracefulShutdown);
331
+
284
332
  activeWatcher = watcher;
285
333
  activePullInterval = pullInterval;
334
+ activeShutdownHandler = gracefulShutdown;
286
335
 
287
- return { watcher, pullInterval };
336
+ return { watcher, pullInterval, gracefulShutdown };
288
337
  }
289
338
 
290
339
  /**
@@ -299,6 +348,11 @@ export function stopSyncDaemon() {
299
348
  clearInterval(activePullInterval);
300
349
  activePullInterval = null;
301
350
  }
351
+ if (activeShutdownHandler) {
352
+ process.removeListener('SIGTERM', activeShutdownHandler);
353
+ process.removeListener('SIGINT', activeShutdownHandler);
354
+ activeShutdownHandler = null;
355
+ }
302
356
  }
303
357
 
304
358
  /**
@@ -336,14 +390,10 @@ export function getSyncStatus(mindRoot) {
336
390
  */
337
391
  export function manualSync(mindRoot) {
338
392
  if (!mindRoot || !isGitRepo(mindRoot)) {
339
- console.error(red('Not a git repository. Run `mindos sync init` first.'));
340
- process.exit(1);
393
+ throw new Error('Not a git repository. Run `mindos sync init` first.');
341
394
  }
342
- console.log(dim('Pulling...'));
343
395
  autoPull(mindRoot);
344
- console.log(dim('Committing & pushing...'));
345
396
  autoCommitAndPush(mindRoot);
346
- console.log(green('✔ Sync complete'));
347
397
  }
348
398
 
349
399
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@geminilight/mindos",
3
- "version": "0.5.9",
3
+ "version": "0.5.11",
4
4
  "description": "MindOS — Human-Agent Collaborative Mind System. Local-first knowledge base that syncs your mind to all AI Agents via MCP.",
5
5
  "keywords": [
6
6
  "mindos",
@@ -54,8 +54,10 @@
54
54
  "!assets/capture-demo.mjs",
55
55
  "!assets/demo-flow.html",
56
56
  "!assets/demo-flow-zh.html",
57
+ "!assets/images",
57
58
  "!mcp/node_modules",
58
- "!mcp/dist"
59
+ "!mcp/dist",
60
+ "!mcp/package-lock.json"
59
61
  ],
60
62
  "scripts": {
61
63
  "setup": "node scripts/setup.js",
@@ -34,15 +34,72 @@ description: "组织和维护 Vibe Coding 项目的 wiki 文档体系。当用
34
34
 
35
35
  ## 文件体系
36
36
 
37
+ ### 编号体系:十位 = 层级,个位 = 序号
38
+
39
+ 编号按**"战略 → 架构 → 规范 → 阶段 → 运维 → 日志"**分层,均匀分布,奇数十位留空备用。
40
+
41
+ ```
42
+ wiki/
43
+ ├── 0x 战略 Strategy — 全局视角,不看代码也能读懂
44
+ │ ├── 00-product-proposal.md
45
+ │ ├── 01-project-roadmap.md
46
+ │ ├── 02-business-model.md # 有商业化需求时
47
+ │ └── 03-technical-pillars.md # 有技术壁垒/研究方向时
48
+
49
+ ├── 2x 架构 Architecture — 系统是怎么建的(描述事实)
50
+ │ ├── 20-system-architecture.md
51
+ │ └── 21-design-principle.md # 有自定义视觉语言时
52
+
53
+ ├── 3x (空,留给接口/API 文档)
54
+
55
+ ├── 4x 规范 Conventions — 怎么参与开发(约束行为)
56
+ │ ├── 40-conventions.md
57
+ │ └── 41-dev-pitfall-patterns.md # 踩坑经验
58
+
59
+ ├── 5x (空)
60
+
61
+ ├── 6x 阶段 Stages — 各阶段详细 spec(按需查阅)
62
+ │ ├── 60-stage-a.md
63
+ │ ├── 61-stage-b.md
64
+ │ └── ...
65
+
66
+ ├── 7x (空)
67
+
68
+ ├── 8x 运维 Operations — 坑、复盘、backlog
69
+ │ ├── 80-known-pitfalls.md
70
+ │ ├── 81-postmortem-*.md
71
+ │ ├── 84-design-exploration.md # 有 UI 探索时
72
+ │ └── 85-backlog.md
73
+
74
+ ├── 9x 日志 Log
75
+ │ └── 90-changelog.md
76
+
77
+ ├── specs/ — 任务 spec(活跃的,完成后归档)
78
+ │ └── task-spec-xxx.md
79
+ ├── refs/ — 参考资料(外部机制说明、技术调研)
80
+ └── archive/ — 已完结的 spec 和历史文档
81
+ ```
82
+
83
+ | 区段 | 用途 | 扩展性 |
84
+ |------|------|--------|
85
+ | `0x` | 战略:产品方向、路线图、商业、壁垒 | 最多 10 个全局文档 |
86
+ | `2x` | 架构:系统设计 + 设计系统 | 可加 22-data-model 等 |
87
+ | `3x` | 留空 | 未来放 API reference、协议文档 |
88
+ | `4x` | 规范:开发流程 + 踩坑经验 | 可加 42-testing-standards 等 |
89
+ | `5x` | 留空 | 未来按需定义 |
90
+ | `6x` | 阶段:各功能的详细 spec | 最多 10 个阶段 |
91
+ | `7x` | 留空 | 未来按需定义 |
92
+ | `8x` | 运维:已知坑、复盘、backlog | 可加 82-xxx、83-xxx |
93
+ | `9x` | 日志 | changelog、release notes |
94
+
37
95
  ### 核心模型:Why / What / How / Look × 全局 / 阶段
38
96
 
39
97
  | | 全局(稳定,新阶段才改) | 阶段(增量更新) |
40
98
  |---|---|---|
41
99
  | **Why** | `00-product-proposal.md` | — |
42
- | **What** | `01-project-roadmap.md` — 功能索引 | `1X-stage-X.md` — 设计决策 |
43
- | **How** | `02-system-architecture.md` — 架构 + 类型 | `1X-stage-X.md` — API、数据模型、受影响文件 |
44
- | **API** | `04-api-reference.md` — 完整 API 参考 | `1X-stage-X.md` 新增 API 的设计决策 |
45
- | **Look** | `03-design-principle.md` — 视觉语言 | — |
100
+ | **What** | `01-project-roadmap.md` — 功能索引 | `6X-stage-X.md` — 设计决策 |
101
+ | **How** | `20-system-architecture.md` — 架构 + 类型 | `6X-stage-X.md` — API、数据模型、受影响文件 |
102
+ | **Look** | `21-design-principle.md` — 视觉语言 | — |
46
103
 
47
104
  **关键规则:** stage 文件同时包含 What 和 How。一个功能的设计决策、API 契约、数据模型放在一个文件里。全局文件只做索引和导航,不重复 stage 的细节。
48
105
 
@@ -62,58 +119,29 @@ description: "组织和维护 Vibe Coding 项目的 wiki 文档体系。当用
62
119
  |------|------|--------|---------|
63
120
  | 00 | `product-proposal.md` | Agent + 你 | 产品愿景、产品定位、**不做什么**、目标用户、功能矩阵、路线图叙事 |
64
121
  | 01 | `project-roadmap.md` | Agent + 你 | 阶段总览表、全量功能索引(功能×状态×stage链接)、里程碑 |
65
- | 02 | `system-architecture.md` | Agent | 技术栈、目录结构、数据流、核心类型、环境变量(300-500 行) |
122
+ | 20 | `system-architecture.md` | Agent | 技术栈、目录结构、数据流、核心类型、环境变量(300-500 行) |
66
123
 
67
124
  ### 按需文件(第二梯队)
68
125
 
69
126
  | 编号 | 文件 | 何时需要 |
70
127
  |------|------|---------|
71
- | 03 | `design-principle.md` | 有自定义视觉语言时(非默认 UI 库样式) |
72
- | 04 | `api-reference.md` | API 超过 5 条路由,或 stage 归档后仍需查 API 细节 |
73
- | 05 | `glossary.md` | 项目有领域术语,Agent 容易用错词或混用近义词 |
74
- | 06 | `conventions.md` | 有明确的编码偏好/约束(库选择、命名、错误处理模式等) |
75
- | 1X | `stage-X.md` | 功能复杂度超过一句话能说清(150-300 行) |
76
- | | `task-spec-xxx.md` | 小功能 / 改进点的 spec,包含需求描述和验收标准;实现完成后归档或合并进对应 stage 文件 |
128
+ | 02 | `business-model.md` | 有商业化/变现需求时 |
129
+ | 03 | `technical-pillars.md` | 有明确的技术壁垒或研究方向时 |
130
+ | 21 | `design-principle.md` | 有自定义视觉语言时(非默认 UI 库样式) |
131
+ | 30 | `api-reference.md` | API 超过 5 条路由,或 stage 归档后仍需查 API 细节 |
132
+ | 40 | `conventions.md` | 有明确的编码偏好/约束(库选择、命名、错误处理模式等) |
133
+ | 41 | `dev-pitfall-patterns.md` | 踩坑积累到需要系统性记录时 |
134
+ | 6X | `stage-X.md` | 功能复杂度超过一句话能说清(150-300 行) |
135
+ | — | `specs/task-spec-xxx.md` | 小功能 / 改进点的 spec;实现完成后归档到 `archive/` |
136
+ | — | `refs/xxx.md` | 外部机制说明、技术调研、协议文档 |
77
137
  | 80 | `known-pitfalls.md` | 踩坑即记,不等阶段结束 |
78
- | 81 | `development-guide.md` | 有非显而易见的配置要求时 |
79
- | 82 | `postmortem-*.md` | 多个 bug 互相关联、暴露系统性问题时(单点问题用 pitfalls,系统性问题用 postmortem) |
138
+ | 81 | `postmortem-*.md` | 多个 bug 互相关联、暴露系统性问题时(单点问题用 pitfalls,系统性问题用 postmortem) |
80
139
  | 84 | `design-exploration.md` | 有 UI 设计探索、原型记录等创意过程产物时 |
81
140
  | 85 | `backlog.md` | 有临时 bug、技术债、改进想法需要追踪时 |
82
- | 8X | `external-*.md` | 依赖外部系统私有数据格式时 |
83
141
  | 90 | `changelog.md` | 发版时从 `85-backlog.md` 已完成条目整理写入,面向用户描述变更,不记内部实现细节 |
84
142
 
85
143
  > 每个文件的详细说明和"为什么需要"的论证见 `references/file-reference.md`。
86
144
 
87
- ### 目录结构与编号规范
88
-
89
- ```
90
- wiki/
91
- ├── 00-product-proposal.md # Why
92
- ├── 01-project-roadmap.md # What(全局索引)
93
- ├── 02-system-architecture.md # How(全局)
94
- ├── 03-design-principle.md # Look(全局)
95
- ├── 04-api-reference.md # API(全局)
96
- ├── 05-glossary.md # 术语表(有领域术语时)
97
- ├── 06-conventions.md # 编码约定(有明确偏好时)
98
- ├── 10-stage-a.md # 阶段文件
99
- ├── 11-stage-b.md
100
- ├── ...
101
- ├── 80-known-pitfalls.md # 辅助参考
102
- ├── 81-development-guide.md
103
- ├── 82-postmortem-*.md # 系统性问题复盘(多 bug 关联时)
104
- ├── 84-design-exploration.md # 设计探索/原型记录(有 UI 探索时)
105
- ├── 85-backlog.md # Bug、技术债、改进想法
106
- ├── 90-changelog.md # 日志
107
- └── archive/ # 已完结阶段归档
108
- ```
109
-
110
- | 区段 | 用途 |
111
- |------|------|
112
- | `00-09` | 全局文件,按阅读优先级排列 |
113
- | `10-79` | 阶段文件,按时间递增 |
114
- | `80-89` | 辅助参考文件 |
115
- | `90-99` | 日志类文件 |
116
-
117
145
  ### Stage 文件生命周期
118
146
 
119
147
  阶段完全交付且后续阶段不再引用其 API/数据模型时 → 移入 `wiki/archive/`,`01-project-roadmap.md` 中保留索引行并标注 `[archived]`。
@@ -126,11 +154,11 @@ wiki/
126
154
 
127
155
  | 场景 | 路径 |
128
156
  |------|------|
129
- | 新对话 / 新功能 | `00-product-proposal` → `02-system-architecture` → 当前 `stage-X` |
130
- | 修 Bug | `02-system-architecture` → `80-known-pitfalls` → 相关 `stage-X` |
131
- | 修 Bug(反复出现) | `82-postmortem-*` → `02-system-architecture` → `80-known-pitfalls` → 相关 `stage-X` |
132
- | UI 调整 | `03-design-principle` → `02-system-architecture`(目录结构)→ 相关组件 |
133
- | 了解全貌 | `00-product-proposal` → `01-project-roadmap` → `02-system-architecture` |
157
+ | 新对话 / 新功能 | `00-product-proposal` → `20-system-architecture` → 当前 `6X-stage-X` |
158
+ | 修 Bug | `20-system-architecture` → `80-known-pitfalls` → 相关 `6X-stage-X` |
159
+ | 修 Bug(反复出现) | `81-postmortem-*` → `20-system-architecture` → `80-known-pitfalls` → 相关 `6X-stage-X` |
160
+ | UI 调整 | `21-design-principle` → `20-system-architecture`(目录结构)→ 相关组件 |
161
+ | 了解全貌 | `00-product-proposal` → `01-project-roadmap` → `20-system-architecture` |
134
162
 
135
163
  ---
136
164
 
@@ -177,20 +205,21 @@ Skill 触发时生成 wiki 结构,但 wiki 的日常同步发生在每次开
177
205
 
178
206
  | 当你做了这件事 | 更新哪个文件 |
179
207
  |--------------|------------|
180
- | 新增/修改 API 路由 | `wiki/04-api-reference.md` 追加或修改对应条目 |
208
+ | 新增/修改 API 路由 | `wiki/30-api-reference.md` 追加或修改对应条目 |
181
209
  | 完成一个 stage 的功能 | `wiki/01-project-roadmap.md` 对应行状态改为 ✅ |
182
210
  | 遇到非显而易见的坑 | `wiki/80-known-pitfalls.md` 追加一条(现象、原因、解法) |
183
- | 多个 bug 互相关联、暴露系统性问题 | 新建 `wiki/82-postmortem-*.md`(单点问题用 pitfalls,系统性问题用 postmortem) |
184
- | 架构变更(新模块、新数据流) | `wiki/02-system-architecture.md` 更新对应章节 |
211
+ | 多个 bug 互相关联、暴露系统性问题 | 新建 `wiki/81-postmortem-*.md`(单点问题用 pitfalls,系统性问题用 postmortem) |
212
+ | 架构变更(新模块、新数据流) | `wiki/20-system-architecture.md` 更新对应章节 |
185
213
  | 阶段全部交付 | `wiki/90-changelog.md` 补一笔(从 backlog 已完成条目整理) |
186
214
  | 发现 bug / 技术债 / 改进想法 | `wiki/85-backlog.md` 追加一条 |
187
- | 新增设计 token / 动效 | `wiki/03-design-principle.md` 追加对应条目 |
215
+ | 新增设计 token / 动效 | `wiki/21-design-principle.md` 追加对应条目 |
188
216
  | 出现新领域术语 | `wiki/05-glossary.md` 追加定义,防止 Agent 后续用词混乱 |
189
217
  | 重命名 / 移动 wiki 文件 | 同步更新所有引用该文件的链接 |
190
218
 
191
219
  **新建文件时机:**
192
- - 新功能复杂度超过一句话说清 → 新建 `wiki/1X-stage-X.md`
193
- - 小功能 / 改进点需要 spec → 新建 `wiki/task-spec-xxx.md`(实现完成后归档或合并进 stage 文件)
220
+ - 新功能复杂度超过一句话说清 → 新建 `wiki/6X-stage-X.md`
221
+ - 小功能 / 改进点需要 spec → 新建 `wiki/specs/task-spec-xxx.md`(实现完成后归档到 `archive/`)
222
+ - 外部机制调研 → 新建 `wiki/refs/xxx.md`
194
223
 
195
224
  **定期检查(每个阶段开始时):**
196
225
  - 扫描 wiki/ 下所有文件,更新 `Last verified` 日期
@@ -209,15 +238,15 @@ Skill 触发时生成 wiki 结构,但 wiki 的日常同步发生在每次开
209
238
  |---------|---------------|
210
239
  | `product-proposal.tmpl.md` | `00-product-proposal.md` |
211
240
  | `project-roadmap.tmpl.md` | `01-project-roadmap.md` |
212
- | `system-architecture.tmpl.md` | `02-system-architecture.md` |
213
- | `design-principle.tmpl.md` | `03-design-principle.md` |
214
- | `api-reference.tmpl.md` | `04-api-reference.md` |
215
- | `glossary.tmpl.md` | `05-glossary.md` |
216
- | `conventions.tmpl.md` | `06-conventions.md` |
217
- | `stage-x.tmpl.md` | `1X-stage-X.md` |
241
+ | `business-model.tmpl.md` | `02-business-model.md` |
242
+ | `technical-pillars.tmpl.md` | `03-technical-pillars.md` |
243
+ | `system-architecture.tmpl.md` | `20-system-architecture.md` |
244
+ | `design-principle.tmpl.md` | `21-design-principle.md` |
245
+ | `api-reference.tmpl.md` | `30-api-reference.md` |
246
+ | `conventions.tmpl.md` | `40-conventions.md` |
247
+ | `stage-x.tmpl.md` | `6X-stage-X.md` |
218
248
  | `known-pitfalls.tmpl.md` | `80-known-pitfalls.md` |
219
- | `development-guide.tmpl.md` | `81-development-guide.md` |
220
- | `postmortem.tmpl.md` | `82-postmortem-*.md` |
249
+ | `postmortem.tmpl.md` | `81-postmortem-*.md` |
221
250
  | `design-exploration.tmpl.md` | `84-design-exploration.md` |
222
251
  | `backlog.tmpl.md` | `85-backlog.md` |
223
252
  | `changelog.tmpl.md` | `90-changelog.md` |
Binary file
Binary file
Binary file
Binary file
Binary file