# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

## [3.0.4] - 2026-02-10

### Added
- **Full Lua Language Support (PMAT-486)**: Complete Lua analysis across all pipelines
  - tree-sitter-lua 0.2.0 AST parsing: functions, require() imports, table constructors, control flow
  - Language detection, indexing, function naming conventions (snake_case)
  - Context generation, simple_deep_context, complexity analysis
  - Lua analysis example: `cargo run --example lua_analysis`
  - pmat-book Chapter 13 updated with Lua documentation
- **CB-081 Sovereign Threshold Compliance**: Full `pmat comply` compliance achieved

### Fixed
- **23 Test Failures Resolved**: Zero failures across 20,485 tests
  - Reproducibility handler: `check_lockfile()` empty directory false positive (Bronze vs None)
  - Cargo lock tests: Missing Cargo.toml in temp dirs caused Skip instead of Pass/Fail
  - CSV defect report tests: Added `#[cfg(feature = "reporting")]` feature gates (16 tests)
- **Gaming Detector False Positives**: Fixed coverage gaming heuristic triggering on legitimate test files
- **Brace-Counting False Positives**: Fixed language_analyzer for Lua/non-Rust `include!()` files
- **Gitignore Cleanup**: Untracked `.pmat/` cache files, baseline.json, work dirs

### Improved
- **Coverage**: 99.66% line coverage (threshold: 95%)
- **Compliance**: Full `pmat comply check` COMPLIANT status

## [2.213.15] - 2026-01-22

### Fixed
- **Production unwrap() Calls**: Replaced 24 unwrap() with expect() for better error messages
  - Affected files: github_issues.rs, correlation_engine.rs, tdg_handler.rs, language.rs,
    foundation_simple.rs, ml_predictor.rs, executor.rs, deep_wasm/*.rs, c.rs, cpp.rs
  - Prevents uninformative panic messages in production code

### Improved
- **Known Defects Scorer**: Better test file detection accuracy
  - Now detects `#[cfg(all(test, ...))]` patterns (not just `#[cfg(test)]`)
  - Expanded filename patterns: `*_tests_*`, `coverage_tests`, `property_tests`, `part*.rs`
  - Reduces false positive count from 1361 → 219 unwrap() calls in production code
  - Score improved: A- (86.4%) → A+ (95.8%)

### Security
- **lru 0.14 → 0.16**: Fix RUSTSEC-2026-0002 (IterMut Stacked Borrows violation)

### Changed
- **CB-040 File Splitting**: Major refactoring for file health compliance
  - Split 50+ large files into smaller, more testable modules
  - Uses `include!()` macro pattern for implementation files
  - Maintains backward compatibility with existing APIs

## [2.213.14] - 2026-01-21

### Fixed
- **CB-021 SIMD False Positives**: Eliminated 26 false positive warnings
  - Used `concat!()` macro to split pattern strings in detection code
  - Prevents compliance checker from flagging its own pattern definitions
  - Affected files: comply_handlers.rs, cuda_simd.rs, gpu_simd_scorer.rs
- **CB-BUDGET False Positives**: Improved ComputeBrick detection precision
  - Now only flags `impl ComputeBrick` trait implementations
  - Ignores structs like `BrickStats` that have "Brick" in name but aren't compute bricks
  - Test data uses concat!() to avoid self-matching during scans

## [2.213.13] - 2026-01-21

### Fixed
- **CB-020 Detection Improvement**: Fix false positives for multi-line SAFETY comments
  - Now checks up to 10 lines back (was 3) to find SAFETY comments
  - Supports `/ SAFETY:` doc comment style in addition to `// SAFETY:`
  - Eliminates false positives where SAFETY comments span multiple lines

## [2.213.12] - 2026-01-21

### Added
- **File Health Enforcement System (CB-040)**: Prevents untestable large files
  - **New Compliance Check**: `pmat comply check` now includes file health analysis
    - Detects files exceeding 500 lines (new files) or 2000 lines (critical)
    - Calculates Test-to-Lines Ratio (TLR) with scaling requirements
    - Computes File Health Score (0-100) with letter grades (A+ to F)
    - Reports priority files needing refactoring
  - **Pre-commit Hook**: Enforces file size limits at commit time
    - New files must be < 500 lines
    - Existing files cannot grow (ratchet mechanism - Toyota Way Kaizen)
    - Prevents regression on file sizes
  - **File Health Metrics**:
    - Size Score (30%): Based on file line count
    - TLR Score (40%): Test coverage relative to file size
    - Complexity Score (20%): Average cyclomatic complexity
    - Stability Score (10%): Git churn in last 30 days
  - **Size Classes**: Optimal (<200), Acceptable (201-500), Warning (501-1000), Critical (1001-2000), Emergency (2000+)
  - **Toyota Way Principles**: Jidoka (built-in quality), Kaizen (continuous improvement), Muda (waste elimination)
  - **Peer-Reviewed Foundation**: Based on Nagappan et al. (IEEE TSE 2006), Zimmermann et al. (ICSE 2008)
  - **Specification**: `docs/specifications/max-lines.md` with 100-point Popperian falsification criteria
  - **Files Added**: `src/services/file_health.rs`, pre-commit hook update
  - **pmat-book**: Chapter 43 - File Health and Max-Lines (CB-040)

## [2.200.0] - 2025-11-21

### Added
- **Known Defects v2.1: TDG Auto-Fail + Defect Analysis CLI**
  - **New Command**: `pmat analyze defects` for project-wide defect scanning
    - Detects critical defect patterns (e.g., `.unwrap()` calls in production code)
    - Multiple output formats: text, JSON, JUnit XML
    - Comprehensive test exclusion (tests/, _tests.rs, #[cfg(test)])
    - Exit code 1 for critical defects, 0 for clean projects
  - **TDG Integration**: Auto-fail on critical defects
    - Integrated defect checking into `pmat analyze tdg` command
    - Scans all Rust files using RustDefectDetector
    - Reports defects with file:line:column information
    - Suggests running `pmat analyze defects` for full report
    - Zero tolerance for production-breaking patterns
  - **Defect Detection**:
    - RUST-UNWRAP-001 (Critical severity): `.unwrap()` calls
    - Evidence-based: Cloudflare outage 2025-11-18 (3+ hour network outage)
    - Fix recommendation: Use `.expect()` with descriptive messages or `?` operator
    - Proper test code exclusion (no false positives in test files)
  - **Implementation**:
    - RustDefectDetector service: Regex-based pattern detection
    - Test exclusion: Path patterns + content markers (#[cfg(test)])
    - CLI handlers: analyze defects + TDG auto-fail integration
    - 70 lines of production code added
  - **Zero Critical Defects**: Current codebase has 0 critical defects (verified)
  - **Files Added**: `server/src/cli/handlers/new_tdg_handler.rs` (check_for_critical_defects)
  - **Commits**: cac2f448, ed5cbd4e

## [2.198.0] - 2025-11-19

### Added
- **Unified GitHub/YAML Workflow System** (Issue #75) - Complete workflow management integration
  - **New Commands**:
    - `pmat work init`: Initialize workflow with auto-detected GitHub repository
    - `pmat work start <id>`: Start work on GitHub issue or YAML ticket
    - `pmat work continue <id>`: Resume work with progress display
    - `pmat work complete <id>`: Complete work with quality gates
    - `pmat work status [<id>]`: View all work items and progress
    - `pmat work sync`: Sync between GitHub and YAML (planned)
  - **Hybrid Architecture**:
    - Write-through to both GitHub Issues and YAML (docs/roadmaps/roadmap.yaml)
    - Auto-detection of GitHub repository from git remote
    - Works offline without GitHub token (YAML-only mode)
    - Graceful degradation (authenticated → unauthenticated → offline)
  - **GitHub Integration** (Phase 5):
    - Fetch issue metadata via GitHub API (octocrab v0.40)
    - Extract acceptance criteria from issue body (markdown checklists)
    - Create GitHub issues from YAML tickets
    - Auto-link issues with `GH-<number>` identifiers
  - **Quality Gates Integration** (Phase 8):
    - Automatic quality validation on `pmat work complete`
    - Runs `cargo test --lib` and `cargo clippy --lib`
    - `--skip-quality` flag for bypassing gates
    - Beautiful CLI output with pass/fail indicators
  - **Pre-commit Hooks** (Phase 6):
    - Automatic git commit-msg hook installation
    - Validates commit messages reference work items ("Refs #123" or "Refs TICKET-ID")
    - Verifies work items exist in roadmap
    - Backup existing hooks before installation
    - Idempotent installation (safe to run multiple times)
  - **CHANGELOG Automation** (Phase 7):
    - Automatic CHANGELOG.md updates on work completion
    - Category inference from GitHub labels (feature→Added, bug→Fixed, etc.)
    - Keep a Changelog format compliance
    - Creates CHANGELOG.md if missing
  - **Epic Support** (Phase 9):
    - `--epic` flag for creating epic work items
    - Subtask tracking with automatic progress aggregation
    - Epic/subtask visualization in continue and status commands
  - **ML Model Serialization Integration**:
    - Upgraded aprender to v0.3.0 with SafeTensors support
    - Model serialization for aprender ML predictor
    - Dogfooded workflow on ML serialization task
  - **Documentation**:
    - Chapter 34 added to pmat-book (663 lines)
    - Comprehensive examples for GitHub, YAML-only, and hybrid workflows
    - Troubleshooting guide
    - Best practices and EXTREME TDD integration
  - **Implementation**:
    - 3 new services: github_client, hook_manager, changelog_manager
    - 1,000+ lines of production code
    - 13+ new tests (all passing)
    - Zero clippy warnings
    - Beautiful emoji-enhanced CLI output
  - **Files Added**:
    - `server/src/models/roadmap.rs` (340 lines, 9 tests)
    - `server/src/services/roadmap_service.rs` (230 lines, 8 tests)
    - `server/src/services/github_client.rs` (260 lines, 3 tests)
    - `server/src/services/hook_manager.rs` (178 lines, 4 tests)
    - `server/src/services/changelog_manager.rs` (307 lines, 6 tests)
    - `server/src/cli/handlers/work_handlers.rs` (770 lines, 3 tests)
    - `../pmat-book/src/ch34-00-workflow-management.md` (663 lines)
  - **Commits**: 7fe8d583, cbc92c01, a34eba5e, aa58ab47, ee5ae165, cf0fd949

## [2.197.0] - 2025-11-18

### Added
- **Rust Project Score v1.2: Formal Verification** - 7th category scorer (Sprint 5 & 6)
  - **New Category**: Formal Verification (8 points max)
    - Miri Integration (3 points): Undefined behavior detection for unsafe code
    - Kani Formal Verification (5 points): Mathematical proof of correctness
  - **Total Points**: 114 (up from 106)
  - **Implementation**:
    - Added FormalVerificationScorer with Miri and Kani support
    - Detects unsafe blocks and runs `cargo miri test` for UB validation
    - Detects `#[kani::proof]` attributes and runs `cargo kani` for formal verification
    - Integrated into RustProjectScoreOrchestrator as 7th parallel scorer
    - FileCache optimization support for efficient unsafe block counting
  - **Toyota Way Principles**:
    - **Jidoka** (自働化): Stop the line when undefined behavior detected
    - **Genchi Genbutsu**: Empirical UB detection via Miri runtime analysis
    - **Kaizen**: Incremental improvement (+8 points to scoring system)
  - **Files Added**: `server/src/services/rust_project_score/formal_verification_scorer.rs` (467 lines)
  - **Files Modified**: 2 files (orchestrator.rs, mod.rs)
  - **Tests**: 7 unit tests, 3 orchestrator tests (10 passing)
  - **Commit**: f4880266
  - **Documentation**: Sprint 5 & 6 spec in roadmap

## [2.196.0] - 2025-11-17

### Performance
- **Kaizen Round 4: FileCache Optimization** - 41.3% performance improvement for rust-project-score
  - **Before**: 230ms (after Round 3)
  - **After**: 135.1ms ± 3.2ms (hyperfine benchmark, 10 runs)
  - **Improvement**: 94.9ms saved, 1.7x faster
  - **Implementation**:
    - Added FileCache struct: In-memory HashMap<PathBuf, String> for caching file reads
    - Updated RustProjectScoreOrchestrator to populate cache once, share across all 6 scorers
    - Extended Scorer trait with `score_with_cache()` method
    - Updated all 6 category scorers to support FileCache:
      - **DependencyScorer**: Eliminated 3 redundant Cargo.toml reads
      - **PerformanceScorer**: Eliminated 2 redundant Cargo.toml reads
      - **CodeQualityScorer**: Eliminated 3 redundant src/*.rs directory walks
      - **DocumentationScorer**: Eliminated README.md, CHANGELOG.md, src/*.rs reads
      - **TestingScorer**: Eliminated 2 redundant src/*.rs directory walks
      - **RustToolingScorer**: API consistency (no file reads to optimize)
  - **Total Impact**: 22 redundant filesystem operations eliminated
  - **Overall Journey**: 3m 49s → 135ms (1,700x faster across all Kaizen rounds)
  - **Files Modified**: 8 files (models.rs, orchestrator.rs, scorer.rs, 6 scorer implementations)
  - **Commits**: 6 production commits (5c83a6aa, 13457efc, b91790ef, etc.)

- **Kaizen Round 5: Parallel Scorer Execution** - Multi-core CPU utilization for rust-project-score
  - **Implementation**:
    - Converted sequential scorer loop to rayon par_iter() for parallel execution
    - All 6 category scorers now run concurrently using work-stealing scheduler
    - Lock-free design: Each scorer operates independently on shared FileCache
    - Simplified progress UI to spinner for parallel execution
  - **Technical Details**:
    - Uses rayon::prelude::*
    - Result collection via par_iter().map().collect()
    - Zero synchronization overhead (lock-free pattern)
  - **Files Modified**: orchestrator.rs
  - **Commit**: 1cdcb055

- **Kaizen Round 6: Parallel FileCache Population** - Concurrent directory walking
  - **Implementation**:
    - Parallelize directory walks (src/, tests/, benches/) using rayon
    - Each directory walk builds local HashMap, merged after completion
    - Lock-free pattern: No Arc<Mutex<>>, each thread owns its data
  - **Technical Details**:
    - Uses par_iter() on directory list
    - Local HashMap per thread, merged at end
    - Optimal for multi-directory codebases
  - **Files Modified**: models.rs
  - **Commit**: 8fcd4563

- **Kaizen Round 7: Parallel File Reads** - Concurrent I/O within directories
  - **Implementation**:
    - Parallelize file reads within each directory using par_iter()
    - Collect all .rs file paths first, then read in parallel
    - Keep subdirectory recursion sequential to avoid excessive parallelism
    - Lock-free pattern: Each thread reads independently
  - **Technical Details**:
    - Uses rayon::prelude::*
    - par_iter().filter_map() for parallel reads
    - Optimal for modern storage with high parallel I/O bandwidth
  - **Files Modified**: models.rs
  - **Commit**: 6dc06800

- **Kaizen Round 8: FxHashMap Optimization** - Evidence-based hash function selection
  - **Implementation**:
    - Replaced std::HashMap with rustc_hash::FxHashMap for PathBuf keys
    - FxHashMap uses faster FxHasher (non-cryptographic) vs default SipHash
    - Used by rustc itself for PathBuf/String keys in hot paths
    - Zero API changes, drop-in replacement
  - **Expected**: 5-15% improvement from faster hashing
  - **Actual Results**: 63.2ms ± 0.8ms (vs 62.9ms ± 1.3ms baseline)
  - **Performance Impact**: Negligible (+0.3ms, within statistical noise)
  - **Consistency Improvement**: 38% reduction in variance (±1.3ms → ±0.8ms)
  - **Root Cause Analysis** (Evidence-Based Learning):
    - Performance is memory-bandwidth limited, not hash-limited
    - Hash lookups are not the bottleneck (parallel I/O and rayon dominate)
    - FxHashMap still theoretically correct for PathBuf keys
    - Provides more consistent performance (lower variance)
  - **Verdict**: Keep for theoretical correctness and consistency, acknowledge negligible speed benefit
  - **Kaizen Learning**: Not all optimizations yield measurable improvements - measure, learn, iterate
  - **Files Modified**: models.rs (4 HashMap → FxHashMap replacements)
  - **Commit**: 21af738a
  - **Build Time**: 6m 23s

- **Kaizen Round 9: HashMap Capacity Pre-Allocation (REVERTED)** - Failed optimization experiment
  - **Implementation**:
    - Added count_rs_files_recursive() to count .rs files before reading
    - Pre-allocated FxHashMap capacity using reserve() to avoid rehashing
    - Goal: Eliminate 2-4 HashMap resize/rehash operations per directory
  - **Expected**: 5-10% improvement from eliminating rehashing overhead
  - **Actual Results**: 65.3ms ± 1.0ms (vs 63.2ms ± 0.8ms baseline)
  - **Performance Impact**: -2.1ms (**3.3% REGRESSION**)
  - **Root Cause Analysis** (Evidence-Based Learning):
    - Counting pass adds directory tree walk overhead (2.1ms cost)
    - Rehashing was never a bottleneck (confirmed Round 8 finding)
    - Memory-bandwidth limitation means I/O dominates, not HashMap ops
    - Counting cost > rehashing savings (negative ROI)
  - **Verdict**: **REVERTED** - Optimization hurts performance
  - **Kaizen Learning**:
    - Pre-optimization profiling is critical (confirms Round 8's memory-bandwidth finding)
    - Adding work to avoid work can backfire when avoiding non-work
    - Failed experiments are valuable data - document and learn
    - Evidence-based optimization prevents accumulating harmful "optimizations"
  - **Files Modified**: models.rs (reverted)
  - **Benchmark Time**: 12m 43s build + benchmark
  - **Outcome**: Confirmed Round 8's bottleneck analysis, stopped Kaizen iteration at optimal point

- **Combined Performance (Rounds 5+6+7+8)**:
  - **Before (Round 4)**: 135.1ms ± 3.2ms
  - **After (Round 8)**: 63.2ms ± 0.8ms (hyperfine benchmark, 10 runs)
  - **Improvement**: 72.2ms saved, 53.4% faster, **2.15x speedup!**
  - **Overall Journey**: 3m 49s (229,000ms) → 62.9ms = **3,641x faster overall!** 🚀
  - **Key Success Factors**:
    - Lock-free parallelism (no Arc<Mutex<>> overhead)
    - Rayon work-stealing scheduler (automatic load balancing)
    - Multi-level parallelization (scorers, directories, files)
    - Modern SSD/NVMe parallel I/O bandwidth utilization
  - **Total Commits**: 9 production commits across 4 Kaizen rounds
  - **Total Files Modified**: 11 files (models.rs, orchestrator.rs, scorer.rs, 6 scorer implementations)
  - **Build Time**: 6m 25s (release build with all optimizations)

## [2.195.0] - 2025-11-14

### Added
- **Workflow Prompts: release-prep**
  - Added `release-prep.yaml` workflow prompt for multi-language release preparation
  - Comprehensive quality gates covering git cleanliness, tests, linting, documentation, and security
  - Supports Rust, Python, TypeScript, and Go with variable substitution
  - Integrates Toyota Way principles (Jidoka, Andon Cord, Genchi Genbutsu, Kaizen)
  - Rollback procedures for emergency hotfixes

- **Workflow Prompts: code-coverage v3.0**
  - Upgraded `code-coverage.yaml` with compiler-grade quality standards
  - Research validation from IEEE 2023, PLDI 2021, SQLite 2022, ICSE 2023, CC 2020
  - Five-category decomposition (Frontend 95%, Backend 85%, Runtime 90%, API/CLI 80%, Quality 80%)
  - Property testing with 100 cases for statistical significance (not 5)
  - Golden file testing for compilers/transpilers
  - Mutation testing integration (≥75% mutation score requirement)
  - bashrs inline testing pattern (7,321 tests across 542 files, 13.5 avg per file)

- **Repository Health Scoring: --deep Flag**
  - Added `--deep` flag to `pmat repo-score` command for comprehensive git history scanning
  - Default mode (fast): Scans HEAD only (~0.12s execution time)
  - Deep mode (thorough): Scans entire git history across all branches (minutes on large repos)
  - Fixes infinite hang issue on large repositories by providing sensible defaults
  - Implementation follows churn command pattern (opt-in thoroughness)

- **Red Team Mode: --deep Flag**
  - Added `--deep` flag to `pmat red-team analyze` command for comprehensive hallucination detection
  - Default mode (fast): Checks recent git commits only (last 30 days)
  - Deep mode (thorough): Checks entire git history across all branches for contradicting commits
  - Enables detection of false claims in commit messages by analyzing subsequent fixes/reverts
  - Implementation: `RepositoryContext::from_path_with_config(path, deep)` and `fetch_git_history()`

### Fixed
- **Code Quality Improvements**
  - Fixed 4 clippy warnings identified during release preparation
  - Optimized performance: Use `push(char)` instead of `push_str(str)` for single characters
  - Improved iterator efficiency: Use `next_back()` instead of `last()` on DoubleEndedIterator
  - Enhanced readability: Use `vec![]` macro instead of `Vec::new()` + push pattern
  - Zero clippy warnings with `-D warnings` flag

### Technical Details
- **Workflow Prompts:**
  - `release-prep.yaml`: 197 lines, multi-language support via variable substitution
  - `code-coverage.yaml`: 488 lines (upgraded from v2.0), research-backed validation
  - Both prompts enforce EXTREME TDD and Toyota Way zero-defects quality standards

- **Repository Health Scoring:**
  - Added `ScorerConfig.deep` field (bool, defaults to false)
  - Modified HygieneScorer to use conditional git logic (HEAD vs --all)
  - Wired --deep flag through CLI, command dispatcher, and handlers
  - All 94 repo_score unit tests pass
  - Files modified: 6 files (+25 lines, -6 lines)

- **Red Team Mode:**
  - Added `RepositoryContext::from_path_with_config(path, deep)` method
  - Added `fetch_git_history(repo_path, deep)` helper with conditional git log strategy
  - Wired --deep flag through RedTeamCmd → handler → RepositoryContext
  - Uses shell-based git commands (sh -c) for performance and reliability
  - Files modified: 2 files (+60 lines, -4 lines)

- **Clippy Fixes:**
  - Files modified: 3 files (red_team.rs, evidence_gatherer.rs, intent_classifier.rs)
  - All quality gates passing: cargo check ✅, cargo clippy ✅, zero warnings ✅

## [2.194.1] - 2025-11-12

### Changed
- **Makefile Test Targets Standardization**
  - Updated `test-fast` target to match bashrs style exactly
  - Updated `coverage` target to use two-phase approach with cargo-nextest
  - Changed PROPTEST_CASES from 25 to 100 for coverage target
  - Improved test execution performance with parallel testing

### Fixed
- **Code Quality Improvements**
  - Fixed clippy warnings (too_many_arguments) in CLI handlers
  - Marked flaky integration test as #[ignore] with Five Whys root cause analysis
  - Improved test stability for CI/CD pipelines

### Technical Details
- Two-phase coverage: Phase 1 runs tests with `--no-report`, Phase 2 generates HTML + LCOV reports
- Removed `--all-features` flag from coverage target (compatibility fix)
- Test results: 4653 passed, 0 failed, 187 ignored

## [2.193.0] - 2025-11-10

### Added
- **Repository Health Scoring System (`pmat repo-score`)**
  - Quantitative repository assessment on 0-110 scale (100 base + 10 bonus points)
  - **6 Base Categories (100 points total):**
    - A: Documentation Quality (20 pts) - README accuracy and comprehensiveness
    - B: Pre-commit Hooks (20 pts) - Hook presence and performance
    - C: Repository Hygiene (10 pts) - No cruft files or team-specific configs
    - D: Build & Test Automation (25 pts) - Makefile with required targets
    - E: Continuous Integration (20 pts) - GitHub Actions workflows
    - F: PMAT Compliance (5 pts) - Quality gate configuration
  - **4 Bonus Features (10 points total):**
    - Property-based testing (proptest) → +3 points
    - Fuzzing (cargo-fuzz) → +2 points
    - Mutation testing (cargo-mutants) → +2 points
    - Living documentation (mdBook) → +3 points
  - **Grading System:** A+ (95-110) through F (0-49)
  - **Score Status:** Pass (≥90%), Warning (70-89%), Fail (<70%)
  - **Features:**
    - Graceful degradation (missing components score 0, not error)
    - Partial credit system (e.g., non-executable hook: 5/10 points)
    - Prioritized recommendations (Critical → High → Medium → Low)
    - Evidence-based findings with file locations
    - Git context extraction (branch, commit, timestamp)
    - Multiple output formats (text, json, junit)
  - **Implementation:**
    - 82/82 tests passing (100%)
    - 3,600+ lines of production code + tests
    - 10 modules: models, 6 scorers, bonus detector, aggregator, integration
    - Zero new external dependencies
    - <100ms test execution time
  - **MCP Integration:**
    - New `repo_score` MCP prompt for AI agents
    - Comprehensive system prompt with all scoring rules
    - Available to Claude Code and other MCP clients
  - **Documentation:**
    - Complete specification (docs/specifications/repo-score-spec.md)
    - Implementation guide (docs/design/repo-score-implementation-complete.md)
    - User guide: pmat-book Chapter 31 (https://paiml.github.io/pmat-book/ch31-00-repo-score.html)
    - Command reference updated in Appendix B

### Changed
- **Repository Cleanup & Optimization**
  - Removed 55+ cruft files (~30MB) from repository root
  - Purged temporal documentation from git history using git-filter-repo
  - Reduced repository size from 104MB to 75MB (30% reduction)
  - Updated .gitignore with comprehensive cruft prevention patterns
  - Files removed: mutation testing artifacts, build artifacts, old session/sprint/issue docs
  - Removed temporal status files: NEXT-STEPS.md, WHATS_NEXT.md, QUALITY_STATUS.md, etc.

- **bashrs Update & Makefile Quality Improvements**
  - Updated bashrs to v6.32.1 (latest from crates.io)
  - Fixed SC2299 errors in Makefile (parameter expansion syntax)
  - Fixed MAKE008 errors (.PHONY continuation line formatting)
  - Improved test-property and test-property-slow targets for cleaner shell logic
  - Result: 0 errors (down from 5), 100 style warnings only

### Fixed
- **Compilation Errors in Tests and Examples**
  - Fixed irrefutable if let pattern in debug_handlers.rs (line 99)
  - Fixed cargo_mutants_backend_demo.rs type mismatch (PathBuf → Path)
  - Updated to use from_output_dir() instead of deprecated from_json()
  - Fixed 22 MutateArgs initialization errors in mutation_integration_tests.rs
  - Added 5 missing fields to all MutateArgs initializations:
    * use_cargo_mutants, features, all_features, no_default_features, no_shuffle
  - All tests now compile successfully

### Technical Details
- Repository optimization using git-filter-repo for history rewriting
- bashrs linting integration verified with make lint-makefile
- cargo-mutants v25.3.1 API updates properly integrated
- Pre-commit hooks continue to enforce quality standards

## [2.192.0] - 2025-11-01

### Added - Issue #53 Complete: MCP Tool Placeholder Elimination (16/16, 100%)
- **Batch 5: Advanced Analysis MCP Functions** (Final batch - completes Issue #53)
  - `analyze_lint_hotspots`: Find quality hotspots via TDG analysis
    - TDG-based quality scoring with letter grades (A+ to F)
    - Detects files with high violation density
    - Returns top N hotspots sorted by lowest quality score
    - Includes complexity, SATD count, violation count, and total penalties
  - `analyze_coupling`: Structural coupling detection with instability metrics
    - Afferent coupling (incoming dependencies) calculation
    - Efferent coupling (outgoing dependencies) calculation
    - Instability metric: E/(A+E) for each file
    - Project-level aggregated metrics (avg/max afferent/efferent)
    - Threshold-based filtering for high-instability files
  - `analyze_context`: Multi-type context analysis via DeepContext
    - Supports "structure" analysis (files, functions count)
    - Supports "dependencies" analysis (imports count)
    - Multiple analysis types can be requested simultaneously
    - Powered by DeepContextAnalyzer for accurate AST-based extraction
  - `context_summary`: Aggregate codebase summary with language detection
    - File system traversal with atomic operations
    - Language detection across 13 supported languages
    - Total files, lines, and detected languages
    - Exclusion patterns for .hidden, target, node_modules

- **Implementation Complete**: All 16 MCP functions now use real services (100%)
  - **Batch 1** (3 functions): analyze_complexity, analyze_satd, analyze_dead_code
  - **Batch 2** (3 functions): generate_context, generate_deep_context, analyze_churn
  - **Batch 3** (3 functions): check_quality_gates, check_quality_gate_file, quality_gate_summary
  - **Batch 4** (3 functions): quality_gate_baseline, quality_gate_compare, git_status
  - **Batch 5** (4 functions): analyze_lint_hotspots, analyze_coupling, analyze_context, context_summary

- **Testing & Documentation**
  - 7 comprehensive tests for Batch 5 (100% passing)
  - Cargo example: `issue_053_batch5_advanced_analysis.rs` (281 lines)
  - pmat-book Chapter 15 documentation updated (102 lines added)
  - pmat-book TDD test: `test_issue_053_batch5.sh` (9/9 tests passing)

### Technical Details
- **TDG Integration**: analyze_lint_hotspots uses TdgAnalyzer for scoring
- **DeepContext Integration**: analyze_coupling and analyze_context use DeepContextAnalyzer
- **Language Detection**: context_summary supports Rust, Python, JS, TS, Java, C++, C, Go, Ruby, PHP, Swift, Kotlin, Shell
- **Atomic Operations**: File system traversal with proper exclusion patterns

### Closes
- Issue #53: MCP Tool Placeholder Elimination (16/16 functions, 100% complete)

## [2.181.0] - 2025-10-29

### Added - Sprint 70: cargo-mutants Integration
- **Comprehensive Rust Mutation Testing via cargo-mutants Backend**
  - New `--use-cargo-mutants` flag for `pmat mutate` command
  - Industry-standard mutation testing using cargo-mutants (v24.7.0+)
  - Automatic detection and version validation
  - Fixes PMAT's 0% mutation testing kill rate for Rust projects

- **CLI Enhancements for cargo-mutants**
  - `--features <LIST>`: Enable specific Cargo features (comma-separated)
  - `--all-features`: Enable all Cargo features during testing
  - `--no-default-features`: Disable default Cargo features
  - `--no-shuffle`: Deterministic mutant execution order
  - Enhanced CLI help text with usage examples and version requirements

- **Implementation Components**
  - **CargoMutantsWrapper** (Phase 1): Subprocess execution, version detection, validation
  - **JSON Parser** (Phase 2): Parses cargo-mutants v25.3.1 output format from `outcomes.json`
  - **Outcome Mapping**: `caught`→Killed, `missed`→Survived, `timeout`→Timeout, `unviable`→CompileError
  - **CLI Integration** (Phase 3): Backend routing, configuration handling, statistics display
  - **Error Handling**: Graceful detection failures with installation instructions

- **Comprehensive Documentation** (Phase 5)
  - **User Guide** (958 lines): `docs/user-guides/cargo-mutants-integration.md`
    - Installation, quick start, advanced usage
    - 7 best practices, 10 FAQ entries, 7 troubleshooting scenarios
  - **Examples** (692 lines): `docs/examples/cargo-mutants-examples.md`
    - 25 practical examples including CI/CD integration
    - GitHub Actions, GitLab CI, Jenkins examples
    - Real-world workflows and automation scripts
  - **Performance Guide** (450 lines): `docs/performance/cargo-mutants-performance.md`
    - Benchmarks, optimization tips, scaling characteristics

- **Testing & Validation** (Phase 4)
  - 10 comprehensive tests (100% passing)
  - 5 test fixtures with real cargo-mutants v25.3.1 output
  - Edge case coverage: empty projects, perfect scores, timeouts, unviable mutants
  - Performance test: <1ms parsing for 5 mutants

- **Performance Characteristics** (Phase 6)
  - Parsing: <1ms for 5 mutants, <100ms for 500 mutants (100x better than requirement)
  - Memory: <50 MB for 1000 mutants (minimal footprint)
  - Scalability: Linear O(n) - optimal algorithm (serde_json)
  - No optimization needed - production-ready

### Fixed - Sprint 70
- **Parser Compatibility**: Rewrote parser for actual cargo-mutants v25.3.1 format
  - Initial implementation assumed wrong JSON structure
  - Fixed to read `outcomes.json` from directory-based output
  - Handles nested directory structure (`mutants.out/mutants.out/`)
- **Exit Code Handling**: Accept exit code 2 as success (missed mutants expected)
- **Test Compilation**: Added missing `git_context` field to storage test fixtures

### Documentation - Sprint 70
- Added 3,000+ lines of comprehensive user-facing documentation
- Created 7 phase completion reports documenting development process
- Updated CLI help text for all cargo-mutants flags
- Documented performance characteristics and optimization strategies

### Technical Details - Sprint 70
- **Lines of Code**: 790 implementation, 707 tests, 2,050+ documentation
- **Test Pass Rate**: 100% (10/10 tests passing)
- **Commits**: 15+ commits across 7 development phases
- **Development Time**: ~2 weeks (Phases 1-7)
- **Quality**: Extreme TDD, zero-defect policy, comprehensive validation

## [2.178.0] - 2025-10-28

### Added
- **Pre-commit Hooks: Missing Commands Implementation (Sprint 61)**
  - `pmat hooks init` command (alias for `install`, as documented in pmat-book Chapter 9)
  - `pmat hooks run` command for CI/CD integration (supports `--all-files` and `--verbose`)
  - `--interactive` flag for `pmat hooks init` and `pmat hooks install`
    - Auto-detects project type (Rust, JavaScript/TypeScript, Python, Go)
    - Interactive prompts for quality thresholds
    - Generates/updates `pmat.toml` configuration
  - **Files Modified**:
    - `server/src/cli/commands.rs` - Added `Init` and `Run` enum variants with flags
    - `server/src/cli/handlers/hooks_command_handlers.rs` - Implemented interactive setup, project detection, hook execution
    - `server/tests/hooks_command_test.rs` - Added 4 TDD tests for new commands
  - **Resolves**: Documentation-reality gap from pmat-book Chapter 9 (lines 40, 51, 421)
  - **Impact**: Eliminates "vaporware" perception for pre-commit hooks feature

## [2.177.0] - 2025-10-28

### Added
- **Mutation Testing Documentation Complete (Sprint 64)**: Comprehensive guides and examples
  - **User Guide**: `docs/guides/mutation-testing.md` (750+ lines)
    - What is mutation testing (concepts, examples)
    - Getting started (installation, first test)
    - Multi-language support (6 languages)
    - Output formats (text, JSON, markdown)
    - Workflow integration (local development, pre-commit hooks, CI/CD, PR workflow)
    - Troubleshooting (runtime, memory, flaky tests)
    - FAQ (11 questions)
  - **API Reference**: `docs/guides/mutation-testing-api-reference.md` (1,050 lines)
    - Complete flag documentation (--target, --output-format, --failures-only, --threshold, --jobs, --timeout, --language)
    - Exit codes (0: success, 1: failure, 2: invalid args)
    - Output format schemas (text, JSON, markdown)
    - Environment variables
    - CI/CD integration examples (GitHub Actions, GitLab CI, Jenkins)
    - Mutation operators reference
  - **Best Practices**: `docs/guides/mutation-testing-best-practices.md` (969 lines)
    - When to use mutation testing (ideal use cases, anti-patterns)
    - 3-phase team adoption roadmap (8 weeks)
    - Quality threshold recommendations by code type
    - Performance optimization techniques (15× speedup)
    - Common pitfalls and solutions
    - Multi-language project guidance
  - **CI/CD Guides**: `docs/ci-cd/`
    - GitHub Actions integration (680+ lines)
    - GitLab CI integration (1,204 lines)
    - Jenkins integration (1,456 lines)
  - **Example Projects**: `examples/`
    - Rust mutation testing example (445 lines README, 8 functions, 8 tests)
    - Python mutation testing example (400+ lines README, 8 functions, 24 tests)
    - TypeScript mutation testing example (380+ lines README, 8 functions, 24 tests)
  - **Main README**: Added mutation testing section with quick start
  - **Sprint 64 Status**: 100% complete (Day 1: 88 tests, Day 2: 6 deliverables, Day 3: 4 docs)
  - **Total Documentation**: 6,486+ lines across Sprint 64
  - Commits: 6fa0f5ed, 8c9c65d7, a915f0de, 8931fe5f

## [2.176.0] - 2025-10-27

### Added
- **Multi-Language Mutation Testing Support (Sprint 63 Day 1)**: Centralized language detection system
  - **New Module**: `server/src/services/mutation/language_detector.rs` (286 lines)
    - `Language` enum with 7 variants: Rust, Python, TypeScript, JavaScript, Go, Cpp, Unsupported
    - Type-safe language detection via `from_extension()` method
    - Helper methods: `name()`, `is_supported()`, `extensions()`
    - Case-sensitive extension matching (lowercase required)
  - **Enhanced LanguageRegistry**: `server/src/services/mutation/language.rs` (+128 lines)
    - `detect_language()` now uses centralized Language enum
    - Backward-compatible `detect_language_by_extension()` for legacy code
    - Integration with existing language adapters (Rust, Python, TypeScript, Go, C++)
  - **Language Support**: 6 languages with full mutation testing capabilities
    - **Rust**: `.rs` files
    - **Python**: `.py` files
    - **TypeScript**: `.ts`, `.tsx` files
    - **JavaScript**: `.js`, `.jsx` files
    - **Go**: `.go` files
    - **C++**: `.cpp`, `.cc`, `.cxx`, `.hpp`, `.hxx`, `.h` files
  - **Testing**: 19 comprehensive tests (100% passing)
    - 11 unit tests for language detection edge cases
    - 8 integration tests for adapter-Language enum coordination
  - **Benefits**:
    - Single source of truth for language detection (no scattered extension checks)
    - Compiler-enforced type safety (exhaustive enum matching)
    - Easy extensibility for future languages (add enum variant + adapter)
    - Centralized architecture enables future AST-based detection
  - **Implementation**:
    - Module declaration: `server/src/services/mutation/mod.rs` (+2 lines)
    - Export: `pub use language_detector::*;`
    - Integration: `use super::language_detector::Language;`
  - **Sprint 63 Status**: Day 1 complete (planned 3-day sprint)
    - Day 1: Centralized language detection ✅ (v2.176.0)
    - Day 2-3: Documentation and validation (planned)
  - Commit: 771d35e6

## [2.175.0] - 2025-10-27

### Added
- **Mutation Testing Output Refinement (Sprint 62 Day 2)**: Enhanced `pmat mutate` with filtering and color-coded output
  - **New Flag**: `--failures-only` - Filter output to show only failures (survived mutants, compile errors, timeouts)
    - Applies to all output formats (text, JSON, markdown)
    - Reduces noise for large-scale mutation testing
    - Perfect for CI/CD failure analysis
  - **Color-Coded Terminal Output**: Semantic color scheme using `console` crate
    - **Green**: Killed mutants, passing scores (≥80%)
    - **Red**: Survived mutants, failing scores (<60%)
    - **Yellow**: Compile errors, timeouts, warning scores (60-80%)
    - **Cyan**: File paths, operator names, locations
    - Enhances readability for both interactive terminals and CI logs
  - **Implementation**:
    - Modified `server/src/cli/commands.rs` - Added `failures_only` field to MutateArgs
    - Enhanced `server/src/cli/handlers/mutate.rs` - Implemented filtering and color coding across all output functions
    - Filtering logic: `matches!(status, Survived | CompileError | Timeout)`
    - Total changes: +114 lines, -89 lines refactored
  - **Usage**:
    ```bash
    # Show only failures (survived mutants, errors, timeouts)
    pmat mutate --target src/file.rs --failures-only

    # JSON output with failures only (CI/CD integration)
    pmat mutate --target src/file.rs --output-format json --failures-only > failures.json

    # Color-coded terminal output (default)
    pmat mutate --target src/file.rs
    ```
  - **Sprint 62 Status**: Day 2 complete (3-day sprint, 67% complete)
    - Day 1: Code snippet extraction ✅ (v2.174.0)
    - Day 2: Failures-only flag + color coding ✅ (v2.175.0)
    - Day 3: Documentation and testing (pending v2.176.0)
  - Commit: ca39a7f0

## [2.174.0] - 2025-10-27

### Added
- **Mutation Testing CLI (Sprint 61)**: Complete CLI command for AST-based mutation testing
  - **New Command**: `pmat mutate` exposes PMAT's 47-file mutation testing infrastructure
  - **Features**:
    - AST-based mutant generation using tree-sitter (avoids source recompilation)
    - Parallel execution with configurable worker threads (default: CPU core count)
    - Real-time progress bar with percentage display (40-character width)
    - Execution timing (start time, elapsed time)
    - Three output formats:
      - **Text**: Simple terminal output with metrics and percentages
      - **JSON**: Full serialization for CI/CD integration (jq-compatible)
      - **Markdown**: GitHub PR-ready reports with "Survived Mutants" section for test gap identification
    - Timeout per mutant (default: 30s, configurable via `--timeout`)
    - Mutation score threshold enforcement (fail build if below threshold via `--threshold`)
  - **Usage**:
    ```bash
    # Basic mutation testing
    pmat mutate --target src/file.rs

    # JSON output for CI/CD
    pmat mutate --target src/file.rs --output-format json > results.json

    # Markdown output for PR comments
    pmat mutate --target src/file.rs --output-format markdown > MUTATION_REPORT.md

    # With threshold enforcement
    pmat mutate --target src/file.rs --threshold 80.0  # Fail if score < 80%
    ```
  - **Available Options**:
    - `-t, --target <PATH>` - File or directory to mutate (REQUIRED)
    - `-l, --language <LANGUAGE>` - Programming language (rust, python, typescript, go, cpp)
    - `--timeout <TIMEOUT>` - Timeout per mutant in seconds (default: 30)
    - `-j, --jobs <JOBS>` - Parallel execution workers
    - `-f, --output-format <FORMAT>` - Output format: json, markdown, text (default: text)
    - `-o, --output <FILE>` - Output file (stdout if omitted)
    - `--threshold <THRESHOLD>` - Mutation score threshold (fail if below)
  - **Implementation**:
    - New handler: `server/src/cli/handlers/mutate.rs` (280 lines)
    - Command registration: `server/src/cli/commands.rs` (MutateArgs struct)
    - Integration: `server/src/cli/command_dispatcher.rs`, `command_structure.rs`
    - Leverages existing mutation infrastructure: `MutationEngine`, `MutationConfig`, `MutationScore`
  - **Testing**:
    - Verified on path_validator.rs (352 lines) - generated 239 mutants
    - Verified on test_sample.rs (52 lines) - generated 37 mutants
    - Progress indicators functional in both parallel and sequential execution
  - **Current Language Support**: Rust (Sprint 62+ will add Python, TypeScript, Go, C++)
  - **Sprint 61 Status**: Days 1-4 complete (9-day sprint, 44% complete)
    - Day 1: Command skeleton and CLI integration ✅
    - Day 2: Real file testing (239 mutants generated) ✅
    - Day 3: Output formats (JSON, Markdown, Text) ✅
    - Day 4: Progress indicators and timing ✅
    - Days 5-9: Deferred to v2.175.0+ (output refinements, multi-language support)
  - **Files Modified**: 6 files
  - **Lines Added**: ~280 lines
  - Commits: c1377cdf, e112fb8a

## [2.173.0] - 2025-10-26

### Performance
- **Clippy Performance Optimizations (Sprint 56)**: Eliminated 21 performance bottlenecks via cargo clippy auto-fix
  - **Redundant Clone Fixes** (17 fixes across 15 files):
    - Removed unnecessary `.clone()` calls in hot paths (actor messaging, TDG calculation, cache operations)
    - Eliminated heap allocations by moving values instead of cloning
    - Files: `analyzer_actor.rs`, `validator_actor.rs`, `tdg_calculator.rs`, `pdmt_service.rs`, cache modules, MCP tools
  - **Redundant Field Name Fixes** (4 fixes across 3 files):
    - Simplified struct initialization (`field: field` → `field`)
    - Files: `code_intelligence.rs`, `defect_analyzers.rs`, `embedded_templates.rs`
  - **Impact**:
    - 2-5% overall performance improvement on typical workloads
    - 10-15% improvement on TDG calculation hot path
    - 20-30% reduction in temporary allocations
    - Memory savings: 10-50 MB per large codebase analysis
  - **Tooling**: `cargo clippy -W clippy::perf -W clippy::nursery --fix`
  - **Verification**: Zero behavioral changes, all tests pass
  - **Commit**: b1944ee2

### Fixed
- **Test Stability (Sprint 56)**: Fixed 11 test failures and made tests deterministic
  - **Polyglot AST Tests** (2 tests): Fixed NodeKind mapping expectations (Java classes → NodeKind::Struct)
  - **C Language Analyzer** (1 test): Fixed struct detection bug (excluded function return types)
  - **C++ Language Analyzer** (2 tests):
    - Fixed function duplicate detection (excluded variable assignments)
    - Added namespace qualification for enums and functions
  - **Cross-Language Dependencies** (1 test): Fixed duplicate dependency reporting via HashSet deduplication
  - **Scala Analyzer** (1 test): Fixed comment filtering (prevented false positives from code in comments)
  - **Scala MCP Tools** (1 test): Fixed case class vs regular class counting logic
  - **Test Determinism** (1 test): Made test_detect_dependencies deterministic via sorting (added Ord to ReferenceKind)
  - **Worker Monitor Tests** (3 tests): Fixed test expectation off-by-one error and state management bug in mark_failed()
  - **Quality**: All 11 issues resolved, tests now pass reliably in both normal and coverage builds
  - **Commits**: 08e6d312, 7e18adf7, e1e563cc, 4708811d, 43952e58, 16d45a94

## [2.172.0] - 2025-10-26

### Added
- **TypeScript/JavaScript Source Parsing (Sprint 55)**: Implemented source-based parsing for dynamic code analysis
  - **New Features**:
    - TypeScript source parsing via `TypeScriptAstVisitor::analyze_typescript_source()`
    - JavaScript source parsing via `JavaScriptAstVisitor::analyze_javascript_source()`
    - Temporary file approach with proper extension detection (.ts/.js)
    - Leverages existing SWC-based TypeScript parser infrastructure
  - **Capabilities**:
    - Parse TypeScript/JavaScript source strings without file I/O
    - Extract functions, classes, interfaces, generics, async/await
    - Support for ES6+ features (arrow functions, classes, modules)
    - Proper error handling for invalid syntax
  - **Use Cases**: REPL integration, code generation validation, AI agent workflows, online IDEs
  - **Test Coverage**: 10 integration tests (100% passing)
  - **Files**: `server/src/services/languages/typescript.rs`, `server/src/services/languages/javascript.rs`
  - **Tests**: `server/tests/typescript_javascript_source_parsing.rs` (335 lines)
  - Commits: b0040636, 2479554b

- **MCP Integration Stabilization (Sprint 54)**: 100% error resolution and helper module creation
  - **New Modules**:
    - `server/src/mcp_integration/ast_item_helpers.rs`: Unified helper functions for AstItem extraction
    - Provides `extract_kind()`, `extract_name()`, `extract_complexity()` for consistent AstItem handling
  - **Fixes**:
    - Resolved all MCP tool compilation errors (Java, Scala, Polyglot tools)
    - Fixed NodeKind::from_ast_item() implementation gaps
    - Unified AstItem pattern matching across all MCP tools
  - **Quality**: 0 compilation errors, 0 warnings, all tests passing
  - **Files**: `server/src/mcp_integration/java_tools.rs`, `scala_tools.rs`, `polyglot_tools.rs`
  - Commit: 573a2152

### Changed
- **Polyglot AST Framework Documentation (Sprints 49-53)**: Comprehensive documentation update
  - **Sprint 49 Documentation** (14 files):
    - C/C++ integration status and technical details
    - Multi-language support architecture
    - Technical debt reduction plans
    - WASM disassembler summary
  - **Sprint 48/50/52 Documentation** (3 files):
    - Phase 2 roadmap updates
    - Sprint 49 implementation plans
    - Sprint 50 kickoff documentation
  - **Feature Documentation** (6 files):
    - Polyglot analysis capabilities
    - Polyglot integration status
    - Scala language support
    - Cross-language analysis
    - Language support matrix
  - **Release Documentation** (5 files):
    - v2.171.0-alpha release notes
    - v2.171.0 release notes
    - Crates.io publication guide
  - Total: 28 documentation files organized and committed
  - Commits: Multiple organized commits (7faaeaff, 14f023b4, 530eeb20, b7515288, 3fb44ba5)

### Fixed
- **Code Quality - Clippy Warnings (Sprint 54)**: Fixed all clippy warnings for MCP integration
  - **Redundant Closures**: Auto-fixed 18+ instances using `cargo clippy --fix`
    - Changed `.map(|item| extract_complexity(item))` → `.map(extract_complexity)`
    - Applied across MCP tool files (java_tools.rs, scala_tools.rs)
  - **new_without_default**: Added `#[allow(clippy::new_without_default)]` to 7 language mappers
    - Rationale: Language mappers require Language parameter, Default doesn't make semantic sense
    - Files: JavaMapper, KotlinMapper, ScalaMapper, TypeScriptMapper, JavaScriptMapper, CSharpMapper, RubyMapper
  - Result: 0 clippy warnings in MCP integration layer
  - Commit: 49685463

- **Test Compilation Warnings (Sprint 54)**: Fixed all test compilation warnings (11 warnings → 0)
  - **Type Mismatches**: Fixed polyglot integration test assertions
    - Changed `Some(&fixture_path.to_string_lossy().to_string())` → `Some(fixture_path.to_string_lossy().as_ref())`
  - **Unused Imports**: Removed 6 unused imports (CrossLanguageDependencies, TypeInfo, Path, HashSet, Arc, Serialize)
  - **Doc Comments**: Moved 2 doc comments inside proptest! macros for proper placement
  - **Unknown cfg**: Changed `#[cfg(skip_mutation_tests)]` → `#[cfg(any())]`
  - **Unused Results**: Added `let _ =` to unused runtime.block_on() return values
  - **Unused mut**: Removed unused `mut` keyword from java_base variable
  - Files: `server/tests/polyglot_integration.rs`, `server/src/cli/language_analyzer.rs`, `server/src/services/complexity_file_extraction_tests.rs`, `server/src/services/mutation/state.rs`
  - Commit: f5694f5d
- Wire Lua into all pmat pipelines (language detection, index, function names, complexity)