@mindfoldhq/trellis 0.5.0-beta.8 → 0.5.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +60 -95
- package/dist/cli/index.js +7 -0
- package/dist/cli/index.js.map +1 -1
- package/dist/commands/init.d.ts +13 -0
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +474 -210
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +295 -54
- package/dist/commands/update.js.map +1 -1
- package/dist/configurators/antigravity.d.ts.map +1 -1
- package/dist/configurators/antigravity.js +2 -8
- package/dist/configurators/antigravity.js.map +1 -1
- package/dist/configurators/claude.d.ts.map +1 -1
- package/dist/configurators/claude.js +4 -10
- package/dist/configurators/claude.js.map +1 -1
- package/dist/configurators/codebuddy.d.ts.map +1 -1
- package/dist/configurators/codebuddy.js +3 -3
- package/dist/configurators/codebuddy.js.map +1 -1
- package/dist/configurators/codex.d.ts.map +1 -1
- package/dist/configurators/codex.js +5 -13
- package/dist/configurators/codex.js.map +1 -1
- package/dist/configurators/copilot.d.ts.map +1 -1
- package/dist/configurators/copilot.js +5 -19
- package/dist/configurators/copilot.js.map +1 -1
- package/dist/configurators/cursor.d.ts.map +1 -1
- package/dist/configurators/cursor.js +3 -3
- package/dist/configurators/cursor.js.map +1 -1
- package/dist/configurators/droid.d.ts.map +1 -1
- package/dist/configurators/droid.js +3 -3
- package/dist/configurators/droid.js.map +1 -1
- package/dist/configurators/gemini.d.ts.map +1 -1
- package/dist/configurators/gemini.js +3 -5
- package/dist/configurators/gemini.js.map +1 -1
- package/dist/configurators/index.d.ts.map +1 -1
- package/dist/configurators/index.js +44 -55
- package/dist/configurators/index.js.map +1 -1
- package/dist/configurators/kilo.d.ts.map +1 -1
- package/dist/configurators/kilo.js +2 -8
- package/dist/configurators/kilo.js.map +1 -1
- package/dist/configurators/kiro.d.ts.map +1 -1
- package/dist/configurators/kiro.js +3 -3
- package/dist/configurators/kiro.js.map +1 -1
- package/dist/configurators/opencode.d.ts.map +1 -1
- package/dist/configurators/opencode.js +7 -4
- package/dist/configurators/opencode.js.map +1 -1
- package/dist/configurators/pi.d.ts +3 -0
- package/dist/configurators/pi.d.ts.map +1 -0
- package/dist/configurators/pi.js +44 -0
- package/dist/configurators/pi.js.map +1 -0
- package/dist/configurators/qoder.d.ts +7 -6
- package/dist/configurators/qoder.d.ts.map +1 -1
- package/dist/configurators/qoder.js +18 -12
- package/dist/configurators/qoder.js.map +1 -1
- package/dist/configurators/shared.d.ts +30 -6
- package/dist/configurators/shared.d.ts.map +1 -1
- package/dist/configurators/shared.js +65 -15
- package/dist/configurators/shared.js.map +1 -1
- package/dist/configurators/windsurf.d.ts.map +1 -1
- package/dist/configurators/windsurf.js +2 -8
- package/dist/configurators/windsurf.js.map +1 -1
- package/dist/constants/paths.d.ts +2 -0
- package/dist/constants/paths.d.ts.map +1 -1
- package/dist/constants/paths.js +2 -0
- package/dist/constants/paths.js.map +1 -1
- package/dist/migrations/manifests/0.5.0-beta.0.json +2 -0
- package/dist/migrations/manifests/0.5.0-beta.10.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.11.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.12.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.13.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.14.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.15.json +116 -0
- package/dist/migrations/manifests/0.5.0-beta.16.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.17.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.18.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.19.json +9 -0
- package/dist/migrations/manifests/0.5.0-beta.5.json +2 -0
- package/dist/migrations/manifests/0.5.0-beta.9.json +48 -0
- package/dist/migrations/manifests/0.5.0-rc.0.json +9 -0
- package/dist/templates/claude/agents/trellis-research.md +1 -1
- package/dist/templates/claude/settings.json +0 -4
- package/dist/templates/codebuddy/agents/trellis-research.md +1 -1
- package/dist/templates/codex/agents/trellis-research.toml +3 -2
- package/dist/templates/codex/hooks/session-start.py +126 -26
- package/dist/templates/codex/skills/finish-work/SKILL.md +41 -109
- package/dist/templates/codex/skills/start/SKILL.md +12 -9
- package/dist/templates/common/bundled-skills/trellis-meta/SKILL.md +73 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/add-project-local-conventions.md +83 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-agents.md +54 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-context-loading.md +81 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-hooks.md +57 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-skills-or-commands.md +78 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-spec-structure.md +83 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-task-lifecycle.md +90 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-workflow.md +64 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/overview.md +55 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/context-injection.md +68 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/generated-files.md +80 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/overview.md +51 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/spec-system.md +102 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/task-system.md +101 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/workflow.md +75 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/workspace-memory.md +71 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/agents.md +79 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/hooks-and-settings.md +69 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/overview.md +59 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/platform-map.md +74 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/skills-and-commands.md +83 -0
- package/dist/templates/common/commands/continue.md +9 -5
- package/dist/templates/common/commands/finish-work.md +34 -10
- package/dist/templates/common/index.d.ts +22 -2
- package/dist/templates/common/index.d.ts.map +1 -1
- package/dist/templates/common/index.js +53 -4
- package/dist/templates/common/index.js.map +1 -1
- package/dist/templates/common/skills/brainstorm.md +50 -4
- package/dist/templates/copilot/hooks/session-start.py +127 -30
- package/dist/templates/copilot/prompts/finish-work.prompt.md +44 -112
- package/dist/templates/copilot/prompts/start.prompt.md +12 -9
- package/dist/templates/cursor/agents/trellis-check.md +1 -1
- package/dist/templates/cursor/agents/trellis-implement.md +1 -1
- package/dist/templates/cursor/agents/trellis-research.md +2 -2
- package/dist/templates/cursor/hooks.json +7 -1
- package/dist/templates/droid/droids/trellis-research.md +1 -1
- package/dist/templates/extract.d.ts +6 -0
- package/dist/templates/extract.d.ts.map +1 -1
- package/dist/templates/extract.js +14 -0
- package/dist/templates/extract.js.map +1 -1
- package/dist/templates/gemini/agents/trellis-research.md +1 -1
- package/dist/templates/kiro/agents/trellis-research.json +1 -1
- package/dist/templates/markdown/agents.md +19 -12
- package/dist/templates/markdown/gitignore.txt +3 -0
- package/dist/templates/markdown/spec/guides/cross-platform-thinking-guide.md.txt +24 -0
- package/dist/templates/opencode/agents/trellis-check.md +1 -1
- package/dist/templates/opencode/agents/trellis-implement.md +7 -4
- package/dist/templates/opencode/agents/trellis-research.md +2 -2
- package/dist/templates/opencode/lib/trellis-context.js +100 -13
- package/dist/templates/opencode/plugins/inject-subagent-context.js +70 -5
- package/dist/templates/opencode/plugins/inject-workflow-state.js +38 -44
- package/dist/templates/opencode/plugins/session-start.js +76 -31
- package/dist/templates/pi/agents/trellis-check.md +28 -0
- package/dist/templates/pi/agents/trellis-implement.md +33 -0
- package/dist/templates/pi/agents/trellis-research.md +25 -0
- package/dist/templates/pi/extensions/trellis/index.ts.txt +997 -0
- package/dist/templates/pi/index.d.ts +5 -0
- package/dist/templates/pi/index.d.ts.map +1 -0
- package/dist/templates/pi/index.js +12 -0
- package/dist/templates/pi/index.js.map +1 -0
- package/dist/templates/pi/settings.json +12 -0
- package/dist/templates/qoder/agents/trellis-research.md +1 -1
- package/dist/templates/shared-hooks/index.d.ts +31 -0
- package/dist/templates/shared-hooks/index.d.ts.map +1 -1
- package/dist/templates/shared-hooks/index.js +59 -0
- package/dist/templates/shared-hooks/index.js.map +1 -1
- package/dist/templates/shared-hooks/inject-shell-session-context.py +180 -0
- package/dist/templates/shared-hooks/inject-subagent-context.py +156 -27
- package/dist/templates/shared-hooks/inject-workflow-state.py +85 -92
- package/dist/templates/shared-hooks/session-start.py +232 -36
- package/dist/templates/trellis/config.yaml +6 -0
- package/dist/templates/trellis/gitignore.txt +3 -0
- package/dist/templates/trellis/index.d.ts +1 -1
- package/dist/templates/trellis/index.d.ts.map +1 -1
- package/dist/templates/trellis/index.js +2 -2
- package/dist/templates/trellis/index.js.map +1 -1
- package/dist/templates/trellis/scripts/common/__init__.py +8 -0
- package/dist/templates/trellis/scripts/common/active_task.py +593 -0
- package/dist/templates/trellis/scripts/common/cli_adapter.py +72 -14
- package/dist/templates/trellis/scripts/common/paths.py +61 -58
- package/dist/templates/trellis/scripts/common/session_context.py +12 -0
- package/dist/templates/trellis/scripts/common/task_context.py +27 -194
- package/dist/templates/trellis/scripts/common/task_store.py +102 -26
- package/dist/templates/trellis/scripts/common/tasks.py +4 -1
- package/dist/templates/trellis/scripts/common/types.py +0 -2
- package/dist/templates/trellis/scripts/common/workflow_phase.py +15 -3
- package/dist/templates/trellis/scripts/task.py +99 -34
- package/dist/templates/trellis/workflow.md +332 -64
- package/dist/types/ai-tools.d.ts +12 -3
- package/dist/types/ai-tools.d.ts.map +1 -1
- package/dist/types/ai-tools.js +29 -0
- package/dist/types/ai-tools.js.map +1 -1
- package/dist/utils/file-writer.d.ts.map +1 -1
- package/dist/utils/file-writer.js +7 -2
- package/dist/utils/file-writer.js.map +1 -1
- package/dist/utils/posix.d.ts +13 -0
- package/dist/utils/posix.d.ts.map +1 -0
- package/dist/utils/posix.js +15 -0
- package/dist/utils/posix.js.map +1 -0
- package/dist/utils/project-detector.d.ts +2 -0
- package/dist/utils/project-detector.d.ts.map +1 -1
- package/dist/utils/project-detector.js +120 -11
- package/dist/utils/project-detector.js.map +1 -1
- package/dist/utils/task-json.d.ts +46 -0
- package/dist/utils/task-json.d.ts.map +1 -0
- package/dist/utils/task-json.js +49 -0
- package/dist/utils/task-json.js.map +1 -0
- package/dist/utils/template-fetcher.d.ts +22 -6
- package/dist/utils/template-fetcher.d.ts.map +1 -1
- package/dist/utils/template-fetcher.js +405 -27
- package/dist/utils/template-fetcher.js.map +1 -1
- package/dist/utils/template-hash.d.ts +22 -3
- package/dist/utils/template-hash.d.ts.map +1 -1
- package/dist/utils/template-hash.js +99 -19
- package/dist/utils/template-hash.js.map +1 -1
- package/package.json +7 -7
- package/dist/templates/markdown/spec/backend/directory-structure.md +0 -292
- package/dist/templates/markdown/spec/backend/index.md +0 -40
- package/dist/templates/markdown/spec/backend/script-conventions.md +0 -742
- package/dist/templates/markdown/spec/guides/code-reuse-thinking-guide.md +0 -118
- package/dist/templates/markdown/spec/guides/cross-platform-thinking-guide.md +0 -394
- package/dist/templates/shared-hooks/statusline.py +0 -218
- package/dist/templates/trellis/scripts/create_bootstrap.py +0 -298
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
"""
|
|
4
4
|
Session Start Hook - Inject structured context
|
|
5
5
|
"""
|
|
6
|
+
from __future__ import annotations
|
|
6
7
|
|
|
7
8
|
# IMPORTANT: Suppress all warnings FIRST
|
|
8
9
|
import warnings
|
|
@@ -10,14 +11,22 @@ warnings.filterwarnings("ignore")
|
|
|
10
11
|
|
|
11
12
|
import json
|
|
12
13
|
import os
|
|
14
|
+
import re
|
|
15
|
+
import shlex
|
|
13
16
|
import subprocess
|
|
14
17
|
import sys
|
|
15
18
|
from io import StringIO
|
|
16
19
|
from pathlib import Path
|
|
17
20
|
|
|
21
|
+
FIRST_REPLY_NOTICE = """<first-reply-notice>
|
|
22
|
+
On the first visible assistant reply in this session, begin with exactly one short Chinese sentence:
|
|
23
|
+
Trellis SessionStart 已注入:workflow、当前任务状态、开发者身份、git 状态、active tasks、spec 索引已加载。
|
|
24
|
+
Then continue directly with the user's request. This notice is one-shot: do not repeat it after the first assistant reply in the same session.
|
|
25
|
+
</first-reply-notice>"""
|
|
26
|
+
|
|
18
27
|
# IMPORTANT: Force stdout to use UTF-8 on Windows
|
|
19
28
|
# This fixes UnicodeEncodeError when outputting non-ASCII characters
|
|
20
|
-
if sys.platform
|
|
29
|
+
if sys.platform.startswith("win"):
|
|
21
30
|
import io as _io
|
|
22
31
|
if hasattr(sys.stdout, "reconfigure"):
|
|
23
32
|
sys.stdout.reconfigure(encoding="utf-8", errors="replace") # type: ignore[union-attr]
|
|
@@ -26,6 +35,30 @@ if sys.platform == "win32":
|
|
|
26
35
|
|
|
27
36
|
|
|
28
37
|
|
|
38
|
+
def _has_curated_jsonl_entry(jsonl_path: Path) -> bool:
|
|
39
|
+
"""Return True iff jsonl has at least one row with a ``file`` field.
|
|
40
|
+
|
|
41
|
+
A freshly seeded jsonl only contains a ``{"_example": ...}`` row (no
|
|
42
|
+
``file`` key) — that is NOT "ready". Readiness requires at least one
|
|
43
|
+
curated entry. Matches the contract used by hook-inject and pull-based
|
|
44
|
+
sub-agent context loaders.
|
|
45
|
+
"""
|
|
46
|
+
try:
|
|
47
|
+
for line in jsonl_path.read_text(encoding="utf-8").splitlines():
|
|
48
|
+
line = line.strip()
|
|
49
|
+
if not line:
|
|
50
|
+
continue
|
|
51
|
+
try:
|
|
52
|
+
row = json.loads(line)
|
|
53
|
+
except json.JSONDecodeError:
|
|
54
|
+
continue
|
|
55
|
+
if isinstance(row, dict) and row.get("file"):
|
|
56
|
+
return True
|
|
57
|
+
except (OSError, UnicodeDecodeError):
|
|
58
|
+
return False
|
|
59
|
+
return False
|
|
60
|
+
|
|
61
|
+
|
|
29
62
|
def should_skip_injection() -> bool:
|
|
30
63
|
"""Check if any platform's non-interactive flag is set."""
|
|
31
64
|
non_interactive_vars = [
|
|
@@ -48,15 +81,97 @@ def read_file(path: Path, fallback: str = "") -> str:
|
|
|
48
81
|
return fallback
|
|
49
82
|
|
|
50
83
|
|
|
51
|
-
def
|
|
84
|
+
def _detect_platform(input_data: dict) -> str | None:
|
|
85
|
+
if isinstance(input_data.get("cursor_version"), str):
|
|
86
|
+
return "cursor"
|
|
87
|
+
env_map = {
|
|
88
|
+
"CLAUDE_PROJECT_DIR": "claude",
|
|
89
|
+
"CURSOR_PROJECT_DIR": "cursor",
|
|
90
|
+
"CODEBUDDY_PROJECT_DIR": "codebuddy",
|
|
91
|
+
"FACTORY_PROJECT_DIR": "droid",
|
|
92
|
+
"GEMINI_PROJECT_DIR": "gemini",
|
|
93
|
+
"QODER_PROJECT_DIR": "qoder",
|
|
94
|
+
"KIRO_PROJECT_DIR": "kiro",
|
|
95
|
+
"COPILOT_PROJECT_DIR": "copilot",
|
|
96
|
+
}
|
|
97
|
+
for env_name, platform in env_map.items():
|
|
98
|
+
if os.environ.get(env_name):
|
|
99
|
+
return platform
|
|
100
|
+
script_parts = set(Path(sys.argv[0]).parts)
|
|
101
|
+
if ".claude" in script_parts:
|
|
102
|
+
return "claude"
|
|
103
|
+
if ".cursor" in script_parts:
|
|
104
|
+
return "cursor"
|
|
105
|
+
if ".codex" in script_parts:
|
|
106
|
+
return "codex"
|
|
107
|
+
if ".gemini" in script_parts:
|
|
108
|
+
return "gemini"
|
|
109
|
+
if ".qoder" in script_parts:
|
|
110
|
+
return "qoder"
|
|
111
|
+
if ".codebuddy" in script_parts:
|
|
112
|
+
return "codebuddy"
|
|
113
|
+
if ".factory" in script_parts:
|
|
114
|
+
return "droid"
|
|
115
|
+
if ".kiro" in script_parts:
|
|
116
|
+
return "kiro"
|
|
117
|
+
return None
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
def _resolve_context_key(trellis_dir: Path, input_data: dict) -> str | None:
|
|
121
|
+
scripts_dir = trellis_dir / "scripts"
|
|
122
|
+
if str(scripts_dir) not in sys.path:
|
|
123
|
+
sys.path.insert(0, str(scripts_dir))
|
|
124
|
+
from common.active_task import resolve_context_key # type: ignore[import-not-found]
|
|
125
|
+
|
|
126
|
+
return resolve_context_key(input_data, platform=_detect_platform(input_data))
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
def _persist_context_key_for_bash(context_key: str | None) -> None:
|
|
130
|
+
"""Expose Trellis session identity to later Claude Code Bash commands.
|
|
131
|
+
|
|
132
|
+
Claude Code SessionStart hooks can append exports to CLAUDE_ENV_FILE; those
|
|
133
|
+
variables are then available to Bash tools in the same conversation. Without
|
|
134
|
+
this bridge, `task.py start` has hook stdin during SessionStart but no
|
|
135
|
+
session identity when the AI later runs it as a normal shell command.
|
|
136
|
+
"""
|
|
137
|
+
if not context_key:
|
|
138
|
+
return
|
|
139
|
+
env_file = os.environ.get("CLAUDE_ENV_FILE")
|
|
140
|
+
if not env_file:
|
|
141
|
+
return
|
|
142
|
+
try:
|
|
143
|
+
with open(env_file, "a", encoding="utf-8") as handle:
|
|
144
|
+
handle.write(f"export TRELLIS_CONTEXT_ID={shlex.quote(context_key)}\n")
|
|
145
|
+
except OSError:
|
|
146
|
+
pass
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
def _resolve_active_task(trellis_dir: Path, input_data: dict):
|
|
150
|
+
scripts_dir = trellis_dir / "scripts"
|
|
151
|
+
if str(scripts_dir) not in sys.path:
|
|
152
|
+
sys.path.insert(0, str(scripts_dir))
|
|
153
|
+
from common.active_task import resolve_active_task # type: ignore[import-not-found]
|
|
154
|
+
|
|
155
|
+
return resolve_active_task(
|
|
156
|
+
trellis_dir.parent,
|
|
157
|
+
input_data,
|
|
158
|
+
platform=_detect_platform(input_data),
|
|
159
|
+
)
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
def run_script(script_path: Path, context_key: str | None = None) -> str:
|
|
52
163
|
try:
|
|
53
164
|
if script_path.suffix == ".py":
|
|
54
165
|
# Add PYTHONIOENCODING to force UTF-8 in subprocess
|
|
55
166
|
env = os.environ.copy()
|
|
56
167
|
env["PYTHONIOENCODING"] = "utf-8"
|
|
168
|
+
if context_key:
|
|
169
|
+
env["TRELLIS_CONTEXT_ID"] = context_key
|
|
57
170
|
cmd = [sys.executable, "-W", "ignore", str(script_path)]
|
|
58
171
|
else:
|
|
59
|
-
env = os.environ
|
|
172
|
+
env = os.environ.copy()
|
|
173
|
+
if context_key:
|
|
174
|
+
env["TRELLIS_CONTEXT_ID"] = context_key
|
|
60
175
|
cmd = [str(script_path)]
|
|
61
176
|
|
|
62
177
|
result = subprocess.run(
|
|
@@ -103,7 +218,7 @@ def _resolve_task_dir(trellis_dir: Path, task_ref: str) -> Path:
|
|
|
103
218
|
return trellis_dir / "tasks" / path_obj
|
|
104
219
|
|
|
105
220
|
|
|
106
|
-
def _get_task_status(trellis_dir: Path) -> str:
|
|
221
|
+
def _get_task_status(trellis_dir: Path, input_data: dict) -> str:
|
|
107
222
|
"""Check current task status and return structured status string with explicit next action.
|
|
108
223
|
|
|
109
224
|
Returns a block with three fields:
|
|
@@ -111,23 +226,32 @@ def _get_task_status(trellis_dir: Path) -> str:
|
|
|
111
226
|
- Task: task identifier (when applicable)
|
|
112
227
|
- Next-Action: explicit skill/command/tool call the AI should invoke
|
|
113
228
|
"""
|
|
114
|
-
|
|
229
|
+
active = _resolve_active_task(trellis_dir, input_data)
|
|
115
230
|
|
|
116
231
|
# Case 1: No active task — waiting for user to describe intent
|
|
117
|
-
if not
|
|
232
|
+
if not active.task_path:
|
|
118
233
|
return (
|
|
119
234
|
"Status: NO ACTIVE TASK\n"
|
|
235
|
+
f"Source: {active.source}\n"
|
|
120
236
|
"Next-Action: After the user describes their intent, load skill `trellis-brainstorm` "
|
|
121
|
-
"to clarify requirements and create a task via `python3 ./.trellis/scripts/task.py create
|
|
237
|
+
"to clarify requirements and create a task via `python3 ./.trellis/scripts/task.py create`.\n"
|
|
238
|
+
"Research reminder: for research-heavy tasks (comparing tools, reading external docs, "
|
|
239
|
+
"cross-platform surveys), spawn `trellis-research` sub-agents via the Task tool — "
|
|
240
|
+
"they persist findings to `{TASK_DIR}/research/*.md` and keep main context clean. "
|
|
241
|
+
"Do NOT do 10+ inline WebFetch/WebSearch in the main conversation.\n"
|
|
242
|
+
"User override (per-turn escape hatch): if the user's first message explicitly opts "
|
|
243
|
+
"out of the workflow (\"跳过 trellis\" / \"别走流程\" / \"小修一下\" / \"直接改\" / "
|
|
244
|
+
"\"skip trellis\" / \"no task\" / \"just do it\"), honor it for this turn — "
|
|
245
|
+
"acknowledge briefly and proceed without creating a task. Per-turn only."
|
|
122
246
|
)
|
|
123
247
|
|
|
124
|
-
task_ref = _normalize_task_ref(current_task_file.read_text(encoding="utf-8").strip())
|
|
125
|
-
|
|
126
248
|
# Case 2: Stale pointer — task dir was deleted
|
|
249
|
+
task_ref = active.task_path
|
|
127
250
|
task_dir = _resolve_task_dir(trellis_dir, task_ref)
|
|
128
|
-
if not task_dir.is_dir():
|
|
251
|
+
if active.stale or not task_dir.is_dir():
|
|
129
252
|
return (
|
|
130
253
|
f"Status: STALE POINTER\nTask: {task_ref}\n"
|
|
254
|
+
f"Source: {active.source}\n"
|
|
131
255
|
f"Next-Action: Run `python3 ./.trellis/scripts/task.py finish` to clear the stale pointer, "
|
|
132
256
|
"then ask the user what to work on next."
|
|
133
257
|
)
|
|
@@ -148,6 +272,7 @@ def _get_task_status(trellis_dir: Path) -> str:
|
|
|
148
272
|
if task_status == "completed":
|
|
149
273
|
return (
|
|
150
274
|
f"Status: COMPLETED\nTask: {task_title}\n"
|
|
275
|
+
f"Source: {active.source}\n"
|
|
151
276
|
f"Next-Action: Load skill `trellis-update-spec` to capture learnings, "
|
|
152
277
|
f"then archive with `python3 ./.trellis/scripts/task.py archive {task_dir.name}`."
|
|
153
278
|
)
|
|
@@ -158,20 +283,46 @@ def _get_task_status(trellis_dir: Path) -> str:
|
|
|
158
283
|
if not has_prd:
|
|
159
284
|
return (
|
|
160
285
|
f"Status: PLANNING\nTask: {task_title}\n"
|
|
286
|
+
f"Source: {active.source}\n"
|
|
161
287
|
"Next-Action: Load skill `trellis-brainstorm` to clarify requirements with the user "
|
|
162
|
-
"and produce prd.md in the task directory
|
|
288
|
+
"and produce prd.md in the task directory.\n"
|
|
289
|
+
"Research reminder: when the task needs external research (tool comparison, docs, "
|
|
290
|
+
"conventions survey), spawn `trellis-research` sub-agents — don't WebFetch/WebSearch "
|
|
291
|
+
"inline in the main session. Findings go to `{task_dir}/research/*.md`; PRD only links to them."
|
|
292
|
+
)
|
|
293
|
+
|
|
294
|
+
# Case 4b: PRD exists but implement.jsonl has only seed (no curated entries) — Phase 1.3 gate
|
|
295
|
+
implement_jsonl = task_dir / "implement.jsonl"
|
|
296
|
+
if implement_jsonl.is_file() and not _has_curated_jsonl_entry(implement_jsonl):
|
|
297
|
+
return (
|
|
298
|
+
f"Status: PLANNING (Phase 1.3)\nTask: {task_title}\n"
|
|
299
|
+
f"Source: {active.source}\n"
|
|
300
|
+
"Next-Action: Curate `implement.jsonl` and `check.jsonl` with the spec + research files "
|
|
301
|
+
"the Phase 2 sub-agents will need. Only spec paths (`.trellis/spec/**/*.md`) and research "
|
|
302
|
+
"files (`{TASK_DIR}/research/*.md`) — no code paths. Run "
|
|
303
|
+
"`python3 ./.trellis/scripts/get_context.py --mode packages` to list available specs, "
|
|
304
|
+
"then edit the jsonl files or use `python3 ./.trellis/scripts/task.py add-context`. "
|
|
305
|
+
"See `.trellis/workflow.md` Phase 1.3 for details."
|
|
163
306
|
)
|
|
164
307
|
|
|
165
|
-
# Case 5: PRD
|
|
308
|
+
# Case 5: PRD + curated jsonl (or agent-less platform with no jsonl) — enter Execute phase
|
|
166
309
|
return (
|
|
167
310
|
f"Status: READY\nTask: {task_title}\n"
|
|
168
|
-
"
|
|
169
|
-
"
|
|
170
|
-
"
|
|
311
|
+
f"Source: {active.source}\n"
|
|
312
|
+
"Next required action: dispatch `trellis-implement` per Phase 2.1. "
|
|
313
|
+
"For agent-capable platforms, the default is to NOT edit code in the main session. "
|
|
314
|
+
"After implementation, dispatch `trellis-check` per Phase 2.2 before reporting completion.\n"
|
|
315
|
+
"Sub-agent roster: `trellis-implement` (writes code), `trellis-check` (verifies + self-fixes), "
|
|
316
|
+
"`trellis-research` (persists findings to `research/*.md` — use when you'd otherwise do "
|
|
317
|
+
"multiple WebFetch/WebSearch inline).\n"
|
|
318
|
+
"User override (per-turn escape hatch): if the user's CURRENT message explicitly tells the "
|
|
319
|
+
"main session to handle it directly (\"你直接改\" / \"别派 sub-agent\" / \"main session 写就行\" / "
|
|
320
|
+
"\"do it inline\" / \"不用 sub-agent\"), honor it for this turn and edit code directly. "
|
|
321
|
+
"Per-turn only; do NOT invent an override the user did not say."
|
|
171
322
|
)
|
|
172
323
|
|
|
173
324
|
|
|
174
|
-
def _load_trellis_config(trellis_dir: Path) -> tuple:
|
|
325
|
+
def _load_trellis_config(trellis_dir: Path, input_data: dict) -> tuple:
|
|
175
326
|
"""Load Trellis config for session-start decisions.
|
|
176
327
|
|
|
177
328
|
Returns:
|
|
@@ -192,7 +343,11 @@ def _load_trellis_config(trellis_dir: Path) -> tuple:
|
|
|
192
343
|
|
|
193
344
|
# Get active task's package
|
|
194
345
|
task_pkg = None
|
|
195
|
-
current = get_current_task(
|
|
346
|
+
current = get_current_task(
|
|
347
|
+
repo_root,
|
|
348
|
+
input_data,
|
|
349
|
+
platform=_detect_platform(input_data),
|
|
350
|
+
)
|
|
196
351
|
if current:
|
|
197
352
|
task_json = repo_root / current / "task.json"
|
|
198
353
|
if task_json.is_file():
|
|
@@ -341,6 +496,24 @@ def _extract_range(content: str, start_header: str, end_header: str) -> str:
|
|
|
341
496
|
return "\n".join(lines[start:end]).rstrip()
|
|
342
497
|
|
|
343
498
|
|
|
499
|
+
_BREADCRUMB_TAG_RE = re.compile(
|
|
500
|
+
r"\[workflow-state:([A-Za-z0-9_-]+)\]\s*\n.*?\n\s*\[/workflow-state:\1\]",
|
|
501
|
+
re.DOTALL,
|
|
502
|
+
)
|
|
503
|
+
|
|
504
|
+
|
|
505
|
+
def _strip_breadcrumb_tag_blocks(content: str) -> str:
|
|
506
|
+
"""Remove `[workflow-state:STATUS]...[/workflow-state:STATUS]` blocks.
|
|
507
|
+
|
|
508
|
+
The tag blocks live inside `## Phase Index` (since v0.5.0-rc.0, when
|
|
509
|
+
they were colocated with their phase summaries) and are consumed by the
|
|
510
|
+
UserPromptSubmit hook (`inject-workflow-state.py`). The session-start
|
|
511
|
+
payload already covers the full step bodies, so re-inlining the
|
|
512
|
+
breadcrumbs here would just duplicate context.
|
|
513
|
+
"""
|
|
514
|
+
return _BREADCRUMB_TAG_RE.sub("", content)
|
|
515
|
+
|
|
516
|
+
|
|
344
517
|
def _build_workflow_overview(workflow_path: Path) -> str:
|
|
345
518
|
"""Inject the workflow guide for the session.
|
|
346
519
|
|
|
@@ -349,10 +522,13 @@ def _build_workflow_overview(workflow_path: Path) -> str:
|
|
|
349
522
|
2. Phase Index section (rules, skill routing table, anti-rationalization table)
|
|
350
523
|
3. Phase 1/2/3 step-level details (the actual how-to for each step)
|
|
351
524
|
|
|
352
|
-
The meta sections (Core Principles / Trellis System /
|
|
353
|
-
|
|
525
|
+
The meta sections (Core Principles / Trellis System / Customizing
|
|
526
|
+
Trellis) are NOT injected — Core Principles is short prose the AI can
|
|
354
527
|
Read on demand; Trellis System lists reference commands duplicated in
|
|
355
|
-
step bodies;
|
|
528
|
+
step bodies; Customizing Trellis is for forks. Workflow-state breadcrumb
|
|
529
|
+
tag blocks (which now live inside Phase Index since v0.5.0-rc.0) are
|
|
530
|
+
stripped from the extracted range — they're consumed by the
|
|
531
|
+
UserPromptSubmit hook, not the session-start preamble.
|
|
356
532
|
|
|
357
533
|
Total budget: Phase Index ~2 KB + Phase 1/2/3 ~7 KB = ~9 KB.
|
|
358
534
|
"""
|
|
@@ -371,14 +547,17 @@ def _build_workflow_overview(workflow_path: Path) -> str:
|
|
|
371
547
|
out_lines.append(line)
|
|
372
548
|
out_lines += ["", "---", ""]
|
|
373
549
|
|
|
374
|
-
# Extract Phase Index through the end of Phase 3 (before
|
|
375
|
-
#
|
|
376
|
-
# →
|
|
550
|
+
# Extract Phase Index through the end of Phase 3 (before "Customizing
|
|
551
|
+
# Trellis" — the docs-for-forks footer added in v0.5.0-rc.0). Since
|
|
552
|
+
# sections appear in order Phase Index → Phase 1 → Phase 2 → Phase 3 →
|
|
553
|
+
# Customizing Trellis, a single range grab captures all four. The
|
|
554
|
+
# breadcrumb tag blocks now embedded inside Phase Index are stripped so
|
|
555
|
+
# they don't duplicate the per-turn UserPromptSubmit injection.
|
|
377
556
|
phases = _extract_range(
|
|
378
|
-
content, "Phase Index", "
|
|
557
|
+
content, "Phase Index", "Customizing Trellis (for forks)"
|
|
379
558
|
)
|
|
380
559
|
if phases:
|
|
381
|
-
out_lines.append(phases)
|
|
560
|
+
out_lines.append(_strip_breadcrumb_tag_blocks(phases).rstrip())
|
|
382
561
|
|
|
383
562
|
return "\n".join(out_lines).rstrip()
|
|
384
563
|
|
|
@@ -387,7 +566,14 @@ def main():
|
|
|
387
566
|
if should_skip_injection():
|
|
388
567
|
sys.exit(0)
|
|
389
568
|
|
|
390
|
-
|
|
569
|
+
try:
|
|
570
|
+
hook_input = json.loads(sys.stdin.read())
|
|
571
|
+
if not isinstance(hook_input, dict):
|
|
572
|
+
hook_input = {}
|
|
573
|
+
except (json.JSONDecodeError, ValueError):
|
|
574
|
+
hook_input = {}
|
|
575
|
+
|
|
576
|
+
# Try platform-specific env vars, hook cwd, fallback to cwd
|
|
391
577
|
project_dir_env_vars = [
|
|
392
578
|
"CLAUDE_PROJECT_DIR",
|
|
393
579
|
"QODER_PROJECT_DIR",
|
|
@@ -405,12 +591,17 @@ def main():
|
|
|
405
591
|
project_dir = Path(val).resolve()
|
|
406
592
|
break
|
|
407
593
|
if project_dir is None:
|
|
408
|
-
project_dir = Path(".").resolve()
|
|
594
|
+
project_dir = Path(hook_input.get("cwd", ".")).resolve()
|
|
409
595
|
|
|
410
596
|
trellis_dir = project_dir / ".trellis"
|
|
597
|
+
context_key = _resolve_context_key(trellis_dir, hook_input)
|
|
598
|
+
_persist_context_key_for_bash(context_key)
|
|
411
599
|
|
|
412
600
|
# Load config for scope filtering and legacy detection
|
|
413
|
-
is_mono, packages, scope_config, task_pkg, default_pkg = _load_trellis_config(
|
|
601
|
+
is_mono, packages, scope_config, task_pkg, default_pkg = _load_trellis_config(
|
|
602
|
+
trellis_dir,
|
|
603
|
+
hook_input,
|
|
604
|
+
)
|
|
414
605
|
allowed_pkgs = _resolve_spec_scope(is_mono, packages, scope_config, task_pkg, default_pkg)
|
|
415
606
|
|
|
416
607
|
output = StringIO()
|
|
@@ -421,6 +612,8 @@ Read and follow all instructions below carefully.
|
|
|
421
612
|
</session-context>
|
|
422
613
|
|
|
423
614
|
""")
|
|
615
|
+
output.write(FIRST_REPLY_NOTICE)
|
|
616
|
+
output.write("\n\n")
|
|
424
617
|
|
|
425
618
|
# Legacy migration warning
|
|
426
619
|
legacy_warning = _check_legacy_spec(trellis_dir, is_mono, packages)
|
|
@@ -429,7 +622,7 @@ Read and follow all instructions below carefully.
|
|
|
429
622
|
|
|
430
623
|
output.write("<current-state>\n")
|
|
431
624
|
context_script = trellis_dir / "scripts" / "get_context.py"
|
|
432
|
-
output.write(run_script(context_script))
|
|
625
|
+
output.write(run_script(context_script, context_key))
|
|
433
626
|
output.write("\n</current-state>\n\n")
|
|
434
627
|
|
|
435
628
|
output.write("<workflow>\n")
|
|
@@ -442,10 +635,13 @@ Read and follow all instructions below carefully.
|
|
|
442
635
|
"**Pre-Development Checklist** listing the specific guideline files to "
|
|
443
636
|
"read before coding.\n\n"
|
|
444
637
|
"- If you're spawning an implement/check sub-agent, context is injected "
|
|
445
|
-
"
|
|
446
|
-
"need to read these indexes yourself.\n"
|
|
447
|
-
"-
|
|
448
|
-
"
|
|
638
|
+
"or loaded by the sub-agent via `{task}/implement.jsonl` / `check.jsonl`. "
|
|
639
|
+
"You do NOT need to read these indexes yourself.\n"
|
|
640
|
+
"- For agent-capable platforms, the default is to dispatch "
|
|
641
|
+
"`trellis-implement` and `trellis-check` (so JSONL context is loaded by "
|
|
642
|
+
"the sub-agents) rather than editing code in the main session. "
|
|
643
|
+
"Honor a per-turn user override only if the user's current message "
|
|
644
|
+
"explicitly opts out (see <task-status> below for override phrases).\n\n"
|
|
449
645
|
)
|
|
450
646
|
|
|
451
647
|
# guides/ is cross-package thinking — always include inline (small, broadly useful)
|
|
@@ -497,13 +693,13 @@ Read and follow all instructions below carefully.
|
|
|
497
693
|
output.write("</guidelines>\n\n")
|
|
498
694
|
|
|
499
695
|
# Check task status and inject structured tag
|
|
500
|
-
task_status = _get_task_status(trellis_dir)
|
|
696
|
+
task_status = _get_task_status(trellis_dir, hook_input)
|
|
501
697
|
output.write(f"<task-status>\n{task_status}\n</task-status>\n\n")
|
|
502
698
|
|
|
503
699
|
output.write("""<ready>
|
|
504
700
|
Context loaded. Workflow index, project state, and guidelines are already injected above — do NOT re-read them.
|
|
505
|
-
|
|
506
|
-
If
|
|
701
|
+
When the user sends the first message, follow <task-status> and the workflow guide.
|
|
702
|
+
If a task is READY, execute its Next required action without asking whether to continue.
|
|
507
703
|
</ready>""")
|
|
508
704
|
|
|
509
705
|
result = {
|
|
@@ -48,6 +48,12 @@ max_journal_lines: 2000
|
|
|
48
48
|
# docs:
|
|
49
49
|
# path: docs-site
|
|
50
50
|
# type: submodule
|
|
51
|
+
# # For polyrepo / meta-repo layouts (independent .git in each subdir),
|
|
52
|
+
# # mark the package with `git: true`. The runtime treats it as an
|
|
53
|
+
# # independent repository for things like git-context display.
|
|
54
|
+
# webapp:
|
|
55
|
+
# path: ./webapp
|
|
56
|
+
# git: true
|
|
51
57
|
|
|
52
58
|
# Default package used when --package is not specified.
|
|
53
59
|
# default_package: frontend
|
|
@@ -22,6 +22,7 @@ export declare const commonDeveloper: string;
|
|
|
22
22
|
export declare const commonGitContext: string;
|
|
23
23
|
export declare const commonTaskQueue: string;
|
|
24
24
|
export declare const commonTaskUtils: string;
|
|
25
|
+
export declare const commonActiveTask: string;
|
|
25
26
|
export declare const commonCliAdapter: string;
|
|
26
27
|
export declare const commonConfig: string;
|
|
27
28
|
export declare const commonIo: string;
|
|
@@ -39,7 +40,6 @@ export declare const initDeveloperScript: string;
|
|
|
39
40
|
export declare const taskScript: string;
|
|
40
41
|
export declare const getContextScript: string;
|
|
41
42
|
export declare const addSessionScript: string;
|
|
42
|
-
export declare const createBootstrapScript: string;
|
|
43
43
|
export declare const workflowMdTemplate: string;
|
|
44
44
|
export declare const configYamlTemplate: string;
|
|
45
45
|
export declare const gitignoreTemplate: string;
|
|
@@ -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,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,M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AACF,eAAO,MAAM,qBAAqB,QAEjC,CAAC;AACF,eAAO,MAAM,mBAAmB,QAE/B,CAAC;AAGF,eAAO,MAAM,kBAAkB,QAA2C,CAAC;AAC3E,eAAO,MAAM,mBAAmB,QAA4C,CAAC;AAC7E,eAAO,MAAM,UAAU,QAAkC,CAAC;AAC1D,eAAO,MAAM,gBAAgB,QAAyC,CAAC;AACvE,eAAO,MAAM,gBAAgB,QAAyC,CAAC;AAGvE,eAAO,MAAM,kBAAkB,QAA8B,CAAC;AAC9D,eAAO,MAAM,kBAAkB,QAA8B,CAAC;AAC9D,eAAO,MAAM,iBAAiB,QAAgC,CAAC;AAE/D;;GAEG;AACH,wBAAgB,aAAa,IAAI,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAmCnD"}
|
|
@@ -32,6 +32,7 @@ export const commonDeveloper = readTemplate("scripts/common/developer.py");
|
|
|
32
32
|
export const commonGitContext = readTemplate("scripts/common/git_context.py");
|
|
33
33
|
export const commonTaskQueue = readTemplate("scripts/common/task_queue.py");
|
|
34
34
|
export const commonTaskUtils = readTemplate("scripts/common/task_utils.py");
|
|
35
|
+
export const commonActiveTask = readTemplate("scripts/common/active_task.py");
|
|
35
36
|
export const commonCliAdapter = readTemplate("scripts/common/cli_adapter.py");
|
|
36
37
|
export const commonConfig = readTemplate("scripts/common/config.py");
|
|
37
38
|
export const commonIo = readTemplate("scripts/common/io.py");
|
|
@@ -50,7 +51,6 @@ export const initDeveloperScript = readTemplate("scripts/init_developer.py");
|
|
|
50
51
|
export const taskScript = readTemplate("scripts/task.py");
|
|
51
52
|
export const getContextScript = readTemplate("scripts/get_context.py");
|
|
52
53
|
export const addSessionScript = readTemplate("scripts/add_session.py");
|
|
53
|
-
export const createBootstrapScript = readTemplate("scripts/create_bootstrap.py");
|
|
54
54
|
// Configuration files
|
|
55
55
|
export const workflowMdTemplate = readTemplate("workflow.md");
|
|
56
56
|
export const configYamlTemplate = readTemplate("config.yaml");
|
|
@@ -69,6 +69,7 @@ export function getAllScripts() {
|
|
|
69
69
|
scripts.set("common/git_context.py", commonGitContext);
|
|
70
70
|
scripts.set("common/task_queue.py", commonTaskQueue);
|
|
71
71
|
scripts.set("common/task_utils.py", commonTaskUtils);
|
|
72
|
+
scripts.set("common/active_task.py", commonActiveTask);
|
|
72
73
|
scripts.set("common/cli_adapter.py", commonCliAdapter);
|
|
73
74
|
scripts.set("common/config.py", commonConfig);
|
|
74
75
|
scripts.set("common/io.py", commonIo);
|
|
@@ -87,7 +88,6 @@ export function getAllScripts() {
|
|
|
87
88
|
scripts.set("task.py", taskScript);
|
|
88
89
|
scripts.set("get_context.py", getContextScript);
|
|
89
90
|
scripts.set("add_session.py", addSessionScript);
|
|
90
|
-
scripts.set("create_bootstrap.py", createBootstrapScript);
|
|
91
91
|
return scripts;
|
|
92
92
|
}
|
|
93
93
|
//# sourceMappingURL=index.js.map
|
|
@@ -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,GAA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