Commit Graph

166 Commits

Author SHA1 Message Date
Profa 6b69449a4b fix(network): change network policies to opt-in instead of opt-out
BREAKING CHANGE: Network policies are now permissive by default

Previously, all agents had restrictive domain whitelisting enabled by
default (blockUnknownDomains: true), which blocked access to:
- Multi-model router's 8+ LLM providers (only Anthropic was allowed)
- Arbitrary websites needed for QE testing purposes

Changes:
- Default policies now use blockUnknownDomains: false (permissive)
- Rate limiting still applies for protection
- Audit logging enabled by default for visibility
- Added LLM_PROVIDER_DOMAINS constant with 15 provider domains
- Added createRestrictivePolicy() for opt-in security when needed
- Added enableRestrictiveModeGlobally() for secure deployments

For security-sensitive deployments, use:
```typescript
// Option 1: Per-agent restrictive policy
const policy = createRestrictivePolicy('qe-test-generator', ['custom.api.com']);
manager.registerPolicy(policy);

// Option 2: Global restrictive mode
enableRestrictiveModeGlobally();
```

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-05 12:41:23 +00:00
Profa 3cb2e1e763 feat(v2.8.1): nervous system integration & Supabase cloud persistence
Major Features:
- Nervous System Integration: BTSP learning, HDC memory, circadian cycling,
  global workspace attention - all QE agents now benefit automatically
- Supabase Cloud Persistence: HybridPersistenceProvider with local-first
  storage and background cloud sync, full CLI commands (aqe supabase)
- Migration Support: Transfer local SQLite data to Supabase cloud

Changes:
- BaseAgent: Auto-initializes nervous system components
- Persistence: New IPersistenceProvider interface with adapters
- CLI: Added supabase subcommands (setup, test, status, sync, schema)
- Version bump to 2.8.1 across all files

Tests:
- 41 nervous system integration tests (all passing)
- BaseAgent.nervous-system.test.ts validates HDC, BTSP, workspace

Closes #188 (MCP tool handlers implemented in previous commit)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-04 18:08:38 +00:00
Profa c1a6ef228e created new goap plans 2026-01-04 11:40:53 +00:00
Profa 5b5a78638d docs(plans): add edge dashboard improvements plan
Comprehensive 6-phase plan to transform web dashboard into a compute
contribution platform based on analysis of ruvector/edge-net:

- Phase 1: Zustand state management migration
- Phase 2: Credit economy system
- Phase 3: WASM task execution
- Phase 4: Cryptographic identity
- Phase 5: Enhanced UI with HeroUI
- Phase 6: Backend infrastructure

Related: #186

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-04 09:20:51 +00:00
Profa 067258e39e docs(webapp): clarify web dashboard use cases and fix P2P connection
- Add comprehensive use cases guide explaining dashboard limitations
- Fix P2P connection bug: connect to discovered peers, not random IDs
- Add webapp package.json with Vite/React dependencies for dev server

The dashboard is for monitoring and pattern sharing, NOT local code
generation. Local QE work requires CLI or VS Code Extension due to
browser sandbox restrictions.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-04 09:02:18 +00:00
Profa d51bc8f156 feat(vscode): prepare extension for marketplace publishing
VS Code Extension Fixes:
- Fix @ruvector/edge missing in VSIX by updating .vscodeignore
- Add fallback mode in EdgeAgentService for when WASM unavailable
- Complete fallback implementation with brute-force cosine search

Marketplace Publishing Assets:
- Add README.md with features, commands, settings documentation
- Add CHANGELOG.md with version history (0.1.0, 0.2.0)
- Add LICENSE (MIT)
- Add 128x128 PNG icon with gradient design
- Add icon and galleryBanner to package.json

Documentation:
- Add vscode-extension-publishing.md guide with step-by-step instructions

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-03 19:14:39 +00:00
Profa 7363bb1278 chore(release): bump version to v2.8.0
## @ruvector/edge Integration - Phases 0-3 Complete

### Phase 0: Browser Runtime
- WASM shims and browser compatibility
- BrowserAgent, BrowserHNSWAdapter, IndexedDBStorage
- Chrome DevTools panel

### Phase 1: VS Code Extension MVP
- Full extension with real-time analysis
- Inline test suggestions, coverage visualization
- Offline-first storage with sync

### Phase 2: P2P Foundation
- Ed25519 crypto, WebRTC connections
- SignalingServer, AgentSpawnAPI, EdgeServer
- Pattern sharing via data channels
- CRDT conflict resolution

### Phase 3: Web Dashboard
- React dashboard with dark theme
- P2P connection management UI
- QE Agent Launcher from browser
- React hooks (useP2P, usePatternSync, etc.)

### Documentation
- Edge Server Guide
- P2P Pattern Sharing Guide
- Updated CLI agent-commands

### Also includes
- Dead code cleanup (~22k lines)
- 143 new P2P integration tests
- Version updates across all files

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-03 13:42:48 +00:00
Profa f13eb30ce1 feat(edge): Phase 4 P2P integration with Edge Server
Phase 4 Implementation:
- SignalingServer: WebSocket server for WebRTC peer discovery
- AgentSpawnAPI: REST API for spawning QE agents from dashboard
- EdgeServer: Combined HTTP + WebSocket server entry point

CLI Enhancements:
- Added `aqe agent spawn <type>` command with task execution
- Added `aqe agent list` to view spawned agents
- Agent state persists to .agentic-qe/agents/ directory

P2PService Fixes (from brutal honesty review):
- Integrated real SignalingClient for WebRTC signaling
- Added RTCPeerConnection management with ICE handling
- Replaced mock connection with actual WebRTC setup
- Fixed PatternCategory enum mapping

Dashboard Fixes:
- Added error state display instead of silent failures
- Shows red error banner when agent spawn fails

Tests:
- AgentSpawnAPI.test.ts (17 tests)
- SignalingServer.test.ts (7 tests)
- Webapp component tests

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-03 13:06:48 +00:00
Profa 8d0711ab27 test(edge): add Phase 2 P2P integration tests (143 tests)
Add comprehensive integration test suite for P2P Foundation:
- crypto-webrtc.integration.test.ts (28 tests)
- protocol-sharing.integration.test.ts (34 tests)
- coordination-crdt.integration.test.ts (33 tests)
- full-stack.integration.test.ts (48 tests)

Update GOAP checklist marking Phase 2 complete:
- All 24 Phase 2 tasks completed
- 605+ total tests (462 unit + 143 integration)
- All modules verified working

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-02 20:50:33 +00:00
Profa 98e58c3c27 refactor: major dead code cleanup and MCP handler integration
- Integrate 8 previously unregistered MCP handlers:
  - Chaos engineering: chaos_inject_latency, chaos_inject_failure, chaos_resilience_test
  - Integration testing: integration_dependency_check, integration_test_orchestrate
  - Token-optimized: test_execute_filtered, performance_test_filtered, quality_assess_filtered
- Create NewDomainToolsHandler.ts to route new domain tools

Dead code removal (~22k lines):
- Delete 4 overlapping filtered handlers (coverage, flaky, security, contract)
- Remove unused directories: src/alerting/, src/reporting/, src/transport/
- Remove 4 unregistered CLI command dirs: fleet/, test/, quality/, monitor/ (42 files)
- Archive 10 one-time verification scripts to scripts/archive/
- Remove 2 CLI backup files (index-spec.ts, index-working.ts)

Test organization:
- Move HNSWPatternStore.test.ts from src/ to tests/unit/memory/
- Delete OutputFormatter duplicate test from src/
- Consolidate duplicate RuVector and learning-persistence tests
- Rename RuVector.SelfLearning.test.ts for consistent naming

Dependencies:
- Remove unused packages: jose, @types/chrome, gpt-tokenizer

Build config:
- Exclude src/edge/ subdirectories from main tsconfig (separate build)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-02 16:30:45 +00:00
Profa 6fd4bfe8fa feat(learning): integrate RuVector intelligence layer for pattern learning
Add RuVector-based learning system that captures patterns from development:
- .ruvector/intelligence.json: stores learned patterns, error fixes, file sequences
- scripts/workers/qe-self-learning.js: background learning worker
- scripts/workers/sync-intelligence.js: intelligence synchronization
- scripts/migrate-memory-to-ruvector.js: migration from legacy memory
- scripts/migrate-swarm-to-ruvector.js: migration from swarm patterns
- scripts/suggest-agents-from-intelligence.js: agent routing suggestions

Updated .gitignore to track .ruvector/ for shared team learning.
Updated .claude/settings.json with RuVector hooks integration.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-02 15:56:00 +00:00
Profa faf9c84221 feat(edge): add @ruvector/edge browser integration (Phase 0)
Implements browser-compatible QE agents using @ruvector/edge WASM:

- Add BrowserHNSWAdapter with real @ruvector/edge WasmHnswIndex
- Add IndexedDBStorage for browser-side vector persistence
- Add BrowserAgent for WASM-compatible agent lifecycle
- Add Chrome DevTools panel for agent monitoring
- Add build:edge script producing 183.4KB gzipped bundle

Verified metrics (not estimated):
- Bundle size: 183.4 KB gzipped (target: <400KB) ✓
- Tests: 173/177 passing (4 expected failures in Node.js)
- Build: TypeScript compilation succeeds

Analysis documents:
- GOAP evaluation of @ruvector/edge integration
- Visionary analysis with 12 novel use cases
- Implementation plan for 5 phases

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-02 13:34:17 +00:00
Profa 1aa321691d feat(goap): Phase 5 & 6 - Plan Learning & Live Agent Execution
## Phase 5: Plan Learning
- PlanLearning: EMA-based action success rate tracking
- PlanSimilarity: Plan signature matching for reuse (<100ms)
- Q-Learning integration for GOAP action selection
- Database persistence for learning history

## Phase 6: Live Agent Execution
- Real agent spawning via AgentRegistry (not just dry-run)
- Output parsing for real-time world state updates
- Plan signature storage after successful execution
- Learning feedback loop integration

## New Files
- src/planning/PlanLearning.ts
- src/planning/PlanSimilarity.ts
- tests/integration/goap-live-execution.test.ts (17 tests)
- tests/integration/goap-phase5-real-integration.test.ts (15 tests)
- tests/integration/goap-plan-learning.test.ts (31 tests)

## Test Coverage
- 84 GOAP-related tests passing
- Output parsing methods verified
- Live vs dry-run code paths tested

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 11:45:42 +00:00
Profa 9d62a40366 feat(goap): Phase 3 Task Orchestration + backup system after data loss
GOAP Phase 3 - Task Orchestration Integration:
- Add TaskWorkflowGoals with 4 goal definitions
- Add 17 orchestration-specific GOAP actions
- Create GOAPTaskOrchestration integration class
- Modify TaskOrchestrateHandler with GOAP planning + template fallback
- Add AgentRegistry integration for fleet state
- Add 31 integration tests for task orchestration

CRITICAL INCIDENT - Data Loss (2025-12-29):
- memory.db accidentally deleted during test debugging
- 2 months of learning data permanently lost
- Added backup system to prevent recurrence:
  - scripts/backup-memory.js with backup/restore
  - npm run backup, backup:list, backup:restore
  - Accelerated learning config for rebuild

Also includes:
- C4 architecture diagrams
- GOAP integration plans and documentation
- Quality gate GOAP integration
- Plan executor with dry-run mode
- Database schema updates for GOAP tables

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 19:20:15 +00:00
Profa d5514b2143 chore(release): bump version to v2.7.1 with type safety improvements
## Summary
- Reduced TypeScript `any` types from 568 to 538 (63% overall reduction from 1,470)
- Fixed all 146 TypeScript compilation errors
- Updated version to v2.7.1 across all 5 required files
- Added ErrorUtils utility for consistent error handling
- Updated GOAP plan with Phase 2 completion status

## Type Safety Improvements
- Added index signatures for SerializableValue compatibility
- Fixed memory retrieval type casts across 15+ agent files
- Added proper task payload typing in agent performTask methods
- Created shared error handling utilities

## Files Updated
- package.json, package-lock.json (version bump)
- README.md (version badge)
- CHANGELOG.md (release notes)
- src/mcp/server-instructions.ts (SERVER_VERSION)
- src/core/memory/HNSWVectorMemory.ts (version info)
- docs/plans/goap-issue-149-code-quality.md (progress tracking)
- 100+ source and test files (type safety fixes)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 08:00:00 +00:00
Profa b91627f282 fix(quality): implement GOAP Issue #149 code quality remediation
Phase 1: Test Determinism
- Create SeededRandom utility with Mulberry32 PRNG (src/utils/SeededRandom.ts)
- Migrate 258+ Math.random() calls to SeededRandom across 65+ test files
- Add timer test utilities (tests/helpers/timerTestUtils.ts)
- Add jest.useFakeTimers() pattern to 13 test files

Phase 2: Type Safety (63.5% reduction)
- Reduce `any` types from ~1,800 to 656
- Add 50+ new interfaces across agents, core, mcp, cli modules
- Fix all TypeScript errors (0 errors, build passes)
- Replace Record<string, any> with Record<string, unknown>
- Add proper type guards for hook methods (PostTaskData, TaskErrorData)

Key improvements:
- agents/: 105 → 0 any types (100% reduction)
- mcp/: 226 → 102 any types (55% reduction)
- cli/: 277 → 168 any types (39% reduction)
- core/: 199 → 175 any types (12% reduction)

Closes #149

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 17:08:12 +00:00
Profa 8bb2ad1aee feat(v2.6.6): Web-Tree-Sitter migration, MinCut analysis, CriticalPathDetector
## Web-Tree-Sitter Migration (Phases 1-5)
- New WebTreeSitterParser replacing native tree-sitter bindings
- Eliminates npm install warnings about native compilation
- Updated all language extractors (TS, JS, Python, Go, Rust)

## MinCut Analysis Integration (Phases 1-6)
- New src/code-intelligence/analysis/mincut/ module
- MinCutAnalyzer: Stoer-Wagner algorithm for graph partitioning
- GraphAdapter: Code graph to MinCut format conversion
- CircularDependencyDetector: Dependency cycle detection
- ModuleCouplingAnalyzer: Module coupling analysis

## CriticalPathDetector for Coverage Analysis
- New src/coverage/CriticalPathDetector.ts
- Identifies structurally critical code paths using MinCut
- Prioritizes coverage gaps by criticality score
- Integrated with CoverageAnalyzerAgent

## Fleet Topology Management
- New src/fleet/topology/ module
- MinCut-based test file partitioning
- Integrated with test-execute-parallel MCP handler

## Other Changes
- MCP tool count corrected: 102 → 105 tools
- New CLI commands: aqe kg mincut, aqe kg circular
- 19 new tests for CriticalPathDetector

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-26 11:02:28 +00:00
Profa acb5973186 feat(providers): LLM Independence Phase 3-4 complete
## New Features

### LLM Providers
- GroqProvider: Free tier (14.4k req/day), streaming, rate limiting
- GitHubModelsProvider: Codespaces auto-detection, GITHUB_TOKEN auth

### Provider Health Monitoring
- ProviderHealthMonitor: Circuit breaker pattern (closed → half-open → open)
- QuotaManager: Per-provider quota tracking with daily/minute limits
- HybridRouterHealthIntegration: Health-aware routing with fallback

### CLI Commands
- `aqe providers status`: Health dashboard
- `aqe providers list`: List configured providers
- `aqe providers test`: Test provider connectivity
- `aqe providers switch`: Switch default provider
- `aqe providers quota`: Show quota usage

## Tests
- 144 new tests for Phase 3-4 components

## Documentation
- Updated README with Provider Health Monitoring section
- Updated CHANGELOG with v2.6.5 features
- Updated implementation plan to COMPLETE status

Closes #169

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-25 16:02:05 +00:00
Profa 0cb4f6fceb feat(release): v2.6.3 - C4 Model Architecture Diagrams
### Added
- C4 diagram builders for context, container, and component levels
- ProjectMetadataAnalyzer for system type inference from package.json/docker-compose
- ExternalSystemDetector for database, API, cache, and queue detection
- ComponentBoundaryAnalyzer for layer and relationship mapping
- CLI commands: `aqe kg c4-context`, `aqe kg c4-container`, `aqe kg c4-component`
- CodeIntelligenceAgent c4-diagrams capability
- 22 unit tests for C4 diagram builders

### Changed
- MermaidGenerator with static C4 generation methods
- Type consolidation in src/code-intelligence/inference/types.ts
- Standardized ComponentRelationship to use sourceId/targetId
- Updated qe-code-intelligence.md with C4 capabilities and examples

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-24 18:59:40 +00:00
Profa 0a7a1c8b09 feat(release): v2.6.2 - Phase 2 LLM Independence & Cost Optimization
## Added
- ML-Based Complexity Classification with 4-level task analysis
- Model Capability Registry with 25+ December 2025 models
  - Claude Opus 4.5, DeepSeek R1/V3, GPT-5, Gemini 2.5 Pro
- Cost Optimization Strategies (PromptCompressor, Caching, Batching)
- HybridRouter integration with complexity-based model selection

## Changed
- README.md Quick Start section (user-focused, no version numbers)
- .env.example rewritten for Phase 2 features
- CONTRIBUTORS.md updated with @fndlalit's n8n contribution (#151)

## Fixed
- HybridRouter RuVector test isolation
- Compression benchmarks with honest expectations (2-8% vs false 50%)

## New Tests
- ComplexityClassifier, ModelCapabilityRegistry, CompressionBenchmark
- HybridRouter integration, model selection, and cost tracking tests

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-24 15:24:41 +00:00
Profa 9fd235d2e6 feat(phase-1): complete LLM Independence Phase 1 implementation
Phase 1.1 - OllamaProvider:
- Add OllamaProvider with all 13 ILLMProvider methods
- Add unit and integration tests for OllamaProvider
- Integrate with LLMProviderFactory auto-detection

Phase 1.2 - Agent Abstraction:
- Add IAgentLLM interface for provider-independent LLM access
- Add AgentLLMAdapter bridging ILLMProvider to IAgentLLM
- Update BaseAgent with getAgentLLM() method
- Migrate 4 LLM-active agents: TestGenerator, CoverageAnalyzer,
  CodeIntelligence, N8nBase
- 15 n8n agents inherit capability via N8nBaseAgent
- 17 algorithmic agents work without LLM by design

Phase 1.3 - Configuration:
- Add ProviderConfig types and ConfigLoader
- Add CLI providers commands (list, status, switch, test)
- Add example provider configurations

Documentation:
- Update implementation plan with accurate agent categorization
- Add usage examples for IAgentLLM patterns
- Add provider guides and research documents

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-24 11:19:04 +00:00
Profa 7a5ff50e5d feat(release): v2.6.1 - Phase 3 B2 Plugin System
## Phase 3 B2: Extensible Plugin System (4,152 lines)

Core Components:
- Plugin Types (types.ts) - 612 lines of TypeScript interfaces
- Plugin Manager (PluginManager.ts) - 987 lines with real implementations:
  - Real hot-reload via fs.watch with debouncing
  - Real plugin loading via dynamic import()
  - Semver-based dependency resolution
  - Service registration and cross-plugin communication
- Base Plugin (BasePlugin.ts) - 189 lines foundation class

Reference Implementations:
- PlaywrightPlugin (539 lines) - E2E adapter with real spawn execution
- VitestPlugin (709 lines) - Unit test adapter with real coverage parsing
- McpToolsPlugin (637 lines) - Real MCP JSON-RPC client

Test Suite:
- 30 tests passing (PluginManager.test.ts - 395 lines)

## Phase 3 D1: Memory Pooling (committed in 0fd6fb60)

- 1750x speedup achieved (0.057ms vs 100ms target)
- AgentPool and QEAgentPoolFactory implementations

## Fixes

- Tree-sitter peer dependency warnings
- Fraudulent benchmarks replaced with honest measurements

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-23 09:23:13 +00:00
Profa 88a5aeb98b docs: add comprehensive journey article v2.5.0 to v2.6.0
7,842-word article documenting:
- 11 releases (v2.5.0 → v2.6.0), 89 commits
- All verified benchmarks with sources
- Pivotal "completion theater" moments (Issue #118)
- Learning persistence crisis (Issue #79)
- FleetManager type mismatch (Issue #137)
- Community contributions (@fndlalit, @gurdasnijor)
- Key metrics: 79.9% token reduction, 150x HNSW search
- Competitive positioning analysis
- User benefit calculations

For use as base for external article/blog post.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 16:41:23 +00:00
Profa 6d93623302 docs: update user-facing docs with Code Intelligence Agent
- Update README.md: 19 → 21 QE agents, add token reduction benefit
- Add link to benchmark results in quickstart guide
- Highlight 80% token reduction as key feature

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 16:14:48 +00:00
Profa e2180f83e7 docs: add Code Intelligence token reduction benchmark results
Benchmark shows 79.9% input token reduction and 92% context relevance
with Code Intelligence vs baseline approach.

Key findings:
- 1,671 → 336 input tokens per query
- 6 files → 2 semantic chunks
- 35% → 92% relevance score
- ~$15/month savings at 100 queries/day

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 16:07:05 +00:00
Profa c42c88b9d6 feat(release): v2.6.0 - Code Intelligence System & MCP Configuration
## Major Features

### Code Intelligence System v2.0
- Tree-sitter multi-language parser (TypeScript, Python, Go, Rust, JavaScript)
- Hybrid search engine (BM25 + semantic vector search with RRF fusion)
- Knowledge graph with relationship extraction
- RAG context builder with 70-80% token reduction
- CodeIntelligenceAgent for intelligent code queries
- Auto-injection into all QE agents via FleetManager

### MCP Configuration Fix
- Added `generateMcpJson()` to create `.claude/mcp.json` during `aqe init`
- Fixed learning persistence via `capture-task-learning.js` hook
- Added `agentic-qe` to `enabledMcpjsonServers`

## CLI Commands
- `aqe kg index <directory>` - Index codebase
- `aqe kg search <query>` - Semantic code search
- `aqe kg visualize <entity>` - Generate Mermaid diagrams
- `aqe code-intel setup/enable/status` - Configuration commands

## Bug Fixes
- Fixed TypeScript build errors in Code Intelligence files
- Fixed FormattedContext type mismatch in CodeIntelligenceAgent
- Fixed Mermaid direction type (TD → TB)
- Fixed autoIndex property type in code-intelligence-init

## Issues Closed
- #158 Code Intelligence System v2.0 (Epic)
- #161 Wave 3: AST-Based Chunking & Embeddings
- #162 Wave 4: Incremental Indexing Pipeline
- #163 Wave 5: Hybrid Search & LlamaIndex RAG
- #164 Wave 6: Agent Integration & CLI Commands

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 15:06:25 +00:00
Profa ab86895b33 feat(agents): add CodeIntelligenceAgent for knowledge graph code understanding
Wave 6 completion - Code Intelligence agent integration:

New Files:
- src/agents/CodeIntelligenceAgent.ts: Full TypeScript implementation
  - Extends BaseAgent with code intelligence capabilities
  - Task types: index, search, context, graph, stats, incremental-update
  - Public API: quickSearch(), getFormattedFileContext(), getFormattedQueryContext()
  - Factory registration for QEAgentFactory

- .claude/agents/qe-code-intelligence.md: Agent definition for Claude Code
  - Learning protocol with MCP tools
  - Memory namespace configuration
  - Usage patterns and examples

- docs/guides/code-intelligence-quickstart.md: User documentation
  - Prerequisites (Ollama, RuVector PostgreSQL)
  - Usage options (CLI, Task tool, programmatic API)
  - Configuration and troubleshooting

Updates:
- src/types/index.ts: Added CODE_INTELLIGENCE to QEAgentType enum
- src/agents/index.ts: Export and factory case for CodeIntelligenceAgent
- docs/reference/agents.md: Added agent reference (now 21 QE agents)
- CLAUDE.md: Updated agent count and added guide link

Capabilities:
- Tree-sitter multi-language parsing (TypeScript, Python, Go, Rust, JS)
- Ollama nomic-embed-text embeddings (768 dimensions)
- Hybrid search (BM25 + Vector with RRF fusion)
- Knowledge graph with entity relationships
- 80% token reduction through intelligent context building
- Mermaid diagram generation
- Incremental indexing with git change detection

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 11:45:45 +00:00
Profa d88c9860d0 feat(code-intelligence): complete Wave 6 - Agent Integration & CLI
Wave 6 Agent 1 - KnowledgeGraphContextBuilder:
- ContextCache with LRU eviction and TTL (70-80% hit rate)
- GraphExpander for 2-hop relationship traversal
- ContextFormatter with LLM-optimized markdown output
- KnowledgeGraphContextBuilder achieving 80% token reduction
- 86 tests passing

Wave 6 Agent 2 - CLI Commands:
- `aqe kg index [--watch] [--incremental] [--git-since]`
- `aqe kg query <text> [--hybrid] [-k N] [--lang]`
- `aqe kg graph <file> [--type class|dependency]`
- `aqe kg stats [--verbose]`
- KGOutputFormatter with progress bars and colors
- 12 tests passing

Wave 6 Agent 3 - Mermaid Visualization:
- MermaidGenerator for graph-to-diagram conversion
- ClassDiagramBuilder with inheritance and visibility
- DependencyGraphBuilder with circular detection
- GitHub-compatible Mermaid syntax
- 40 tests passing

Total: 507 tests passing (was 467), 4 skipped (Ollama-only)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 08:45:51 +00:00
Profa dc91c7d39c feat(code-intelligence): complete Waves 3-5 implementation
Wave 3 - Incremental Indexing & Embeddings:
- IncrementalIndexer with content hashing and change detection
- FileWatcher with debouncing and pattern matching
- GitChangeDetector for commit-based change tracking
- ASTChunker with semantic boundaries (avg 847 tokens)
- NomicEmbedder with Ollama nomic-embed-text integration

Wave 4 - Knowledge Graph:
- GraphBuilder with SQL-based node/edge storage
- RelationshipExtractor for inheritance, calls, implements
- ImportParser for multi-language import resolution
- TestMapper for test-to-source file correlation

Wave 5 - Hybrid Search & RAG:
- BM25Search with TF-IDF ranking
- VectorSearch with pgvector/in-memory fallback
- HybridSearchEngine with RRF fusion (k=60)
- CodeChunkStore for PostgreSQL persistence
- CodeIntelligenceHybridRouter for embeddings
- ContextBuilder and GraphExpander for RAG
- SemanticRetriever for context-aware retrieval

Infrastructure:
- Separate Jest configs for code-intelligence tests
- Worker isolation to prevent tree-sitter corruption
- Fixed FileWatcher timer issues (real timers)
- 467 tests passing, 4 skipped (Ollama-only)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-22 08:22:26 +00:00
Profa ae528aea7e feat(code-intelligence): implement Wave 1-2 with SQL-based graph architecture
## Wave 1: Database Foundation
- Add SQL schema for code_chunks, code_entities, entity_relationships
- Use RuVector 768-dim embeddings (not pgvector)
- Implement hybrid_code_search function (BM25 + vector)
- Add pg_trgm extension for full-text search
- Create setup scripts for Ollama/nomic-embed-text

## Wave 2: Multi-Language Parser
- Implement TreeSitterParser with 5 language support
- Add language-specific extractors (TS, Python, Go, Rust, JS)
- Implement incremental parsing with tree caching
- Create comprehensive test suite with fixtures

## Architecture Decision
- Defer Apache AGE to v2 (see ADR-002)
- Use SQL tables for graph relationships
- Rationale: Lower complexity, team familiarity, sufficient for v1

Closes #159, Closes #160

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-21 13:49:39 +00:00
Profa 73d4bfbe54 Merge branch 'main' into working-with-agents
Resolves conflicts between v2.5.9 (main) and v2.5.10 (working-with-agents):
- Combined CHANGELOG entries for both versions
- Kept v2.5.10 version numbers
- Merged BaseAgent changes (RuVector cache + QE Pattern Store)
- Accepted v2.5.9 agent migrations (CoverageAnalyzer, QualityGate)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-19 20:45:40 +00:00
Profa 1d5abe9aec chore(release): bump version to v2.5.10
Phase 0.5: RuVector Self-Learning Integration

Features:
- RuVectorPostgresAdapter: PostgreSQL vector database with GNN/LoRA/EWC++
- CLI commands: aqe ruvector status/metrics/learn/migrate/health
- Agent pattern store integration (FlakyTestHunter, SecurityScanner)
- Migration script for memory.db → RuVector patterns
- Validation tests for GOAP targets (7 tests)
- User documentation guide

GOAP Targets:
- Cache hit rate: >50%
- Search latency: <1ms (production)
- Pattern retention: >98% (EWC++ guaranteed)
- LoRA memory: <300MB

Changes:
- BaseAgent: Environment variable support for RuVector config
- aqe init: Shows optional RuVector enhancement info
- Security: crypto.randomUUID() instead of Math.random()
- Docker: Docker-in-Docker instead of host socket

Zero breaking changes - RuVector is opt-in (disabled by default)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-19 20:19:47 +00:00
Profa be071d7afa merge 2025-12-19 12:34:17 +00:00
Profa a25a1c2679 feat(agents): migrate CoverageAnalyzerAgent and QualityGateAgent to BaseAgent for RuVector integration
Phase 0.5: Universal RuVector Integration (v2.5.9)

## Agent Architecture Migration

- **CoverageAnalyzerAgent**: Migrated from EventEmitter to extend BaseAgent
  - Full RuVector integration with HybridRouter support
  - Implements abstract methods: initializeComponents(), performTask(), loadKnowledge(), cleanup()
  - New getCoverageStatus() method for agent-specific status
  - Configuration via CoverageAnalyzerConfig extending BaseAgentConfig

- **QualityGateAgent**: Migrated from EventEmitter to extend BaseAgent
  - Full RuVector integration with HybridRouter support
  - Implements abstract methods: initializeComponents(), performTask(), loadKnowledge(), cleanup()
  - New getQualityGateStatus() method for agent-specific status
  - Configuration via QualityGateConfig extending BaseAgentConfig

## RuVector Methods Now Available on All Agents

All QE agents now inherit these methods from BaseAgent:
- hasRuVectorCache() - Check if RuVector GNN cache is enabled
- getRuVectorMetrics() - Get GNN/LoRA/cache performance metrics
- getCacheHitRate() - Get cache hit rate (0-1)
- getRoutingStats() - Get routing decisions and latency statistics
- forceRuVectorLearn() - Trigger LoRA learning consolidation
- getCostSavingsReport() - Get cost savings from caching
- getLLMStats() - Get LLM provider status including RuVector

## Other Changes

- Updated QEAgentFactory to use new single-config constructor pattern
- Added 6 RuVector MCP tools for external integration
- Updated verification script - All 6 tests pass
- Added BaseAgent.RuVector.test.ts unit tests
- Added ruvector-agent-usage.ts example

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-18 14:58:07 +00:00
Dragan Spiridonov 0999e5d2b7 Merge branch 'main' into working-with-agents 2025-12-18 12:11:28 +01:00
Profa 0f40bda3ef chore(release): bump version to v2.5.8
## Phase 0: LLM Independence Foundation

### M0.3: HNSW Pattern Store Integration
- HNSWPatternAdapter - Bridge between LearningEngine and HNSWPatternStore
- LearningEngine HNSW Integration - searchSimilarPatterns(), getHNSWStats()
- O(log n) similarity search for pattern matching

### M0.5: Federated Learning
- FederatedManager - Cross-agent pattern sharing with consensus
- Pattern synchronization across distributed agents

### M0.6: Pattern Curation
- PatternCurator - Manual curation workflow with approval/rejection
- RuvllmPatternCurator - RuvLLM integration for pattern quality assessment

### RuvllmProvider Enhancements
- Session Management (50% latency reduction)
- Batch API (4x throughput improvement)
- TRM/SONA integration for advanced reasoning
- LLMBaselineTracker for performance monitoring
- Error tracking in session metrics

### Documentation
- Complete agent learning system architecture documentation
- HNSW pattern store usage examples
- Phase 0 implementation guides

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-18 11:06:56 +00:00
Dragan Spiridonov 0f3fd5f9db Delete docs/qx-reports/testingexperience-qx-analysis.html 2025-12-17 13:34:07 +01:00
Dragan Spiridonov 57ad30bd8e Delete docs/qx-reports/qx-report-https---www-carnelian-tech--2025-12-03T16-15-25.html 2025-12-17 13:33:29 +01:00
Profa 60eb9609a1 chore(release): bump version to v2.5.7
## Changes
- Add 15 n8n workflow testing agents (contributed by @fndlalit)
- Add 5 n8n testing skills to QE skill patterns
- Update aqe init to copy n8n agent directory
- Update documentation with n8n agent reference
- Bump version in all required files

## Files Updated
- package.json, package-lock.json (version 2.5.7)
- README.md (version badge, n8n agents line, 46 skills)
- CHANGELOG.md (v2.5.7 section)
- CLAUDE.md (agent/skill counts)
- docs/reference/agents.md (n8n section)
- docs/reference/skills.md (n8n skills)
- src/cli/init/agents.ts (n8n directory copying)
- src/cli/init/skills.ts (n8n skill patterns)
- src/mcp/server-instructions.ts (SERVER_VERSION)
- src/core/memory/HNSWVectorMemory.ts (version)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 11:51:56 +00:00
Lalit 078237e9ed chore: restore docs/reports from upstream main
Restores 225 report files that were previously removed in cleanup.
These reports are present in upstream main and should be preserved.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 10:27:10 +00:00
Lalitkumar Bhamare c4e2477621 Merge branch 'main' into qcsd-agents-lalit 2025-12-16 19:27:02 +01:00
Lalit 4c902f0c3d feat(n8n): add production-ready n8n workflow testing agents
This PR adds a comprehensive suite of 10+ n8n workflow testing agents:

Core Agents:
- N8nWorkflowExecutorAgent: Execute workflows with data validation
- N8nPerformanceTesterAgent: Load/stress testing with metrics
- N8nChaosTesterAgent: Fault injection with N8nTestHarness
- N8nBDDScenarioTesterAgent: Cucumber-style BDD testing
- N8nSecurityAuditorAgent: 40+ secret patterns, runtime leak detection
- N8nExpressionValidatorAgent: Safe expression validation (no eval)
- N8nIntegrationTestAgent: Real API connectivity testing
- N8nTriggerTestAgent: Webhook testing with correct URL patterns
- N8nComplianceValidatorAgent: GDPR/HIPAA/SOC2/PCI-DSS checks
- N8nMonitoringValidatorAgent: SLA compliance and metrics

Key Features:
- Runtime execution is DEFAULT (not opt-in)
- Real workflow execution, not just static analysis
- Proper n8n webhook URL patterns (/webhook/<path>, /webhook-test/<workflowId>/<path>)
- Safe expression evaluation using pattern matching (no unsafe eval)
- Dual authentication support (API key + session fallback)
- Graceful fallback with warnings if execution fails

⚠️ IMPORTANT: These agents need to be tested against a real n8n instance
before marking them as final. See docs/guides/n8n-real-instance-setup.md
for setup instructions.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 18:15:53 +00:00
Lalit 22d693069b Merge remote-tracking branch 'upstream/main' into qcsd-agents-lalit 2025-12-16 12:14:30 +00:00
Profa bc6cac266b docs: add QE fleet analysis reports for code quality and tests
Generated comprehensive analysis using QE fleet with 4 specialized agents:
- complexity-analyzer: 1,529 issues found (429 high, 1,100 medium)
- security-analyzer: 7.8/10 score, 0 npm vulnerabilities
- quality-analyzer: Code smell inventory (1,674 any types, 33 large files)
- test-analyzer: 72/100 test quality score, 335 Math.random() instances

Reports added:
- complexity-analysis-report.md: Full complexity analysis
- complexity-analysis-data.json: Structured data for tooling
- complexity-summary.txt: ASCII summary
- security-analysis-report.md: OWASP Top 10 compliance
- TEST_QUALITY_ANALYSIS_REPORT.md: Test smells and improvements

Related: Issue #149

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 12:06:33 +00:00
Profa 0a6c799d3c chore(release): bump version to v2.5.5
Closes #144 - RuvLLM/SONA Integration (all 4 phases)
Closes #39 - MCP handler test fixes

## Added
- SONALifecycleManager (717 lines, 72 tests)
  - Automatic lifecycle hooks: onAgentSpawn, onTaskComplete, cleanupAgent
  - Real-time experience capture from agent task completions
  - Integration with AgentRegistry for fleet-wide coordination

- InferenceCostTracker (679 lines, 30 tests)
  - Track local vs cloud inference costs in real-time
  - Support for multiple providers: ruvllm, anthropic, openrouter, openai, onnx
  - Cost savings analysis with multi-format reporting

- AdaptiveModelRouter local routing
  - Local model preference for routine tasks via RuvLLM
  - Fallback cascade: ruvllm → openrouter → anthropic

## Fixed
- Video Vision Analyzer multimodal analysis pipeline
- MCP Handler Tests (36 files stabilized)

## Testing
- 102 new tests (56 + 30 + 16)
- All new code tests passing
- Regression suite verified

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-15 20:57:15 +00:00
Lalit e9a8a7bf64 feat(n8n): add Phase 1 n8n testing agents and skills
Add 5 core n8n testing agents:
- n8n-base-agent: Abstract base with shared utilities (API client, memory, events)
- n8n-workflow-executor: Execute workflows, validate outputs, test error handling
- n8n-node-validator: Validate node configs, connections, data mappings
- n8n-trigger-test: Test webhooks, schedules, polling triggers
- n8n-expression-validator: Validate expressions, detect security issues
- n8n-integration-test: Test integrations (Slack, Sheets, Jira, etc.)

Add 5 essential skills:
- n8n-workflow-testing-fundamentals: Workflow structure, execution lifecycle
- n8n-expression-testing: Expression syntax, context variables, security
- n8n-integration-testing-patterns: API testing, auth flows, rate limits
- n8n-trigger-testing-strategies: Webhook, cron, polling testing
- n8n-security-testing: Credential exposure, encryption, data leakage

Include comprehensive test suite for workflow executor agent (15 tests passing).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-15 12:00:13 +00:00
Lalit 639a00ad62 chore: cleanup obsolete reports and enhance qe-a11y-ally agent
- Remove 200+ obsolete docs/reports files (old release/validation reports)
- Remove test accessibility frame images (no longer needed)
- Enhance qe-a11y-ally.md with expanded documentation (+617 lines)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 18:29:45 +00:00
Lalit ebac241ae7 chore: remove all brand-specific (Audi) references from codebase
- Remove Audi Q3/Sportback references from test files
- Update scan-comprehensive.ts with generic examples
- Update video-vision-analyzer.ts with generic vehicle example
- Delete docs/accessibility/ folder with brand-specific content
- Update enhancement plan with generic test references

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 13:19:18 +00:00
Lalit 96f2f93f82 feat(a11y-ally): enhance agent with developer-focused capabilities
- Update agent description to emphasize copy-paste ready fixes
- Document video frame analysis workflow using Claude Code native vision
- Add comprehensive WebVTT caption generation for WCAG 1.2.x compliance
- Include audio descriptions for blind/visually impaired users
- Add Audi Q3 Sportback video accessibility test artifacts:
  - 10 extracted frames from walkaround video
  - English and German WebVTT captions
  - Detailed audio descriptions
  - WCAG compliance audit report

Key developer benefits:
- Every violation includes ready-to-use code fixes
- Video accessibility content generated automatically
- Context-aware ARIA labels (not generic suggestions)
- Zero-cost video analysis via Claude vision or Ollama

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-14 12:53:47 +00:00
Profa e4fa6e0fc4 docs: add AccessibilityAllyAgent to v2.5.0 + update agent counts (19→20)
## Changes

### AccessibilityAllyAgent Documentation (PR #129)
- Added to CHANGELOG.md with full feature list
- Added to docs/reference/agents.md
- Added to .agentic-qe/docs/agents.md
- Added to README.md agent tables

### Agent Count Updates (19 → 20)
Updated all references to reflect new AccessibilityAllyAgent:
- CLAUDE.md (20 QE Agents, 20 main + 11 subagents)
- README.md (20 Specialized Agents, 31 total)
- docs/reference/agents.md
- .agentic-qe/docs/agents.md, skills.md, usage.md
- src/cli/init/agents.ts, claude-config.ts, database-init.ts
- src/learning/baselines/*.ts
- src/telemetry/instrumentation/*.ts

Contributed by: @fndlalit (PR #129)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-13 18:14:53 +00:00