@blxzer/cursor-trellis 0.1.3 → 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.
Files changed (74) hide show
  1. package/CHANGELOG.md +58 -0
  2. package/README.md +45 -23
  3. package/dist/configurators/workflow.d.ts +1 -1
  4. package/dist/configurators/workflow.d.ts.map +1 -1
  5. package/dist/configurators/workflow.js +20 -9
  6. package/dist/configurators/workflow.js.map +1 -1
  7. package/dist/migrations/manifests/0.1.3.json +9 -0
  8. package/dist/migrations/manifests/0.1.4.json +9 -0
  9. package/dist/templates/markdown/agents.md +1 -1
  10. package/dist/templates/markdown/index.d.ts +1 -0
  11. package/dist/templates/markdown/index.d.ts.map +1 -1
  12. package/dist/templates/markdown/index.js +1 -0
  13. package/dist/templates/markdown/index.js.map +1 -1
  14. package/dist/templates/markdown/prompts/run-semantic-slice-12.md.txt +13 -29
  15. package/dist/templates/markdown/spec/guides/code-reuse-thinking-guide.md.txt +0 -49
  16. package/dist/templates/markdown/spec/guides/cross-layer-thinking-guide.md.txt +0 -85
  17. package/dist/templates/markdown/spec/guides/cursor-semantic-compliance.md.txt +7 -21
  18. package/dist/templates/markdown/spec/guides/cursor-subagent-policy.md.txt +6 -10
  19. package/dist/templates/markdown/spec/guides/retrieval-daily-guide.md.txt +7 -13
  20. package/dist/templates/shared-hooks/inject-retrieval-plan.py +42 -23
  21. package/dist/templates/shared-hooks/inject-subagent-context.py +6 -2
  22. package/dist/templates/shared-hooks/session-start.py +17 -9
  23. package/dist/templates/trellis/index.d.ts +7 -4
  24. package/dist/templates/trellis/index.d.ts.map +1 -1
  25. package/dist/templates/trellis/index.js +11 -7
  26. package/dist/templates/trellis/index.js.map +1 -1
  27. package/dist/templates/trellis/scripts/common/codebase_retrieval_router.py +2 -2
  28. package/dist/templates/trellis/scripts/common/config.py +1 -1
  29. package/dist/templates/trellis/scripts/common/parent_orchestration.py +27 -15
  30. package/dist/templates/trellis/scripts/common/retrieval_agent_instructions.py +1 -1
  31. package/dist/templates/trellis/scripts/common/smart_search_resolve.py +28 -3
  32. package/dist/templates/trellis/scripts/common/task_gates.py +372 -73
  33. package/dist/templates/trellis/scripts/common/task_map.py +29 -1
  34. package/dist/templates/trellis/workflow.md +9 -53
  35. package/package.json +5 -44
  36. package/bin/smart-search.js +0 -79
  37. package/dist/templates/trellis/scripts/aggregate_retrieval_telemetry.py +0 -342
  38. package/dist/templates/trellis/scripts/batch_plan_envelope.py +0 -105
  39. package/vendor/smart-search/LICENSE +0 -21
  40. package/vendor/smart-search/README.md +0 -412
  41. package/vendor/smart-search/README.zh-CN.md +0 -430
  42. package/vendor/smart-search/npm/bin/smart-search.js +0 -63
  43. package/vendor/smart-search/npm/scripts/postinstall.js +0 -87
  44. package/vendor/smart-search/npm/scripts/resolve-prerelease-version.js +0 -108
  45. package/vendor/smart-search/npm/scripts/set-package-version.js +0 -35
  46. package/vendor/smart-search/npm/scripts/sync-python-version.js +0 -22
  47. package/vendor/smart-search/npm/scripts/test-wrapper-repair.js +0 -99
  48. package/vendor/smart-search/npm/scripts/test.js +0 -85
  49. package/vendor/smart-search/package.json +0 -42
  50. package/vendor/smart-search/pyproject.toml +0 -37
  51. package/vendor/smart-search/skills/smart-search-cli/SKILL.md +0 -387
  52. package/vendor/smart-search/skills/smart-search-cli/agents/openai.yaml +0 -3
  53. package/vendor/smart-search/skills/smart-search-cli/examples/batch-search.md +0 -98
  54. package/vendor/smart-search/skills/smart-search-cli/examples/evidence-gathering.md +0 -89
  55. package/vendor/smart-search/skills/smart-search-cli/references/cli-contract.md +0 -337
  56. package/vendor/smart-search/src/smart_search/__init__.py +0 -1
  57. package/vendor/smart-search/src/smart_search/assets/skills/smart-search-cli/SKILL.md +0 -387
  58. package/vendor/smart-search/src/smart_search/assets/skills/smart-search-cli/agents/openai.yaml +0 -3
  59. package/vendor/smart-search/src/smart_search/assets/skills/smart-search-cli/examples/batch-search.md +0 -98
  60. package/vendor/smart-search/src/smart_search/assets/skills/smart-search-cli/examples/evidence-gathering.md +0 -89
  61. package/vendor/smart-search/src/smart_search/assets/skills/smart-search-cli/references/cli-contract.md +0 -337
  62. package/vendor/smart-search/src/smart_search/cli.py +0 -2003
  63. package/vendor/smart-search/src/smart_search/config.py +0 -580
  64. package/vendor/smart-search/src/smart_search/logger.py +0 -43
  65. package/vendor/smart-search/src/smart_search/providers/__init__.py +0 -16
  66. package/vendor/smart-search/src/smart_search/providers/base.py +0 -41
  67. package/vendor/smart-search/src/smart_search/providers/context7.py +0 -141
  68. package/vendor/smart-search/src/smart_search/providers/exa.py +0 -206
  69. package/vendor/smart-search/src/smart_search/providers/jina.py +0 -136
  70. package/vendor/smart-search/src/smart_search/providers/openai_compatible.py +0 -370
  71. package/vendor/smart-search/src/smart_search/providers/zhipu.py +0 -143
  72. package/vendor/smart-search/src/smart_search/service.py +0 -2865
  73. package/vendor/smart-search/src/smart_search/sources.py +0 -429
  74. package/vendor/smart-search/src/smart_search/utils.py +0 -220
@@ -47,7 +47,7 @@ If unsure: Task dispatch is the path Trellis workflow routes through; Agent sess
47
47
 
48
48
  ## Model dispatch strategy (BYOK-aware)
49
49
 
50
- > **Full technical analysis:** .trellis/spec/guides/cursor-subagent-reverse-engineering-report.md
50
+ > **Model routing details:** See Method 2.5 / 2.6 below and Cursor++ provider settings (`~/.ccursor/providers.json`).
51
51
 
52
52
  ### Environment detection
53
53
 
@@ -56,7 +56,7 @@ If unsure: Task dispatch is the path Trellis workflow routes through; Agent sess
56
56
  | **Native Cursor API** | Frontmatter `model:` works (server-side routing) | Native model picker |
57
57
  | **Cursor++ BYOK** | ❌ Frontmatter / Cursor Settings per-agent: not wired for `trellis-*`; **✅ Method 2.5** if applied | ✅ Independent model via Cursor++ panel (v0.0.11+) |
58
58
 
59
- Under Cursor++ BYOK, **committed** agent frontmatter `model:` and **Cursor Settings** UI for `trellis-research` / `trellis-implement` / `trellis-check` do **not** populate `subagentModelOverrides` for those types (verified). Without **Method 2.5**, custom Task subagents **inherit** the parent session BYOK model. See `.trellis/spec/guides/cursor-subagent-reverse-engineering-report.md`.
59
+ Under Cursor++ BYOK, **committed** agent frontmatter `model:` and **Cursor Settings** UI for `trellis-research` / `trellis-implement` / `trellis-check` do **not** populate `subagentModelOverrides` for those types (verified). Without **Method 2.5**, custom Task subagents **inherit** the parent session BYOK model.
60
60
 
61
61
  ### Dispatch strategy matrix
62
62
 
@@ -332,15 +332,12 @@ When `preToolUse` cannot resolve a selected task, the subagent should read **`Se
332
332
 
333
333
  ### Confirmed compatibility (v0.0.11+, Cursor 3.7.27)
334
334
 
335
- Verified by local testing on `D:\MyHarness` workspace:
336
-
337
- | Trellis component | Status under Cursor++ | Evidence |
335
+ | Trellis component | Status under Cursor++ | Notes |
338
336
  | --------------------- | --------------------- | ----------------------------------------------------------------------------------- |
339
337
  | `.cursor/agents/` | Normal | Agent files not intercepted; `model:` frontmatter read by Cursor at spawn |
340
- | `.cursor/hooks/` | Normal | Agent log `requestContextKeys` contains `hooksConfig` |
341
- | `.cursor/skills/` | Normal | Agent log `requestContextKeys` contains `agentSkills` |
342
- | `.cursor/mcp.json` | Normal | 4+ MCP servers, 300+ tools load normally |
343
- | SubAgent write access | **Fixed in v0.0.11** | Prior versions defaulted SubAgent to readonly; `ttrellis-implement` now writes files |
338
+ | `.cursor/hooks/` | Normal | Hook config loads; verify `hooksConfig` in agent logs when debugging |
339
+ | `.cursor/mcp.json` | Normal | MCP servers and tools load normally |
340
+ | SubAgent write access | **Fixed in v0.0.11** | Prior versions defaulted SubAgent to readonly; `trellis-implement` now writes files |
344
341
 
345
342
  **Minimum version: v0.0.11.** Earlier versions break `ttrellis-implement` due to SubAgent readonly bug.
346
343
 
@@ -351,7 +348,6 @@ Verified by local testing on `D:\MyHarness` workspace:
351
348
  - The `model:` ID **must match** a model configured in Cursor++ provider settings (`~/.ccursor/providers.json`). If it doesn't match, the request will fail with a provider error.
352
349
  - Cursor++ intercepts `AvailableModels`/`GetDefaultModel` - the model picker and model list are determined by BYOK provider config, not Cursor's official model catalog.
353
350
  - Under Cursor++, "inherit" means the parent session's BYOK-routed model, which may differ from what the Cursor UI label suggests.
354
- - **Full technical analysis:** `.trellis/spec/guides/cursor-subagent-reverse-engineering-report.md`
355
351
 
356
352
  ### Safety boundary
357
353
 
@@ -41,7 +41,7 @@ Each route in the router output includes a `tokenEconomy` label:
41
41
 
42
42
  When `projectFileCount > 2000`, the router promotes structural (codegraph) routes ahead of rg routes for better token efficiency on large codebases.
43
43
 
44
- **Dogfood default (REC-10):** `route_codebase_retrieval.py` and `get_context.py --mode retrieval-pack` default `--project-file-count` to **`auto`** — they count files under the Trellis repo root (`git ls-files` when `.git` exists, else a bounded walk). Override with an integer (e.g. `5000`) for eval fixtures or non-git trees. **Harness note:** `D:\MyHarness` is not a git repo; dogfood from `Trellis/` or pass `--project-file-count` explicitly when routing from the workspace root.
44
+ **Project file count default:** `route_codebase_retrieval.py` and `get_context.py --mode retrieval-pack` default `--project-file-count` to **`auto`** — they count files under the repo root (`git ls-files` when `.git` exists, else a bounded walk). Override with an integer (e.g. `5000`) for large non-git trees or eval fixtures.
45
45
 
46
46
  ## Commands
47
47
 
@@ -76,7 +76,7 @@ Paste into the **run report header** (markdown):
76
76
 
77
77
  When `smart-search doctor` is not ok or `run_smart_search.py` status is `not_configured` / `failed` (including **search timeout**), use **Cursor WebSearch/WebFetch**, then persist to `{TASK}/research/` with `source: cursor-web-fallback` in frontmatter. See `smart-search-cli` skill §4b.
78
78
 
79
- **CLI discovery (Cursor):** optional env/config override → PATH → `node_modules/.bin` / package script optional harness wrappers (`Trellis/packages/cli/bin/smart-search.js`). No `.trellis/.runtime/` cache.
79
+ **CLI discovery (Cursor):** `TRELLIS_SMART_SEARCH_COMMAND` / `smart_search.command` → PATH `smart-search` project `node_modules/.bin/smart-search` (when installed as a dependency). Agent entrypoint is always `./.trellis/scripts/run_smart_search.py`.
80
80
 
81
81
  ## Router vs execution
82
82
 
@@ -95,8 +95,8 @@ After Grep/codegraph/semantic produce **path candidates**, reorder before choosi
95
95
  | `env-config-literal` | Prefer `scripts/`, `e2e/`, `bench/`, `test/` over generic `src/auth` / `src/paths`. |
96
96
 
97
97
  - **Agent plans**: `render_agent_instructions` / `inject-retrieval-plan.py` append a **结果层排序** block when these intents appear.
98
- - **Eval / offline**: `python ./.trellis/scripts/rank_retrieval_candidates.py --candidates fixtures.json --intents caller-chain --top-k 5 --pretty`
99
- - **Library**: TS `packages/cli/src/utils/retrieval-result-ranking.ts` (Vitest fixtures B03/B05/D03); Python mirror `common/retrieval_result_ranking.py`.
98
+ - **Offline reorder**: `python ./.trellis/scripts/rank_retrieval_candidates.py --candidates fixtures.json --intents caller-chain --top-k 5 --pretty`
99
+ - **Library**: `common/retrieval_result_ranking.py` (Python mirror used by router and rank script).
100
100
 
101
101
  Do **not** claim aggregate openclaw score gains from ranking alone without fresh telemetry (`candidate_pool_recall` vs final Top-K).
102
102
 
@@ -119,22 +119,16 @@ On **Cursor**, `semantic_exec_rate` uses `classify_tool_calls(..., platform=curs
119
119
 
120
120
  Plan-level presence does not imply execution-level use (see parent research `06-19` OQ-1 双轨).
121
121
 
122
- ### Execution telemetry (schema v2, eval / openclaw)
122
+ ### Execution telemetry (schema v2)
123
123
 
124
- Store **one JSON object per query** in JSONL (`schema_version: 2`). Split scores:
124
+ When recording eval or audit runs, store **one JSON object per query** in JSONL (`schema_version: 2`). Split scores:
125
125
 
126
126
  | Field | Owner | Meaning |
127
127
  | --- | --- | --- |
128
128
  | `answer_score` | Human rubric | Top-1 / Recall@5 / answer quality (0–6 per query in main-50) |
129
129
  | `compliance_score` | Derived | Plan vs exec layer compliance (0–1); structural/codegraph, semantic, read verify |
130
130
 
131
- Report **summary rates must not be hand-copied** from batch router envelopes. Aggregate from JSONL:
132
-
133
- ```powershell
134
- python ./.trellis/scripts/aggregate_retrieval_telemetry.py runs/<run>/telemetry.jsonl --markdown
135
- ```
136
-
137
- Key exec fields (fill from session tool log): `tools_called`, `grep_count`, `read_count`, `codegraph_executed`, `semantic_executed`, `router_cli_invoked`, `plan_block_in_prompt`, `read_verification_done`. TypeScript contract: `packages/cli/src/utils/retrieval-execution-telemetry.ts` (`RETRIEVAL_TELEMETRY_FIELD_OWNERSHIP`).
131
+ Key exec fields (fill from session tool log): `tools_called`, `grep_count`, `read_count`, `codegraph_executed`, `semantic_executed`, `router_cli_invoked`, `plan_block_in_prompt`, `read_verification_done`. Classify tool names with `common/retrieval_tool_classification.py` (see `cursor-semantic-compliance.md`).
138
132
 
139
133
  ## retrieval-pack
140
134
 
@@ -1,9 +1,14 @@
1
1
  #!/usr/bin/env python3
2
- """Cursor beforeSubmitPrompt: inject router-derived ## 代码库检索计划 per user turn.
2
+ """Cursor beforeSubmitPrompt: telemetry-only for retrieval plan routing.
3
3
 
4
- Runs route_codebase_retrieval + render_agent_instructions for the submitted
5
- prompt. Complements retrieval-routing.mdc (Rules) with an explicit plan block
6
- so REC-03 telemetry can set plan_block_in_prompt=true.
4
+ DEGRADED MODE (2026-06-24): beforeSubmitPrompt hook's additional_context does
5
+ not reach the model in current Cursor versions (L1: event often not fired;
6
+ L2: additional_context not delivered). This hook now runs in telemetry-only
7
+ mode: logs routing decisions to .trellis/.runtime/retrieval-plan-events.log
8
+ for post-session analysis but does NOT inject plan blocks.
9
+
10
+ See .trellis/tasks/06-24-handle-beforesubmitprompt-unreliability/prd.md for
11
+ probe results and mitigation strategy.
7
12
 
8
13
  Silent exit 0 (no stdout) when:
9
14
  - TRELLIS_HOOKS=0 / not a Trellis repo
@@ -15,6 +20,7 @@ from __future__ import annotations
15
20
  import json
16
21
  import os
17
22
  import sys
23
+ from datetime import datetime, timezone
18
24
  from pathlib import Path
19
25
  from typing import Any
20
26
 
@@ -45,6 +51,7 @@ if sys.platform.startswith("win"):
45
51
  DIR_WORKFLOW = ".trellis"
46
52
  PLAN_MARKER_ZH = "## 代码库检索计划"
47
53
  PLAN_MARKER_EN = "## Codebase retrieval plan"
54
+ TELEMETRY_LOG = ".runtime/retrieval-plan-events.log"
48
55
 
49
56
 
50
57
  def _find_trellis_root(start: Path) -> Path | None:
@@ -80,15 +87,31 @@ def _load_capabilities(root: Path) -> dict[str, object] | None:
80
87
  return None
81
88
 
82
89
 
83
- def _emit_plan_block(plan_text: str) -> None:
84
- payload = {
85
- "additional_context": plan_text,
86
- "hookSpecificOutput": {
87
- "hookEventName": "beforeSubmitPrompt",
88
- "additionalContext": plan_text,
89
- },
90
+ def _write_telemetry_log(
91
+ root: Path,
92
+ query_preview: str,
93
+ cursor_env: str,
94
+ intents: list[str],
95
+ ) -> None:
96
+ """Write telemetry event to side-channel log (no injection to model)."""
97
+ log_path = root / DIR_WORKFLOW / TELEMETRY_LOG
98
+ log_path.parent.mkdir(parents=True, exist_ok=True)
99
+
100
+ event = {
101
+ "ts": datetime.now(timezone.utc).isoformat(),
102
+ "event": "beforeSubmitPrompt",
103
+ "query_preview": query_preview[:120],
104
+ "cursorEnv": cursor_env,
105
+ "intents": intents,
106
+ "action": "telemetry-only",
107
+ "note": "additional_context channel unreliable, no injection",
90
108
  }
91
- print(json.dumps(payload, ensure_ascii=False), flush=True)
109
+
110
+ try:
111
+ with log_path.open("a", encoding="utf-8") as handle:
112
+ handle.write(json.dumps(event, ensure_ascii=False) + "\n")
113
+ except Exception:
114
+ pass
92
115
 
93
116
 
94
117
  def main() -> int:
@@ -122,9 +145,6 @@ def main() -> int:
122
145
  from common.project_file_stats import ( # type: ignore[import-not-found]
123
146
  resolve_project_file_count_arg,
124
147
  )
125
- from common.retrieval_agent_instructions import ( # type: ignore[import-not-found]
126
- render_agent_instructions,
127
- )
128
148
  from common.retrieval_plan_gate import ( # type: ignore[import-not-found]
129
149
  extract_user_prompt,
130
150
  should_inject_retrieval_plan,
@@ -148,14 +168,13 @@ def main() -> int:
148
168
  codebase_retrieval_selected=selected,
149
169
  project_file_count=project_file_count,
150
170
  )
151
- instructions = render_agent_instructions(
152
- plan,
153
- locale="zh",
154
- )
155
- if PLAN_MARKER_ZH not in instructions and PLAN_MARKER_EN not in instructions:
156
- return 0
157
-
158
- _emit_plan_block(instructions)
171
+
172
+ # TELEMETRY-ONLY: log routing decision but do not inject
173
+ cursor_env = plan.get("cursorEnv", "unknown")
174
+ intent_ids = [i.get("id", "unknown") for i in plan.get("intents", [])]
175
+ _write_telemetry_log(root, query, cursor_env, intent_ids)
176
+
177
+ # Exit 0 with no stdout (no injection to model context)
159
178
  return 0
160
179
 
161
180
 
@@ -166,8 +166,12 @@ def main() -> None:
166
166
  sys.exit(0)
167
167
 
168
168
  try:
169
- input_data = json.load(sys.stdin)
170
- except json.JSONDecodeError:
169
+ input_text = sys.stdin.read()
170
+ # Remove UTF-8 BOM if present
171
+ if input_text.startswith('\ufeff'):
172
+ input_text = input_text[1:]
173
+ input_data = json.loads(input_text)
174
+ except (json.JSONDecodeError, ValueError):
171
175
  sys.exit(0)
172
176
 
173
177
  subagent_type, original_prompt, tool_input = _parse_hook_input(input_data)
@@ -18,6 +18,9 @@ import sys
18
18
  from io import StringIO
19
19
  from pathlib import Path
20
20
 
21
+ # Cross-platform Python command resolver: Windows standard install has 'python', not 'python3'
22
+ _PYTHON_CMD = "python" if sys.platform == "win32" else "python3"
23
+
21
24
 
22
25
  def _normalize_windows_shell_path(path_str: str) -> str:
23
26
  """Normalize Unix-style shell paths to real Windows paths.
@@ -338,7 +341,7 @@ def _get_task_status(trellis_dir: Path, input_data: dict) -> str:
338
341
  return (
339
342
  f"Trellis framework: active\nSelected task: {task_ref}\n"
340
343
  "Status: STALE SELECTION\n"
341
- f"Next-Action: Run `python3 ./.trellis/scripts/task.py exit` to clear the stale selection, "
344
+ f"Next-Action: Run `{_PYTHON_CMD} ./.trellis/scripts/task.py exit` to clear the stale selection, "
342
345
  "then ask the user what to work on next."
343
346
  )
344
347
 
@@ -638,7 +641,7 @@ def _build_compact_current_state(
638
641
  try:
639
642
  task_count = sum(1 for _ in iter_active_tasks(get_tasks_dir(repo_root)))
640
643
  lines.append(
641
- f"Active tasks: {task_count} total. Use the Task Dashboard for routing; use `python3 ./.trellis/scripts/task.py list --mine` only for raw inspection."
644
+ f"Active tasks: {task_count} total. Use the Task Dashboard for routing; use `{_PYTHON_CMD} ./.trellis/scripts/task.py list --mine` only for raw inspection."
642
645
  )
643
646
  except Exception:
644
647
  pass
@@ -669,7 +672,7 @@ def _build_task_dashboard(trellis_dir: Path, input_data: dict) -> str:
669
672
  _detect_platform(input_data),
670
673
  )
671
674
  except Exception:
672
- return "Task Dashboard unavailable. Run: python3 ./.trellis/scripts/task.py dashboard"
675
+ return f"Task Dashboard unavailable. Run: {_PYTHON_CMD} ./.trellis/scripts/task.py dashboard"
673
676
 
674
677
 
675
678
  def _extract_range(content: str, start_header: str, end_header: str) -> str:
@@ -736,7 +739,7 @@ def _build_workflow_overview(workflow_path: Path) -> str:
736
739
 
737
740
  out_lines = [
738
741
  "# Development Workflow - Session Summary",
739
- "Full guide: .trellis/workflow.md. Step detail: `python3 ./.trellis/scripts/get_context.py --mode phase --step <X.Y>`.",
742
+ f"Full guide: .trellis/workflow.md. Step detail: `{_PYTHON_CMD} ./.trellis/scripts/get_context.py --mode phase --step <X.Y>`.",
740
743
  "",
741
744
  ]
742
745
 
@@ -833,14 +836,19 @@ Trellis compact SessionStart context. Use it to orient the session; load details
833
836
 
834
837
  output.write(
835
838
  "Discover more via: "
836
- "`python3 ./.trellis/scripts/get_context.py --mode packages`\n"
839
+ f"`{_PYTHON_CMD} ./.trellis/scripts/get_context.py --mode packages`\n"
837
840
  )
838
841
  if _detect_platform(hook_input) == "cursor":
839
842
  output.write(
840
- "\n**External web research (Cursor):** `smart-search-cli` + Bash first "
841
- "(resolves PATH, optional `smart_search.command`, or "
842
- "`Trellis/packages/cli/bin/smart-search.js`). "
843
- "If `run_smart_search.py` returns `not_configured` or `failed` (incl. timeout), "
843
+ "\n**External web research (Cursor):** run "
844
+ f"`{_PYTHON_CMD} ./.trellis/scripts/run_smart_search.py \"<question>\" "
845
+ "--intent deep-research --json` first (Trellis evidence wrapper → "
846
+ "`smart-search` CLI). CLI discovery: `TRELLIS_SMART_SEARCH_COMMAND` / "
847
+ "`smart_search.command`, then PATH `smart-search`, then project "
848
+ "`node_modules/.bin/smart-search`, then optional repo-local layouts "
849
+ "(see `.trellis/spec/guides/retrieval-daily-guide.md`). "
850
+ "`smart-search-cli` is an internal workflow skill name — not a file under `.cursor/skills/` on Cursor. "
851
+ "If `run_smart_search.py` status is `not_configured` or `failed` (incl. timeout), "
844
852
  "use **WebSearch/WebFetch**, persist `{TASK}/research/*.md` with "
845
853
  "`source: cursor-web-fallback`.\n"
846
854
  )
@@ -47,19 +47,16 @@ export declare const commonCodebaseRetrievalRouter: string;
47
47
  export declare const commonCursorRetrievalEnv: string;
48
48
  export declare const commonProjectFileStats: string;
49
49
  export declare const commonRetrievalToolClassification: string;
50
- export declare const aggregateRetrievalTelemetryScript: string;
51
50
  export declare const commonRetrievalAgentInstructions: string;
52
51
  export declare const commonRetrievalPlanGate: string;
53
52
  export declare const commonSemanticPlanGate: string;
54
53
  export declare const commonRetrievalResultRanking: string;
55
54
  export declare const rankRetrievalCandidatesScript: string;
56
- export declare const batchPlanEnvelopeScript: string;
57
55
  export declare const scoreEvidenceScript: string;
58
56
  export declare const commonRetrievalAdapterMetadata: string;
59
57
  export declare const commonContextPack: string;
60
58
  export declare const commonRetrievalPack: string;
61
59
  export declare const commonRetrievalPackContext: string;
62
- export declare const commonTestRetrievalArbitration: string;
63
60
  export declare const commonSessionContext: string;
64
61
  export declare const commonPackagesContext: string;
65
62
  export declare const commonWorkflowPhase: string;
@@ -87,7 +84,13 @@ export declare const gitignoreTemplate: string;
87
84
  */
88
85
  export declare function getAllTaskTemplates(): Map<string, string>;
89
86
  /**
90
- * Get all script templates as a map of relative path to content
87
+ * Python scripts kept in the template tree for Trellis maintainers only.
88
+ * Present under `templates/trellis/scripts/` but not shipped via init/update.
89
+ */
90
+ export declare const MAINTAINER_ONLY_SCRIPT_PATHS: Set<string>;
91
+ /**
92
+ * Get all user-shipped script templates as a map of relative path to content.
93
+ * Init and update both use this as the single source of truth (no full-dir copy).
91
94
  */
92
95
  export declare function getAllScripts(): Map<string, string>;
93
96
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/templates/trellis/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAcH,eAAO,MAAM,WAAW,QAAsC,CAAC;AAG/D,eAAO,MAAM,UAAU,QAA6C,CAAC;AACrE,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,eAAe,QAA8C,CAAC;AAC3E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,oBAAoB,QAEhC,CAAC;AACF,eAAO,MAAM,YAAY,QAA2C,CAAC;AACrE,eAAO,MAAM,QAAQ,QAAuC,CAAC;AAC7D,eAAO,MAAM,SAAS,QAAwC,CAAC;AAC/D,eAAO,MAAM,SAAS,QAAwC,CAAC;AAC/D,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,iBAAiB,QAAiD,CAAC;AAChF,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,mBAAmB,QAE/B,CAAC;AACF,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,aAAa,QAA6C,CAAC;AACxE,eAAO,MAAM,yBAAyB,QAErC,CAAC;AACF,eAAO,MAAM,sBAAsB,QAElC,CAAC;AACF,eAAO,MAAM,oBAAoB,QAEhC,CAAC;AACF,eAAO,MAAM,mBAAmB,QAE/B,CAAC;AACF,eAAO,MAAM,yBAAyB,QAErC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,CAAC;AAC7E,eAAO,MAAM,UAAU,QAAkC,CAAC;AAC1D,eAAO,MAAM,gBAAgB,QAAyC,CAAC;AACvE,eAAO,MAAM,gBAAgB,QAAyC,CAAC;AACvE,eAAO,MAAM,qBAAqB,QAA8C,CAAC;AACjF,eAAO,MAAM,kBAAkB,QAA2C,CAAC;AAC3E,eAAO,MAAM,oBAAoB,QAA8C,CAAC;AAChF,eAAO,MAAM,sBAAsB,QAAgD,CAAC;AACpF,eAAO,MAAM,wBAAwB,QAAkD,CAAC;AACxF,eAAO,MAAM,4BAA4B,QAExC,CAAC;AACF,eAAO,MAAM,2BAA2B,QAEvC,CAAC;AAEF,eAAO,MAAM,kBAAkB,QAA8B,CAAC;AAC9D,eAAO,MAAM,kBAAkB,QAA8B,CAAC;AAC9D,eAAO,MAAM,iBAAiB,QAAgC,CAAC;AAoB/D;;;;GAIG;AACH,wBAAgB,mBAAmB,IAAI,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAezD;AAED;;;GAGG;AACH,eAAO,MAAM,4BAA4B,aAIvC,CAAC;AAEH;;;GAGG;AACH,wBAAgB,aAAa,IAAI,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CA2EnD"}
@@ -57,19 +57,16 @@ export const commonCodebaseRetrievalRouter = readTemplate("scripts/common/codeba
57
57
  export const commonCursorRetrievalEnv = readTemplate("scripts/common/cursor_retrieval_env.py");
58
58
  export const commonProjectFileStats = readTemplate("scripts/common/project_file_stats.py");
59
59
  export const commonRetrievalToolClassification = readTemplate("scripts/common/retrieval_tool_classification.py");
60
- export const aggregateRetrievalTelemetryScript = readTemplate("scripts/aggregate_retrieval_telemetry.py");
61
60
  export const commonRetrievalAgentInstructions = readTemplate("scripts/common/retrieval_agent_instructions.py");
62
61
  export const commonRetrievalPlanGate = readTemplate("scripts/common/retrieval_plan_gate.py");
63
62
  export const commonSemanticPlanGate = readTemplate("scripts/common/semantic_plan_gate.py");
64
63
  export const commonRetrievalResultRanking = readTemplate("scripts/common/retrieval_result_ranking.py");
65
64
  export const rankRetrievalCandidatesScript = readTemplate("scripts/rank_retrieval_candidates.py");
66
- export const batchPlanEnvelopeScript = readTemplate("scripts/batch_plan_envelope.py");
67
65
  export const scoreEvidenceScript = readTemplate("scripts/score_evidence.py");
68
66
  export const commonRetrievalAdapterMetadata = readTemplate("scripts/common/retrieval_adapter_metadata.py");
69
67
  export const commonContextPack = readTemplate("scripts/common/context_pack.py");
70
68
  export const commonRetrievalPack = readTemplate("scripts/common/retrieval_pack.py");
71
69
  export const commonRetrievalPackContext = readTemplate("scripts/common/retrieval_pack_context.py");
72
- export const commonTestRetrievalArbitration = readTemplate("scripts/common/test_retrieval_arbitration.py");
73
70
  export const commonSessionContext = readTemplate("scripts/common/session_context.py");
74
71
  export const commonPackagesContext = readTemplate("scripts/common/packages_context.py");
75
72
  export const commonWorkflowPhase = readTemplate("scripts/common/workflow_phase.py");
@@ -123,7 +120,17 @@ export function getAllTaskTemplates() {
123
120
  return templates;
124
121
  }
125
122
  /**
126
- * Get all script templates as a map of relative path to content
123
+ * Python scripts kept in the template tree for Trellis maintainers only.
124
+ * Present under `templates/trellis/scripts/` but not shipped via init/update.
125
+ */
126
+ export const MAINTAINER_ONLY_SCRIPT_PATHS = new Set([
127
+ "cursor_retrieval_probe.py",
128
+ "common/test_retrieval_arbitration.py",
129
+ "hooks/linear_sync.py",
130
+ ]);
131
+ /**
132
+ * Get all user-shipped script templates as a map of relative path to content.
133
+ * Init and update both use this as the single source of truth (no full-dir copy).
127
134
  */
128
135
  export function getAllScripts() {
129
136
  const scripts = new Map();
@@ -169,7 +176,6 @@ export function getAllScripts() {
169
176
  scripts.set("common/context_pack.py", commonContextPack);
170
177
  scripts.set("common/retrieval_pack.py", commonRetrievalPack);
171
178
  scripts.set("common/retrieval_pack_context.py", commonRetrievalPackContext);
172
- scripts.set("common/test_retrieval_arbitration.py", commonTestRetrievalArbitration);
173
179
  scripts.set("common/session_context.py", commonSessionContext);
174
180
  scripts.set("common/packages_context.py", commonPackagesContext);
175
181
  scripts.set("common/workflow_phase.py", commonWorkflowPhase);
@@ -188,9 +194,7 @@ export function getAllScripts() {
188
194
  scripts.set("build_retrieval_pack.py", buildRetrievalPackScript);
189
195
  scripts.set("route_codebase_retrieval.py", routeCodebaseRetrievalScript);
190
196
  scripts.set("codegraph_session_smoke.py", codegraphSessionSmokeScript);
191
- scripts.set("aggregate_retrieval_telemetry.py", aggregateRetrievalTelemetryScript);
192
197
  scripts.set("rank_retrieval_candidates.py", rankRetrievalCandidatesScript);
193
- scripts.set("batch_plan_envelope.py", batchPlanEnvelopeScript);
194
198
  scripts.set("score_evidence.py", scoreEvidenceScript);
195
199
  return scripts;
196
200
  }
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/templates/trellis/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;AAEtC,SAAS,YAAY,CAAC,YAAoB;IACxC,OAAO,YAAY,CAAC,IAAI,CAAC,SAAS,EAAE,YAAY,CAAC,EAAE,OAAO,CAAC,CAAC;AAC9D,CAAC;AAED,gCAAgC;AAChC,MAAM,CAAC,MAAM,WAAW,GAAG,YAAY,CAAC,qBAAqB,CAAC,CAAC;AAE/D,0BAA0B;AAC1B,MAAM,CAAC,MAAM,UAAU,GAAG,YAAY,CAAC,4BAA4B,CAAC,CAAC;AACrE,MAAM,CAAC,MAAM,WAAW,GAAG,YAAY,CAAC,yBAAyB,CAAC,CAAC;AACnE,MAAM,CAAC,MAA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AE,gBAAgB,CAAC,CAAC;IAChD,OAAO,CAAC,GAAG,CAAC,qBAAqB,EAAE,qBAAqB,CAAC,CAAC;IAC1D,OAAO,CAAC,GAAG,CAAC,kBAAkB,EAAE,kBAAkB,CAAC,CAAC;IACpD,OAAO,CAAC,GAAG,CAAC,qBAAqB,EAAE,oBAAoB,CAAC,CAAC;IACzD,OAAO,CAAC,GAAG,CAAC,uBAAuB,EAAE,sBAAsB,CAAC,CAAC;IAC7D,OAAO,CAAC,GAAG,CAAC,yBAAyB,EAAE,wBAAwB,CAAC,CAAC;IACjE,OAAO,CAAC,GAAG,CAAC,6BAA6B,EAAE,4BAA4B,CAAC,CAAC;IACzE,OAAO,CAAC,GAAG,CAAC,4BAA4B,EAAE,2BAA2B,CAAC,CAAC;IACvE,OAAO,CAAC,GAAG,CAAC,8BAA8B,EAAE,6BAA6B,CAAC,CAAC;IAC3E,OAAO,CAAC,GAAG,CAAC,mBAAmB,EAAE,mBAAmB,CAAC,CAAC;IAEtD,OAAO,OAAO,CAAC;AACjB,CAAC"}
@@ -2,8 +2,8 @@
2
2
  """
3
3
  Deterministic codebase retrieval intent router (Python template).
4
4
 
5
- Mirrors packages/cli/src/utils/codebase-retrieval-router.ts for dogfood and
6
- get_context retrieval-pack flows. Does not invoke rg, MCP, or network tools.
5
+ Shared contract with the Trellis CLI router; used by hooks, route_codebase_retrieval.py,
6
+ and get_context retrieval-pack flows. Does not invoke rg, MCP, or network tools.
7
7
  """
8
8
 
9
9
  from __future__ import annotations
@@ -289,7 +289,7 @@ def get_packages(repo_root: Path | None = None) -> dict[str, dict] | None:
289
289
  or None if not configured (single-repo mode).
290
290
 
291
291
  Example return:
292
- {"cli": {"path": "packages/cli"}, "docs-site": {"path": "docs-site", "type": "submodule"}}
292
+ {"api": {"path": "packages/api"}, "web": {"path": "packages/web"}}
293
293
  """
294
294
  config = _load_config(repo_root)
295
295
  packages = config.get("packages")
@@ -16,6 +16,7 @@ from .paths import get_repo_root
16
16
  from .task_gates import (
17
17
  build_spec_update_scaffold,
18
18
  durable_learning_decision_status,
19
+ task_closeout_profile,
19
20
  )
20
21
  from .task_map import (
21
22
  PARENT_TERMINAL_STATES,
@@ -31,7 +32,6 @@ _GLOBAL_CHILD_CONSTRAINTS = """General constraints:
31
32
  - Stay inside your child scope and declared touch areas.
32
33
  - Do not publish packages, push remotes, create tags, edit credentials, or change global/MCP configuration.
33
34
  - Preserve explicit user approval for destructive, remote, credential-bearing, publish, push, tag, and global configuration actions.
34
- - Keep template and dogfood copies synchronized when touching `.trellis/scripts` or Trellis CLI templates.
35
35
  - Write `verify.md` and `handoff.md` in your child task directory.
36
36
  - Handoff must include changed files, validation commands/results, residual risks, and parent integration notes.
37
37
  - If you find a needed contract change, stop and report it to the parent instead of silently redefining shared state/gate semantics.
@@ -530,18 +530,29 @@ def build_review_report(
530
530
  ),
531
531
  }
532
532
  )
533
- actions["gates"].append(
534
- {
535
- "task": "child",
536
- "transition": "child-review",
537
- "optional": True,
538
- "hint": (
539
- f"python ./.trellis/scripts/task.py record-gate {child_name} "
540
- f"--transition child-review --gate code-review --result PASS "
541
- f"--reviewer parent --evidence verify.md"
542
- ),
543
- }
544
- )
533
+ child_profile = task_closeout_profile(child_dir, child_data)
534
+ if child_profile == "full":
535
+ actions["gates"].append(
536
+ {
537
+ "task": "child",
538
+ "transition": "child-review",
539
+ "optional": False,
540
+ "hint": (
541
+ f"Required before accept: python ./.trellis/scripts/task.py record-gate {child_name} "
542
+ f"--transition child-review --gate code-review --result PASS "
543
+ f"--reviewer parent --evidence verify.md"
544
+ ),
545
+ }
546
+ )
547
+ elif child_profile == "lite":
548
+ actions["gates"].append(
549
+ {
550
+ "task": "child",
551
+ "transition": "child-review",
552
+ "optional": True,
553
+ "hint": "Lite child: no child-review gate chain required.",
554
+ }
555
+ )
545
556
  elif decision == "changes":
546
557
  target = "changes"
547
558
  errors.extend(
@@ -611,6 +622,7 @@ def build_review_report(
611
622
  evidence,
612
623
  ref,
613
624
  reason,
625
+ current_state_override=sim_state,
614
626
  )
615
627
  errors.extend(step_errors)
616
628
  if step_errors:
@@ -626,9 +638,9 @@ def build_review_report(
626
638
  {
627
639
  "task": "parent",
628
640
  "transition": "parent-integrated",
629
- "optional": True,
641
+ "optional": False,
630
642
  "hint": (
631
- f"python ./.trellis/scripts/task.py record-gate {parent_dir.name} "
643
+ f"Required before parent archive: python ./.trellis/scripts/task.py record-gate {parent_dir.name} "
632
644
  f"--transition parent-integrated --gate integration-review --result PASS "
633
645
  f"--reviewer parent --evidence task-map.md"
634
646
  ),
@@ -157,7 +157,7 @@ def _cursor_step_for_route(
157
157
  return (
158
158
  "使用 Cursor **内置代码库语义搜索**(宿主工具常为 **SemanticSearch**;"
159
159
  "**`target_directories`** 为目录 glob 数组,省略会报错;**`[]`** = 不缩范围、搜全工作区索引;"
160
- "若计划或 Grep/codegraph 已指向子树可传如 `['Trellis/packages/cli']`;"
160
+ "若计划或 Grep/codegraph 已指向子树可传如 `['src/components']`;"
161
161
  "无路径线索的概念题优先 **`[]`**;Native 下 **不要**用 fast-context MCP 顶替)。"
162
162
  )
163
163
  if role == "semantic":
@@ -65,6 +65,12 @@ def _npm_local_wrappers(repo_root: Path) -> list[list[str]]:
65
65
  repo_root / "node_modules" / ".bin" / "smart-search.js",
66
66
  repo_root
67
67
  / "node_modules"
68
+ / "@blxzer"
69
+ / "cursor-trellis"
70
+ / "bin"
71
+ / "smart-search.js",
72
+ repo_root
73
+ / "node_modules"
68
74
  / "@konbakuyomu"
69
75
  / "smart-search"
70
76
  / "npm"
@@ -83,9 +89,28 @@ def _npm_local_wrappers(repo_root: Path) -> list[list[str]]:
83
89
  return out
84
90
 
85
91
 
86
- def _harness_wrappers(repo_root: Path) -> list[list[str]]:
87
- """Optional polyrepo harness layouts (e.g. MyHarness)."""
92
+ def _optional_repo_wrappers(repo_root: Path) -> list[list[str]]:
93
+ """
94
+ Optional repo-local layouts when PATH and node_modules resolution fail.
95
+
96
+ Order is intentional: published npm co-install, standalone smart-search package,
97
+ then maintainer polyrepo sibling checkouts (names vary by fork/upstream).
98
+ """
88
99
  candidates: list[Path] = [
100
+ repo_root
101
+ / "node_modules"
102
+ / "@blxzer"
103
+ / "cursor-trellis"
104
+ / "bin"
105
+ / "smart-search.js",
106
+ repo_root
107
+ / "node_modules"
108
+ / "@konbakuyomu"
109
+ / "smart-search"
110
+ / "npm"
111
+ / "bin"
112
+ / "smart-search.js",
113
+ repo_root / "cursor-trellis" / "packages" / "cli" / "bin" / "smart-search.js",
89
114
  repo_root / "Trellis" / "packages" / "cli" / "bin" / "smart-search.js",
90
115
  repo_root / "smartsearch-private" / "npm" / "bin" / "smart-search.js",
91
116
  ]
@@ -115,7 +140,7 @@ def resolve_smart_search_argv(repo_root: Path | None = None) -> list[str] | None
115
140
  for argv in _npm_local_wrappers(root):
116
141
  return argv
117
142
 
118
- for argv in _harness_wrappers(root):
143
+ for argv in _optional_repo_wrappers(root):
119
144
  return argv
120
145
 
121
146
  return None