architext 0.0.5 → 0.0.6

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 (78) hide show
  1. package/CHANGELOG.md +29 -1
  2. package/README.md +18 -16
  3. package/README.zh-CN.md +15 -14
  4. package/dist/index.js +43 -29
  5. package/dist/templates/en/briefs/_base.md +13 -6
  6. package/dist/templates/en/briefs/_modules.md +2 -2
  7. package/dist/templates/en/docs/global/error_memory.json +40 -0
  8. package/dist/templates/en/docs/global/map.json +46 -90
  9. package/dist/templates/en/{rules/04_cli_tools.md → docs/global/references/cli_reference.md} +6 -13
  10. package/dist/templates/en/{rules/02_tech_stack.md → docs/global/tech_stack.md} +7 -18
  11. package/dist/templates/en/docs/global/vision.md +1 -1
  12. package/dist/templates/en/docs/prompts/audit.md +5 -5
  13. package/dist/templates/en/docs/prompts/code.md +23 -11
  14. package/dist/templates/en/docs/prompts/edit.md +21 -7
  15. package/dist/templates/en/docs/prompts/fix.md +11 -2
  16. package/dist/templates/en/docs/prompts/inherit.md +18 -13
  17. package/dist/templates/en/docs/prompts/map.md +4 -3
  18. package/dist/templates/en/docs/prompts/plan.md +11 -5
  19. package/dist/templates/en/docs/prompts/remove.md +13 -8
  20. package/dist/templates/en/docs/prompts/revise.md +10 -2
  21. package/dist/templates/en/docs/prompts/scope.md +4 -3
  22. package/dist/templates/en/docs/prompts/script.md +102 -0
  23. package/dist/templates/en/docs/prompts/start.md +20 -14
  24. package/dist/templates/en/docs/prompts/ui.md +113 -0
  25. package/dist/templates/en/docs/shared/ui-redlines.md +7 -0
  26. package/dist/templates/en/docs/templates/spec.template.md +1 -1
  27. package/dist/templates/en/docs/templates/ui.template.md +8 -8
  28. package/dist/templates/en/rules/00_system.md +245 -51
  29. package/dist/templates/en/rules/90_custom_rules.md +3 -1
  30. package/dist/templates/en/skills/archi-data-sync/SKILL.md +26 -12
  31. package/dist/templates/en/skills/archi-decompose-roadmap/SKILL.md +137 -208
  32. package/dist/templates/en/skills/archi-design-patterns/SKILL.md +6 -2
  33. package/dist/templates/en/skills/archi-feature-relations/SKILL.md +6 -2
  34. package/dist/templates/en/skills/archi-interview-protocol/SKILL.md +1 -2
  35. package/dist/templates/en/skills/archi-plan-options/SKILL.md +77 -302
  36. package/dist/templates/en/skills/archi-silent-audit/SKILL.md +4 -5
  37. package/dist/templates/en/skills/archi-ui-wireframe/SKILL.md +131 -306
  38. package/dist/templates/icon.svg +16 -0
  39. package/dist/templates/zh/briefs/_base.md +17 -10
  40. package/dist/templates/zh/briefs/_modules.md +2 -2
  41. package/dist/templates/zh/docs/global/error_memory.json +40 -0
  42. package/dist/templates/zh/docs/global/map.json +39 -109
  43. package/dist/templates/zh/{rules/04_cli_tools.md → docs/global/references/cli_reference.md} +0 -7
  44. package/dist/templates/zh/{rules/02_tech_stack.md → docs/global/tech_stack.md} +9 -20
  45. package/dist/templates/zh/docs/global/vision.md +1 -1
  46. package/dist/templates/zh/docs/prompts/audit.md +5 -5
  47. package/dist/templates/zh/docs/prompts/code.md +22 -10
  48. package/dist/templates/zh/docs/prompts/edit.md +20 -6
  49. package/dist/templates/zh/docs/prompts/fix.md +10 -1
  50. package/dist/templates/zh/docs/prompts/inherit.md +18 -13
  51. package/dist/templates/zh/docs/prompts/map.md +5 -4
  52. package/dist/templates/zh/docs/prompts/plan.md +11 -5
  53. package/dist/templates/zh/docs/prompts/remove.md +13 -8
  54. package/dist/templates/zh/docs/prompts/revise.md +12 -4
  55. package/dist/templates/zh/docs/prompts/scope.md +4 -3
  56. package/dist/templates/zh/docs/prompts/script.md +102 -0
  57. package/dist/templates/zh/docs/prompts/start.md +19 -15
  58. package/dist/templates/zh/docs/prompts/ui.md +113 -0
  59. package/dist/templates/zh/docs/shared/ui-redlines.md +7 -0
  60. package/dist/templates/zh/docs/templates/spec.template.md +1 -1
  61. package/dist/templates/zh/docs/templates/ui.template.md +8 -8
  62. package/dist/templates/zh/rules/00_system.md +243 -49
  63. package/dist/templates/zh/rules/90_custom_rules.md +2 -1
  64. package/dist/templates/zh/skills/archi-data-sync/SKILL.md +27 -13
  65. package/dist/templates/zh/skills/archi-decompose-roadmap/SKILL.md +133 -204
  66. package/dist/templates/zh/skills/archi-design-patterns/SKILL.md +6 -2
  67. package/dist/templates/zh/skills/archi-feature-relations/SKILL.md +6 -2
  68. package/dist/templates/zh/skills/archi-interview-protocol/SKILL.md +1 -2
  69. package/dist/templates/zh/skills/archi-plan-options/SKILL.md +77 -302
  70. package/dist/templates/zh/skills/archi-silent-audit/SKILL.md +4 -5
  71. package/dist/templates/zh/skills/archi-ui-wireframe/SKILL.md +131 -306
  72. package/package.json +3 -1
  73. package/dist/templates/en/rules/01_workflow.md +0 -95
  74. package/dist/templates/en/rules/03_data_governance.md +0 -106
  75. package/dist/templates/en/rules/99_context_glue.md +0 -53
  76. package/dist/templates/zh/rules/01_workflow.md +0 -95
  77. package/dist/templates/zh/rules/03_data_governance.md +0 -106
  78. package/dist/templates/zh/rules/99_context_glue.md +0 -53
package/CHANGELOG.md CHANGED
@@ -6,7 +6,35 @@ All notable changes are documented here, following [Keep a Changelog](https://ke
6
6
 
7
7
  ---
8
8
 
9
- ## [Unreleased](https://github.com/JiuNian3219/architext/compare/v0.0.5...HEAD) / 待发布
9
+ ## [Unreleased](https://github.com/JiuNian3219/architext/compare/v0.0.6...HEAD) / 待发布
10
+
11
+ ---
12
+
13
+ ## [0.0.6](https://github.com/JiuNian3219/architext/releases/tag/v0.0.6) - 2026-03-17
14
+
15
+ ### Added / 新增
16
+
17
+ - `/archi.script` 命令 — 生成自动化脚本 / Added `/archi.script` command for generating automation scripts
18
+ - `error_memory.json` — 错误记忆库,记录关键词签名与历史解决方案 / Added `error_memory.json` for error pattern tracking
19
+ - 桌面通知功能 — 支持 IDE 事件通知 / Added desktop notification support
20
+ - AI Git 工作流相关条目 / Added AI Git workflow entries
21
+ - IDE 通知配置检查功能 / Added IDE notification configuration check
22
+ - UI 概念设计支持多文件生成 / Enhanced UI wireframe with multi-file generation
23
+
24
+ ### Changed / 变更
25
+
26
+ - 系统文档重构 — 合并分散规则至 00_system.md / Refactored system docs, merged scattered rules into 00_system.md
27
+ - 双层架构与资产体系增强 / Enhanced dual-layer architecture and asset system
28
+ - 网站部署和页面更新 — SEO 优化 / Updated website deployment and pages with SEO optimization
29
+ - 数据治理与文件同步流程优化 / Optimized data governance and file sync flow
30
+ - 技能文档精简与一致性提升 / Streamlined skills documentation
31
+
32
+ ### Fixed / 修复
33
+
34
+ - 修复 file-model 测试 — 添加缺失的 script prompt 和全局种子文件 / Fixed file-model tests by adding missing script prompts
35
+ - 修复 IDE 和 Claude 通知集成不生效问题 / Fixed IDE and Claude notification integration
36
+ - 修复能力标记解析器 — 命令功能检测 / Fixed capability marker parser for command detection
37
+ - 修复模板表述 — 避免功能被误解为任务 / Fixed template wording to prevent feature-task confusion
10
38
 
11
39
  ---
12
40
 
package/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  [简体中文](https://github.com/JiuNian3219/architext/blob/main/README.zh-CN.md) · **English**
4
4
 
5
- # 🏛️ Architext
5
+ # <img src="templates/icon.svg" width="40" height="40" align="top" /> Architext
6
6
 
7
7
  **The AI Architecture Protocol. Define first, build right.**
8
8
 
@@ -74,8 +74,7 @@ npx archi init
74
74
  ✔ Docs deployed → .architext/
75
75
  prompts/ global/ templates/ tasks/
76
76
  ✔ Rules deployed → .cursor/rules/ (Cursor: .mdc)
77
- 00_system · 01_workflow · 02_tech_stack · 03_data_governance
78
- 04_cli_tools · 90_custom_rules · 99_context_glue
77
+ 00_system · 90_custom_rules
79
78
  ✔ Commands deployed → .cursor/commands/ (Cursor only)
80
79
  archi.start · archi.scope · archi.plan · archi.code · archi.audit · ...
81
80
  ✔ Skills deployed → .cursor/skills/ (Cursor)
@@ -104,10 +103,10 @@ The AI reads the brief, interviews you on key decisions, and generates the proje
104
103
  The main trunk of a project lifecycle. Everything happens in your AI chat window.
105
104
 
106
105
  ```
107
- project-brief.md → /archi.start → /archi.plan → /archi.code → /archi.audit
108
-
109
- /archi.scope runs anytime you have NEW feature requirements
110
- (not limited to "right after start" — mid-project, post-release, etc.)
106
+ project-brief.md → /archi.start → [?UI] /archi.ui → /archi.plan → /archi.code → /archi.audit
107
+
108
+ /archi.scope runs anytime you have NEW feature requirements
109
+ (not limited to "right after start" — mid-project, post-release, etc.)
111
110
  ```
112
111
 
113
112
  **Stage 1 — Initialize**
@@ -122,12 +121,12 @@ AI: [Analyzing project brief...]
122
121
  ✔ ADDED: .architext/global/roadmap.json
123
122
  ✔ ADDED: .architext/global/dictionary.json
124
123
  ✔ ADDED: .architext/global/error_codes.json
124
+ ✔ ADDED: .architext/global/env_registry.json
125
+ ✔ ADDED: .architext/global/tech_stack.md
125
126
  ✔ ADDED: .architext/global/ui_context.md (UI projects only)
126
- ✔ ADDED: .architext/global/ui_concept.html (UI projects only)
127
- ✔ MODIFIED: .cursor/rules/02_tech_stack.mdc (filled with project tech decisions)
128
127
  ✔ MODIFIED: .cursor/rules/90_custom_rules.mdc (filled with team conventions)
129
128
 
130
- Next: if the brief covers everything → /archi.plan <first-task-id>
129
+ Next: run /archi.ui to generate UI concept designs then /archi.plan <first-task-id>
131
130
  if you have more requirements → /archi.scope to add tasks first
132
131
  ```
133
132
 
@@ -209,7 +208,7 @@ AI: [Reading code + spec + plan + vision + tech_stack...]
209
208
  [LOW] Token expiry not configurable via env var → suggest /archi.edit
210
209
  ```
211
210
 
212
- > **Daily development between commands** is driven by natural language **Chat Mode**. Describe what you want in plain language — e.g. "add a login feature" or "fix the auth bug" — and the AI will automatically load and execute the right protocol (scope/plan/code/edit/fix). No need to manually type `/archi.*` slash commands. For questions, trivial edits, and debugging, the AI answers directly. Four of the seven rule files act as always-on base rules: `00_system`, `02_tech_stack`, `90_custom_rules`, `99_context_glue`.
211
+ > **Daily development between commands** is driven by natural language **Chat Mode**. Describe what you want in plain language — e.g. "add a login feature" or "fix the auth bug" — and the AI will automatically load and execute the right protocol (scope/plan/code/edit/fix). No need to manually type `/archi.*` slash commands. For questions, trivial edits, and debugging, the AI answers directly. Two rule files act as always-on base rules: `00_system` and `90_custom_rules`.
213
212
 
214
213
  ---
215
214
 
@@ -222,10 +221,10 @@ Different scenarios, same protocol. Pick the one that matches your situation.
222
221
  Your `project-brief.md` already lists all features. No scope needed.
223
222
 
224
223
  ```
225
- /archi.start project-brief.md → /archi.plan FEAT-001 → /archi.code FEAT-001 → ...
224
+ /archi.start project-brief.md → [?UI] /archi.ui → /archi.plan FEAT-001 → /archi.code FEAT-001 → ...
226
225
  ```
227
226
 
228
- Start produces a roadmap. Go straight to plan the first task, then code.
227
+ Start produces a roadmap. For UI projects, run `/archi.ui` to generate screen prototypes. Then plan and code as usual.
229
228
 
230
229
  ---
231
230
 
@@ -234,10 +233,10 @@ Start produces a roadmap. Go straight to plan the first task, then code.
234
233
  You ran start, but later realize you forgot features or want to add more.
235
234
 
236
235
  ```
237
- /archi.start project-brief.md → /archi.scope scope-brief.md → /archi.plan FEAT-001 → ...
236
+ /archi.start project-brief.md → [?UI] /archi.ui → /archi.scope scope-brief.md → /archi.plan FEAT-001 → ...
238
237
  ```
239
238
 
240
- Scope appends new tasks to `roadmap.json`. Then plan and code as usual.
239
+ Scope appends new tasks to `roadmap.json`. Then run `/archi.ui` for UI projects, and plan and code as usual.
241
240
 
242
241
  ---
243
242
 
@@ -297,10 +296,12 @@ You can trigger these either by typing `/archi.<command>` or by describing your
297
296
  | `/archi.start [brief]` | Read a project brief and generate foundation docs (vision / roadmap / tech_stack etc.) |
298
297
  | `/archi.inherit [brief]` | Reverse-engineer existing codebase; optionally pass project-brief.md to supplement vision/roadmap (skeleton repos) |
299
298
  | `/archi.scope [file_path]` | Decompose extra requirements into roadmap tasks; omit file to trigger an interview |
300
- | `/archi.plan <ID> [context]` | Deep architecture interview → spec / plan ([?UI] also ui.md + ui_concept.html); supply context to reduce questions |
299
+ | `/archi.plan <ID> [context]` | Deep architecture interview → spec / plan ([?UI] also ui.md); supply context to reduce questions |
301
300
  | `/archi.code <ID>` | Implement from plan phase by phase; only `active` tasks are allowed |
301
+ | `/archi.script` | Generate AI automation scripts (validate/dev-up/dev-reset) post-infrastructure |
302
302
  | `/archi.edit <ID> [context]` | Update feature spec → append new dev phase; history is preserved |
303
303
  | `/archi.revise [context]` | Global arch/stack change → impact assessment → cascade update on confirm |
304
+ | `/archi.ui` | Generate or incrementally update multi-file UI concept designs (`screens/` directory); UI projects only |
304
305
  | `/archi.audit [ID]` | Deep code audit; with ID audits a task, without ID does a project-wide health check |
305
306
  | `/archi.fix [ID] <context>` | Root-cause diagnosis and bug fix; ID optional, context describes the symptom |
306
307
  | `/archi.map` | Diff map.json against actual file tree and sync |
@@ -317,6 +318,7 @@ You can trigger these either by typing `/archi.<command>` or by describing your
317
318
  | `npx archi render` | Generate Markdown views from JSON data |
318
319
  | `npx archi task [--check]` | View / validate roadmap task status |
319
320
  | `npx archi plan <id>` | Check plan completion status for a feature |
321
+ | `npx archi pack [-o file]` | Pack user data into XML for backup/migration |
320
322
  | `npx archi template <name>` | Fetch a template file to project root |
321
323
  | `npx archi uninstall` | Remove Architext files from project |
322
324
 
package/README.zh-CN.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  **简体中文** · [English](https://github.com/JiuNian3219/architext/blob/main/README.md)
4
4
 
5
- # 🏛️ Architext
5
+ # <img src="templates/icon.svg" width="40" height="40" align="top" /> Architext
6
6
 
7
7
  **AI 原生架构协议 · 先想清楚,再让 AI 实现**
8
8
 
@@ -74,8 +74,7 @@ npx archi init
74
74
  ✔ 文档已部署 → .architext/
75
75
  prompts/ global/ templates/ tasks/
76
76
  ✔ 规则文件已部署 → .cursor/rules/ (Cursor: .mdc)
77
- 00_system · 01_workflow · 02_tech_stack · 03_data_governance
78
- 04_cli_tools · 90_custom_rules · 99_context_glue
77
+ 00_system · 90_custom_rules
79
78
  ✔ 命令文件已部署 → .cursor/commands/ (仅 Cursor)
80
79
  archi.start · archi.scope · archi.plan · archi.code · archi.audit · ...
81
80
  ✔ Skills 已部署 → .cursor/skills/ (Cursor)
@@ -104,8 +103,8 @@ AI 读取 Brief,就关键决策向你提问,生成项目的基础文档(`v
104
103
  项目全生命周期的主干路径,全部在 AI 对话框中完成。
105
104
 
106
105
  ```
107
- project-brief.md → /archi.start → /archi.plan → /archi.code → /archi.audit
108
-
106
+ project-brief.md → /archi.start → [?UI] /archi.ui → /archi.plan → /archi.code → /archi.audit
107
+
109
108
  /archi.scope anytime you have NEW feature requirements
110
109
  (不限「start 之后」——项目进行中、发布后均可)
111
110
  ```
@@ -122,12 +121,12 @@ AI: [正在分析项目 Brief...]
122
121
  ✔ 新增: .architext/global/roadmap.json
123
122
  ✔ 新增: .architext/global/dictionary.json
124
123
  ✔ 新增: .architext/global/error_codes.json
124
+ ✔ 新增: .architext/global/env_registry.json
125
+ ✔ 新增: .architext/global/tech_stack.md
125
126
  ✔ 新增: .architext/global/ui_context.md (仅 UI 类项目)
126
- ✔ 新增: .architext/global/ui_concept.html (仅 UI 类项目)
127
- ✔ 填充: .cursor/rules/02_tech_stack.mdc (写入项目技术决策)
128
127
  ✔ 填充: .cursor/rules/90_custom_rules.mdc (写入团队编码规范)
129
128
 
130
- 下一步:Brief 已覆盖全部需求 → /archi.plan <首个任务ID>
129
+ 下一步:运行 /archi.ui 生成 UI 概念设计 然后 /archi.plan <首个任务ID>
131
130
  Brief 之外还有需求 → /archi.scope 先追加任务
132
131
  ```
133
132
 
@@ -209,7 +208,7 @@ AI: [正在读取 代码 + spec + plan + vision + tech_stack...]
209
208
  [低] Token 过期时间未通过环境变量配置 → 建议运行 /archi.edit
210
209
  ```
211
210
 
212
- > **命令之间的日常开发**由自然语言 **Chat Mode** 驱动。用自然语言描述需求(如「加个登录功能」「修一下认证的 bug」),AI 会自动识别意图并加载对应协议(scope/plan/code/edit/fix)执行,**无需手动输入 `/archi.*` 斜杠命令**。提问、琐碎修改、调试则直接回答。7 个规则文件中有 4 个作为始终在线的基底规则:`00_system`、`02_tech_stack`、`90_custom_rules`、`99_context_glue`,AI 不会因会话切换而"失忆"。
211
+ > **命令之间的日常开发**由自然语言 **Chat Mode** 驱动。用自然语言描述需求(如「加个登录功能」「修一下认证的 bug」),AI 会自动识别意图并加载对应协议(scope/plan/code/edit/fix)执行,**无需手动输入 `/archi.*` 斜杠命令**。提问、琐碎修改、调试则直接回答。2 个规则文件作为始终在线的基底规则:`00_system`、`90_custom_rules`,AI 不会因会话切换而"失忆"。
213
212
 
214
213
  ---
215
214
 
@@ -222,10 +221,10 @@ AI: [正在读取 代码 + spec + plan + vision + tech_stack...]
222
221
  `project-brief.md` 已列出所有功能,无需 scope。
223
222
 
224
223
  ```
225
- /archi.start project-brief.md → /archi.plan FEAT-001 → /archi.code FEAT-001 → ...
224
+ /archi.start project-brief.md → [?UI] /archi.ui → /archi.plan FEAT-001 → /archi.code FEAT-001 → ...
226
225
  ```
227
226
 
228
- Start 产出 roadmap 后,直接 plan 首个任务,再 code。
227
+ Start 产出 roadmap 后,UI 项目运行 `/archi.ui` 生成屏幕原型,再 plan 首个任务,然后 code。
229
228
 
230
229
  ---
231
230
 
@@ -234,10 +233,10 @@ Start 产出 roadmap 后,直接 plan 首个任务,再 code。
234
233
  start 跑完后发现漏了功能,或想追加更多。
235
234
 
236
235
  ```
237
- /archi.start project-brief.md → /archi.scope scope-brief.md → /archi.plan FEAT-001 → ...
236
+ /archi.start project-brief.md → [?UI] /archi.ui → /archi.scope scope-brief.md → /archi.plan FEAT-001 → ...
238
237
  ```
239
238
 
240
- Scope 向 `roadmap.json` 追加任务,再按 plan → code 继续。
239
+ Scope 向 `roadmap.json` 追加任务,UI 项目运行 `/archi.ui`,再按 plan → code 继续。
241
240
 
242
241
  ---
243
242
 
@@ -297,10 +296,11 @@ Fix 诊断根因,向 plan 追加 Bugfix Phase,并修复代码。
297
296
  | `/archi.start [brief]` | 读取需求 Brief,生成项目基础文档(vision / roadmap / tech_stack 等) |
298
297
  | `/archi.inherit [brief]` | 逆向分析已有代码库;可选传 project-brief.md 补充愿景/路线图(骨架仓库) |
299
298
  | `/archi.scope [file_path]` | 将额外需求拆解为 Roadmap 任务;无文件则自动发起访谈 |
300
- | `/archi.plan <ID> [context]` | 深度架构访谈 → 生成 spec / plan([?UI] 附 ui.md + ui_concept.html);可附加已知上下文减少提问 |
299
+ | `/archi.plan <ID> [context]` | 深度架构访谈 → 生成 spec / plan([?UI] 附 ui.md);可附加已知上下文减少提问 |
301
300
  | `/archi.code <ID>` | 按 plan 分阶段实现代码;仅 `active` 任务可进入 |
302
301
  | `/archi.edit <ID> [context]` | 修改功能规格 → 追加新开发 Phase;不覆盖历史记录 |
303
302
  | `/archi.revise [context]` | 全局架构/技术栈变更 → 输出影响评估 → 用户确认后级联更新 |
303
+ | `/archi.ui` | 生成或增量更新多文件 UI 概念设计(`screens/` 目录);仅 UI 类项目 |
304
304
  | `/archi.audit [ID]` | 深度代码审查,输出审计报告;带 ID 审查单任务,不带 ID 做项目级体检 |
305
305
  | `/archi.fix [ID] <context>` | 诊断根因并修复 Bug;ID 可选,context 描述问题现象 |
306
306
  | `/archi.map` | 对比 map.json 与实际目录树,同步架构地图 |
@@ -317,6 +317,7 @@ Fix 诊断根因,向 plan 追加 Bugfix Phase,并修复代码。
317
317
  | `npx archi render` | 将 JSON 数据生成可读 Markdown 视图 |
318
318
  | `npx archi task [--check]` | 查看/校验 Roadmap 任务状态 |
319
319
  | `npx archi plan <id>` | 检查指定功能的 plan 完成度 |
320
+ | `npx archi pack [-o file]` | 打包用户数据为 XML 备份文件 |
320
321
  | `npx archi template <name>` | 获取模板文件到项目根目录 |
321
322
  | `npx archi uninstall` | 从项目中移除 Architext 文件 |
322
323