bugx-cli 0.1.3 → 0.1.4

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 (129) hide show
  1. package/core/README.md +5 -3
  2. package/core/assets/bugx-wechat-group.png +0 -0
  3. package/core/bugx.md +2 -2
  4. package/core/bugx_paths.py +10 -2
  5. package/core/bundled_docs/OVERVIEW.md +310 -0
  6. package/core/bundled_docs/README.md +10 -0
  7. package/core/bundled_docs/README_EN.md +278 -0
  8. package/core/bundled_docs/ai/01_AI_REFERENCE.md +833 -0
  9. package/core/bundled_docs/ai/02_AI_USAGE.md +161 -0
  10. package/core/bundled_docs/ai/03_AI_COMMANDS.md +322 -0
  11. package/core/bundled_docs/guides/01_USER_GUIDE.md +887 -0
  12. package/core/bundled_docs/guides/02_COMMANDS.md +935 -0
  13. package/core/bundled_docs/guides/03_TROUBLESHOOTING.md +763 -0
  14. package/core/bundled_docs/guides/04_CLOUD_AUTH_AND_SYNC_COOKBOOK.md +48 -0
  15. package/core/bundled_docs/guides/05_HOST_MATRIX_AND_DISPATCH.md +23 -0
  16. package/core/bundled_docs/guides/06_PROBES_AND_POC_COOKBOOK.md +49 -0
  17. package/core/bundled_docs/guides/07_LIFECYCLE_AND_RECOVERY_STATES.md +46 -0
  18. package/core/bundled_docs/guides/08_LESSONS_AND_PRIVACY_BOUNDARY.md +35 -0
  19. package/core/bundled_docs/hosts/bugx-claude_SKILL.md +326 -0
  20. package/core/bundled_docs/hosts/bugx-dsh_SKILL.md +229 -0
  21. package/core/bundled_docs/hosts/bugx-opencode_SKILL.md +129 -0
  22. package/core/bundled_docs/hosts/bugx-zcode_SKILL.md +459 -0
  23. package/core/bundled_docs/hosts/bugx_SKILL.md +118 -0
  24. package/core/bundled_docs/hosts/cline_bugx_SKILL.md +69 -0
  25. package/core/bundled_docs/hosts/platform_bugx_SKILL.md +50 -0
  26. package/core/bundled_docs/manifest.json +140 -0
  27. package/core/bundled_docs/reference/01_ENVIRONMENT_VARIABLES.md +421 -0
  28. package/core/bundled_docs/reference/04_REPOSITORY_TOPOLOGY.md +180 -0
  29. package/core/cli-help.txt +7 -3
  30. package/core/cloud_sync/cloud_client.py +81 -2
  31. package/core/cloud_sync/endpoint_router.py +22 -9
  32. package/core/cloud_sync/issue_uploader.py +297 -0
  33. package/core/cloud_sync/sensitive_filter.py +77 -7
  34. package/core/contracts/AGENT_GUIDE.md +3 -9
  35. package/core/contracts/README.md +1 -1
  36. package/core/contracts/bugx-runtime-contract.md +10 -20
  37. package/core/contracts/bugx-worker.md +1 -1
  38. package/core/engine-integrity.json +209 -93
  39. package/core/host_acp/antigravity.py +153 -0
  40. package/core/host_runtime/adapters.py +5 -1
  41. package/core/host_runtime/antigravity.py +162 -0
  42. package/core/host_runtime/host_bootstrap.py +18 -7
  43. package/core/host_runtime/host_evaluators.py +4 -4
  44. package/core/host_runtime/host_registry.py +2 -1
  45. package/core/host_runtime/mcp_process_tracker.py +30 -3
  46. package/core/host_runtime/mcp_registry_gate.py +34 -11
  47. package/core/hosts/antigravity.py +115 -0
  48. package/core/hosts/codex.py +3 -0
  49. package/core/hosts/dsh.py +42 -23
  50. package/core/hosts/minimax.py +5 -4
  51. package/core/i18n.py +94 -5
  52. package/core/infra/README.md +1 -1
  53. package/core/infra/build_info.py +2 -2
  54. package/core/launch_phases/README.md +2 -2
  55. package/core/launch_phases/startup_version_gate.py +2 -2
  56. package/core/launch_phases/supervisor_bridge.py +2 -0
  57. package/core/launch_phases/supervisor_degraded.py +7 -5
  58. package/core/ledger/README.md +1 -1
  59. package/core/locales/en-US.json +3 -3
  60. package/core/locales/zh-CN.json +3 -3
  61. package/core/mcp_runtime_support/environment.py +6 -1
  62. package/core/metadata.txt +1 -1
  63. package/core/planning/README.md +1 -1
  64. package/core/planning/prompt_harness.py +2 -2
  65. package/core/probes/codebase_memory_probe.py +43 -24
  66. package/core/probes/probe_registry.py +10 -7
  67. package/core/prompts/command_routing_en.md +6 -5
  68. package/core/prompts/command_routing_zh.md +6 -5
  69. package/core/repair/rsi_rounds.py +3 -0
  70. package/core/repair/self_heal.py +160 -6
  71. package/core/retrieval/README.md +1 -1
  72. package/core/runtime/README.md +1 -1
  73. package/core/runtime/scenario_eval.py +5 -1
  74. package/core/runtime/tool_install_targets.py +12 -2
  75. package/core/skills/README.md +4 -2
  76. package/core/skills/bugx_docs_cloud_sync.py +658 -0
  77. package/core/skills/bugx_docs_mcp_server.py +966 -140
  78. package/core/supervisor/README.md +1 -1
  79. package/core/supervisor/worker_execution.py +16 -3
  80. package/core/webui/docs_session_service.py +40 -2
  81. package/core/webui/mcp_inspector.py +6 -6
  82. package/ecosystem/integrations/cline/skills/bugx/SKILL.md +46 -46
  83. package/ecosystem/integrations/dsh/agents/bugx.md +2 -1
  84. package/ecosystem/integrations/dsh/mcp/package.json +1 -1
  85. package/ecosystem/integrations/dsh/skills/bugx/SKILL.md +5 -5
  86. package/ecosystem/integrations/dsh/ui/package.json +1 -1
  87. package/ecosystem/integrations/opencode/bugx-mcp-manifest.json +2 -2
  88. package/ecosystem/integrations/pi/extensions/bugx/manifest.json +1 -1
  89. package/ecosystem/integrations/pi/skills/bugx/SKILL.md +5 -5
  90. package/ecosystem/integrations/qoder/CONNECTORS.md +11 -23
  91. package/ecosystem/integrations/qoder/connector-meta.json +1 -1
  92. package/ecosystem/integrations/workbuddy/connector-meta.json +1 -1
  93. package/ecosystem/integrations/workbuddy/skills/bugx/SKILL.md +8 -7
  94. package/ecosystem/plugins/bugx/.claude-plugin/plugin.json +1 -1
  95. package/ecosystem/plugins/bugx/.codex-plugin/plugin.json +1 -1
  96. package/ecosystem/plugins/bugx/.zcode-plugin/plugin.json +1 -1
  97. package/ecosystem/plugins/bugx/agents/bugx-worker.md +14 -18
  98. package/ecosystem/plugins/bugx/agents/bugx.md +45 -49
  99. package/ecosystem/plugins/bugx/skills/bugx/SKILL.md +7 -7
  100. package/ecosystem/plugins/bugx/skills/bugx-zcode/SKILL.md +2 -2
  101. package/interfaces/cli/bugx_cli/__init__.py +1 -1
  102. package/interfaces/cli/bugx_cli/cli.py +138 -8
  103. package/interfaces/cli/bugx_cli/commands/agent.py +376 -69
  104. package/interfaces/cli/bugx_cli/commands/cloud.py +42 -1
  105. package/interfaces/cli/bugx_cli/commands/doctor.py +650 -223
  106. package/interfaces/cli/bugx_cli/commands/guide.py +143 -0
  107. package/interfaces/cli/bugx_cli/commands/issue.py +262 -0
  108. package/interfaces/cli/bugx_cli/commands/lifecycle.py +55 -25
  109. package/interfaces/cli/bugx_cli/commands/plugin.py +295 -54
  110. package/interfaces/cli/bugx_cli/commands/plugin_antigravity.py +350 -0
  111. package/interfaces/cli/bugx_cli/commands/plugin_claude.py +2 -2
  112. package/interfaces/cli/bugx_cli/commands/plugin_kimi.py +154 -62
  113. package/interfaces/cli/bugx_cli/commands/plugin_minimax.py +308 -108
  114. package/interfaces/cli/bugx_cli/commands/system.py +11 -1
  115. package/interfaces/cli/bugx_cli/common.py +39 -8
  116. package/interfaces/cli/bugx_cli/host_adapters.py +40 -3
  117. package/interfaces/cli/bugx_cli/hosts/registry.py +3 -2
  118. package/interfaces/cli/bugx_cli/hosts/template_engine.py +21 -2
  119. package/interfaces/cli/bugx_cli/infra/__init__.py +4 -0
  120. package/interfaces/cli/bugx_cli/infra/ai_advisor.py +14 -12
  121. package/interfaces/cli/bugx_cli/infra/engine_installer.py +76 -10
  122. package/interfaces/cli/bugx_cli/infra/host_sync.py +66 -1
  123. package/interfaces/cli/bugx_cli/infra/mcp_advisor.py +240 -50
  124. package/package.json +3 -2
  125. package/pyproject.toml +22 -2
  126. package/scripts/sync-version.mjs +1 -1
  127. package/skills/README.md +1 -2
  128. package/skills/platform/bugx/SKILL.md +50 -0
  129. package/skills/platform/bugx-user/SKILL.md +0 -92
@@ -374,6 +374,9 @@ def _is_bugx_entry(name: str, spec: Mapping[str, Any]) -> bool:
374
374
  """
375
375
 
376
376
  del name
377
+ raw_url = spec.get("url")
378
+ if isinstance(raw_url, str) and "/api/v1/mcp/docs" in raw_url:
379
+ return True
377
380
  tokens = [str(spec.get("command") or "")]
378
381
  tokens.extend(str(arg) for arg in (spec.get("args") or ()))
379
382
  return any(_BUGX_NAME_PREFIX in token.lower() for token in tokens)
package/core/hosts/dsh.py CHANGED
@@ -250,18 +250,34 @@ def _uninstall_hint() -> str:
250
250
  )
251
251
 
252
252
 
253
- def _mcp_insert_block(root: Path) -> str:
253
+ def _dynamic_mcp_args(argv: list[str]) -> list[str]:
254
+ """Strip ``--root {ROOT}`` / ``--db {ROOT}/...`` for unbound user-global overlays."""
255
+ out: list[str] = []
256
+ skip_next = False
257
+ for token in argv:
258
+ if skip_next:
259
+ skip_next = False
260
+ continue
261
+ if token == "--root":
262
+ skip_next = True
263
+ continue
264
+ if token == "--db":
265
+ skip_next = True
266
+ continue
267
+ out.append(token)
268
+ return out
269
+
270
+
271
+ def _mcp_insert_block(root: Path | None) -> str:
254
272
  """生成官方 ``dsh-mcp-client`` 的三条 stdio 条目(顶层 ``- insert:``),根绝对化。
255
273
 
256
274
  ``serverName`` 是**必填**且必须唯一(README 的 Config 表);缺它会让
257
- ``loader entries failed to apply``。
258
-
259
- 历史缺陷:这里原本写死 ``--root .``,假设 dsh 以自己的项目目录为 cwd 启动。
260
- 真机不成立——MCP server 由**长驻宿主进程** spawn,cwd 是宿主自己的目录,
261
- ``.`` 于是指向那个目录而不是被审计项目,Supervisor 在错的 ``.bugx`` 上跑并
262
- 报「缺少有效的 .bugx 项目运行布局」。根必须写成绝对路径。
275
+ ``loader entries failed to apply``。当 ``root`` 为 None 或指向用户家目录时,
276
+ 写动态工作区解析参数,禁止把用户根目录写死成 ``--root``。
263
277
  """
264
- root_str = str(Path(root).expanduser().resolve())
278
+ home_resolved = Path.home().resolve()
279
+ resolved_root = Path(root).expanduser().resolve() if root is not None else None
280
+ global_unbound = resolved_root is None or resolved_root == home_resolved
265
281
  lines = [_OVERLAY_MARKER, "- insert:"]
266
282
  for server_name, argv in _MCP_SERVERS:
267
283
  lines.extend([
@@ -273,29 +289,32 @@ def _mcp_insert_block(root: Path) -> str:
273
289
  " command: bugx",
274
290
  " args:",
275
291
  ])
276
- lines.extend(f" - '{token.replace('{ROOT}', root_str)}'" for token in argv)
292
+ if global_unbound:
293
+ for token in _dynamic_mcp_args(argv):
294
+ lines.append(f" - '{token}'")
295
+ else:
296
+ root_str = str(resolved_root)
297
+ lines.extend(f" - '{token.replace('{ROOT}', root_str)}'" for token in argv)
277
298
  return "\n".join(lines) + "\n"
278
299
 
279
300
 
280
- def _bootstrap(root: Path, servers) -> dict:
281
- """把三条 BugX MCP 通道写进用户级 profile patch(幂等、根绝对化)。
282
-
283
- dsh 没有项目级配置层:实测 ``dsh --profile headless --dump-config`` 里项目级
284
- ``.dsh/patch.yml`` 与 ``.dsh/mcp.json`` 零命中,真正被 compose 的是
285
- ``$DSH_HOME/profiles/<profile>/cordis.patch.yml``。
286
-
287
- ``root`` 必须真正参与写入(条目里的 ``--root``/``--db`` 要绝对化到本项目);
288
- 并且这里**不能**用「命中就跳过」的幂等:那会让换了项目的用户永远停留在旧根,
289
- Supervisor 于是继续在错的 ``.bugx`` 上跑。已存在的自有 overlay(以
290
- :data:`_OVERLAY_MARKER` 开头、第二行为顶层 ``- insert:``)由引擎全权拥有,
291
- 直接按本次根重写;他人的块逐字保留。
292
- """
301
+ def _bootstrap(root: Path | None, servers) -> dict:
302
+ """把三条 BugX MCP 通道写进用户级 profile patch(幂等、根绝对化)。"""
293
303
  del servers
294
304
  path = _profile_patch_path()
295
305
  path.parent.mkdir(parents=True, exist_ok=True)
296
306
  existing = path.read_text(encoding="utf-8") if path.is_file() else ""
297
- block = _mcp_insert_block(root)
307
+ home_resolved = Path.home().resolve()
308
+ resolved_root = Path(root).expanduser().resolve() if root is not None else None
309
+ global_unbound = resolved_root is None or resolved_root == home_resolved
298
310
  owned = _owned_overlay_span(existing)
311
+ if global_unbound and owned is not None:
312
+ existing_block = existing[owned[0]:owned[1]]
313
+ home_marker = f"'{home_resolved}'"
314
+ if home_marker not in existing_block and "--root" in existing_block:
315
+ # 用户级安装不覆写已有的具体项目绑定。
316
+ return {"path": str(path), "changed": False, "inserted": False}
317
+ block = _mcp_insert_block(root)
299
318
  if owned is not None:
300
319
  begin, finish = owned
301
320
  if existing[begin:finish].rstrip("\n") == block.rstrip("\n"):
@@ -1,13 +1,14 @@
1
1
  #!/usr/bin/env python3
2
2
  """core/hosts/minimax.py - MiniMax Code desktop Plugin V1 host.
3
3
 
4
- Facts captured from the installed MiniMax Code 3.1.0 package on Windows and its
4
+ Facts captured from the installed MiniMax Code 3.1.17 package on Windows and its
5
5
  embedded local-plugin-v1 contract:
6
6
 
7
7
  * user plugins are discovered below ~/.minimax/plugins/<plugin>/;
8
8
  * the package manifest is .minimax-plugin/plugin.json;
9
9
  * MCP servers are declared in servers.mcp.json;
10
- * plugin Agents are Markdown files under agents/ and Skills under skills/.
10
+ * plugin subagents are Markdown files under agents/ and Skills under skills/;
11
+ * the Agents roster uses ~/.minimax/agents/<name>/agent.md for Custom Agents.
11
12
 
12
13
  The desktop package exposes the PluginSystem/MCP/Agent surface, but this
13
14
  repository has not verified a MiniMax Code headless or standard ACP entry point.
@@ -125,7 +126,7 @@ def _mcp_config_paths(_root: Path) -> tuple[Path, ...]:
125
126
 
126
127
 
127
128
  def _agent_config_path(_root: Path) -> Path:
128
- return _minimax_plugin_root() / ".minimax-plugin" / "plugin.json"
129
+ return _minimax_data_dir() / "agents" / "bugx" / "agent.md"
129
130
 
130
131
 
131
132
  def _resolve_minimax_cli() -> str | None:
@@ -230,7 +231,7 @@ def run_static_degraded(root: Path | None = None) -> dict:
230
231
  "aliases": list(PLUGIN.identity.aliases),
231
232
  "markers": list(PLUGIN.identity.markers),
232
233
  },
233
- "agent_entry": str(plugin_root / "agents" / "bugx.md"),
234
+ "agent_entry": str(_agent_config_path(root or Path.cwd())),
234
235
  "worker_entry": str(plugin_root / "agents" / "bugx-worker.md"),
235
236
  "plugin_manifest": str(manifest),
236
237
  "mcp_config": str(plugin_root / "servers.mcp.json"),
package/core/i18n.py CHANGED
@@ -11,6 +11,8 @@ from __future__ import annotations
11
11
  from dataclasses import dataclass
12
12
  import json
13
13
  import os
14
+ import re
15
+ import sys
14
16
  from functools import lru_cache
15
17
  from pathlib import Path
16
18
  from typing import Any, Mapping
@@ -38,12 +40,22 @@ class LocaleResolution:
38
40
  }
39
41
 
40
42
 
43
+ def _is_neutral_locale(raw: str) -> bool:
44
+ """Check if raw locale string represents a neutral POSIX placeholder (e.g. C, POSIX, C.UTF-8)."""
45
+ if not isinstance(raw, str):
46
+ return False
47
+ stripped = raw.strip()
48
+ if not stripped:
49
+ return False
50
+ token = stripped.split(".", 1)[0].split("@", 1)[0].replace("_", "-").casefold()
51
+ return token in {"c", "posix"}
52
+
53
+
41
54
  def normalize_locale(value: object) -> str | None:
42
55
  """Normalize a BCP-47/POSIX-ish locale to a supported locale.
43
56
 
44
- ``None`` means the input is not supported. ``C``/``POSIX`` are treated as
45
- the conventional English process locale, while arbitrary languages are not
46
- silently mistaken for Chinese.
57
+ ``None`` means the input is not supported or is neutral (e.g. C/POSIX).
58
+ Explicit English and Chinese locales map to ``en-US`` and ``zh-CN`` respectively.
47
59
  """
48
60
  if not isinstance(value, str):
49
61
  return None
@@ -56,7 +68,7 @@ def normalize_locale(value: object) -> str | None:
56
68
  if not parts:
57
69
  return None
58
70
  primary = parts[0].casefold()
59
- if primary in {"c", "posix", "en", "eng"}:
71
+ if primary in {"en", "eng"}:
60
72
  return "en-US"
61
73
  if primary in {"zh", "chi", "zho"}:
62
74
  # The first release intentionally has one Chinese regional catalog.
@@ -82,6 +94,71 @@ def _read_preference(path: Path) -> str | None:
82
94
  return None
83
95
 
84
96
 
97
+ def _detect_system_locale() -> LocaleResolution | None:
98
+ """Detect display locale from OS native system preferences (macOS, system, timezone)."""
99
+ # 1. macOS (darwin)
100
+ if sys.platform == "darwin":
101
+ # Fast path: read ~/Library/Preferences/.GlobalPreferences.plist (~2ms via plistlib)
102
+ try:
103
+ plist_path = Path.home() / "Library" / "Preferences" / ".GlobalPreferences.plist"
104
+ if plist_path.is_file() and not plist_path.is_symlink():
105
+ import plistlib
106
+ with plist_path.open("rb") as f:
107
+ prefs = plistlib.load(f)
108
+ languages = prefs.get("AppleLanguages")
109
+ if isinstance(languages, (list, tuple)) and languages:
110
+ for lang in languages:
111
+ if isinstance(lang, str):
112
+ resolved = normalize_locale(lang)
113
+ if resolved:
114
+ return LocaleResolution(lang, resolved, "system-preference")
115
+ apple_locale = prefs.get("AppleLocale")
116
+ if isinstance(apple_locale, str) and apple_locale:
117
+ resolved = normalize_locale(apple_locale)
118
+ if resolved:
119
+ return LocaleResolution(apple_locale, resolved, "system-preference")
120
+ except Exception:
121
+ pass
122
+
123
+ # Subprocess fallback for macOS if plist direct read failed
124
+ try:
125
+ import subprocess
126
+ out = subprocess.check_output(
127
+ ["defaults", "read", "-g", "AppleLanguages"],
128
+ text=True, stderr=subprocess.DEVNULL, timeout=1,
129
+ )
130
+ for m in re.finditer(r'"([^"]+)"', out):
131
+ lang = m.group(1).strip()
132
+ resolved = normalize_locale(lang)
133
+ if resolved:
134
+ return LocaleResolution(lang, resolved, "system-preference")
135
+ except Exception:
136
+ pass
137
+
138
+ # 2. Python locale.getlocale() (for non-darwin or fallback)
139
+ try:
140
+ import locale as py_locale
141
+ loc = py_locale.getlocale()[0]
142
+ if loc and not _is_neutral_locale(loc):
143
+ resolved = normalize_locale(loc)
144
+ if resolved:
145
+ return LocaleResolution(loc, resolved, "system-locale")
146
+ except Exception:
147
+ pass
148
+
149
+ # 3. Timezone heuristic (East Asia / China UTC+8)
150
+ try:
151
+ import time
152
+ offset_hours = -time.timezone // 3600
153
+ tz_names = tuple(name.upper() for name in time.tzname)
154
+ if offset_hours == 8 and any(name in {"CST", "CHINA", "BEIJING", "SHANGHAI", "HKT", "CST-8"} for name in tz_names):
155
+ return LocaleResolution("zh-CN", "zh-CN", "timezone-hint")
156
+ except Exception:
157
+ pass
158
+
159
+ return None
160
+
161
+
85
162
  def resolve_locale(
86
163
  *,
87
164
  environ: Mapping[str, str] | None = None,
@@ -122,10 +199,14 @@ def resolve_locale(
122
199
  f"unsupported locale: {requested}",
123
200
  )
124
201
 
202
+ saw_neutral = False
125
203
  for key in _ENV_KEYS:
126
204
  raw = env.get(key, "").strip()
127
205
  if not raw:
128
206
  continue
207
+ if _is_neutral_locale(raw):
208
+ saw_neutral = True
209
+ continue
129
210
  resolved = normalize_locale(raw)
130
211
  if resolved:
131
212
  return LocaleResolution(raw, resolved, key)
@@ -133,7 +214,15 @@ def resolve_locale(
133
214
  raw, DEFAULT_LOCALE, key,
134
215
  f"unsupported locale: {raw}",
135
216
  )
136
- return LocaleResolution(None, DEFAULT_LOCALE, "default")
217
+
218
+ # 4. OS native preference detection (macOS AppleLanguages, system locale, timezone)
219
+ if environ is None:
220
+ detected = _detect_system_locale()
221
+ if detected is not None:
222
+ return detected
223
+
224
+ fallback_reason = "neutral locale: C/POSIX" if saw_neutral else None
225
+ return LocaleResolution(None, DEFAULT_LOCALE, "default", fallback_reason)
137
226
 
138
227
 
139
228
  def _catalog_path(locale: str) -> Path:
@@ -1,6 +1,6 @@
1
1
  # BugX Core Infrastructure & Primitives (核心基础设施与底层操作系统原语子系统)
2
2
 
3
- > **版本契约**: `0.1.2` | **所属分层**: `Layer 0: 基础设施与操作系统抽象`
3
+ > **版本契约**: `0.1.4` | **所属分层**: `Layer 0: 基础设施与操作系统抽象`
4
4
  > **工程规范**: 参见 [`docs/02_architecture/05_ARCH_NOMENCLATURE_GUIDE.md`](../../docs/02_architecture/05_ARCH_NOMENCLATURE_GUIDE.md) 与 [`docs/02_architecture/06_MODULE_GOVERNANCE_SPEC.md`](../../docs/02_architecture/06_MODULE_GOVERNANCE_SPEC.md)
5
5
  > **守卫机制**: `scripts/verify_directory_indices.py` (100% 物理条目索引覆盖)
6
6
 
@@ -12,8 +12,8 @@ import re
12
12
  from pathlib import Path
13
13
 
14
14
  VERSION_ENV = "BUGX_VERSION"
15
- VERSION_TOKEN = "0.1.3"
16
- _DEFAULT_VERSION = "0.1.3"
15
+ VERSION_TOKEN = "0.1.4"
16
+ _DEFAULT_VERSION = "0.1.4"
17
17
  _VERSION_RE = re.compile(r"^\d+\.\d+\.\d+(?:[-+][0-9A-Za-z.-]+)?$")
18
18
 
19
19
 
@@ -91,7 +91,7 @@ flowchart TD
91
91
  | `startup_gates.py` | 启动前置安全门禁(文件树白名单、脏工作区检查、权限拦截) | `verify_startup_gates` |
92
92
  | `startup_interaction.py` | 交互式问答决策引擎,根据终端能力与配置解析交互模式 | `resolve_startup_interaction` |
93
93
  | `verify_loop.py` | 独立验证员盲审输入包构造、Anti-Gaming 校验与报错驱动 PoC 自纠错闭环 | `build_verify_bundle`, `execute_verify_attempt`, `run_verification_loop` |
94
- | `startup_version_gate.py` | 版本硬门禁校验器,确保运行时版本严格等于 `0.1.2` 绝不漂移 | `assert_version_integrity` |
94
+ | `startup_version_gate.py` | 版本硬门禁校验器,确保运行时版本严格等于 `0.1.4` 绝不漂移 | `assert_version_integrity` |
95
95
  | `supervisor_bridge.py` | Supervisor 模块间解耦桥接层,提供轻量化调用门面 | `SupervisorBridge` |
96
96
  | `supervisor_coverage.py` | 覆盖率生命周期继承器,支持空闲历史会话继承与动态分发 | `SupervisorCoverageSync` |
97
97
  | `supervisor_degraded.py` | 降级容灾与探针就地自愈控制器,无损处理缺失依赖与环境 | `SupervisorDegradedCoordinator` |
@@ -103,7 +103,7 @@ flowchart TD
103
103
 
104
104
  ## 3. 核心设计契约与公理 (Design Axioms)
105
105
 
106
- 1. **版本绝对固化公理**:`startup_version_gate.py` 必须在任何业务逻辑启动前执行,基线版本严格锁定在 `0.1.2`,杜绝任何环境版本漂移。
106
+ 1. **版本绝对固化公理**:`startup_version_gate.py` 必须在任何业务逻辑启动前执行,基线版本严格锁定在 `0.1.4`,杜绝任何环境版本漂移。
107
107
  2. **状态机单向流转与幂等性**:生命周期从 `Pre` $\rightarrow$ `Round` $\rightarrow$ `Worker` $\rightarrow$ `Judge` $\rightarrow$ `Settlement` $\rightarrow$ `Post` 严格单向流动,禁止逆流操作;重试必须走显式的轮次迭代(`advance_round_lifecycle`)。
108
108
  3. **证据零伪造公理**:在 `findings_adjudication.py` 与 `candidate_revalidation.py` 中,所有缺陷判定必须有可执行的反事实测试证据,严禁仅凭模型推理文本定性。
109
109
  4. **工作树物理安全红线**:`post_dry_run.py` 与 `post_commit.py` 严格遵守工作树保护宪法,未授权时绝对禁止覆盖用户未暂存的修改。
@@ -240,8 +240,8 @@ def version_marker(path: Path) -> str | None:
240
240
  if not match:
241
241
  return None
242
242
  value = match.group(1)
243
- if value == "0.1.3":
244
- value = os.environ.get("BUGX_VERSION", "0.1.3")
243
+ if value == "0.1.4":
244
+ value = os.environ.get("BUGX_VERSION", "0.1.4")
245
245
  return value
246
246
 
247
247
  def startup_release_version(value: object) -> tuple[int, int, int] | None:
@@ -992,6 +992,8 @@ def host_entry_gate() -> int:
992
992
  print(f"[launch_bugx] ✗ 宿主入口就绪性检查失败({type(exc).__name__}):{exc}")
993
993
  return RESTART_REQUIRED
994
994
  if status.get("ready"):
995
+ for warning in status.get("warnings") or []:
996
+ print(f"[launch_bugx] ⚠ {warning}")
995
997
  return 0
996
998
  print("[launch_bugx] ✗ 需要重启宿主:宿主侧入口(MCP + skill)未就绪——"
997
999
  + str(status.get("reason") or "未知原因"))
@@ -185,11 +185,13 @@ def degraded_item_transient(item: Mapping[str, Any]) -> bool:
185
185
 
186
186
 
187
187
  def degraded_item_critical(item: Mapping[str, Any]) -> bool:
188
- """能力是否 critical:以描述符机器声明为准,缺失时才回落到 ``kind=mcp`` 猜测。"""
188
+ """能力是否 critical:codebase-memory 为必装核心能力,其余以描述符或 mcp 判定。"""
189
+ name = str(item.get("name", "")).casefold()
190
+ if "codebase-memory" in name or "tree-sitter" in name:
191
+ return True
189
192
  declared = item.get("critical")
190
193
  if isinstance(declared, bool):
191
194
  return declared
192
- name = str(item.get("name", "")).casefold()
193
195
  return bool(item.get("kind") == "mcp" or "mcp" in name)
194
196
 
195
197
 
@@ -370,12 +372,12 @@ def auto_provision_accelerators(
370
372
  if isinstance(probe_report, dict) else "invalid-report"
371
373
  )
372
374
  print(
373
- f"[launch_bugx] Codebase Memory 复核未 READY({failed}),保留降级选项"
375
+ f"[launch_bugx] Codebase Memory 必装组件未 READY({failed}),将阻断放行"
374
376
  )
375
377
  except Exception as exc:
376
378
  print(
377
- "[launch_bugx] Codebase Memory 自愈/复核异常 "
378
- f"({type(exc).__name__}),保留降级选项"
379
+ "[launch_bugx] Codebase Memory 必装组件自愈/复核异常 "
380
+ f"({type(exc).__name__}),将阻断放行"
379
381
  )
380
382
 
381
383
  # 2. bugx-supervisor / 宿主 MCP 自动就地配置注入
@@ -1,6 +1,6 @@
1
1
  # BugX Ledger (攻防复盘账本与错题经验库)
2
2
 
3
- > **版本契约**: `0.1.2` | **所属分层**: `Layer 3: 并发协调、智能体编排与账本`
3
+ > **版本契约**: `0.1.4` | **所属分层**: `Layer 3: 并发协调、智能体编排与账本`
4
4
  > **工程规范**: 参见 [`docs/02_architecture/05_ARCH_NOMENCLATURE_GUIDE.md`](../../docs/02_architecture/05_ARCH_NOMENCLATURE_GUIDE.md)
5
5
  > **守卫机制**: `scripts/verify_directory_indices.py` (100% 物理条目索引覆盖)
6
6
 
@@ -415,8 +415,8 @@
415
415
  "prompt.tier.default.description": "General default model",
416
416
  "prompt.tier.explore.description": "High-throughput scanning model (Flash / Haiku / GPT-4o-mini), for large-scale unit and route exploration",
417
417
  "prompt.tier.gate.description": "Fast lightweight model (Flash / Haiku / GPT-4o-mini), for fast gates and baseline checks",
418
- "prompt.tier.mutate.description": "Deep reasoning model (Sonnet / DeepSeek-R1 / GPT-4o), for concurrency race, state simulation, and differential testing",
419
- "prompt.tier.repair.description": "High-precision code engineering model (Claude 3.5 Sonnet / Codex), for minimal TDD fix and unit test closure",
418
+ "prompt.tier.mutate.description": "Deep reasoning model (Claude Sonnet 5.5 / Gemini 4 Carbon / DeepSeek-R1 / GPT-4o), for concurrency race, state simulation, and differential testing",
419
+ "prompt.tier.repair.description": "High-precision code engineering model (Claude Sonnet 5.5 / Opus 5.5 / Codex), for minimal TDD fix and unit test closure",
420
420
  "prompt.workers.shared_instruction_body": "You are a BugX concurrent worker. The host has already atomically claimed the coverage unit(s) below; do not claim again.\n1. Resolve the global script with `bugx engine path --name audit_supervisor.py`, then confirm actual start (returned execution_id must stay unchanged; copy the preoccupied value verbatim, omit it when unconfirmed, and never generate/replace it):\n <Python> <global-engine>/audit_supervisor.py worker-start --root . \\\n --state {state_rel} --worker <claimed worker_id> --provider <provider>\n2. Complete exploration → test → evidence verification for assigned units; write all evidence to artifact_root returned by claim. Each coverage unit must have its own unique artifact file; never overwrite or modify it after submitting its checkpoint.\n Modifying shared source without host-provided git worktree is prohibited; fixes are performed serially by host;\n Do not write shared runtime, do not write life, do not run verify_life.py settle, do not generate final report.\n3. Submit checkpoint (life_delta must be JSON number 0, never string \\\"0\\\"; artifact_path must reside in own artifact_root):\n <Python> <global-engine>/audit_supervisor.py checkpoint --root . \\\n --state {state_rel} --worker <claimed worker_id> --input <payload.json>\n payload.json must contain unique and retryable checkpoint_id covering all claimed units. expected_revision may be included only when returned by the immediately preceding MCP response; otherwise omit it and never guess 0/1.\n coverage=covered is a coverage state; evidence.status must be passed with exit_code=0. Other evidence.status values are only failed/error/skipped/blocked; never put covered in evidence.status. Each candidate finding's evidence must be a list of objects `[{{\"path\": \"<relative_path>\", \"line\": <positive_int>}}]`, never a \"path:line\" string. If a finding sets `reproducible=true`, it must include a non-empty `reproduction` command or step list; otherwise do not mark it reproducible.\n4. Call bugx_supervisor_heartbeat immediately after a successful worker-start (your first liveness proof), then every <=5 minutes; before any long command (>60s probes/tests) call MCP bugx_supervisor_begin_long_call (expected_seconds<=1800, keep-alive window so the lease survives the command) before any long command (>60s probes/tests), then call bugx_supervisor_heartbeat every 5 minutes; leases will be reclaimed by host if stuck; do not treat ordinary claim as execution or call a project `.bugx/core` entry.\n4a. If a checkpoint is rejected (run_id/execution_receipt/cross-epoch), rewrite the probe output to a NEW file inside artifact_root and resubmit via the bounded finalizer (worker_checkpoint.py finalize, step 3 pattern) rebound to the current epoch; never blindly re-run probes.",
421
421
  "prompt.workers.shared_instruction_header": "【Shared Instructions】Paste the following block into each worker's Task prompt:",
422
422
  "prompt.workers.task_harness_banner": " [Active Stage Harness Injection Task Package]:",
@@ -454,7 +454,7 @@
454
454
  "host.entry.body.qoder_worker": "\n# BugX Worker — Qoder concurrent worker sub-agent\n\nYou are BugX's concurrent worker sub-agent, dispatched in parallel within a Round by the main agent through Qoder's subagent capability (`subagent_type=bugx-worker`). First read and obey the following global engine protocols via `bugx engine path --name <file>`; they are the only authoritative entities and this entry does not copy their content:\n\n- `bugx engine path --name bugx-worker.md`: worker unit-level execution rules (four start-up steps, mining discipline, case-filing oracle, hard evidence gate, checkpoint submission);\n- `bugx engine path --name bugx-runtime-contract.md` and `bugx engine path --name bugx-quick.md`: lifetime, Supervisor, evidence, and reporting protocols.\n\nThese files are provided by the global engine; do not inspect the project's `.bugx/core`. If the project lacks `.bugx/manifest.json`, stop immediately and report this to the dispatcher. The dispatcher must first run the read-only command `bugx engine --root <ROOT> status --json`; only a result of `UNINITIALIZED` permits `bugx engine --root <ROOT> pre` to safely prepare a fresh project. If the result is `FATAL_BLOCKED`, another blocked state, or the status check fails, preserve project data and stop; never bypass the gate with `bugx init`, `bugx reset`, or `--force`. After the project layout is safely prepared, the dispatcher may refresh host Worker integration from the main session if needed. A Worker never runs host-control initialization or installation commands and never executes protocol steps while the layout is missing.\n\n## Worker role boundary (mandatory)\n\n- Handle only the coverage units or affinity task bundles the Supervisor assigns to you: `claim` (skip when the host has pre-reserved) → `worker-start` → mine and produce evidence → `checkpoint`; `life_delta` must be 0, and you never write lifetime, settle accounts, produce the final report, or take units outside the list.\n- Use only the worker channel: the Supervisor MCP's `bugx-supervisor-worker` tools (claim/worker_start/tool_call/heartbeat/checkpoint), or the same-named subcommands of `audit_supervisor.py` in the global engine; never call host-control tools (start/bootstrap/next_round/bind_context/finish/fail/recover) and never run the host-control entries' `pre|post|settle`.\n- Evidence may only be written into the `artifact_root` returned by the claim; out-of-bounds paths are rejected by the Supervisor. Unless the dispatcher explicitly provides an independent git worktree, never modify shared worktree source — fixes are performed serially by the host.\n- During long commands send a heartbeat every 5 minutes; on a non-zero return or `CONTROL_PAUSED`/`CONTROL_ABORTED`, stop at a safe boundary and report the state to the dispatcher.\n\n## Qoder Worker interaction adaptation (mandatory)\n\nA worker is a sub-agent: it presents no startup gate and must not call `AskUserQuestion` — a regular start is decided automatically by project configuration and raises no serial startup questionnaire. When a user decision is truly required, end directly and report the raw `BUGX_INTERACTION_REQUEST <json>` to the dispatcher; never answer on your own or guess options. Treat the worker itself as non-TTY: forward only the current single-choice request and continue once the dispatcher returns the answer.\n",
455
455
  "plugin.zcode_plugin_boundary": "## User-level plugin boundary (plugin form only)\n\nThis entry is registered as a ZCode plugin (agent name `{agent_ref}`) and can be used across projects. Before operating on a project, run the read-only command `bugx engine --root . status --json`: only a result of `UNINITIALIZED` permits `bugx engine --root . pre` to safely prepare a fresh project. If the result is `FATAL_BLOCKED`, another blocked state, or the status check fails, preserve project data and stop; never bypass the gate with `bugx init`, `bugx reset`, or `--force`. This entry is not a substitute for the global engine payload.\n",
456
456
  "plugin.chatgpt_skill_banner": "This is the BugX ChatGPT Skill mirror. Before executing, read the global protocol via `bugx engine path --name AGENT_GUIDE.md` and `bugx engine path --name bugx.md`; the global engine is the only authoritative source for protocol and runtime.\n\nProtocol Mirror Version: {version}\n",
457
- "host.entry.section.commands": "## Host Route (before intent triage)\n\n- **ZCode host**: prefer loading the sibling `bugx-zcode` skill (ZCode-specific handbook: direct-drive path, rpc fallback, field-tested remedies). If it is not registered in the current session (newly installed skills need a host-session restart to appear), apply its core conclusions directly: after `workers` pre-claim, **drive the protocol channel from the host session** (worker MCP tools or `bugx supervisor rpc --role worker`, caller_role=worker); do not default to wrapping the worker in a subagent; `run_sandboxed_probe` must carry the current Task's lease_id/execution_id.\n- All other hosts follow the sections below.\n\n\n\n## How to Use This Skill (AI Meta-Guidance and Intent Decision Tree)\n\nWhen you (the AI) trigger and read this Skill, strictly follow this cognitive model and execution order:\n\n### 1. Intent Decision Tree\nIn the first second of receiving a task, classify which branch it belongs to:\n- **Branch A: Focused Quick Triage / Specific Function / Diff / Error Stack**\n - **Indicators**: Single-file inspection, reproducing a specific function, analyzing an exception stack trace.\n - **Action**: Write a lightweight reproduction test (PoC) or run targeted tests locally using `bugx view`, `bugx test-generate`, `bugx test-verify`; **strictly forbid starting heavy full-lifecycle gates!**\n- **Branch B: Full-Repository Vulnerability Hunting / Deep Mutation / Parallel Worker Audit**\n - **Indicators**: User explicitly triggers `/bugx`, requests \"full codebase audit\", or \"hunt deep vulnerabilities\".\n - **Action**: Follow the canonical lifecycle progression (`engine pre` -> gate confirmation -> Explore -> Mutate -> Repair -> post settlement).\n- **Branch C: Environment Diagnosis / Dependency Repair / Host Inspection**\n - **Action**: Run `bugx doctor --root <ROOT> --json` and `bugx engine --root <ROOT> status --json`; never use `init` or `--force` blindly.\n\n### 2. Standard 5-Step Execution Loop\n1. **Target Root**: Confirm the target repository's absolute path `<ROOT>`; strictly restrict operations within `<ROOT>`, and forbid broad filesystem scans.\n2. **Inspect State**: Run read-only commands to check runtime state first (`bugx engine --root <ROOT> status --json` or `bugx doctor`).\n3. **Select Route**: Pick commands based on intent; if parameters are needed, run `bugx help <top-level-cmd>` (e.g. `bugx help cloud`) to read live syntax dynamically; never guess.\n4. **Handle Gates**: If `engine pre` exits with code `2`, it signals waiting for host structured gate interaction; present options via the host's native control and execute the controlled action selected by the user. Do not fabricate choices or spin-loop. Exit code `0` confirms gate passage only, not audit completion.\n5. **Close the Loop**: Defects require standalone reproduction scripts (PoC) and call-stack evidence; report truthfully using the 6 standard status terms (read-only inspection, project ready, gate ready, test execution, mining launched, mining completed).\n\n### 3. Core Action Matrix (High-Frequency Commands Covering 90% of Calls)\n- **Environment Diagnosis**: `bugx doctor --root <ROOT> --json` (`--repair-assets` for repair)\n- **Startup and Gates**: Run `bugx engine --root <ROOT> status --json` first. Only when the status is `UNINITIALIZED`, run `bugx engine --root <ROOT> pre` to prepare a fresh project; do not run `bugx init` first when starting mining through a host plugin; it is a separate explicit CLI operation and does not replace the status/pre state machine. If the status is `FATAL_BLOCKED`, another blocked state, or the status check fails, preserve the state and stop; never use `init`, `reset`, or `--force` to bypass the gate.\n- **Reproduction and Mutation**: `bugx test-generate --root <ROOT> --scope <PATH::SYM> --out <FILE>` / `bugx test-verify verify --scope <SCOPE>`\n- **Supervisor and Concurrency**: `bugx supervisor status --root <ROOT>`\n- **Telemetry and Logs**: `bugx telemetry inspect` / `bugx log --root <ROOT> --errors`\n- **Dual Reports and Preview**: `bugx report both --eval-dir verification/evals/oss --out verification/evals/oss` / `bugx report serve --port 18991`\n\n### 4. Compact Command Radar (41 Top-level Commands Classified Index)\nTo invoke any command below, inspect exact parameters dynamically via `bugx help <cmd>`; never guess:\n- **Diagnostics and Inspection (9)**: `help`, `doctor`, `hosts`, `completion`, `log`, `stats`, `view`, `project`, `self-audit`\n- **Core Lifecycle and Hosts (14)**: `init`, `engine`, `supervisor`, `daemon`, `config`, `reset`, `install`, `uninstall`, `dsh`, `plugin`, `mcp`, `mcp-runtime`, `capability`, `logic-analysis`\n- **Deep Audit and Verification (10)**: `audit`, `probe`, `test-generate`, `test-audit`, `test-verify`, `patch-forge`, `test-strategy`, `fuzz-input`, `differential-probe`, `mining-audit`\n- **Knowledge Flywheel and Delivery (8)**: `report`, `lesson`, `knowledge`, `skill`, `cloud`, `auth`, `telemetry`, `advisory`\n\n### 5. Mandatory Rules and Deprecated Command Redirection\n- **Gate Blockage Forbids Destructive Repairs**: `FATAL_BLOCKED` must never be bypassed using `init`, `reset`, or `--force`; preserve logs and state first.\n- **Deprecated Command Redirections**: `matrix` -> `bugx audit`; `console` -> `bugx report serve`; `watch` -> `bugx log --watch`; `test` is not a public command. For development checks, create a minimal temporary verification script outside the repository or run tests owned by the target project, then delete the process file.\n",
457
+ "host.entry.section.commands": "## Host Route (before intent triage)\n\n- **ZCode host**: prefer loading the sibling `bugx-zcode` skill (ZCode-specific handbook: direct-drive path, rpc fallback, field-tested remedies). If it is not registered in the current session (newly installed skills need a host-session restart to appear), apply its core conclusions directly: after `workers` pre-claim, **drive the protocol channel from the host session** (worker MCP tools or `bugx supervisor rpc --role worker`, caller_role=worker); do not default to wrapping the worker in a subagent; `run_sandboxed_probe` must carry the current Task's lease_id/execution_id.\n- All other hosts follow the sections below.\n\n\n\n## How to Use This Skill (AI Meta-Guidance and Intent Decision Tree)\n\nWhen you (the AI) trigger and read this Skill, strictly follow this cognitive model and execution order:\n\n### 1. Intent Decision Tree\nIn the first second of receiving a task, classify which branch it belongs to:\n- **Branch A: Focused Quick Triage / Specific Function / Diff / Error Stack**\n - **Indicators**: Single-file inspection, reproducing a specific function, analyzing an exception stack trace.\n - **Action**: Write a lightweight reproduction test (PoC) or run targeted tests locally using `bugx view`, `bugx test-generate`, `bugx test-verify`; **strictly forbid starting heavy full-lifecycle gates!**\n- **Branch B: Full-Repository Vulnerability Hunting / Deep Mutation / Parallel Worker Audit**\n - **Indicators**: User explicitly triggers `/bugx`, requests \"full codebase audit\", or \"hunt deep vulnerabilities\".\n - **Action**: Follow the canonical lifecycle progression (`engine pre` -> gate confirmation -> Explore -> Mutate -> Repair -> post settlement).\n- **Branch C: Environment Diagnosis / Dependency Repair / Host Inspection**\n - **Action**: Run `bugx doctor --root <ROOT> --json` and `bugx engine --root <ROOT> status --json`; never use `init` or `--force` blindly.\n\n### 2. Standard 5-Step Execution Loop\n1. **Target Root**: Confirm the target repository's absolute path `<ROOT>`; strictly restrict operations within `<ROOT>`, and forbid broad filesystem scans.\n2. **Inspect State**: Run read-only commands to check runtime state first (`bugx engine --root <ROOT> status --json` or `bugx doctor`).\n3. **Select Route**: Pick commands based on intent; if parameters are needed, run `bugx help <top-level-cmd>` (e.g. `bugx help cloud`) to read live syntax dynamically; never guess.\n4. **Handle Gates**: If `engine pre` exits with code `2`, it signals waiting for host structured gate interaction; present options via the host's native control and execute the controlled action selected by the user. Do not fabricate choices or spin-loop. Exit code `0` confirms gate passage only, not audit completion.\n5. **Close the Loop**: Defects require standalone reproduction scripts (PoC) and call-stack evidence; report truthfully using the 6 standard status terms (read-only inspection, project ready, gate ready, test execution, mining launched, mining completed).\n\n### 3. Core Action Matrix (High-Frequency Commands Covering 90% of Calls)\n- **Live Guide Lookup**: `bugx guide \"<keyword>\"` (queries synced official docs and project docs; pass `--offline` for airgap environments)\n- **Environment Diagnosis**: `bugx doctor --root <ROOT> --json` (`--repair-assets` for repair)\n- **Startup and Gates**: Run `bugx engine --root <ROOT> status --json` first. Only when the status is `UNINITIALIZED`, run `bugx engine --root <ROOT> pre` to prepare a fresh project; do not run `bugx init` first when starting mining through a host plugin; it is a separate explicit CLI operation and does not replace the status/pre state machine. If the status is `FATAL_BLOCKED`, another blocked state, or the status check fails, preserve the state and stop; never use `init`, `reset`, or `--force` to bypass the gate.\n- **Reproduction and Mutation**: `bugx test-generate --root <ROOT> --scope <PATH::SYM> --out <FILE>` / `bugx test-verify verify --scope <SCOPE>`\n- **Supervisor and Concurrency**: `bugx supervisor status --root <ROOT>`\n- **Telemetry and Logs**: `bugx telemetry inspect` / `bugx log --root <ROOT> --errors`\n- **Dual Reports and Preview**: `bugx report both --eval-dir verification/evals/oss --out verification/evals/oss` / `bugx report serve --port 18991`\n\n### 4. Compact Command Radar (43 Top-level Commands Classified Index)\nTo invoke any command below, inspect exact parameters dynamically via `bugx help <cmd>`; never guess:\n- **Diagnostics and Inspection (10)**: `help`, `completion`, `guide`, `hosts`, `doctor`, `log`, `stats`, `view`, `project`, `self-audit`\n- **Core Lifecycle and Hosts (15)**: `init`, `install`, `reset`, `uninstall`, `dsh`, `engine`, `supervisor`, `daemon`, `config`, `plugin`, `mcp`, `capability`, `mcp-runtime`, `update`, `interaction`\n- **Deep Audit and Verification (10)**: `audit`, `probe`, `logic-analysis`, `mining-audit`, `test-generate`, `test-audit`, `test-verify`, `patch-forge`, `autonomous`, `goal`\n- **Cloud, Knowledge, and Delivery (8)**: `cloud`, `auth`, `telemetry`, `knowledge`, `lesson`, `skill`, `advisory`, `report`\n\n### 5. Mandatory Rules and Deprecated Command Redirection\n- **Gate Blockage Forbids Destructive Repairs**: `FATAL_BLOCKED` must never be bypassed using `init`, `reset`, or `--force`; preserve logs and state first.\n- **Deprecated Command Redirections**: `matrix` -> `bugx audit`; `console` -> `bugx report serve`; `watch` -> `bugx log --watch`; `test` is not a public command. For development checks, create a minimal temporary verification script outside the repository or run tests owned by the target project, then delete the process file.\n",
458
458
  "host.entry.description.codex": "Codex-specific BugX operation Skill for starting, resuming and diagnosing BugX audits and reviewing local model and token usage. Preserve the complete Agent workflow, native user gates and evidence validation while dispatching native Workers for the actual project scope.",
459
459
  "prompt.plugin.chatgpt_shared_skill_write_failed": "Shared global Skill write failed (plugin registration unaffected): {error}",
460
460
  "exception.plugin.claude_usage_skill_missing": "Claude host manual skill is missing; installation cannot complete: {path}\nThis file is a mandatory load listed in bugx/SKILL.md, not an optional add-on.\nFix: ensure ecosystem/plugins/bugx/skills/bugx-claude/SKILL.md is tracked by git, then rebuild the wheel."
@@ -415,8 +415,8 @@
415
415
  "prompt.tier.default.description": "通用默认模型",
416
416
  "prompt.tier.explore.description": "高吞吐扫描模型 (Flash / Haiku / GPT-4o-mini),适用于大规模单元与路由勘察",
417
417
  "prompt.tier.gate.description": "快速轻量级模型 (Flash / Haiku / GPT-4o-mini),适用于快速门禁与基线核验",
418
- "prompt.tier.mutate.description": "深度推理模型 (Sonnet / DeepSeek-R1 / GPT-4o),适用于并发竞态、状态推演与差分验证",
419
- "prompt.tier.repair.description": "高精度工程代码模型 (Claude 3.5 Sonnet / Codex),适用于 TDD 最小修复与单测闭环",
418
+ "prompt.tier.mutate.description": "深度推理模型 (Claude Sonnet 5.5 / Gemini 4 Carbon / DeepSeek-R1 / GPT-4o),适用于并发竞态、状态推演与差分验证",
419
+ "prompt.tier.repair.description": "高精度工程代码模型 (Claude Sonnet 5.5 / Opus 5.5 / Codex),适用于 TDD 最小修复与单测闭环",
420
420
  "prompt.workers.shared_instruction_body": "你是 BugX 并发 worker。宿主已经原子预占了下面给你的 coverage unit(s);不要再次 claim。\n1. 先通过 `bugx engine path --name audit_supervisor.py` 定位全局脚本,再确认真实启动(返回的 execution_id 必须保持不变;只能逐字复制预占值,无法确认时省略,禁止生成/替换):\n <Python> <全局引擎>/audit_supervisor.py worker-start --root . \\\n --state {state_rel} --worker <预占 worker_id> --provider <provider>\n2. 对分配单元完成勘察 → 测试 → 证据复验;所有证据写入预占 claim 返回的 artifact_root。每个 coverage unit 必须使用独立且唯一的 artifact 文件;提交 checkpoint 后不得覆盖或修改。\n 没有宿主提供的独立 git worktree 时禁止修改共享源码,修复由宿主串行完成;\n 不写共享运行态、不写 life、不跑 verify_life.py settle、不生成最终报告。\n3. 提交 checkpoint(JSON 中 life_delta 必须是数字 0,不能写成字符串 \\\"0\\\";artifact_path 必须位于自己的 artifact_root):\n <Python> <全局引擎>/audit_supervisor.py checkpoint --root . \\\n --state {state_rel} --worker <预占 worker_id> --input <payload.json>\n payload.json 必须包含本次提交唯一且可重试的 checkpoint_id,覆盖所有领取的 units。expected_revision 只有在同一 MCP 响应刚返回该值时才能原样带上;否则省略,禁止猜测 0/1。\n coverage=covered 表示覆盖状态;evidence.status 必须填 passed(且 exit_code=0),其他证据状态只能是 failed/error/skipped/blocked,不能填 covered。每个 candidate finding 的 evidence 必须是对象列表 `[{{\"path\": \"<相对路径>\", \"line\": <正整数行号>}}]`,严禁写成 `path:line` 字符串。候选 finding 若 `reproducible=true`,必须同时填写非空 `reproduction`,内容应是可复现命令或步骤;没有复现步骤就不要标记为可复现。\n4. worker-start 成功后立即调用一次 bugx_supervisor_heartbeat(这是启动后的首个活性证明),此后每 ≤5 分钟一次;长命令(预计 >60s 的探针/测试)开始前先调用 bugx_supervisor_begin_long_call(expected_seconds≤1800,声明保活窗口防止租约在命令执行中被回收),窗口结束后每 5 分钟调用 bugx_supervisor_heartbeat;卡住由宿主回收租约,不要把普通 claim 当成真实执行,也不要调用项目 `.bugx/core` 入口。\n4a. checkpoint 被拒(run_id/execution_receipt/跨纪元证据)时,把探针输出重写到 artifact_root 下的新文件,再用步骤 3 的收尾器(worker_checkpoint.py finalize)按当前纪元重建合规 checkpoint,勿盲目重跑探针。",
421
421
  "prompt.workers.shared_instruction_header": "【共享指令】把下面这段粘进每个 worker 的 Task 提示词:",
422
422
  "prompt.workers.task_harness_banner": " [主动注入 Stage Harness 任务包]:",
@@ -454,7 +454,7 @@
454
454
  "host.entry.body.qoder_worker": "\n# BugX Worker — Qoder 并发 Worker 子智能体\n\n你是 BugX 的并发 worker 子智能体,由主 Agent 通过 Qoder 的 subagent 能力(`subagent_type=bugx-worker`)在 Round 内并发派发。先通过 `bugx engine path --name <文件>` 读取并遵守以下全局引擎协议;它们是唯一权威实体,本入口不复制其内容:\n\n- `bugx engine path --name bugx-worker.md`:worker 单元级执行规则(开工四步、挖掘纪律、立案 oracle、证据硬门槛、checkpoint 提交);\n- `bugx engine path --name bugx-runtime-contract.md` 与 `bugx engine path --name bugx-quick.md`:寿命、Supervisor、证据和报告协议。\n\n上述文件由全局引擎提供,不检查项目 `.bugx/core`。若项目缺少 `.bugx/manifest.json`,立即停止并将事实报告给派发方。派发方必须先运行只读命令 `bugx engine --root <ROOT> status --json`:只有结果为 `UNINITIALIZED` 时才运行 `bugx engine --root <ROOT> pre` 安全准备新项目;若为 `FATAL_BLOCKED`、其他阻断状态或检查失败,保留项目数据并停止,不得用 `bugx init`、`bugx reset` 或 `--force` 绕过。项目布局准备完成后,如需刷新宿主 Worker 集成,由派发方在主会话中执行;Worker 不运行主控初始化或安装命令,也不在布局缺失时执行协议步骤。\n\n## Worker 角色边界(强制)\n\n- 只负责 Supervisor 分配给你的覆盖单元或亲和任务包:`claim`(宿主已预占时跳过)→ `worker-start` → 挖掘举证 → `checkpoint`;`life_delta` 必须为 0,不写寿命、不结算、不生成最终报告、不领取清单外的单元。\n- 只能使用 worker 通道:Supervisor MCP 的 `bugx-supervisor-worker` 工具(claim/worker_start/tool_call/heartbeat/checkpoint),或全局引擎中的 `audit_supervisor.py` 的同名子命令;不得调用宿主控制工具(start/bootstrap/next_round/bind_context/finish/fail/recover),不得执行宿主控制入口的 `pre|post|settle`。\n- 证据只能写入 claim 返回的 `artifact_root`,越界路径会被 Supervisor 拒绝;没有派发方明确提供独立 git worktree 时,不得修改共享工作树源码,修复由宿主串行完成。\n- 长命令期间每 5 分钟补一次 heartbeat;返回非零或 `CONTROL_PAUSED`/`CONTROL_ABORTED` 时,停在安全边界并把状态报告给派发方。\n\n## Qoder Worker 交互适配(强制)\n\nWorker 是子智能体,不呈现任何启动门禁,也不得调用 `AskUserQuestion`——常规启动由项目配置自动决策,不发起串行启动问卷。确需用户决策时,直接结束并把 `BUGX_INTERACTION_REQUEST <json>` 原文报告给派发方,不得自行作答或猜选项。Worker 自身按非 TTY 处理:只转发当前一个单选请求,答案由派发方回传后再继续。\n",
455
455
  "plugin.zcode_plugin_boundary": "## 用户级插件边界(插件形态专用)\n\n本入口以 ZCode 插件(agent 命名 `{agent_ref}`)注册,可跨项目使用。操作项目前先运行只读命令 `bugx engine --root . status --json`:仅当返回 `UNINITIALIZED` 时,才运行 `bugx engine --root . pre` 安全准备新项目;返回 `FATAL_BLOCKED`、其他阻断状态或检查失败时,保留数据并停止,严禁用 `bugx init`、`bugx reset` 或 `--force` 绕过。本入口不能替代全局引擎载荷。\n",
456
456
  "plugin.chatgpt_skill_banner": "这是 BugX 的 ChatGPT Skill 镜像。执行前通过 `bugx engine path --name AGENT_GUIDE.md` 和 `bugx engine path --name bugx.md` 读取全局协议;全局引擎是协议和运行时的唯一权威来源。\n\n协议镜像版本:{version}\n",
457
- "host.entry.section.commands": "## 宿主路由(先于意图分流)\n\n- **ZCode 宿主**:优先加载同插件 `bugx-zcode` skill(ZCode 专属手册:直驱路径、rpc 回退、坑位对策)。若当前会话未注册该 skill(新装 skill 需重启宿主会话才可见),直接按其核心结论执行:`workers` 预占后**由宿主会话直驱协议通道**(worker MCP 工具或 `bugx supervisor rpc --role worker`,caller_role=worker),勿默认为 worker 派发子代理;`run_sandboxed_probe` 必须携带本次 Task 的 lease_id/execution_id。\n- 其余宿主按后续章节执行。\n\n\n\n## 如何使用本技能(AI 执行元指南与意图决策树)\n\n当你(AI)触发并阅读本技能时,请无条件遵循以下认知模型与执行时序:\n\n### 1. 意图决策树(Triage Decision Tree)\n拿到任务第一秒,判定属于哪个分支:\n- **分支 A:单点敏捷排查 / 特定函数 / Diff / 报错堆栈**\n - **标志**:单文件排查、复现某个函数、分析异常报错。\n - **动作**:就地编写轻量复现脚本(PoC)或运行定向测试,使用 `bugx view`, `bugx test-generate`, `bugx test-verify`;**严禁启动重型全流程门禁!**\n- **分支 B:全库漏洞挖掘 / 深度变异 / 多 Worker 并发审计**\n - **标志**:用户明确输入 `/bugx`、要求“全库审计”、“挖掘潜在漏洞”。\n - **动作**:按标准生命周期流转(`engine pre` -> 门禁确认 -> Explore -> Mutate -> Repair -> 结算)。\n- **分支 C:环境诊断 / 依赖修复 / 宿主状态排查**\n - **动作**:优先运行 `bugx doctor --root <ROOT> --json` 与 `bugx engine --root <ROOT> status --json`,绝不盲目 `init` 或 `--force`。\n\n### 2. 标准五步操作闭环(5-Step Execution Loop)\n1. **定根**:确定被测项目根绝对路径 `<ROOT>`,严格在 `<ROOT>` 内部执行,禁止全盘发散扫描。\n2. **探况**:先执行只读命令检查运行态(`bugx engine --root <ROOT> status --json` 或 `bugx doctor`)。\n3. **选路**:根据意图挑选命令;若需查阅参数,运行 `bugx help <顶层命令>`(如 `bugx help cloud`)按需动态读取,严禁盲猜。\n4. **承接**:若 `engine pre` 返回退出码 `2`,表示等待宿主单选门禁交互;必须调用宿主原生控件展示选项,按用户选择的 action 执行,禁止文本伪造选择或自旋重试。退出码 `0` 只代表门禁通过,不代表挖掘完成。\n5. **闭环**:缺陷必须给出最小独立复现脚本(PoC)与完整调用栈证据;使用 6 大标准汇报用词(只读检查、项目就绪、门禁就绪、测试执行、挖掘启动、挖掘完成)如实汇报。\n\n### 3. 高频场景命令(覆盖 90% 日常调用)\n- **环境诊断**:`bugx doctor --root <ROOT> --json`(`--repair-assets` 按需修复)\n- **启动与门禁**:先运行 `bugx engine --root <ROOT> status --json`;仅当状态为 `UNINITIALIZED` 时运行 `bugx engine --root <ROOT> pre` 自动准备新项目。挖掘启动不要先调用 `bugx init`;它是独立 CLI 初始化操作,不替代 status/pre 状态机。若状态为 `FATAL_BLOCKED`、其他阻断状态或检查失败,保留现场并停止;禁止用 `init`、`reset` 或 `--force` 绕过门禁。\n- **单点复现与变异**:`bugx test-generate --root <ROOT> --scope <PATH::SYM> --out <FILE>` / `bugx test-verify verify --scope <SCOPE>`\n- **Supervisor 与并发排查**:`bugx supervisor status --root <ROOT>`\n- **脱敏飞轮与日志**:`bugx telemetry inspect` / `bugx log --root <ROOT> --errors`\n- **双轨报告与预览**:`bugx report both --eval-dir verification/evals/oss --out verification/evals/oss` / `bugx report serve --port 18991`\n\n### 4. 紧凑型命令全景雷达(41 个顶层命令分类索引)\n如需调用以下命令,通过 `bugx help <命令>` 动态获取具体参数与子命令,严禁盲猜:\n- **诊断探索 (9)**:`help`, `doctor`, `hosts`, `completion`, `log`, `stats`, `view`, `project`, `self-audit`\n- **核心生命周期 (14)**:`init`, `engine`, `supervisor`, `daemon`, `config`, `reset`, `install`, `uninstall`, `dsh`, `plugin`, `mcp`, `mcp-runtime`, `capability`, `logic-analysis`\n- **深度审计验证 (10)**:`audit`, `probe`, `test-generate`, `test-audit`, `test-verify`, `patch-forge`, `test-strategy`, `fuzz-input`, `differential-probe`, `mining-audit`\n- **知识飞轮交付 (8)**:`report`, `lesson`, `knowledge`, `skill`, `cloud`, `auth`, `telemetry`, `advisory`\n\n### 5. 核心军规与废弃命令重定向\n- **阻断不授权暴力修复**:`FATAL_BLOCKED` 严禁使用 `init`、`reset`、`--force` 绕过,先保留报告和日志。\n- **废弃命令重定向**:`matrix` -> `bugx audit`;`console` -> `bugx report serve`;`watch` -> `bugx log --watch`;`test` 不是公共命令。开发验证请在仓库外生成最小临时验证脚本,或运行被测目标项目自带的测试,完成后删除过程文件。\n",
457
+ "host.entry.section.commands": "## 宿主路由(先于意图分流)\n\n- **ZCode 宿主**:优先加载同插件 `bugx-zcode` skill(ZCode 专属手册:直驱路径、rpc 回退、坑位对策)。若当前会话未注册该 skill(新装 skill 需重启宿主会话才可见),直接按其核心结论执行:`workers` 预占后**由宿主会话直驱协议通道**(worker MCP 工具或 `bugx supervisor rpc --role worker`,caller_role=worker),勿默认为 worker 派发子代理;`run_sandboxed_probe` 必须携带本次 Task 的 lease_id/execution_id。\n- 其余宿主按后续章节执行。\n\n\n\n## 如何使用本技能(AI 执行元指南与意图决策树)\n\n当你(AI)触发并阅读本技能时,请无条件遵循以下认知模型与执行时序:\n\n### 1. 意图决策树(Triage Decision Tree)\n拿到任务第一秒,判定属于哪个分支:\n- **分支 A:单点敏捷排查 / 特定函数 / Diff / 报错堆栈**\n - **标志**:单文件排查、复现某个函数、分析异常报错。\n - **动作**:就地编写轻量复现脚本(PoC)或运行定向测试,使用 `bugx view`, `bugx test-generate`, `bugx test-verify`;**严禁启动重型全流程门禁!**\n- **分支 B:全库漏洞挖掘 / 深度变异 / 多 Worker 并发审计**\n - **标志**:用户明确输入 `/bugx`、要求“全库审计”、“挖掘潜在漏洞”。\n - **动作**:按标准生命周期流转(`engine pre` -> 门禁确认 -> Explore -> Mutate -> Repair -> 结算)。\n- **分支 C:环境诊断 / 依赖修复 / 宿主状态排查**\n - **动作**:优先运行 `bugx doctor --root <ROOT> --json` 与 `bugx engine --root <ROOT> status --json`,绝不盲目 `init` 或 `--force`。\n\n### 2. 标准五步操作闭环(5-Step Execution Loop)\n1. **定根**:确定被测项目根绝对路径 `<ROOT>`,严格在 `<ROOT>` 内部执行,禁止全盘发散扫描。\n2. **探况**:先执行只读命令检查运行态(`bugx engine --root <ROOT> status --json` 或 `bugx doctor`)。\n3. **选路**:根据意图挑选命令;若需查阅参数,运行 `bugx help <顶层命令>`(如 `bugx help cloud`)按需动态读取,严禁盲猜。\n4. **承接**:若 `engine pre` 返回退出码 `2`,表示等待宿主单选门禁交互;必须调用宿主原生控件展示选项,按用户选择的 action 执行,禁止文本伪造选择或自旋重试。退出码 `0` 只代表门禁通过,不代表挖掘完成。\n5. **闭环**:缺陷必须给出最小独立复现脚本(PoC)与完整调用栈证据;使用 6 大标准汇报用词(只读检查、项目就绪、门禁就绪、测试执行、挖掘启动、挖掘完成)如实汇报。\n\n### 3. 高频场景命令(覆盖 90% 日常调用)\n- **手册即时检索**:`bugx guide \"<关键词>\"`(官方热点同步 + 本地项目文档检索;离线加 `--offline`)\n- **环境诊断**:`bugx doctor --root <ROOT> --json`(`--repair-assets` 按需修复)\n- **启动与门禁**:先运行 `bugx engine --root <ROOT> status --json`;仅当状态为 `UNINITIALIZED` 时运行 `bugx engine --root <ROOT> pre` 自动准备新项目。挖掘启动不要先调用 `bugx init`;它是独立 CLI 初始化操作,不替代 status/pre 状态机。若状态为 `FATAL_BLOCKED`、其他阻断状态或检查失败,保留现场并停止;禁止用 `init`、`reset` 或 `--force` 绕过门禁。\n- **单点复现与变异**:`bugx test-generate --root <ROOT> --scope <PATH::SYM> --out <FILE>` / `bugx test-verify verify --scope <SCOPE>`\n- **Supervisor 与并发排查**:`bugx supervisor status --root <ROOT>`\n- **脱敏飞轮与日志**:`bugx telemetry inspect` / `bugx log --root <ROOT> --errors`\n- **双轨报告与预览**:`bugx report both --eval-dir verification/evals/oss --out verification/evals/oss` / `bugx report serve --port 18991`\n\n### 4. 紧凑型命令全景雷达(43 个顶层命令分类索引)\n如需调用以下命令,通过 `bugx help <命令>` 动态获取具体参数与子命令,严禁盲猜:\n- **诊断与探索 (10)**:`help`, `completion`, `guide`, `hosts`, `doctor`, `log`, `stats`, `view`, `project`, `self-audit`\n- **核心生命周期与宿主 (15)**:`init`, `install`, `reset`, `uninstall`, `dsh`, `engine`, `supervisor`, `daemon`, `config`, `plugin`, `mcp`, `capability`, `mcp-runtime`, `update`, `interaction`\n- **深度审计与测试验证 (10)**:`audit`, `probe`, `logic-analysis`, `mining-audit`, `test-generate`, `test-audit`, `test-verify`, `patch-forge`, `autonomous`, `goal`\n- **云端、知识与交付 (8)**:`cloud`, `auth`, `telemetry`, `knowledge`, `lesson`, `skill`, `advisory`, `report`\n\n### 5. 核心军规与废弃命令重定向\n- **阻断不授权暴力修复**:`FATAL_BLOCKED` 严禁使用 `init`、`reset`、`--force` 绕过,先保留报告和日志。\n- **废弃命令重定向**:`matrix` -> `bugx audit`;`console` -> `bugx report serve`;`watch` -> `bugx log --watch`;`test` 不是公共命令。开发验证请在仓库外生成最小临时验证脚本,或运行被测目标项目自带的测试,完成后删除过程文件。\n",
458
458
  "host.entry.description.codex": "Codex 宿主专属 BugX 操作 Skill。用于在 Codex 中启动、恢复和排障 BugX 审计及读取本地模型与 Token 用量。保留完整 Agent 流程、原生用户门禁和证据校验;按项目规模分派真实原生 Worker。",
459
459
  "prompt.plugin.chatgpt_shared_skill_write_failed": "共享全局 Skill 写入失败(不影响插件注册):{error}",
460
460
  "exception.plugin.claude_usage_skill_missing": "Claude 宿主手册 Skill 缺失,无法完成安装:{path}\n该文件是 bugx/SKILL.md 要求的强制加载项,不属于可选增强件。\n修复:确认仓库内 ecosystem/plugins/bugx/skills/bugx-claude/SKILL.md 已纳入版本控制(git add),并重新构建 wheel。"
@@ -364,7 +364,12 @@ def _install_pypi_environment(
364
364
  python = executable
365
365
  venv_dir = _venv_dir(staging, env_id)
366
366
  _create_venv(venv_dir, python, python_spec)
367
- pip = _venv_bin_dir(staging, env_id) / "pip"
367
+ bin_dir = _venv_bin_dir(staging, env_id)
368
+ pip = bin_dir / ("pip.exe" if os.name == "nt" else "pip")
369
+ if not pip.is_file() and os.name == "nt":
370
+ alt_pip = bin_dir / "pip"
371
+ if alt_pip.is_file():
372
+ pip = alt_pip
368
373
  if not pip.is_file() or pip.is_symlink():
369
374
  raise McpRuntimeError(f"venv 未提供普通文件形式的 pip,拒绝受限安装: {pip}")
370
375
  command = [str(pip), "install", *PYPI_INSTALL_FLAGS, "-r", str(requirements)]
package/core/metadata.txt CHANGED
@@ -1,4 +1,4 @@
1
- bugx_version: "0.1.3"
1
+ bugx_version: "0.1.4"
2
2
  bugx_channel: "stable"
3
3
  bugx_marker: "stable"
4
4
  build_id: 1
@@ -1,6 +1,6 @@
1
1
  # BugX Planning & Slicing Engine (能力规划、领域路由、代码切片与仲裁流水线)
2
2
 
3
- > **版本契约**: `0.1.2` | **所属分层**: `Layer 2: 分析、切片与探测引擎`
3
+ > **版本契约**: `0.1.4` | **所属分层**: `Layer 2: 分析、切片与探测引擎`
4
4
  > **工程规范**: 参见 [`docs/02_architecture/05_ARCH_NOMENCLATURE_GUIDE.md`](../../docs/02_architecture/05_ARCH_NOMENCLATURE_GUIDE.md)
5
5
  > **守卫机制**: `scripts/verify_directory_indices.py` (100% 物理条目索引覆盖)
6
6
 
@@ -150,13 +150,13 @@ _STAGE_TIER_MAP: dict[str, dict[str, Any]] = {
150
150
  },
151
151
  "mutate": {
152
152
  "tier": "tier_2_deep_reasoning",
153
- "description": "深度推理模型 (Sonnet / DeepSeek-R1 / GPT-4o),适用于并发竞态、状态推演与差分验证",
153
+ "description": "深度推理模型 (Claude Sonnet 5.5 / Gemini 4 Carbon / DeepSeek-R1 / GPT-4o),适用于并发竞态、状态推演与差分验证",
154
154
  "allowed_actions": ["fuzz", "perturb", "differential_test", "race_detect", "test_verify"],
155
155
  "recommended_tools": ["bugx_test_verify", "bugx_test_mutate", "bugx_fuzz_input", "bugx_fuzz_concurrency", "bugx_fuzz_stateful"],
156
156
  },
157
157
  "repair": {
158
158
  "tier": "tier_3_precise_code",
159
- "description": "高精度工程代码模型 (Claude 3.5 Sonnet / Codex),适用于 TDD 最小修复与单测闭环",
159
+ "description": "高精度工程代码模型 (Claude Sonnet 5.5 / Opus 5.5 / Codex),适用于 TDD 最小修复与单测闭环",
160
160
  "allowed_actions": ["minimize_repro", "tdd_fix", "directed_test", "post_settle", "test_verify"],
161
161
  "recommended_tools": ["bugx_minimize_repro", "bugx_test_verify"],
162
162
  },