BOHICA-LABS / BOHICA-LABS/vsdd-factory
scaffold-claude-md injects raw `<!-- TODO -->` placeholders into CLAUDE.md — should live elsewhere or be lazy-referenced
- Dominant language
- Rust
- Stars
- 2
- Forks
- 1
- Avg merge
- 6h 43m
- Merged PRs (30d)
- 29
Description
## Summary
The `scaffold-claude-md` skill **injects raw `` placeholder comments directly into the generated `CLAUDE.md`** when a detector finds nothing. This bakes incomplete-scaffolding markers into a file that is auto-loaded into the model's context on every Claude Code session. That is potentially problematic and, I'd argue, the wrong home for TODO content.
## Where it's specified (skill source)
`skills/scaffold-claude-md/SKILL.md` (v1.0.0-rc.21):
- **Line 18 (Detection):** "If a detector finds nothing, produce a section with a `` placeholder instead of omitting it."
- **Lines 92–95 (Detector 4):** emits `` when nothing is found.
## Observed in the wild
On a real project bootstrapped via `chore: replace kos scaffolding with vsdd-factory bootstrap`, the generated `CLAUDE.md` shipped with:
```
...
```
These persisted long after the project acquired a clear stack (Godot/GDScript + GUT + gdlint), because nothing ever prompts a re-scaffold and nobody hand-edits generated boilerplate. The TODOs become stale, misleading context.
## Why this is problematic
1. **CLAUDE.md is always-on context.** Every byte is injected into the model on each session. TODO/process-bookkeeping noise dilutes the signal and can mislead (e.g. a stale "no stack detected" line on a project that clearly has one).
2. **TODO is project-management state, not project *guidance*.** CLAUDE.md is meant to tell Claude how to build/test/navigate the repo — not to track the factory's own incomplete-detection state.
3. **Re-scaffold clobber risk.** Because the file mixes generated boilerplate (incl. TODOs) with hand-written policy, re-running the skill risks overwriting human edits — and the skill's own guidance encourages re-running it.
## Proposed fix (any of, in preference order)
1. **Don't write TODOs into CLAUDE.md at all.** If a detector finds nothing, **omit the section** (or emit a single neutral one-liner), and instead record outstanding detection gaps in a *separate* artifact — e.g. `.factory/scaffold-todo.md` or a STATE.md drift item — that is not auto-loaded into context.
2. **If a pointer must live in CLAUDE.md, make it a lazy-loaded reference, not inline content.** e.g. a single line like `See @.factory/scaffold-todo.md for outstanding project-setup gaps.` so the detail is loaded on demand (via `@`) rather than always resident.
3. **Mark generated regions explicitly** (e.g. `` / ``) so re-scaffold can update only its own region and never clobber hand-written sections — and keep TODOs out of the human-authored zone.
## Acceptance criteria
- Generated `CLAUDE.md` contains **no raw `` placeholders**.
- Outstanding detection gaps are recorded outside always-on context (separate file or STATE.md), or referenced via `@`-style lazy loading if they must be surfaced from CLAUDE.md.
- Re-running `scaffold-claude-md` does not overwrite human-authored sections.
## Environment
- Plugin: `vsdd-factory@1.0.0-rc.21`
- Skill: `skills/scaffold-claude-md/SKILL.md`
Contributor guide
Assessment
This issue has not been assessed yet.