Commit Graph

12 Commits

Author SHA1 Message Date
Magal cdec481a66 feat(story-6.4): implement hallucination-free documentation with Memtrace graph queries 2026-05-21 14:40:31 -03:00
Magal dcad68e975 feat(story-6.3): implement test architect coverage gap analysis with self-contained Memtrace context blocks
- Install bmad-tea (Murat/Test Architect) and bmad-testarch-trace skills
- Add Memtrace persistent facts to bmad-tea and bmad-testarch-trace customize.toml
- Add structural symbol discovery (step-02), symbol-to-test mapping (step-03),
  and structural gap analysis (step-04) to trace workflow
- Add Structural Coverage Analysis section to trace template
- Add self-contained Memtrace context blocks to 13 step files across 6 skills
  (trace, code-review, gds-code-review, quick-dev, architecture, readiness)
  with complete 22-tool categorized catalog
- Eliminates resolve_customization.py script dependency for loading Memtrace context

FR14: Test Architect cross-references test files against graph symbols
2026-05-21 13:49:14 -03:00
Magal afde2efcf6 feat(story-6.2): implement code reviewer deep audit with independent get_impact and find_dead_code queries
The code-review skills (bmad-code-review, gds-code-review) now independently
query Memtrace during reviews. Step 1 runs get_impact on modified symbols and
find_dead_code on modified files via memtrace-adapter.mjs with
--check-freshness --summarize. Step 2 Acceptance Auditor cross-references
structural data against the diff, raising decision_needed findings for
unhandled downstream dependencies and patch findings for dead code and high
blast radius.

FR12: Code Review Agent queries get_impact on PRs for downstream dependency audit
FR13: Code Review Agent executes find_dead_code to block orphaned code

9 files modified across source templates and installed copies.
2026-05-21 11:33:31 -03:00
Magal 5d5ecb60d5 feat(story-5.3): implement autonomous telemetry deduplication with +1 upvote mechanism
- Add Upvotes column and Status field to Feature Requests table
- Replace placeholder with full deduplication protocol (7a Read History, 7b Detect Duplicates, 7c Consolidated Ledger)
- Add 3 deduplication confinement rules and bounded-read output convention
- Address code review: FR ID regex algorithm, intra-sprint dedup, priority elevation
2026-05-21 06:29:22 -03:00
Magal 7d5ffc5280 feat(story-5.1): implement markdown telemetry report generation skill
Create bmad-memtrace-telemetry skill with introspection protocol,
embedded Markdown template (42 tools across 8 categories), and
confinement rules for post-sprint Memtrace usage reporting.

Code review patches applied:
- Expanded tool catalog to cover all ~42 Memtrace MCP tools
- Added history-unavailable fallback guidance
- Added objective activation criteria (Memtrace tool call check)
- Added output directory creation, collision guard, permission handling
2026-05-20 14:34:56 -03:00
Magal c902a6f0a4 feat(story-4.3): implement manual intervention and fallback override 2026-05-20 12:24:21 -03:00
Magal aecd1ac27b feat(story-4.2): implement autonomous server recovery workflow (Phase 2)
Created memtrace-restart.mjs: cross-platform MCP server recovery script that terminates stale processes and verifies server operability via MCP initialize handshake. Added npm script memtrace:restart. Created bmad-memtrace-recovery skill. Includes 8 tests, all passing with 32/32 adapter regression.
2026-05-20 10:52:25 -03:00
Magal 72e293f346 feat(story-3.4): implement server concurrency throttling and freshness check
Add --check-freshness flag (index freshness gate blocking stale data),
--batch flag (sequential for...of query processing, anti-Promise.all),
and freshness metadata in list_repos output.

Code review patches applied:
- Reset 7 patch findings (AC #4 real diagnostic, null guards,
  shutdown separation, empty target validation)
- Resolved 3 deferred edge cases (Date.parse NaN, falsy 0, type guard)
- Resolved 4 pre-existing issues (infinite while-loop guard,
  resolveRepoId cross-platform, empty fallback, JSON error logging)

Closes story-3.4
2026-05-19 19:22:39 -03:00
Magal abd758e7ee feat(adapter): add hierarchical summarization via --summarize flag (Story 3.3)
Adds --summarize flag to memtrace-adapter.mjs for token-budgeted
hierarchical summarization of get_impact blast radius responses:
- summarizeBlastRadius(): groups by directory prefix, extracts depth<=2
  critical dependents, builds module impact with top symbols, enforces
  <=2000 token budget via progressive while-loop trimming
- estimateTokens(): chars/4 * 1.15 buffer safety margin
- Cross-platform path support (/[\\\\/]/ regex), NaN/Infinity depth guards
- Non-object entry guards, JSON.stringify try/catch
- total_critical field added for count transparency

Workflow files updated to use --summarize flag:
- bmad-dev-story/SKILL.md step 5, bmad-quick-dev step files
- bmad-code-review and gds-code-review auditors check for --summarize

6 summarization tests added. 42/42 tests passing (adapter 20 +
qa-memtrace 10 + validate-dead-code 12).
2026-05-19 18:41:01 -03:00
Magal ffb430ed99 feat(adapter): implement MCP query adapter with get_impact, list_repos, and find_dead_code (Stories 3.1-3.2)
- Add memtrace-adapter.mjs: standalone Node.js MCP client over stdio
  with 10000ms timeout, MEMTRACE_MCP_ERROR_TIMEOUT token,
  structured JSON output matching qa-memtrace.mjs contract
- Support --query get_impact (blast radius), --query find_dead_code
  (dead code detection with repo_id + file_path scoping),
  --query list_repos (index freshness)
- Add 14 automated tests: 9 CLI arg handling + 5 MCP integration
- Update dev-story SKILL.md step 5 to use adapter for blast radius
  and dead-code queries, with empty-results skip for pitfall validation
- Update quick-dev step-03-implement and step-oneshot workflows
- Extend code-review acceptance auditors with adapter usage verification
  and dead-code adapter check
- Fix raw memtrace_get_impact reference in SKILL.md (review patch)
2026-05-19 17:50:32 -03:00
Magal 7a9d66364a feat(workflows): integrate dead-code pitfall validation into dev and review workflows
Insert Dead Code Pitfall Validation substep (step 5) in bmad-dev-story
SKILL.md, after mathematical gate and before approve/reject gate.

Add Step 5c to bmad-quick-dev step-03-implement.md and step-oneshot.md.

Expand code-review Acceptance Auditors in bmad-code-review and
gds-code-review with Dead Code Validation Report ground-truth checks.

Include Ignored section rendering for FALSE_POS/GHOST entries.
2026-05-19 14:27:03 -03:00
Magal 79b3f7d9dc feat(quality-gate): implement mathematical blocking quality gate (Phase 2)
- Create qa-memtrace.mjs - standalone Node.js script computing set
  intersection of blast radius nodes vs test coverage, with 10s timeout
  and MEMTRACE_MCP_ERROR_TIMEOUT token emission
- Create qa-memtrace.test.mjs with 10 automated test cases
- Integrate mathematical gate into bmad-dev-story step 5, bmad-quick-dev
  step-03-implement and step-oneshot
- Expand bmad-code-review and gds-code-review Acceptance Auditors with
  mathematical gate ground-truth checks
- Fix .gitignore to track .agents/skills/ and _bmad/scripts/memtrace/
2026-05-19 14:00:56 -03:00