agentic-qe 3.3.0 → 3.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -2
- package/package.json +6 -1
- package/v3/CHANGELOG.md +88 -0
- package/v3/dist/cli/bundle.js +18794 -15534
- package/v3/dist/cli/command-registry.d.ts +55 -0
- package/v3/dist/cli/command-registry.d.ts.map +1 -0
- package/v3/dist/cli/command-registry.js +103 -0
- package/v3/dist/cli/command-registry.js.map +1 -0
- package/v3/dist/cli/commands/code.d.ts +9 -0
- package/v3/dist/cli/commands/code.d.ts.map +1 -0
- package/v3/dist/cli/commands/code.js +254 -0
- package/v3/dist/cli/commands/code.js.map +1 -0
- package/v3/dist/cli/commands/completions.d.ts +8 -0
- package/v3/dist/cli/commands/completions.d.ts.map +1 -0
- package/v3/dist/cli/commands/completions.js +99 -0
- package/v3/dist/cli/commands/completions.js.map +1 -0
- package/v3/dist/cli/commands/coverage.d.ts +9 -0
- package/v3/dist/cli/commands/coverage.d.ts.map +1 -0
- package/v3/dist/cli/commands/coverage.js +208 -0
- package/v3/dist/cli/commands/coverage.js.map +1 -0
- package/v3/dist/cli/commands/fleet.d.ts +11 -0
- package/v3/dist/cli/commands/fleet.d.ts.map +1 -0
- package/v3/dist/cli/commands/fleet.js +338 -0
- package/v3/dist/cli/commands/fleet.js.map +1 -0
- package/v3/dist/cli/commands/migrate.d.ts +9 -0
- package/v3/dist/cli/commands/migrate.d.ts.map +1 -0
- package/v3/dist/cli/commands/migrate.js +566 -0
- package/v3/dist/cli/commands/migrate.js.map +1 -0
- package/v3/dist/cli/commands/quality.d.ts +9 -0
- package/v3/dist/cli/commands/quality.d.ts.map +1 -0
- package/v3/dist/cli/commands/quality.js +40 -0
- package/v3/dist/cli/commands/quality.js.map +1 -0
- package/v3/dist/cli/commands/security.d.ts +9 -0
- package/v3/dist/cli/commands/security.d.ts.map +1 -0
- package/v3/dist/cli/commands/security.js +124 -0
- package/v3/dist/cli/commands/security.js.map +1 -0
- package/v3/dist/cli/commands/sync.d.ts +19 -0
- package/v3/dist/cli/commands/sync.d.ts.map +1 -0
- package/v3/dist/cli/commands/sync.js +283 -0
- package/v3/dist/cli/commands/sync.js.map +1 -0
- package/v3/dist/cli/commands/test.d.ts +9 -0
- package/v3/dist/cli/commands/test.d.ts.map +1 -0
- package/v3/dist/cli/commands/test.js +166 -0
- package/v3/dist/cli/commands/test.js.map +1 -0
- package/v3/dist/cli/handlers/agent-handler.d.ts +20 -0
- package/v3/dist/cli/handlers/agent-handler.d.ts.map +1 -0
- package/v3/dist/cli/handlers/agent-handler.js +158 -0
- package/v3/dist/cli/handlers/agent-handler.js.map +1 -0
- package/v3/dist/cli/handlers/domain-handler.d.ts +20 -0
- package/v3/dist/cli/handlers/domain-handler.d.ts.map +1 -0
- package/v3/dist/cli/handlers/domain-handler.js +115 -0
- package/v3/dist/cli/handlers/domain-handler.js.map +1 -0
- package/v3/dist/cli/handlers/index.d.ts +13 -0
- package/v3/dist/cli/handlers/index.d.ts.map +1 -0
- package/v3/dist/cli/handlers/index.js +15 -0
- package/v3/dist/cli/handlers/index.js.map +1 -0
- package/v3/dist/cli/handlers/init-handler.d.ts +38 -0
- package/v3/dist/cli/handlers/init-handler.d.ts.map +1 -0
- package/v3/dist/cli/handlers/init-handler.js +288 -0
- package/v3/dist/cli/handlers/init-handler.js.map +1 -0
- package/v3/dist/cli/handlers/interfaces.d.ts +104 -0
- package/v3/dist/cli/handlers/interfaces.d.ts.map +1 -0
- package/v3/dist/cli/handlers/interfaces.js +109 -0
- package/v3/dist/cli/handlers/interfaces.js.map +1 -0
- package/v3/dist/cli/handlers/protocol-handler.d.ts +19 -0
- package/v3/dist/cli/handlers/protocol-handler.d.ts.map +1 -0
- package/v3/dist/cli/handlers/protocol-handler.js +79 -0
- package/v3/dist/cli/handlers/protocol-handler.js.map +1 -0
- package/v3/dist/cli/handlers/status-handler.d.ts +30 -0
- package/v3/dist/cli/handlers/status-handler.d.ts.map +1 -0
- package/v3/dist/cli/handlers/status-handler.js +218 -0
- package/v3/dist/cli/handlers/status-handler.js.map +1 -0
- package/v3/dist/cli/handlers/task-handler.d.ts +22 -0
- package/v3/dist/cli/handlers/task-handler.d.ts.map +1 -0
- package/v3/dist/cli/handlers/task-handler.js +271 -0
- package/v3/dist/cli/handlers/task-handler.js.map +1 -0
- package/v3/dist/cli/index.d.ts +4 -0
- package/v3/dist/cli/index.d.ts.map +1 -1
- package/v3/dist/cli/index.js +48 -2677
- package/v3/dist/cli/index.js.map +1 -1
- package/v3/dist/cli/wizards/core/index.d.ts +11 -0
- package/v3/dist/cli/wizards/core/index.d.ts.map +1 -0
- package/v3/dist/cli/wizards/core/index.js +15 -0
- package/v3/dist/cli/wizards/core/index.js.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-base.d.ts +87 -0
- package/v3/dist/cli/wizards/core/wizard-base.d.ts.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-base.js +120 -0
- package/v3/dist/cli/wizards/core/wizard-base.js.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-command.d.ts +182 -0
- package/v3/dist/cli/wizards/core/wizard-command.d.ts.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-command.js +45 -0
- package/v3/dist/cli/wizards/core/wizard-command.js.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-step.d.ts +109 -0
- package/v3/dist/cli/wizards/core/wizard-step.d.ts.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-step.js +384 -0
- package/v3/dist/cli/wizards/core/wizard-step.js.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-utils.d.ts +117 -0
- package/v3/dist/cli/wizards/core/wizard-utils.d.ts.map +1 -0
- package/v3/dist/cli/wizards/core/wizard-utils.js +291 -0
- package/v3/dist/cli/wizards/core/wizard-utils.js.map +1 -0
- package/v3/dist/cli/wizards/coverage-wizard.d.ts +13 -68
- package/v3/dist/cli/wizards/coverage-wizard.d.ts.map +1 -1
- package/v3/dist/cli/wizards/coverage-wizard.js +127 -391
- package/v3/dist/cli/wizards/coverage-wizard.js.map +1 -1
- package/v3/dist/cli/wizards/fleet-wizard.d.ts +13 -64
- package/v3/dist/cli/wizards/fleet-wizard.d.ts.map +1 -1
- package/v3/dist/cli/wizards/fleet-wizard.js +150 -363
- package/v3/dist/cli/wizards/fleet-wizard.js.map +1 -1
- package/v3/dist/cli/wizards/index.d.ts +2 -0
- package/v3/dist/cli/wizards/index.d.ts.map +1 -1
- package/v3/dist/cli/wizards/index.js +3 -0
- package/v3/dist/cli/wizards/index.js.map +1 -1
- package/v3/dist/cli/wizards/security-wizard.d.ts +13 -64
- package/v3/dist/cli/wizards/security-wizard.d.ts.map +1 -1
- package/v3/dist/cli/wizards/security-wizard.js +152 -395
- package/v3/dist/cli/wizards/security-wizard.js.map +1 -1
- package/v3/dist/cli/wizards/test-wizard.d.ts +13 -77
- package/v3/dist/cli/wizards/test-wizard.d.ts.map +1 -1
- package/v3/dist/cli/wizards/test-wizard.js +196 -328
- package/v3/dist/cli/wizards/test-wizard.js.map +1 -1
- package/v3/dist/coordination/mincut/mincut-health-monitor.d.ts +3 -0
- package/v3/dist/coordination/mincut/mincut-health-monitor.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/mincut-health-monitor.js +6 -2
- package/v3/dist/coordination/mincut/mincut-health-monitor.js.map +1 -1
- package/v3/dist/coordination/mincut/queen-integration.d.ts +3 -0
- package/v3/dist/coordination/mincut/queen-integration.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/queen-integration.js +6 -1
- package/v3/dist/coordination/mincut/queen-integration.js.map +1 -1
- package/v3/dist/coordination/task-executor.js +2 -2
- package/v3/dist/coordination/task-executor.js.map +1 -1
- package/v3/dist/domains/chaos-resilience/plugin.js +2 -2
- package/v3/dist/domains/chaos-resilience/plugin.js.map +1 -1
- package/v3/dist/domains/code-intelligence/plugin.js +2 -2
- package/v3/dist/domains/code-intelligence/plugin.js.map +1 -1
- package/v3/dist/domains/contract-testing/plugin.js +2 -2
- package/v3/dist/domains/contract-testing/plugin.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/plugin.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/plugin.js +2 -1
- package/v3/dist/domains/coverage-analysis/plugin.js.map +1 -1
- package/v3/dist/domains/defect-intelligence/plugin.js +2 -2
- package/v3/dist/domains/defect-intelligence/plugin.js.map +1 -1
- package/v3/dist/domains/domain-interface.d.ts.map +1 -1
- package/v3/dist/domains/domain-interface.js +3 -1
- package/v3/dist/domains/domain-interface.js.map +1 -1
- package/v3/dist/domains/learning-optimization/plugin.js +2 -2
- package/v3/dist/domains/learning-optimization/plugin.js.map +1 -1
- package/v3/dist/domains/quality-assessment/plugin.js +2 -2
- package/v3/dist/domains/quality-assessment/plugin.js.map +1 -1
- package/v3/dist/domains/requirements-validation/plugin.js +2 -2
- package/v3/dist/domains/requirements-validation/plugin.js.map +1 -1
- package/v3/dist/domains/security-compliance/plugin.js +2 -2
- package/v3/dist/domains/security-compliance/plugin.js.map +1 -1
- package/v3/dist/domains/test-execution/index.d.ts +2 -1
- package/v3/dist/domains/test-execution/index.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/index.js +0 -2
- package/v3/dist/domains/test-execution/index.js.map +1 -1
- package/v3/dist/domains/test-execution/interfaces.d.ts +222 -25
- package/v3/dist/domains/test-execution/interfaces.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/interfaces.js +130 -3
- package/v3/dist/domains/test-execution/interfaces.js.map +1 -1
- package/v3/dist/domains/test-execution/plugin.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/plugin.js +2 -1
- package/v3/dist/domains/test-execution/plugin.js.map +1 -1
- package/v3/dist/domains/test-execution/test-prioritization-types.d.ts +5 -172
- package/v3/dist/domains/test-execution/test-prioritization-types.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/test-prioritization-types.js +6 -129
- package/v3/dist/domains/test-execution/test-prioritization-types.js.map +1 -1
- package/v3/dist/domains/test-execution/types/index.d.ts +7 -3
- package/v3/dist/domains/test-execution/types/index.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/types/index.js +7 -17
- package/v3/dist/domains/test-execution/types/index.js.map +1 -1
- package/v3/dist/domains/test-generation/coordinator.d.ts +1 -1
- package/v3/dist/domains/test-generation/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/coordinator.js +3 -3
- package/v3/dist/domains/test-generation/coordinator.js.map +1 -1
- package/v3/dist/domains/test-generation/factories/index.d.ts +8 -0
- package/v3/dist/domains/test-generation/factories/index.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/factories/index.js +8 -0
- package/v3/dist/domains/test-generation/factories/index.js.map +1 -0
- package/v3/dist/domains/test-generation/factories/test-generator-factory.d.ts +108 -0
- package/v3/dist/domains/test-generation/factories/test-generator-factory.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/factories/test-generator-factory.js +158 -0
- package/v3/dist/domains/test-generation/factories/test-generator-factory.js.map +1 -0
- package/v3/dist/domains/test-generation/generators/base-test-generator.d.ts +79 -0
- package/v3/dist/domains/test-generation/generators/base-test-generator.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/generators/base-test-generator.js +252 -0
- package/v3/dist/domains/test-generation/generators/base-test-generator.js.map +1 -0
- package/v3/dist/domains/test-generation/generators/index.d.ts +11 -0
- package/v3/dist/domains/test-generation/generators/index.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/generators/index.js +13 -0
- package/v3/dist/domains/test-generation/generators/index.js.map +1 -0
- package/v3/dist/domains/test-generation/generators/jest-vitest-generator.d.ts +77 -0
- package/v3/dist/domains/test-generation/generators/jest-vitest-generator.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/generators/jest-vitest-generator.js +365 -0
- package/v3/dist/domains/test-generation/generators/jest-vitest-generator.js.map +1 -0
- package/v3/dist/domains/test-generation/generators/mocha-generator.d.ts +56 -0
- package/v3/dist/domains/test-generation/generators/mocha-generator.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/generators/mocha-generator.js +197 -0
- package/v3/dist/domains/test-generation/generators/mocha-generator.js.map +1 -0
- package/v3/dist/domains/test-generation/generators/pytest-generator.d.ts +66 -0
- package/v3/dist/domains/test-generation/generators/pytest-generator.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/generators/pytest-generator.js +240 -0
- package/v3/dist/domains/test-generation/generators/pytest-generator.js.map +1 -0
- package/v3/dist/domains/test-generation/index.d.ts +2 -2
- package/v3/dist/domains/test-generation/index.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/index.js +3 -3
- package/v3/dist/domains/test-generation/index.js.map +1 -1
- package/v3/dist/domains/test-generation/interfaces/index.d.ts +9 -0
- package/v3/dist/domains/test-generation/interfaces/index.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/interfaces/index.js +9 -0
- package/v3/dist/domains/test-generation/interfaces/index.js.map +1 -0
- package/v3/dist/domains/test-generation/interfaces/test-generator.interface.d.ts +166 -0
- package/v3/dist/domains/test-generation/interfaces/test-generator.interface.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/interfaces/test-generator.interface.js +8 -0
- package/v3/dist/domains/test-generation/interfaces/test-generator.interface.js.map +1 -0
- package/v3/dist/domains/test-generation/interfaces.d.ts +163 -24
- package/v3/dist/domains/test-generation/interfaces.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/interfaces.js +2 -2
- package/v3/dist/domains/test-generation/plugin.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/plugin.js +6 -5
- package/v3/dist/domains/test-generation/plugin.js.map +1 -1
- package/v3/dist/domains/test-generation/{coherence-gate.d.ts → services/coherence-gate-service.d.ts} +4 -4
- package/v3/dist/domains/test-generation/services/coherence-gate-service.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/{coherence-gate.js → services/coherence-gate-service.js} +2 -2
- package/v3/dist/domains/test-generation/services/coherence-gate-service.js.map +1 -0
- package/v3/dist/domains/test-generation/services/index.d.ts +8 -2
- package/v3/dist/domains/test-generation/services/index.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/services/index.js +10 -3
- package/v3/dist/domains/test-generation/services/index.js.map +1 -1
- package/v3/dist/domains/test-generation/services/property-test-generator.d.ts +34 -0
- package/v3/dist/domains/test-generation/services/property-test-generator.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/services/property-test-generator.js +306 -0
- package/v3/dist/domains/test-generation/services/property-test-generator.js.map +1 -0
- package/v3/dist/domains/test-generation/services/tdd-generator.d.ts +33 -0
- package/v3/dist/domains/test-generation/services/tdd-generator.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/services/tdd-generator.js +342 -0
- package/v3/dist/domains/test-generation/services/tdd-generator.js.map +1 -0
- package/v3/dist/domains/test-generation/services/test-data-generator.d.ts +34 -0
- package/v3/dist/domains/test-generation/services/test-data-generator.d.ts.map +1 -0
- package/v3/dist/domains/test-generation/services/test-data-generator.js +245 -0
- package/v3/dist/domains/test-generation/services/test-data-generator.js.map +1 -0
- package/v3/dist/domains/test-generation/services/test-generator.d.ts +51 -160
- package/v3/dist/domains/test-generation/services/test-generator.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/services/test-generator.js +101 -1858
- package/v3/dist/domains/test-generation/services/test-generator.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/plugin.js +2 -2
- package/v3/dist/domains/visual-accessibility/plugin.js.map +1 -1
- package/v3/dist/init/phases/12-verification.d.ts +23 -0
- package/v3/dist/init/phases/12-verification.d.ts.map +1 -1
- package/v3/dist/init/phases/12-verification.js +185 -2
- package/v3/dist/init/phases/12-verification.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/model-router/complexity-analyzer.d.ts +24 -62
- package/v3/dist/integrations/agentic-flow/model-router/complexity-analyzer.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/model-router/complexity-analyzer.js +45 -497
- package/v3/dist/integrations/agentic-flow/model-router/complexity-analyzer.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/model-router/router.js +2 -2
- package/v3/dist/integrations/agentic-flow/model-router/router.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/model-router/score-calculator.d.ts +98 -0
- package/v3/dist/integrations/agentic-flow/model-router/score-calculator.d.ts.map +1 -0
- package/v3/dist/integrations/agentic-flow/model-router/score-calculator.js +197 -0
- package/v3/dist/integrations/agentic-flow/model-router/score-calculator.js.map +1 -0
- package/v3/dist/integrations/agentic-flow/model-router/signal-collector.d.ts +102 -0
- package/v3/dist/integrations/agentic-flow/model-router/signal-collector.d.ts.map +1 -0
- package/v3/dist/integrations/agentic-flow/model-router/signal-collector.js +372 -0
- package/v3/dist/integrations/agentic-flow/model-router/signal-collector.js.map +1 -0
- package/v3/dist/integrations/agentic-flow/model-router/tier-recommender.d.ts +64 -0
- package/v3/dist/integrations/agentic-flow/model-router/tier-recommender.d.ts.map +1 -0
- package/v3/dist/integrations/agentic-flow/model-router/tier-recommender.js +120 -0
- package/v3/dist/integrations/agentic-flow/model-router/tier-recommender.js.map +1 -0
- package/v3/dist/integrations/coherence/coherence-service.d.ts.map +1 -1
- package/v3/dist/integrations/coherence/coherence-service.js +87 -30
- package/v3/dist/integrations/coherence/coherence-service.js.map +1 -1
- package/v3/dist/integrations/coherence/engines/spectral-adapter.d.ts.map +1 -1
- package/v3/dist/integrations/coherence/engines/spectral-adapter.js +124 -35
- package/v3/dist/integrations/coherence/engines/spectral-adapter.js.map +1 -1
- package/v3/dist/learning/memory-auditor.d.ts.map +1 -1
- package/v3/dist/learning/memory-auditor.js +3 -1
- package/v3/dist/learning/memory-auditor.js.map +1 -1
- package/v3/dist/mcp/bundle.js +2475 -1463
- package/v3/dist/mcp/security/cve-prevention.d.ts +31 -134
- package/v3/dist/mcp/security/cve-prevention.d.ts.map +1 -1
- package/v3/dist/mcp/security/cve-prevention.js +37 -562
- package/v3/dist/mcp/security/cve-prevention.js.map +1 -1
- package/v3/dist/mcp/security/index.d.ts +5 -1
- package/v3/dist/mcp/security/index.d.ts.map +1 -1
- package/v3/dist/mcp/security/validators/command-validator.d.ts +41 -0
- package/v3/dist/mcp/security/validators/command-validator.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/command-validator.js +123 -0
- package/v3/dist/mcp/security/validators/command-validator.js.map +1 -0
- package/v3/dist/mcp/security/validators/crypto-validator.d.ts +40 -0
- package/v3/dist/mcp/security/validators/crypto-validator.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/crypto-validator.js +72 -0
- package/v3/dist/mcp/security/validators/crypto-validator.js.map +1 -0
- package/v3/dist/mcp/security/validators/index.d.ts +12 -0
- package/v3/dist/mcp/security/validators/index.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/index.js +22 -0
- package/v3/dist/mcp/security/validators/index.js.map +1 -0
- package/v3/dist/mcp/security/validators/input-sanitizer.d.ts +56 -0
- package/v3/dist/mcp/security/validators/input-sanitizer.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/input-sanitizer.js +157 -0
- package/v3/dist/mcp/security/validators/input-sanitizer.js.map +1 -0
- package/v3/dist/mcp/security/validators/interfaces.d.ts +164 -0
- package/v3/dist/mcp/security/validators/interfaces.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/interfaces.js +6 -0
- package/v3/dist/mcp/security/validators/interfaces.js.map +1 -0
- package/v3/dist/mcp/security/validators/path-traversal-validator.d.ts +50 -0
- package/v3/dist/mcp/security/validators/path-traversal-validator.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/path-traversal-validator.js +242 -0
- package/v3/dist/mcp/security/validators/path-traversal-validator.js.map +1 -0
- package/v3/dist/mcp/security/validators/regex-safety-validator.d.ts +50 -0
- package/v3/dist/mcp/security/validators/regex-safety-validator.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/regex-safety-validator.js +183 -0
- package/v3/dist/mcp/security/validators/regex-safety-validator.js.map +1 -0
- package/v3/dist/mcp/security/validators/validation-orchestrator.d.ts +66 -0
- package/v3/dist/mcp/security/validators/validation-orchestrator.d.ts.map +1 -0
- package/v3/dist/mcp/security/validators/validation-orchestrator.js +146 -0
- package/v3/dist/mcp/security/validators/validation-orchestrator.js.map +1 -0
- package/v3/dist/mcp/server.d.ts.map +1 -1
- package/v3/dist/mcp/server.js +1 -0
- package/v3/dist/mcp/server.js.map +1 -1
- package/v3/dist/mcp/tool-registry.d.ts +3 -1
- package/v3/dist/mcp/tool-registry.d.ts.map +1 -1
- package/v3/dist/mcp/tool-registry.js +155 -2
- package/v3/dist/mcp/tool-registry.js.map +1 -1
- package/v3/dist/mcp/tools/test-generation/generate.d.ts +1 -0
- package/v3/dist/mcp/tools/test-generation/generate.d.ts.map +1 -1
- package/v3/dist/mcp/tools/test-generation/generate.js +3 -2
- package/v3/dist/mcp/tools/test-generation/generate.js.map +1 -1
- package/v3/dist/sync/cloud/index.d.ts +8 -0
- package/v3/dist/sync/cloud/index.d.ts.map +1 -0
- package/v3/dist/sync/cloud/index.js +8 -0
- package/v3/dist/sync/cloud/index.js.map +1 -0
- package/v3/dist/sync/cloud/postgres-writer.d.ts +88 -0
- package/v3/dist/sync/cloud/postgres-writer.d.ts.map +1 -0
- package/v3/dist/sync/cloud/postgres-writer.js +319 -0
- package/v3/dist/sync/cloud/postgres-writer.js.map +1 -0
- package/v3/dist/sync/cloud/tunnel-manager.d.ts +75 -0
- package/v3/dist/sync/cloud/tunnel-manager.d.ts.map +1 -0
- package/v3/dist/sync/cloud/tunnel-manager.js +221 -0
- package/v3/dist/sync/cloud/tunnel-manager.js.map +1 -0
- package/v3/dist/sync/index.d.ts +35 -0
- package/v3/dist/sync/index.d.ts.map +1 -0
- package/v3/dist/sync/index.js +35 -0
- package/v3/dist/sync/index.js.map +1 -0
- package/v3/dist/sync/interfaces.d.ts +245 -0
- package/v3/dist/sync/interfaces.d.ts.map +1 -0
- package/v3/dist/sync/interfaces.js +160 -0
- package/v3/dist/sync/interfaces.js.map +1 -0
- package/v3/dist/sync/readers/index.d.ts +8 -0
- package/v3/dist/sync/readers/index.d.ts.map +1 -0
- package/v3/dist/sync/readers/index.js +8 -0
- package/v3/dist/sync/readers/index.js.map +1 -0
- package/v3/dist/sync/readers/json-reader.d.ts +95 -0
- package/v3/dist/sync/readers/json-reader.d.ts.map +1 -0
- package/v3/dist/sync/readers/json-reader.js +306 -0
- package/v3/dist/sync/readers/json-reader.js.map +1 -0
- package/v3/dist/sync/readers/sqlite-reader.d.ts +88 -0
- package/v3/dist/sync/readers/sqlite-reader.d.ts.map +1 -0
- package/v3/dist/sync/readers/sqlite-reader.js +255 -0
- package/v3/dist/sync/readers/sqlite-reader.js.map +1 -0
- package/v3/dist/sync/sync-agent.d.ts +116 -0
- package/v3/dist/sync/sync-agent.d.ts.map +1 -0
- package/v3/dist/sync/sync-agent.js +416 -0
- package/v3/dist/sync/sync-agent.js.map +1 -0
- package/v3/package.json +13 -2
- package/v3/dist/domains/test-generation/coherence-gate.d.ts.map +0 -1
- package/v3/dist/domains/test-generation/coherence-gate.js.map +0 -1
|
@@ -0,0 +1,288 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - Init Command Handler
|
|
3
|
+
*
|
|
4
|
+
* Handles the 'aqe init' command for system initialization.
|
|
5
|
+
*/
|
|
6
|
+
import chalk from 'chalk';
|
|
7
|
+
import { QEKernelImpl } from '../../kernel/kernel.js';
|
|
8
|
+
import { ALL_DOMAINS } from '../../shared/types/index.js';
|
|
9
|
+
import { CrossDomainEventRouter } from '../../coordination/cross-domain-router.js';
|
|
10
|
+
import { DefaultProtocolExecutor } from '../../coordination/protocol-executor.js';
|
|
11
|
+
import { WorkflowOrchestrator } from '../../coordination/workflow-orchestrator.js';
|
|
12
|
+
import { createQueenCoordinator } from '../../coordination/queen-coordinator.js';
|
|
13
|
+
import { InitOrchestrator } from '../../init/init-wizard.js';
|
|
14
|
+
import { createModularInitOrchestrator, } from '../../init/orchestrator.js';
|
|
15
|
+
import { setupClaudeFlowIntegration } from '../commands/claude-flow-setup.js';
|
|
16
|
+
// ============================================================================
|
|
17
|
+
// Init Handler
|
|
18
|
+
// ============================================================================
|
|
19
|
+
export class InitHandler {
|
|
20
|
+
name = 'init';
|
|
21
|
+
description = 'Initialize the AQE v3 system';
|
|
22
|
+
cleanupAndExit;
|
|
23
|
+
constructor(cleanupAndExit) {
|
|
24
|
+
this.cleanupAndExit = cleanupAndExit;
|
|
25
|
+
}
|
|
26
|
+
register(program, context) {
|
|
27
|
+
program
|
|
28
|
+
.command('init')
|
|
29
|
+
.description(this.description)
|
|
30
|
+
.option('-d, --domains <domains>', 'Comma-separated list of domains to enable', 'all')
|
|
31
|
+
.option('-m, --max-agents <number>', 'Maximum concurrent agents', '15')
|
|
32
|
+
.option('--memory <backend>', 'Memory backend (sqlite|agentdb|hybrid)', 'hybrid')
|
|
33
|
+
.option('--lazy', 'Enable lazy loading of domains')
|
|
34
|
+
.option('--wizard', 'Run interactive setup wizard')
|
|
35
|
+
.option('--auto', 'Auto-configure based on project analysis')
|
|
36
|
+
.option('--minimal', 'Minimal configuration (skip optional features)')
|
|
37
|
+
.option('--skip-patterns', 'Skip loading pre-trained patterns')
|
|
38
|
+
.option('--with-n8n', 'Install n8n workflow testing agents and skills')
|
|
39
|
+
.option('--auto-migrate', 'Automatically migrate from v2 if detected')
|
|
40
|
+
.option('--with-claude-flow', 'Force Claude Flow integration setup')
|
|
41
|
+
.option('--skip-claude-flow', 'Skip Claude Flow integration')
|
|
42
|
+
.option('--modular', 'Use new modular init system (default for --auto)')
|
|
43
|
+
.action(async (options) => {
|
|
44
|
+
await this.execute(options, context);
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
async execute(options, context) {
|
|
48
|
+
try {
|
|
49
|
+
// --auto-migrate implies --auto (must use orchestrator for migration)
|
|
50
|
+
if (options.autoMigrate && !options.auto && !options.wizard) {
|
|
51
|
+
options.auto = true;
|
|
52
|
+
}
|
|
53
|
+
// Check if wizard mode requested
|
|
54
|
+
if (options.wizard || options.auto) {
|
|
55
|
+
console.log(chalk.blue('\n Agentic QE v3 Initialization\n'));
|
|
56
|
+
// Use modular orchestrator for --auto or --modular
|
|
57
|
+
if (options.auto || options.modular) {
|
|
58
|
+
await this.runModularInit(options, context);
|
|
59
|
+
return;
|
|
60
|
+
}
|
|
61
|
+
// Legacy wizard mode using InitOrchestrator
|
|
62
|
+
await this.runLegacyWizard(options, context);
|
|
63
|
+
return;
|
|
64
|
+
}
|
|
65
|
+
// Standard init without wizard
|
|
66
|
+
await this.runStandardInit(options, context);
|
|
67
|
+
}
|
|
68
|
+
catch (error) {
|
|
69
|
+
console.error(chalk.red('\n Failed to initialize:'), error);
|
|
70
|
+
await this.cleanupAndExit(1);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
async runModularInit(options, context) {
|
|
74
|
+
const orchestrator = createModularInitOrchestrator({
|
|
75
|
+
projectRoot: process.cwd(),
|
|
76
|
+
autoMode: options.auto,
|
|
77
|
+
minimal: options.minimal,
|
|
78
|
+
skipPatterns: options.skipPatterns,
|
|
79
|
+
withN8n: options.withN8n,
|
|
80
|
+
autoMigrate: options.autoMigrate,
|
|
81
|
+
});
|
|
82
|
+
console.log(chalk.white(' Analyzing project...\n'));
|
|
83
|
+
const result = await orchestrator.initialize();
|
|
84
|
+
// Display step results
|
|
85
|
+
for (const step of result.steps) {
|
|
86
|
+
const statusIcon = step.status === 'success' ? '*' : step.status === 'error' ? 'x' : '!';
|
|
87
|
+
const statusColor = step.status === 'success' ? chalk.green : step.status === 'error' ? chalk.red : chalk.yellow;
|
|
88
|
+
console.log(statusColor(` ${statusIcon} ${step.step} (${step.durationMs}ms)`));
|
|
89
|
+
}
|
|
90
|
+
console.log('');
|
|
91
|
+
// Claude Flow integration (after base init)
|
|
92
|
+
let cfResult;
|
|
93
|
+
if (!options.skipClaudeFlow && (options.withClaudeFlow || result.success)) {
|
|
94
|
+
try {
|
|
95
|
+
cfResult = await setupClaudeFlowIntegration({
|
|
96
|
+
projectRoot: process.cwd(),
|
|
97
|
+
force: options.withClaudeFlow,
|
|
98
|
+
});
|
|
99
|
+
if (cfResult.available) {
|
|
100
|
+
console.log(chalk.green(' * Claude Flow integration enabled'));
|
|
101
|
+
if (cfResult.features.trajectories) {
|
|
102
|
+
console.log(chalk.gray(' - SONA trajectory tracking'));
|
|
103
|
+
}
|
|
104
|
+
if (cfResult.features.modelRouting) {
|
|
105
|
+
console.log(chalk.gray(' - 3-tier model routing (haiku/sonnet/opus)'));
|
|
106
|
+
}
|
|
107
|
+
if (cfResult.features.pretrain) {
|
|
108
|
+
console.log(chalk.gray(' - Codebase pretrain analysis'));
|
|
109
|
+
}
|
|
110
|
+
console.log('');
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
catch {
|
|
114
|
+
// Claude Flow not available - continue without it
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
if (result.success) {
|
|
118
|
+
console.log(chalk.green(' AQE v3 initialized successfully!\n'));
|
|
119
|
+
// Show summary
|
|
120
|
+
console.log(chalk.blue(' Summary:'));
|
|
121
|
+
console.log(chalk.gray(` - Patterns loaded: ${result.summary.patternsLoaded}`));
|
|
122
|
+
console.log(chalk.gray(` - Skills installed: ${result.summary.skillsInstalled}`));
|
|
123
|
+
console.log(chalk.gray(` - Agents installed: ${result.summary.agentsInstalled}`));
|
|
124
|
+
console.log(chalk.gray(` - Hooks configured: ${result.summary.hooksConfigured ? 'Yes' : 'No'}`));
|
|
125
|
+
console.log(chalk.gray(` - Workers started: ${result.summary.workersStarted}`));
|
|
126
|
+
console.log(chalk.gray(` - Claude Flow: ${cfResult?.available ? 'Enabled' : 'Standalone mode'}`));
|
|
127
|
+
console.log(chalk.gray(` - Total time: ${result.totalDurationMs}ms\n`));
|
|
128
|
+
console.log(chalk.white('Next steps:'));
|
|
129
|
+
console.log(chalk.gray(' 1. Add MCP: claude mcp add aqe -- aqe-mcp'));
|
|
130
|
+
console.log(chalk.gray(' 2. Run tests: aqe test <path>'));
|
|
131
|
+
console.log(chalk.gray(' 3. Check status: aqe status\n'));
|
|
132
|
+
}
|
|
133
|
+
else {
|
|
134
|
+
console.log(chalk.red(' Initialization failed. Check errors above.\n'));
|
|
135
|
+
await this.cleanupAndExit(1);
|
|
136
|
+
}
|
|
137
|
+
await this.cleanupAndExit(0);
|
|
138
|
+
}
|
|
139
|
+
async runLegacyWizard(options, context) {
|
|
140
|
+
const orchestratorOptions = {
|
|
141
|
+
projectRoot: process.cwd(),
|
|
142
|
+
autoMode: options.auto,
|
|
143
|
+
minimal: options.minimal,
|
|
144
|
+
skipPatterns: options.skipPatterns,
|
|
145
|
+
withN8n: options.withN8n,
|
|
146
|
+
autoMigrate: options.autoMigrate,
|
|
147
|
+
};
|
|
148
|
+
const orchestrator = new InitOrchestrator(orchestratorOptions);
|
|
149
|
+
if (options.wizard) {
|
|
150
|
+
// Show wizard steps
|
|
151
|
+
console.log(chalk.white(' Setup Wizard Steps:\n'));
|
|
152
|
+
const steps = orchestrator.getWizardSteps();
|
|
153
|
+
for (let i = 0; i < steps.length; i++) {
|
|
154
|
+
console.log(chalk.gray(` ${i + 1}. ${steps[i].title}`));
|
|
155
|
+
console.log(chalk.gray(` ${steps[i].description}\n`));
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
console.log(chalk.white(' Analyzing project...\n'));
|
|
159
|
+
const result = await orchestrator.initialize();
|
|
160
|
+
// Display step results
|
|
161
|
+
for (const step of result.steps) {
|
|
162
|
+
const statusIcon = step.status === 'success' ? '*' : step.status === 'error' ? 'x' : '!';
|
|
163
|
+
const statusColor = step.status === 'success' ? chalk.green : step.status === 'error' ? chalk.red : chalk.yellow;
|
|
164
|
+
console.log(statusColor(` ${statusIcon} ${step.step} (${step.durationMs}ms)`));
|
|
165
|
+
}
|
|
166
|
+
console.log('');
|
|
167
|
+
if (result.success) {
|
|
168
|
+
console.log(chalk.green(' AQE v3 initialized successfully!\n'));
|
|
169
|
+
// Show summary
|
|
170
|
+
console.log(chalk.blue(' Summary:'));
|
|
171
|
+
console.log(chalk.gray(` - Patterns loaded: ${result.summary.patternsLoaded}`));
|
|
172
|
+
console.log(chalk.gray(` - Hooks configured: ${result.summary.hooksConfigured ? 'Yes' : 'No'}`));
|
|
173
|
+
console.log(chalk.gray(` - Workers started: ${result.summary.workersStarted}`));
|
|
174
|
+
if (result.summary.n8nInstalled) {
|
|
175
|
+
console.log(chalk.gray(` - N8n agents: ${result.summary.n8nInstalled.agents}`));
|
|
176
|
+
console.log(chalk.gray(` - N8n skills: ${result.summary.n8nInstalled.skills}`));
|
|
177
|
+
}
|
|
178
|
+
console.log(chalk.gray(` - Total time: ${result.totalDurationMs}ms\n`));
|
|
179
|
+
console.log(chalk.white('Next steps:'));
|
|
180
|
+
console.log(chalk.gray(' 1. Add MCP: claude mcp add aqe -- aqe-mcp'));
|
|
181
|
+
console.log(chalk.gray(' 2. Run tests: aqe test <path>'));
|
|
182
|
+
console.log(chalk.gray(' 3. Check status: aqe status\n'));
|
|
183
|
+
}
|
|
184
|
+
else {
|
|
185
|
+
console.log(chalk.red(' Initialization failed. Check errors above.\n'));
|
|
186
|
+
await this.cleanupAndExit(1);
|
|
187
|
+
}
|
|
188
|
+
await this.cleanupAndExit(0);
|
|
189
|
+
}
|
|
190
|
+
async runStandardInit(options, context) {
|
|
191
|
+
console.log(chalk.blue('\n Initializing Agentic QE v3...\n'));
|
|
192
|
+
// Determine enabled domains
|
|
193
|
+
const enabledDomains = options.domains === 'all'
|
|
194
|
+
? [...ALL_DOMAINS]
|
|
195
|
+
: options.domains.split(',').filter((d) => ALL_DOMAINS.includes(d));
|
|
196
|
+
console.log(chalk.gray(` Domains: ${enabledDomains.length}`));
|
|
197
|
+
console.log(chalk.gray(` Max Agents: ${options.maxAgents}`));
|
|
198
|
+
console.log(chalk.gray(` Memory: ${options.memory}`));
|
|
199
|
+
console.log(chalk.gray(` Lazy Loading: ${options.lazy ? 'enabled' : 'disabled'}\n`));
|
|
200
|
+
// Create kernel
|
|
201
|
+
context.kernel = new QEKernelImpl({
|
|
202
|
+
maxConcurrentAgents: parseInt(options.maxAgents, 10),
|
|
203
|
+
memoryBackend: options.memory,
|
|
204
|
+
hnswEnabled: true,
|
|
205
|
+
lazyLoading: options.lazy || false,
|
|
206
|
+
enabledDomains,
|
|
207
|
+
});
|
|
208
|
+
await context.kernel.initialize();
|
|
209
|
+
console.log(chalk.green(' * Kernel initialized'));
|
|
210
|
+
// Create cross-domain router
|
|
211
|
+
context.router = new CrossDomainEventRouter(context.kernel.eventBus);
|
|
212
|
+
await context.router.initialize();
|
|
213
|
+
console.log(chalk.green(' * Cross-domain router initialized'));
|
|
214
|
+
// Create protocol executor
|
|
215
|
+
const getDomainAPI = (domain) => {
|
|
216
|
+
return context.kernel.getDomainAPI(domain);
|
|
217
|
+
};
|
|
218
|
+
const protocolExecutor = new DefaultProtocolExecutor(context.kernel.eventBus, context.kernel.memory, getDomainAPI);
|
|
219
|
+
console.log(chalk.green(' * Protocol executor initialized'));
|
|
220
|
+
// Create workflow orchestrator
|
|
221
|
+
context.workflowOrchestrator = new WorkflowOrchestrator(context.kernel.eventBus, context.kernel.memory, context.kernel.coordinator);
|
|
222
|
+
await context.workflowOrchestrator.initialize();
|
|
223
|
+
// Register domain workflow actions (Issue #206)
|
|
224
|
+
this.registerDomainWorkflowActions(context.kernel, context.workflowOrchestrator);
|
|
225
|
+
console.log(chalk.green(' * Workflow orchestrator initialized'));
|
|
226
|
+
// Create Queen Coordinator
|
|
227
|
+
context.queen = createQueenCoordinator(context.kernel, context.router, protocolExecutor, undefined);
|
|
228
|
+
await context.queen.initialize();
|
|
229
|
+
console.log(chalk.green(' * Queen Coordinator initialized'));
|
|
230
|
+
context.initialized = true;
|
|
231
|
+
console.log(chalk.green('\n AQE v3 initialized successfully!\n'));
|
|
232
|
+
// Show enabled domains
|
|
233
|
+
console.log(chalk.blue(' Enabled Domains:'));
|
|
234
|
+
for (const domain of enabledDomains) {
|
|
235
|
+
console.log(chalk.gray(` - ${domain}`));
|
|
236
|
+
}
|
|
237
|
+
console.log('');
|
|
238
|
+
await this.cleanupAndExit(0);
|
|
239
|
+
}
|
|
240
|
+
registerDomainWorkflowActions(kernel, orchestrator) {
|
|
241
|
+
// Register visual-accessibility domain actions
|
|
242
|
+
const visualAccessibilityAPI = kernel.getDomainAPI('visual-accessibility');
|
|
243
|
+
if (visualAccessibilityAPI?.registerWorkflowActions) {
|
|
244
|
+
try {
|
|
245
|
+
visualAccessibilityAPI.registerWorkflowActions(orchestrator);
|
|
246
|
+
}
|
|
247
|
+
catch (error) {
|
|
248
|
+
// Log but don't fail - domain may not be enabled
|
|
249
|
+
console.error(chalk.yellow(` ! Could not register visual-accessibility workflow actions: ${error instanceof Error ? error.message : String(error)}`));
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
getHelp() {
|
|
254
|
+
return `
|
|
255
|
+
Initialize the AQE v3 system with various configuration options.
|
|
256
|
+
|
|
257
|
+
Usage:
|
|
258
|
+
aqe init [options]
|
|
259
|
+
|
|
260
|
+
Options:
|
|
261
|
+
-d, --domains <domains> Comma-separated list of domains to enable (default: all)
|
|
262
|
+
-m, --max-agents <number> Maximum concurrent agents (default: 15)
|
|
263
|
+
--memory <backend> Memory backend: sqlite, agentdb, or hybrid (default: hybrid)
|
|
264
|
+
--lazy Enable lazy loading of domains
|
|
265
|
+
--wizard Run interactive setup wizard
|
|
266
|
+
--auto Auto-configure based on project analysis
|
|
267
|
+
--minimal Minimal configuration (skip optional features)
|
|
268
|
+
--skip-patterns Skip loading pre-trained patterns
|
|
269
|
+
--with-n8n Install n8n workflow testing agents and skills
|
|
270
|
+
--auto-migrate Automatically migrate from v2 if detected
|
|
271
|
+
--with-claude-flow Force Claude Flow integration setup
|
|
272
|
+
--skip-claude-flow Skip Claude Flow integration
|
|
273
|
+
--modular Use new modular init system
|
|
274
|
+
|
|
275
|
+
Examples:
|
|
276
|
+
aqe init --auto # Auto-configure based on project
|
|
277
|
+
aqe init --wizard # Run interactive wizard
|
|
278
|
+
aqe init --domains test-generation,coverage-analysis
|
|
279
|
+
`;
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
// ============================================================================
|
|
283
|
+
// Factory
|
|
284
|
+
// ============================================================================
|
|
285
|
+
export function createInitHandler(cleanupAndExit) {
|
|
286
|
+
return new InitHandler(cleanupAndExit);
|
|
287
|
+
}
|
|
288
|
+
//# sourceMappingURL=init-handler.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"init-handler.js","sourceRoot":"","sources":["../../../src/cli/handlers/init-handler.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAc,WAAW,EAAE,MAAM,6BAA6B,CAAC;AACtE,OAAO,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AACnF,OAAO,EAAE,uBAAuB,EAAE,MAAM,yCAAyC,CAAC;AAClF,OAAO,EAAE,oBAAoB,EAAE,MAAM,6CAA6C,CAAC;AACnF,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AACjF,OAAO,EAAE,gBAAgB,EAAgC,MAAM,2BAA2B,CAAC;AAC3F,OAAO,EACL,6BAA6B,GAC9B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,0BAA0B,EAA8B,MAAM,kCAAkC,CAAC;AAK1G,+EAA+E;AAC/E,eAAe;AACf,+EAA+E;AAE/E,MAAM,OAAO,WAAW;IACb,IAAI,GAAG,MAAM,CAAC;IACd,WAAW,GAAG,8BAA8B,CAAC;IAE9C,cAAc,CAAmC;IAEzD,YAAY,cAAgD;QAC1D,IAAI,CAAC,cAAc,GAAG,cAAc,CAAC;IACvC,CAAC;IAED,QAAQ,CAAC,OAAgB,EAAE,OAAmB;QAC5C,OAAO;aACJ,OAAO,CAAC,MAAM,CAAC;aACf,WAAW,CAAC,IAAI,CAAC,WAAW,CAAC;aAC7B,MAAM,CAAC,yBAAyB,EAAE,2CAA2C,EAAE,KAAK,CAAC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X,KAAK,CAAC,MAAM,CAAC,iEAAiE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CACxI,CAAC;YACJ,CAAC;QACH,CAAC;IACH,CAAC;IAED,OAAO;QACL,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;CAyBV,CAAC;IACA,CAAC;CACF;AAsBD,+EAA+E;AAC/E,UAAU;AACV,+EAA+E;AAE/E,MAAM,UAAU,iBAAiB,CAAC,cAAgD;IAChF,OAAO,IAAI,WAAW,CAAC,cAAc,CAAC,CAAC;AACzC,CAAC"}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - Command Handler Interfaces
|
|
3
|
+
*
|
|
4
|
+
* Defines the common interfaces for all CLI command handlers.
|
|
5
|
+
* Part of the CLI modularization refactoring.
|
|
6
|
+
*/
|
|
7
|
+
import { Command } from 'commander';
|
|
8
|
+
import { QEKernel } from '../../kernel/interfaces.js';
|
|
9
|
+
import { QueenCoordinator } from '../../coordination/queen-coordinator.js';
|
|
10
|
+
import { CrossDomainEventRouter } from '../../coordination/cross-domain-router.js';
|
|
11
|
+
import { WorkflowOrchestrator } from '../../coordination/workflow-orchestrator.js';
|
|
12
|
+
import type { PersistentScheduler } from '../scheduler/index.js';
|
|
13
|
+
export interface ScheduledWorkflow {
|
|
14
|
+
id: string;
|
|
15
|
+
workflowId: string;
|
|
16
|
+
pipelinePath: string;
|
|
17
|
+
schedule: string;
|
|
18
|
+
scheduleDescription: string;
|
|
19
|
+
nextRun: Date;
|
|
20
|
+
enabled: boolean;
|
|
21
|
+
createdAt: Date;
|
|
22
|
+
lastRun?: Date;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Shared CLI context that command handlers can access
|
|
26
|
+
*/
|
|
27
|
+
export interface CLIContext {
|
|
28
|
+
kernel: QEKernel | null;
|
|
29
|
+
queen: QueenCoordinator | null;
|
|
30
|
+
router: CrossDomainEventRouter | null;
|
|
31
|
+
workflowOrchestrator: WorkflowOrchestrator | null;
|
|
32
|
+
scheduledWorkflows: Map<string, ScheduledWorkflow>;
|
|
33
|
+
persistentScheduler: PersistentScheduler | null;
|
|
34
|
+
initialized: boolean;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Command options common to many handlers
|
|
38
|
+
*/
|
|
39
|
+
export interface CommonOptions {
|
|
40
|
+
verbose?: boolean;
|
|
41
|
+
json?: boolean;
|
|
42
|
+
progress?: boolean;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Interface for all command handlers
|
|
46
|
+
*/
|
|
47
|
+
export interface ICommandHandler {
|
|
48
|
+
/** Unique command name */
|
|
49
|
+
readonly name: string;
|
|
50
|
+
/** Command description shown in help */
|
|
51
|
+
readonly description: string;
|
|
52
|
+
/** Aliases for the command (e.g., 't' for 'task') */
|
|
53
|
+
readonly aliases?: string[];
|
|
54
|
+
/**
|
|
55
|
+
* Register the command with the Commander program
|
|
56
|
+
* @param program The Commander program or parent command
|
|
57
|
+
* @param context Shared CLI context
|
|
58
|
+
*/
|
|
59
|
+
register(program: Command, context: CLIContext): void;
|
|
60
|
+
/**
|
|
61
|
+
* Get help text for this command
|
|
62
|
+
*/
|
|
63
|
+
getHelp(): string;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Interface for command handlers that require initialization
|
|
67
|
+
*/
|
|
68
|
+
export interface IInitializableHandler extends ICommandHandler {
|
|
69
|
+
/**
|
|
70
|
+
* Initialize handler-specific state
|
|
71
|
+
*/
|
|
72
|
+
initialize(context: CLIContext): Promise<void>;
|
|
73
|
+
/**
|
|
74
|
+
* Cleanup handler-specific state
|
|
75
|
+
*/
|
|
76
|
+
dispose(): Promise<void>;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Get status color based on status string
|
|
80
|
+
*/
|
|
81
|
+
export declare function getStatusColor(status: string): string;
|
|
82
|
+
/**
|
|
83
|
+
* Format duration in human-readable format
|
|
84
|
+
*/
|
|
85
|
+
export declare function formatDuration(ms: number): string;
|
|
86
|
+
/**
|
|
87
|
+
* Format uptime in human-readable format
|
|
88
|
+
*/
|
|
89
|
+
export declare function formatUptime(ms: number): string;
|
|
90
|
+
/**
|
|
91
|
+
* Get color function based on percentage value
|
|
92
|
+
*/
|
|
93
|
+
export declare function getColorForPercent(percent: number): (str: string) => string;
|
|
94
|
+
/**
|
|
95
|
+
* Walk directory recursively to find files
|
|
96
|
+
*/
|
|
97
|
+
export declare function walkDirectory(dir: string, options?: {
|
|
98
|
+
extensions?: string[];
|
|
99
|
+
exclude?: string[];
|
|
100
|
+
maxDepth?: number;
|
|
101
|
+
includeTests?: boolean;
|
|
102
|
+
}): Promise<string[]>;
|
|
103
|
+
export type { Command };
|
|
104
|
+
//# sourceMappingURL=interfaces.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/cli/handlers/interfaces.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AACtD,OAAO,EAAE,gBAAgB,EAAE,MAAM,yCAAyC,CAAC;AAC3E,OAAO,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AACnF,OAAO,EAAE,oBAAoB,EAAE,MAAM,6CAA6C,CAAC;AACnF,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAGjE,MAAM,WAAW,iBAAiB;IAChC,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,mBAAmB,EAAE,MAAM,CAAC;IAC5B,OAAO,EAAE,IAAI,CAAC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AAM,EAAE,MAAM,GAAG,MAAM,CAiBrD;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,CAKjD;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,CAK/C;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAI3E;AAED;;GAEG;AACH,wBAAsB,aAAa,CACjC,GAAG,EAAE,MAAM,EACX,OAAO,GAAE;IACP,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,OAAO,CAAC;CACnB,GACL,OAAO,CAAC,MAAM,EAAE,CAAC,CAoDnB;AAMD,YAAY,EAAE,OAAO,EAAE,CAAC"}
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - Command Handler Interfaces
|
|
3
|
+
*
|
|
4
|
+
* Defines the common interfaces for all CLI command handlers.
|
|
5
|
+
* Part of the CLI modularization refactoring.
|
|
6
|
+
*/
|
|
7
|
+
import chalk from 'chalk';
|
|
8
|
+
// ============================================================================
|
|
9
|
+
// Helper Functions for Handlers
|
|
10
|
+
// ============================================================================
|
|
11
|
+
/**
|
|
12
|
+
* Get status color based on status string
|
|
13
|
+
*/
|
|
14
|
+
export function getStatusColor(status) {
|
|
15
|
+
switch (status) {
|
|
16
|
+
case 'healthy':
|
|
17
|
+
case 'completed':
|
|
18
|
+
return chalk.green(status);
|
|
19
|
+
case 'idle':
|
|
20
|
+
// Issue #205 fix: 'idle' is normal - show in cyan (neutral/ready)
|
|
21
|
+
return chalk.cyan(status);
|
|
22
|
+
case 'degraded':
|
|
23
|
+
case 'running':
|
|
24
|
+
return chalk.yellow(status);
|
|
25
|
+
case 'unhealthy':
|
|
26
|
+
case 'failed':
|
|
27
|
+
return chalk.red(status);
|
|
28
|
+
default:
|
|
29
|
+
return chalk.gray(status);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Format duration in human-readable format
|
|
34
|
+
*/
|
|
35
|
+
export function formatDuration(ms) {
|
|
36
|
+
if (ms < 1000)
|
|
37
|
+
return `${ms}ms`;
|
|
38
|
+
if (ms < 60000)
|
|
39
|
+
return `${(ms / 1000).toFixed(1)}s`;
|
|
40
|
+
if (ms < 3600000)
|
|
41
|
+
return `${(ms / 60000).toFixed(1)}m`;
|
|
42
|
+
return `${(ms / 3600000).toFixed(1)}h`;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Format uptime in human-readable format
|
|
46
|
+
*/
|
|
47
|
+
export function formatUptime(ms) {
|
|
48
|
+
const hours = Math.floor(ms / 3600000);
|
|
49
|
+
const minutes = Math.floor((ms % 3600000) / 60000);
|
|
50
|
+
const seconds = Math.floor((ms % 60000) / 1000);
|
|
51
|
+
return `${hours}h ${minutes}m ${seconds}s`;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Get color function based on percentage value
|
|
55
|
+
*/
|
|
56
|
+
export function getColorForPercent(percent) {
|
|
57
|
+
if (percent >= 80)
|
|
58
|
+
return chalk.green;
|
|
59
|
+
if (percent >= 50)
|
|
60
|
+
return chalk.yellow;
|
|
61
|
+
return chalk.red;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Walk directory recursively to find files
|
|
65
|
+
*/
|
|
66
|
+
export async function walkDirectory(dir, options = {}) {
|
|
67
|
+
const fs = await import('fs');
|
|
68
|
+
const path = await import('path');
|
|
69
|
+
const { extensions = ['.ts'], exclude = ['node_modules', 'dist'], maxDepth = 4, includeTests = false, } = options;
|
|
70
|
+
const walkDir = (currentDir, depth) => {
|
|
71
|
+
if (depth > maxDepth)
|
|
72
|
+
return [];
|
|
73
|
+
const result = [];
|
|
74
|
+
let items;
|
|
75
|
+
try {
|
|
76
|
+
items = fs.readdirSync(currentDir);
|
|
77
|
+
}
|
|
78
|
+
catch {
|
|
79
|
+
return [];
|
|
80
|
+
}
|
|
81
|
+
for (const item of items) {
|
|
82
|
+
if (exclude.includes(item))
|
|
83
|
+
continue;
|
|
84
|
+
if (!includeTests && (item === 'tests' || item.includes('.test.') || item.includes('.spec.')))
|
|
85
|
+
continue;
|
|
86
|
+
const fullPath = path.join(currentDir, item);
|
|
87
|
+
let stat;
|
|
88
|
+
try {
|
|
89
|
+
stat = fs.statSync(fullPath);
|
|
90
|
+
}
|
|
91
|
+
catch {
|
|
92
|
+
continue;
|
|
93
|
+
}
|
|
94
|
+
if (stat.isDirectory()) {
|
|
95
|
+
result.push(...walkDir(fullPath, depth + 1));
|
|
96
|
+
}
|
|
97
|
+
else {
|
|
98
|
+
const hasValidExtension = extensions.some(ext => item.endsWith(ext));
|
|
99
|
+
const isDeclarationFile = item.endsWith('.d.ts');
|
|
100
|
+
if (hasValidExtension && !isDeclarationFile) {
|
|
101
|
+
result.push(fullPath);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
return result;
|
|
106
|
+
};
|
|
107
|
+
return walkDir(dir, 0);
|
|
108
|
+
}
|
|
109
|
+
//# sourceMappingURL=interfaces.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interfaces.js","sourceRoot":"","sources":["../../../src/cli/handlers/interfaces.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,KAAK,MAAM,OAAO,CAAC;AA2F1B,+EAA+E;AAC/E,gCAAgC;AAChC,+EAA+E;AAE/E;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,MAAc;IAC3C,QAAQ,MAAM,EAAE,CAAC;QACf,KAAK,SAAS,CAAC;QACf,KAAK,WAAW;YACd,OAAO,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QAC7B,K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,EAAE,IAAI,CAAC,CAAC;YAC7C,IAAI,IAAI,CAAC;YAET,IAAI,CAAC;gBACH,IAAI,GAAG,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;YAC/B,CAAC;YAAC,MAAM,CAAC;gBACP,SAAS;YACX,CAAC;YAED,IAAI,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC;gBACvB,MAAM,CAAC,IAAI,CAAC,GAAG,OAAO,CAAC,QAAQ,EAAE,KAAK,GAAG,CAAC,CAAC,CAAC,CAAC;YAC/C,CAAC;iBAAM,CAAC;gBACN,MAAM,iBAAiB,GAAG,UAAU,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC;gBACrE,MAAM,iBAAiB,GAAG,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;gBAEjD,IAAI,iBAAiB,IAAI,CAAC,iBAAiB,EAAE,CAAC;oBAC5C,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;gBACxB,CAAC;YACH,CAAC;QACH,CAAC;QAED,OAAO,MAAM,CAAC;IAChB,CAAC,CAAC;IAEF,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;AACzB,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - Protocol Command Handler
|
|
3
|
+
*
|
|
4
|
+
* Handles the 'aqe protocol' command group for protocol execution.
|
|
5
|
+
*/
|
|
6
|
+
import { Command } from 'commander';
|
|
7
|
+
import { ICommandHandler, CLIContext } from './interfaces.js';
|
|
8
|
+
export declare class ProtocolHandler implements ICommandHandler {
|
|
9
|
+
readonly name = "protocol";
|
|
10
|
+
readonly description = "Execute coordination protocols";
|
|
11
|
+
private cleanupAndExit;
|
|
12
|
+
private ensureInitialized;
|
|
13
|
+
constructor(cleanupAndExit: (code: number) => Promise<never>, ensureInitialized: () => Promise<boolean>);
|
|
14
|
+
register(program: Command, context: CLIContext): void;
|
|
15
|
+
private executeRun;
|
|
16
|
+
getHelp(): string;
|
|
17
|
+
}
|
|
18
|
+
export declare function createProtocolHandler(cleanupAndExit: (code: number) => Promise<never>, ensureInitialized: () => Promise<boolean>): ProtocolHandler;
|
|
19
|
+
//# sourceMappingURL=protocol-handler.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"protocol-handler.d.ts","sourceRoot":"","sources":["../../../src/cli/handlers/protocol-handler.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,OAAO,EACL,eAAe,EACf,UAAU,EACX,MAAM,iBAAiB,CAAC;AAOzB,qBAAa,eAAgB,YAAW,eAAe;IACrD,QAAQ,CAAC,IAAI,cAAc;IAC3B,QAAQ,CAAC,WAAW,oCAAoC;IAExD,OAAO,CAAC,cAAc,CAAmC;IACzD,OAAO,CAAC,iBAAiB,CAAyB;gBAGhD,cAAc,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,KAAK,CAAC,EAChD,iBAAiB,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC;IAM3C,QAAQ,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,UAAU,GAAG,IAAI;YAevC,UAAU;IAyBxB,OAAO,IAAI,MAAM;CAkBlB;AAcD,wBAAgB,qBAAqB,CACnC,cAAc,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,KAAK,CAAC,EAChD,iBAAiB,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC,GACxC,eAAe,CAEjB"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - Protocol Command Handler
|
|
3
|
+
*
|
|
4
|
+
* Handles the 'aqe protocol' command group for protocol execution.
|
|
5
|
+
*/
|
|
6
|
+
import chalk from 'chalk';
|
|
7
|
+
import { parseJsonOption } from '../helpers/safe-json.js';
|
|
8
|
+
// ============================================================================
|
|
9
|
+
// Protocol Handler
|
|
10
|
+
// ============================================================================
|
|
11
|
+
export class ProtocolHandler {
|
|
12
|
+
name = 'protocol';
|
|
13
|
+
description = 'Execute coordination protocols';
|
|
14
|
+
cleanupAndExit;
|
|
15
|
+
ensureInitialized;
|
|
16
|
+
constructor(cleanupAndExit, ensureInitialized) {
|
|
17
|
+
this.cleanupAndExit = cleanupAndExit;
|
|
18
|
+
this.ensureInitialized = ensureInitialized;
|
|
19
|
+
}
|
|
20
|
+
register(program, context) {
|
|
21
|
+
const protocolCmd = program
|
|
22
|
+
.command('protocol')
|
|
23
|
+
.description(this.description);
|
|
24
|
+
// protocol run
|
|
25
|
+
protocolCmd
|
|
26
|
+
.command('run <protocolId>')
|
|
27
|
+
.description('Execute a protocol')
|
|
28
|
+
.option('--params <json>', 'Protocol parameters as JSON', '{}')
|
|
29
|
+
.action(async (protocolId, options) => {
|
|
30
|
+
await this.executeRun(protocolId, options, context);
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
async executeRun(protocolId, options, context) {
|
|
34
|
+
if (!await this.ensureInitialized())
|
|
35
|
+
return;
|
|
36
|
+
try {
|
|
37
|
+
const params = parseJsonOption(options.params, 'params');
|
|
38
|
+
console.log(chalk.blue(`\n Executing protocol: ${protocolId}\n`));
|
|
39
|
+
const result = await context.queen.executeProtocol(protocolId, params);
|
|
40
|
+
if (result.success) {
|
|
41
|
+
console.log(chalk.green(` Protocol execution started`));
|
|
42
|
+
console.log(chalk.cyan(` Execution ID: ${result.value}`));
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
console.log(chalk.red(` Failed to execute protocol: ${result.error.message}`));
|
|
46
|
+
}
|
|
47
|
+
console.log('');
|
|
48
|
+
}
|
|
49
|
+
catch (error) {
|
|
50
|
+
console.error(chalk.red('\n Failed to execute protocol:'), error);
|
|
51
|
+
await this.cleanupAndExit(1);
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
getHelp() {
|
|
55
|
+
return `
|
|
56
|
+
Execute coordination protocols.
|
|
57
|
+
|
|
58
|
+
Usage:
|
|
59
|
+
aqe protocol <command> [options]
|
|
60
|
+
|
|
61
|
+
Commands:
|
|
62
|
+
run <protocolId> Execute a protocol
|
|
63
|
+
|
|
64
|
+
Options:
|
|
65
|
+
--params <json> Protocol parameters as JSON (default: {})
|
|
66
|
+
|
|
67
|
+
Examples:
|
|
68
|
+
aqe protocol run cross-domain-sync
|
|
69
|
+
aqe protocol run data-validation --params '{"strict": true}'
|
|
70
|
+
`;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
// ============================================================================
|
|
74
|
+
// Factory
|
|
75
|
+
// ============================================================================
|
|
76
|
+
export function createProtocolHandler(cleanupAndExit, ensureInitialized) {
|
|
77
|
+
return new ProtocolHandler(cleanupAndExit, ensureInitialized);
|
|
78
|
+
}
|
|
79
|
+
//# sourceMappingURL=protocol-handler.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"protocol-handler.js","sourceRoot":"","sources":["../../../src/cli/handlers/protocol-handler.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAE1D,+EAA+E;AAC/E,mBAAmB;AACnB,+EAA+E;AAE/E,MAAM,OAAO,eAAe;IACjB,IAAI,GAAG,UAAU,CAAC;IAClB,WAAW,GAAG,gCAAgC,CAAC;IAEhD,cAAc,CAAmC;IACjD,iBAAiB,CAAyB;IAElD,YACE,cAAgD,EAChD,iBAAyC;QAEzC,IAAI,CAAC,cAAc,GAAG,cAAc,CAAC;QACrC,IAAI,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;IAC7C,CAAC;IAED,QAAQ,CAAC,OAAgB,EAAE,OAAmB;QAC5C,MAAM,WAAW,GAAG,OAAO;aACxB,O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