@devflow-tools/devflow 0.18.73 → 0.19.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 (132) hide show
  1. package/acceptance-manifest.json +24 -6
  2. package/dist/cli.js +72 -68
  3. package/dist/dashboard/404.html +1 -1
  4. package/dist/dashboard/__next.__PAGE__.txt +1 -1
  5. package/dist/dashboard/__next._full.txt +1 -1
  6. package/dist/dashboard/__next._tree.txt +1 -1
  7. package/dist/dashboard/_not-found/__next._full.txt +1 -1
  8. package/dist/dashboard/_not-found/__next._not-found.__PAGE__.txt +1 -1
  9. package/dist/dashboard/_not-found/__next._tree.txt +1 -1
  10. package/dist/dashboard/_not-found.html +1 -1
  11. package/dist/dashboard/_not-found.txt +1 -1
  12. package/dist/dashboard/accuracy/__next._full.txt +1 -1
  13. package/dist/dashboard/accuracy/__next._tree.txt +1 -1
  14. package/dist/dashboard/accuracy/__next.accuracy.__PAGE__.txt +1 -1
  15. package/dist/dashboard/accuracy.html +1 -1
  16. package/dist/dashboard/accuracy.txt +1 -1
  17. package/dist/dashboard/benchmark/__next._full.txt +1 -1
  18. package/dist/dashboard/benchmark/__next._tree.txt +1 -1
  19. package/dist/dashboard/benchmark/__next.benchmark.__PAGE__.txt +1 -1
  20. package/dist/dashboard/benchmark.html +1 -1
  21. package/dist/dashboard/benchmark.txt +1 -1
  22. package/dist/dashboard/context/__next._full.txt +1 -1
  23. package/dist/dashboard/context/__next._tree.txt +1 -1
  24. package/dist/dashboard/context/__next.context.__PAGE__.txt +1 -1
  25. package/dist/dashboard/context.html +1 -1
  26. package/dist/dashboard/context.txt +1 -1
  27. package/dist/dashboard/doctor/__next._full.txt +1 -1
  28. package/dist/dashboard/doctor/__next._tree.txt +1 -1
  29. package/dist/dashboard/doctor/__next.doctor.__PAGE__.txt +1 -1
  30. package/dist/dashboard/doctor.html +1 -1
  31. package/dist/dashboard/doctor.txt +1 -1
  32. package/dist/dashboard/executions/__next._full.txt +1 -1
  33. package/dist/dashboard/executions/__next._tree.txt +1 -1
  34. package/dist/dashboard/executions/__next.executions.__PAGE__.txt +1 -1
  35. package/dist/dashboard/executions.html +1 -1
  36. package/dist/dashboard/executions.txt +1 -1
  37. package/dist/dashboard/graph/__next._full.txt +1 -1
  38. package/dist/dashboard/graph/__next._tree.txt +1 -1
  39. package/dist/dashboard/graph/__next.graph.__PAGE__.txt +1 -1
  40. package/dist/dashboard/graph.html +1 -1
  41. package/dist/dashboard/graph.txt +1 -1
  42. package/dist/dashboard/index.html +1 -1
  43. package/dist/dashboard/index.txt +1 -1
  44. package/dist/dashboard/intelligence/__next._full.txt +1 -1
  45. package/dist/dashboard/intelligence/__next._tree.txt +1 -1
  46. package/dist/dashboard/intelligence/__next.intelligence.__PAGE__.txt +1 -1
  47. package/dist/dashboard/intelligence/knowledge/__next._full.txt +1 -1
  48. package/dist/dashboard/intelligence/knowledge/__next._tree.txt +1 -1
  49. package/dist/dashboard/intelligence/knowledge/__next.intelligence.knowledge.__PAGE__.txt +1 -1
  50. package/dist/dashboard/intelligence/knowledge.html +1 -1
  51. package/dist/dashboard/intelligence/knowledge.txt +1 -1
  52. package/dist/dashboard/intelligence/memory/__next._full.txt +1 -1
  53. package/dist/dashboard/intelligence/memory/__next._tree.txt +1 -1
  54. package/dist/dashboard/intelligence/memory/__next.intelligence.memory.__PAGE__.txt +1 -1
  55. package/dist/dashboard/intelligence/memory.html +1 -1
  56. package/dist/dashboard/intelligence/memory.txt +1 -1
  57. package/dist/dashboard/intelligence.html +1 -1
  58. package/dist/dashboard/intelligence.txt +1 -1
  59. package/dist/dashboard/knowledge/__next._full.txt +1 -1
  60. package/dist/dashboard/knowledge/__next._tree.txt +1 -1
  61. package/dist/dashboard/knowledge/__next.knowledge.__PAGE__.txt +1 -1
  62. package/dist/dashboard/knowledge.html +1 -1
  63. package/dist/dashboard/knowledge.txt +1 -1
  64. package/dist/dashboard/memory/__next._full.txt +1 -1
  65. package/dist/dashboard/memory/__next._tree.txt +1 -1
  66. package/dist/dashboard/memory/__next.memory.__PAGE__.txt +1 -1
  67. package/dist/dashboard/memory.html +1 -1
  68. package/dist/dashboard/memory.txt +1 -1
  69. package/dist/dashboard/replay/__next._full.txt +1 -1
  70. package/dist/dashboard/replay/__next._tree.txt +1 -1
  71. package/dist/dashboard/replay/__next.replay.__PAGE__.txt +1 -1
  72. package/dist/dashboard/replay.html +1 -1
  73. package/dist/dashboard/replay.txt +1 -1
  74. package/dist/dashboard/runs/_/__next._full.txt +1 -1
  75. package/dist/dashboard/runs/_/__next._tree.txt +1 -1
  76. package/dist/dashboard/runs/_/__next.runs.$d$id.__PAGE__.txt +1 -1
  77. package/dist/dashboard/runs/_.html +1 -1
  78. package/dist/dashboard/runs/_.txt +1 -1
  79. package/dist/dashboard/runs/__next._full.txt +1 -1
  80. package/dist/dashboard/runs/__next._tree.txt +1 -1
  81. package/dist/dashboard/runs/__next.runs.__PAGE__.txt +1 -1
  82. package/dist/dashboard/runs.html +1 -1
  83. package/dist/dashboard/runs.txt +1 -1
  84. package/dist/dashboard/settings/__next._full.txt +1 -1
  85. package/dist/dashboard/settings/__next._tree.txt +1 -1
  86. package/dist/dashboard/settings/__next.settings.__PAGE__.txt +1 -1
  87. package/dist/dashboard/settings.html +1 -1
  88. package/dist/dashboard/settings.txt +1 -1
  89. package/dist/dashboard/timeline/__next._full.txt +1 -1
  90. package/dist/dashboard/timeline/__next._tree.txt +1 -1
  91. package/dist/dashboard/timeline/__next.timeline.__PAGE__.txt +1 -1
  92. package/dist/dashboard/timeline.html +1 -1
  93. package/dist/dashboard/timeline.txt +1 -1
  94. package/dist/dashboard/tool-metrics/__next._full.txt +1 -1
  95. package/dist/dashboard/tool-metrics/__next._tree.txt +1 -1
  96. package/dist/dashboard/tool-metrics/__next.tool-metrics.__PAGE__.txt +1 -1
  97. package/dist/dashboard/tool-metrics.html +1 -1
  98. package/dist/dashboard/tool-metrics.txt +1 -1
  99. package/dist/dashboard/workflows/__next._full.txt +1 -1
  100. package/dist/dashboard/workflows/__next._tree.txt +1 -1
  101. package/dist/dashboard/workflows/__next.workflows.__PAGE__.txt +1 -1
  102. package/dist/dashboard/workflows.html +1 -1
  103. package/dist/dashboard/workflows.txt +1 -1
  104. package/dist/hooks/hook-daemon.js +28 -27
  105. package/dist/hooks/post-tool-use-failure.js +2 -2
  106. package/dist/hooks/post-tool-use.js +4 -4
  107. package/dist/hooks/pre-tool-use.js +5 -4
  108. package/dist/hooks/session-end.js +6 -6
  109. package/dist/hooks/stop.js +9 -9
  110. package/dist/plugin/.claude-plugin/plugin.json +1 -1
  111. package/dist/plugin/dist/hooks/hook-daemon.js +28 -27
  112. package/dist/plugin/dist/hooks/post-tool-use-failure.js +2 -2
  113. package/dist/plugin/dist/hooks/post-tool-use.js +4 -4
  114. package/dist/plugin/dist/hooks/pre-tool-use.js +5 -4
  115. package/dist/plugin/dist/hooks/session-end.js +6 -6
  116. package/dist/plugin/dist/hooks/stop.js +9 -9
  117. package/dist/plugin/dist/runtime-manifest.json +5 -5
  118. package/dist/plugin/hooks/constitution.md +7 -16
  119. package/dist/plugin/hooks/hooks.json +35 -14
  120. package/dist/plugin/hooks/post-tool-use +7 -0
  121. package/dist/plugin/hooks/post-tool-use-failure +7 -0
  122. package/dist/plugin/hooks/pre-compact +7 -0
  123. package/dist/plugin/hooks/pre-tool-use +17 -9
  124. package/dist/plugin/hooks/runtime-node +11 -0
  125. package/dist/plugin/hooks/session-end +7 -0
  126. package/dist/plugin/hooks/session-start +28 -27
  127. package/dist/plugin/hooks/stop +7 -0
  128. package/dist/plugin/hooks/user-prompt-submit +7 -0
  129. package/dist/plugin/package.json +13 -13
  130. package/package.json +17 -17
  131. /package/dist/dashboard/_next/static/{Pxwskm195oqVNNqbq-7Fo → Jo2zPkpXCR3MZbbWYPoTu}/_buildManifest.js +0 -0
  132. /package/dist/dashboard/_next/static/{Pxwskm195oqVNNqbq-7Fo → Jo2zPkpXCR3MZbbWYPoTu}/_ssgManifest.js +0 -0
@@ -1,6 +1,16 @@
1
1
  #!/usr/bin/env bash
2
2
  set -euo pipefail
3
3
 
4
+ SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
5
+ PLUGIN_ROOT="${CLAUDE_PLUGIN_ROOT:-$(cd "${SCRIPT_DIR}/.." && pwd)}"
6
+ source "${PLUGIN_ROOT}/hooks/runtime-node"
7
+
8
+ # Global kill switch: exit with no opinion before spawning any runtime.
9
+ if devflow_is_disabled; then
10
+ cat >/dev/null 2>&1 || true
11
+ exit 0
12
+ fi
13
+
4
14
  PROJECT_ROOT="${CLAUDE_PROJECT_DIR:-$(pwd)}"
5
15
  SESSION_START_INPUT="$(cat)"
6
16
 
@@ -18,14 +28,6 @@ RECEIPT_FILE="$RECEIPT_DIR/${SESSION_ID}.json"
18
28
  OVERRIDE_FILE="$RECEIPT_DIR/${SESSION_ID}.override"
19
29
  rm -f "$RECEIPT_FILE" "$OVERRIDE_FILE" 2>/dev/null || true
20
30
 
21
- # Determine plugin root directory (same way as superpowers)
22
- if [ -z "${CLAUDE_PLUGIN_ROOT:-}" ]; then
23
- SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
24
- PLUGIN_ROOT="$(cd "${SCRIPT_DIR}/.." && pwd)"
25
- else
26
- PLUGIN_ROOT="$CLAUDE_PLUGIN_ROOT"
27
- fi
28
- source "${PLUGIN_ROOT}/hooks/runtime-node"
29
31
  DEVFLOW_NODE="$(devflow_resolve_node "$PLUGIN_ROOT")"
30
32
 
31
33
  # The registry points at an immutable build directory. Verify that this
@@ -113,17 +115,16 @@ else
113
115
  fi
114
116
  GATEWAY_STATUS="${GATEWAY_STATUS}━━━━━━━━━━━━━━━━━━━━━━━━━━━"
115
117
 
116
- # ── MCP Tool Usage Protocol (injected into every session) ──
118
+ # ── DevFlow capability declaration (injected into every session) ──
117
119
  MCP_PROTOCOL="
118
120
 
119
- ## DevFlow MCP 工具使用协议(必须遵守)
121
+ ## DevFlow MCP 使用指南
120
122
 
121
- 当用户使用 /devflow: 开头的技能时(如 /devflow:react、/devflow:vue、/devflow:context 等),你必须按以下流程操作:
123
+ 用户使用 /devflow: 技能时(如 /devflow:react、/devflow:vue、/devflow:context),推荐流程:
122
124
 
123
- ### Step 1: 获取上下文(必须先执行)
125
+ ### Step 1: 获取上下文
124
126
  调用 mcp__plugin_devflow_devflow__get_project_context,参数格式:{\"query\": \"用户的问题描述\", \"projectRoot\": \"\${CLAUDE_PROJECT_DIR}\"}
125
- 这个工具返回项目中的相关文件、符号、风险提示和下一步建议。
126
- 不要跳过这一步。不要用 Explore、Agent、Grep 或 Bash 代替。
127
+ 返回相关文件、符号、风险提示与下一步建议——通常比自行搜索更快更准。
127
128
 
128
129
  ### Step 2: 按需调用领域工具
129
130
  根据已加载 Skill 和 command registry 调用对应的 MCP 工具。以下仅为高频示例,完整能力以 /devflow 列表和 command registry 为准:
@@ -138,21 +139,21 @@ MCP_PROTOCOL="
138
139
  ### Step 3: 基于工具返回结果进行分析
139
140
  用 Read 确认工具返回的关键文件,然后给出分析结论。
140
141
 
141
- ### 铁律
142
- - 永远不要用 Explore、Agent、Grep 或 Glob 替代 MCP 工具的第一步上下文获取
142
+ ### 约定
143
143
  - Every mcp__plugin_devflow_devflow__ tool MUST pass projectRoot = \${CLAUDE_PROJECT_DIR}; missing projectRoot is rejected; no cwd fallback.
144
- - 如果 MCP 工具返回错误,重试一次;再失败则回退到直接读文件"
144
+ - MCP 工具失败时重试一次;再失败则回退直接读文件,并如实说明已降级"
145
145
 
146
146
  COMPACT_PROTOCOL="
147
147
 
148
- ## DevFlow compact protocol
149
- - Project: ${PROJECT_NAME} (${PROJECT_ROOT})
150
- - For /devflow:* tasks, call mcp__plugin_devflow_devflow__get_project_context before broad native search, then use the applicable domain MCP tool.
151
- - Explicit memory is successful only after a DevFlow canonical receipt. Queue acceptance or host-local memory is not a successful save.
148
+ ## DevFlow
149
+ You have DevFlow — project intelligence for this repo: scoped context packs, symbol and dependency search, project memory, knowledge base, and standardized workflows. /devflow lists every installed capability; /devflow:<stack> skills pair a task with the right tool. mcp__plugin_devflow_devflow__get_project_context is the fastest way to scope a task before searching.
150
+
151
+ How DevFlow reports truth (whenever you use it):
152
+ - A memory save counts only with a DevFlow canonical receipt; queue acceptance or host-local memory is not a saved memory.
152
153
  - Static findings are not runtime measurements. Do not claim observed bottlenecks, severity, or quantified benefit without evidence.
153
154
  - Workflow success requires canonical host-action and verification evidence. Never convert degraded, cancelled, failed, or unknown state into success.
154
155
  - Full versioned rules: devflow://protocol/core, devflow://protocol/memory, devflow://protocol/evidence.
155
- - Retry MCP transport failure once, then degrade truthfully to direct file inspection."
156
+ - If an MCP call fails, retry once, then fall back to direct file inspection and say so."
156
157
 
157
158
  DEVFLOW_DAEMON_REACHABLE=0
158
159
  DEVFLOW_DAEMON_LAUNCHING=0
@@ -341,13 +342,13 @@ COMPACT_SESSION_START_MODE="${DEVFLOW_ROLLOUT_COMPACT_SESSION_START:-}"
341
342
  if [ -z "$COMPACT_SESSION_START_MODE" ] && [ -f "$CONFIG_FILE" ] && command -v python3 >/dev/null 2>&1; then
342
343
  COMPACT_SESSION_START_MODE=$(python3 - "$CONFIG_FILE" 2>/dev/null <<'PY'
343
344
  import json,sys
344
- try: value=json.load(open(sys.argv[1])).get('rollout',{}).get('compactSessionStart','off')
345
- except Exception: value='off'
346
- print(value if value in ('off','shadow','on') else 'off')
345
+ try: value=json.load(open(sys.argv[1])).get('rollout',{}).get('compactSessionStart','on')
346
+ except Exception: value='on'
347
+ print(value if value in ('off','shadow','on') else 'on')
347
348
  PY
348
- ) || COMPACT_SESSION_START_MODE="off"
349
+ ) || COMPACT_SESSION_START_MODE="on"
349
350
  fi
350
- case "$COMPACT_SESSION_START_MODE" in off|shadow|on) ;; *) COMPACT_SESSION_START_MODE="off" ;; esac
351
+ case "$COMPACT_SESSION_START_MODE" in off|shadow|on) ;; *) COMPACT_SESSION_START_MODE="on" ;; esac
351
352
  if [ "${DEVFLOW_TEST_PROTOCOL_RESOURCE_FAIL:-0}" = "1" ]; then
352
353
  COMPACT_SESSION_START_MODE="off"
353
354
  fi
@@ -5,6 +5,13 @@ set -euo pipefail
5
5
  SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
6
6
  PLUGIN_ROOT="${CLAUDE_PLUGIN_ROOT:-$SCRIPT_DIR/..}"
7
7
  source "$SCRIPT_DIR/runtime-node"
8
+
9
+ # Global kill switch: exit with no opinion before spawning any runtime.
10
+ if devflow_is_disabled; then
11
+ cat >/dev/null 2>&1 || true
12
+ exit 0
13
+ fi
14
+
8
15
  DEVFLOW_NODE="$(devflow_resolve_node "$PLUGIN_ROOT")"
9
16
 
10
17
  # 1. Use the daemon as the authoritative Stop handler.
@@ -4,6 +4,13 @@ set -euo pipefail
4
4
  SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
5
5
  PLUGIN_ROOT="${CLAUDE_PLUGIN_ROOT:-$SCRIPT_DIR/..}"
6
6
  source "$SCRIPT_DIR/runtime-node"
7
+
8
+ # Global kill switch: exit with no opinion before spawning any runtime.
9
+ if devflow_is_disabled; then
10
+ cat >/dev/null 2>&1 || true
11
+ exit 0
12
+ fi
13
+
7
14
  DEVFLOW_NODE="$(devflow_resolve_node "$PLUGIN_ROOT")"
8
15
  CLIENT_JS="$PLUGIN_ROOT/dist/hooks/hook-client.js"
9
16
  FALLBACK_JS="$PLUGIN_ROOT/dist/hooks/user-prompt-submit.js"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devflow-tools/claude-code-plugin",
3
- "version": "0.18.73",
3
+ "version": "0.19.0",
4
4
  "description": "Claude Code hooks and skills for the DevFlow development intelligence runtime.",
5
5
  "type": "module",
6
6
  "scripts": {
@@ -12,17 +12,17 @@
12
12
  "verify:runtime-dependencies": "node --import tsx scripts/verify-runtime-dependencies.ts"
13
13
  },
14
14
  "dependencies": {
15
- "@devflow-tools/benchmark": "0.18.73",
16
- "@devflow-tools/context-engine": "0.18.73",
17
- "@devflow-tools/database": "0.18.73",
18
- "@devflow-tools/mcp-server": "0.18.73",
19
- "@devflow-tools/memory-engine": "0.18.73",
20
- "@devflow-tools/sdk": "0.18.73",
21
- "@devflow-tools/semantic-engine": "0.18.73",
22
- "@devflow-tools/server": "0.18.73",
23
- "@devflow-tools/task-runtime": "0.18.73",
24
- "@devflow-tools/telemetry": "0.18.73",
25
- "@devflow-tools/workflow-engine": "0.18.73"
15
+ "@devflow-tools/benchmark": "0.19.0",
16
+ "@devflow-tools/context-engine": "0.19.0",
17
+ "@devflow-tools/database": "0.19.0",
18
+ "@devflow-tools/mcp-server": "0.19.0",
19
+ "@devflow-tools/memory-engine": "0.19.0",
20
+ "@devflow-tools/sdk": "0.19.0",
21
+ "@devflow-tools/semantic-engine": "0.19.0",
22
+ "@devflow-tools/server": "0.19.0",
23
+ "@devflow-tools/task-runtime": "0.19.0",
24
+ "@devflow-tools/telemetry": "0.19.0",
25
+ "@devflow-tools/workflow-engine": "0.19.0"
26
26
  },
27
27
  "devDependencies": {
28
28
  "@devflow-tools/devflow": "0.18.65"
@@ -50,7 +50,7 @@
50
50
  "hooks",
51
51
  "skills"
52
52
  ],
53
- "gitHead": "f80c5d8fde0b5387e89cf3d38a0c533a5fbfb8c2",
53
+ "gitHead": "d4f681428ac2f83d868e152a10c85ec892afda8b",
54
54
  "license": "MIT",
55
55
  "repository": {
56
56
  "type": "git",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devflow-tools/devflow",
3
- "version": "0.18.73",
3
+ "version": "0.19.0",
4
4
  "type": "module",
5
5
  "description": "Installable DevFlow distribution containing the CLI, runtime hooks, and Claude plugin.",
6
6
  "bin": {
@@ -21,21 +21,21 @@
21
21
  },
22
22
  "dependencies": {
23
23
  "@colbymchenry/codegraph": "^1.1.1",
24
- "@devflow-tools/adapters": "0.18.73",
25
- "@devflow-tools/benchmark": "0.18.73",
26
- "@devflow-tools/context-engine": "0.18.73",
27
- "@devflow-tools/database": "0.18.73",
28
- "@devflow-tools/delivery-line": "0.18.73",
29
- "@devflow-tools/knowledge-engine": "0.18.73",
30
- "@devflow-tools/mcp-server": "0.18.73",
31
- "@devflow-tools/memory-engine": "0.18.73",
32
- "@devflow-tools/retrieval-engine": "0.18.73",
33
- "@devflow-tools/sdk": "0.18.73",
34
- "@devflow-tools/semantic-engine": "0.18.73",
35
- "@devflow-tools/server": "0.18.73",
36
- "@devflow-tools/task-runtime": "0.18.73",
37
- "@devflow-tools/telemetry": "0.18.73",
38
- "@devflow-tools/workflow-engine": "0.18.73",
24
+ "@devflow-tools/adapters": "0.19.0",
25
+ "@devflow-tools/benchmark": "0.19.0",
26
+ "@devflow-tools/context-engine": "0.19.0",
27
+ "@devflow-tools/database": "0.19.0",
28
+ "@devflow-tools/delivery-line": "0.19.0",
29
+ "@devflow-tools/knowledge-engine": "0.19.0",
30
+ "@devflow-tools/mcp-server": "0.19.0",
31
+ "@devflow-tools/memory-engine": "0.19.0",
32
+ "@devflow-tools/retrieval-engine": "0.19.0",
33
+ "@devflow-tools/sdk": "0.19.0",
34
+ "@devflow-tools/semantic-engine": "0.19.0",
35
+ "@devflow-tools/server": "0.19.0",
36
+ "@devflow-tools/task-runtime": "0.19.0",
37
+ "@devflow-tools/telemetry": "0.19.0",
38
+ "@devflow-tools/workflow-engine": "0.19.0",
39
39
  "@inquirer/prompts": "^7.10.1",
40
40
  "@modelcontextprotocol/sdk": "^1.32.1",
41
41
  "@nestjs/common": "^12.1.2",
@@ -63,7 +63,7 @@
63
63
  "plugin-registry.json",
64
64
  "scripts/postinstall.js"
65
65
  ],
66
- "gitHead": "f80c5d8fde0b5387e89cf3d38a0c533a5fbfb8c2",
66
+ "gitHead": "d4f681428ac2f83d868e152a10c85ec892afda8b",
67
67
  "license": "MIT",
68
68
  "repository": {
69
69
  "type": "git",