@adamchanadam/agent-handoff-kit 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Agent Handoff Kit
2
2
 
3
- 狀態:`v0.2.0` 已正式發佈到 GitHub 與 npm。這是早期可用版本,尚未宣稱所有需求已完成。
3
+ 狀態:`v0.2.1` 已正式發佈到 GitHub 與 npm。這是早期可用版本,尚未宣稱所有需求已完成。
4
4
 
5
5
  ![Agent Handoff Kit 主視覺](https://raw.githubusercontent.com/Adamchanadam/agent-handoff-kit/main/images/agent-handoff-kit-main-visual2.png)
6
6
 
@@ -49,7 +49,17 @@ npx @adamchanadam/agent-handoff-kit init
49
49
 
50
50
  ### 二、開工
51
51
 
52
- 打開你想用的 AI 工具,在新對話貼上安裝工具顯示的文字。沒有那段文字時,可貼這句:
52
+ 打開你想用的 AI 工具,在新對話貼上安裝工具顯示的文字。
53
+
54
+ **第一次用(R-029 onboarding trigger)**:
55
+
56
+ ```text
57
+ Work in <你的專案資料夾>. I just installed agent-handoff-kit. Help me get started.
58
+ ```
59
+
60
+ AI 會自動載入 onboarding pack,引導你選擇情景(寫代碼 / 研究報告 / 知識庫整理 / 學寫代碼 / 其他),然後一步一步帶你做第一個任務。
61
+
62
+ **之後 session(你已熟悉 v2 之後)可用更直接 prompt**:
53
63
 
54
64
  ```text
55
65
  Work in <你的專案資料夾>. Read AGENTS.md and follow it. Before changing anything, tell me the current state and your recommended next step.
@@ -252,7 +262,7 @@ Agent Handoff Kit 同 [Adam-AI-Instructions](https://github.com/prompt-templates
252
262
 
253
263
  ## 目前限制
254
264
 
255
- - `v0.2.0` 是 GitHub 與 npm 同步發佈版本。
265
+ - `v0.2.1` 是 GitHub 與 npm 同步發佈版本。
256
266
  - 這是早期可用版本,尚未宣稱完整穩定。
257
267
  - 升級合併仍是窄範圍策略,不是完整的複雜合併工具。
258
268
  - `doctor` 能檢查結構,不能代替 AI 對專案內容的理解。
@@ -302,7 +302,12 @@ const schemaChecks = [
302
302
  includes("dev/rules/safety.md"),
303
303
  includes("dev/rules/coding.md"),
304
304
  includes("dev/rules/research.md"),
305
- includes("dev/rules/release.md")
305
+ includes("dev/rules/release.md"),
306
+ // R-029 v0.2.1+: routing table must include onboarding pack first-time signal row.
307
+ // Without this anchor, the upgrade flow may silently leave v0.1.X users with a
308
+ // stale routing table that does not route onboarding signals.
309
+ includes("First-time user signals"),
310
+ includes("dev/rules/onboarding.md")
306
311
  ]
307
312
  },
308
313
  {
@@ -762,6 +767,21 @@ function classifyExistingFile(command, sourceRel, targetRel, sourceAbs, targetAb
762
767
  mergedText: mergeManagedBlock(targetText, sourceText)
763
768
  };
764
769
  }
770
+ // R-029 v0.2.0+: RULE_PACKS.md is a routing table, not a user customization target.
771
+ // Stale v0.1.X versions miss the "First-time user signals" onboarding routing row.
772
+ // Force-refresh during upgrade so R-029 onboarding routing propagates to existing users.
773
+ // Any user-added custom routing rows will be lost on upgrade — this is by design;
774
+ // RULE_PACKS.md is treated as a maintainer-owned routing table, similar to the
775
+ // AGENTS.md managed-core block. User customizations belong in pack rule files
776
+ // (packs/*.md), not in the routing table.
777
+ if (targetRel === "dev/RULE_PACKS.md" && command === "upgrade" && !targetText.includes("First-time user signals")) {
778
+ return {
779
+ ...base,
780
+ action: "merge",
781
+ reason: "refresh stale routing table to include v0.2.0+ rows (R-029 onboarding signal routing)",
782
+ mergedText: sourceText
783
+ };
784
+ }
765
785
  if ((targetRel === "CLAUDE.md" || targetRel === "GEMINI.md") && !targetText.includes("AGENTS.md")) {
766
786
  return { ...base, action: "conflict", reason: "existing bridge does not route to AGENTS.md" };
767
787
  }
@@ -1205,11 +1225,14 @@ function printInstallNextSteps(root, conflictCount) {
1205
1225
  console.log("⚠️ 請注意:下面文字不是 Terminal 指令。");
1206
1226
  console.log("📋 請打開你要使用的 AI 工具,新增一段對話,貼上下面一句:");
1207
1227
  console.log("------------------------------------------------------------");
1208
- console.log(`Work in ${root}. Read AGENTS.md and follow it. Before changing anything, tell me the current state and your recommended next step.`);
1228
+ console.log(`Work in ${root}. I just installed agent-handoff-kit. Help me get started.`);
1209
1229
  console.log("------------------------------------------------------------");
1210
1230
  console.log("");
1211
- console.log("🚀 然後直接描述你的任務,例如:");
1212
- console.log(" 整理這個專案,先告訴我你讀到的目前狀態與下一步。");
1231
+ console.log("🚀 AI 會主動引導你選擇情景(寫代碼 / 研究報告 / 知識庫整理 / 學寫代碼 / 其他),");
1232
+ console.log(" 一步一步帶你做第一個任務(由 R-029 onboarding pack 主動接管)。");
1233
+ console.log("");
1234
+ console.log("💡 之後 session(你已熟悉 v2 之後)可改用更直接 prompt:");
1235
+ console.log(` Work in ${root}. Read AGENTS.md and follow it. Before changing anything, tell me the current state and your recommended next step.`);
1213
1236
  console.log("");
1214
1237
  console.log("🩺 如要檢查安裝是否完整,可在 Terminal 執行:");
1215
1238
  console.log(" npx @adamchanadam/agent-handoff-kit doctor");
@@ -1250,9 +1273,11 @@ Commands:
1250
1273
  🩺 doctor 檢查必要文件與交接結構是否完整。
1251
1274
 
1252
1275
  After install:
1253
- Do not type "Follow AGENTS.md" into Terminal.
1254
- Open your AI tool, start a new chat, paste the shown Work in ... message,
1255
- then describe your task in normal language.
1276
+ Do not type the shown "Work in ..." message into Terminal.
1277
+ Open your AI tool, start a new chat, and paste it there.
1278
+ The default post-install prompt triggers the R-029 onboarding pack — AI
1279
+ will guide you through scenario selection (coding / research / knowledge /
1280
+ learning / other) and walk you through your first task in 5 steps.
1256
1281
  `);
1257
1282
  console.log(`📦 版本:v${version}`);
1258
1283
  console.log(`🛠️ 模式:help ready`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adamchanadam/agent-handoff-kit",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "description": "Lightweight agent harness for project memory, handoff, and multi-session continuity.",
5
5
  "type": "module",
6
6
  "bin": {