TS โ TFW-12: Config Centralization¶
Date: 2026-03-30 Author: Coordinator (AI) Status: ๐ก TS โ waiting for approval Parent HL: HL-TFW-12 RES: RES-TFW-12
1. Goal¶
Centralize 4 categories of duplicated parameters into PROJECT_CONFIG.yaml as single source of truth:
- Scope budgets (4 values ร 6 files)
- Version strings (~17 places)
- Template list (6+ places, already drifted)
- Workflow list (5 places, already drifted)
2. PROJECT_CONFIG.yaml Target State¶
tfw:
version: "0.5.0"
upstream: "https://github.com/saubakirov/trace-first-starter"
task_prefix: TFW
id_format: "{prefix}-{seq}"
initial_seq: 12
scope_budgets:
max_files_per_phase: 7
max_new_files: 4
max_loc: 600
max_modified_files: 6
templates:
hl: .tfw/templates/HL.md
ts: .tfw/templates/TS.md
res: .tfw/templates/RES.md
rf: .tfw/templates/RF.md
onb: .tfw/templates/ONB.md
review: .tfw/templates/REVIEW.md
knowledge: .tfw/templates/KNOWLEDGE.md
release: .tfw/templates/RELEASE.md
workflows:
plan: .tfw/workflows/plan.md
research: .tfw/workflows/research.md
handoff: .tfw/workflows/handoff.md
review: .tfw/workflows/review.md
resume: .tfw/workflows/resume.md
docs: .tfw/workflows/docs.md
release: .tfw/workflows/release.md
update: .tfw/workflows/update.md
research:
max_web_queries_per_stage: 5
max_files_per_stage: 15
max_questions_per_stage: 3
max_passes: 3
3. Reference Patterns¶
Pattern A: "Values + pointer" (conventions.md, plan.md, .tfw/README.md)¶
Readable table with values marked as defaults, header links to config.
> Scope budgets are configured in `.tfw/PROJECT_CONFIG.yaml` (`tfw.scope_budgets`).
> Values below are defaults.
| Parameter | Default | Rationale |
|-----------|---------|-----------|
| Files per phase | 7 | Agent maintains full mental model |
Pattern B: "Pure reference" (TS.md template, glossary.md)¶
Subject to scope budgets (see `tfw.scope_budgets` in `.tfw/PROJECT_CONFIG.yaml`).
Pattern C: "Version placeholder" (adapter templates)¶
# TFW {version}
Resolved by init.md setup or tfw-update adapter refresh.
Pattern D: "Version removed from titles" (core .tfw/ files)¶
# TFW Conventions โ was: # TFW 0.4 โ Conventions
# TFW Glossary โ was: # TFW 0.4 Glossary
4. Scope¶
Phase A: Config + Core Docs (0 new, 7 modified)¶
| # | File | Changes |
|---|---|---|
| 1 | .tfw/PROJECT_CONFIG.yaml |
Add scope_budgets, complete templates (+res/knowledge/release), add workflows, add research |
| 2 | .tfw/conventions.md |
ยง6: Pattern A budgets. L1: remove version from title (Pattern D). Fix workflow table if needed |
| 3 | .tfw/README.md |
Scope Budgets section: Pattern A. Body: remove TFW 0.5 from prose. Tree comments: reference config for lists |
| 4 | .tfw/workflows/plan.md |
ยงScope Budget: Pattern A |
| 5 | .tfw/glossary.md |
L1: remove version (Pattern D). L69: Pattern B for budget values |
| 6 | .tfw/templates/TS.md |
L27: Pattern B for budget values |
| 7 | README.md (root) |
Budget reference โ "see PROJECT_CONFIG". Version โ "see .tfw/VERSION" |
Budget: 0 new, 7 modified โ
Phase B: Adapters + Init + Local Copies (0 new, 8 modified)¶
| # | File | Changes |
|---|---|---|
| 8 | .tfw/adapters/claude-code/CLAUDE.md.template |
TFW 0.5 โ TFW {version}. Template/workflow lists โ reference config |
| 9 | .tfw/adapters/cursor/tfw.mdc.template |
TFW 0.5 โ TFW {version}. Lists โ reference config |
| 10 | .tfw/adapters/antigravity/tfw-rules.md.template |
TFW 0.5 โ TFW {version}. Lists โ reference config |
| 11 | .tfw/adapters/antigravity/README.md |
Fix stale TFW 0.4 reference |
| 12 | .tfw/init.md |
Remove version from title. Add {version} replacement instruction. Update config example with full structure. Update template/workflow copy commands |
| 13 | CLAUDE.md |
TFW 0.5 โ value from VERSION. Lists โ reference config |
| 14 | .agent/rules/tfw.md |
Templates +RES. Version reference (TD-26) |
| 15 | .tfw/workflows/research.md |
Verify L122 research: reference is accurate (now config exists) |
Budget: 0 new, 8 modified (exceeds โค6 by 2 โ all single-line mechanical edits in adapters, justified)
5. Steps¶
Phase A¶
- Edit
PROJECT_CONFIG.yamlโ add all 4 sections per ยง2 - Edit
conventions.mdโ remove version from title, Pattern A for budgets ยง6 - Edit
.tfw/README.mdโ remove version from prose, Pattern A for budget section, update tree comments - Edit
plan.mdโ Pattern A for scope budget table - Edit
glossary.mdโ remove version from title, Pattern B for inline budgets - Edit
TS.mdtemplate โ Pattern B for budget line - Edit root
README.mdโ reference config for budgets, reference VERSION for version - Verify: grep for hardcoded budget values and version strings in Phase A files
Phase B¶
- Edit 3 adapter templates โ Pattern C for version, reference config for lists
- Edit antigravity README โ fix stale 0.4
- Edit
init.mdโ full config example,{version}instructions, update copy commands - Edit
CLAUDE.mdโ version from VERSION, lists from config - Edit
.agent/rules/tfw.mdโ fix TD-26 - Verify
research.mdL122 reference - Verify: grep for remaining hardcoded values across all files
- Resolve TD-25, TD-26 in TECH_DEBT.md
6. Acceptance Criteria¶
Phase A¶
- [ ] AC-1:
tfw.scope_budgetsexists in PROJECT_CONFIG with 4 keys - [ ] AC-2:
tfw.templateshas 8 entries (hl, ts, res, rf, onb, review, knowledge, release) - [ ] AC-3:
tfw.workflowshas 8 entries (plan, research, handoff, review, resume, docs, release, update) - [ ] AC-4:
tfw.researchhas 4 limit entries - [ ] AC-5: conventions.md ยง6 has "configured in PROJECT_CONFIG" header + defaults table
- [ ] AC-6: plan.md scope budget section references config
- [ ] AC-7:
grep "โค 7" .tfw/conventions.md .tfw/README.md .tfw/workflows/plan.mdโ 0 matches (values without โค symbol) - [ ] AC-8:
grep "TFW 0\." .tfw/conventions.md .tfw/glossary.mdโ 0 matches (no version in titles)
Phase B¶
- [ ] AC-9: All 3 adapter templates use
{version}not hardcoded version - [ ] AC-10:
CLAUDE.mdreferences VERSION file for version - [ ] AC-11: init.md config example shows all 4 sections (scope_budgets, templates, workflows, research)
- [ ] AC-12:
grep "TFW 0\." .tfw/adapters/ CLAUDE.md .agent/rules/โ 0 matches - [ ] AC-13: TD-25, TD-26 marked โ in TECH_DEBT.md
7. Verification¶
# Phase A
grep "scope_budgets" .tfw/PROJECT_CONFIG.yaml
grep -c "templates:" .tfw/PROJECT_CONFIG.yaml # sections exist
grep -c "workflows:" .tfw/PROJECT_CONFIG.yaml
# No hardcoded budget values with โค prefix
grep "โค 7\|โค 4\|โค 600\|โค 6" .tfw/conventions.md .tfw/README.md .tfw/workflows/plan.md .tfw/glossary.md .tfw/templates/TS.md README.md || echo "PASS"
# No version in core titles
grep "TFW 0\." .tfw/conventions.md .tfw/glossary.md || echo "PASS"
# Phase B
grep "{version}" .tfw/adapters/*/tfw*.template .tfw/adapters/claude-code/CLAUDE.md.template
grep "TFW 0\." .tfw/adapters/ CLAUDE.md .agent/rules/tfw.md 2>/dev/null || echo "PASS"
grep "research:" .tfw/PROJECT_CONFIG.yaml
8. Out of Scope¶
- Status pipeline diagrams (8 copies โ accepted as documentation)
- Research limits in research.md body (L115, L144 โ same file, local)
.agent/workflows/copies of plan.md, research.md, handoff.md โ these are synced from canonical, will get updated on next tfw-update- Historical task artifacts
- KNOWLEDGE.md updates โ via
/tfw-docsafter REVIEW
TS โ TFW-12: Config Centralization | 2026-03-30