Router: Quality Assurance
Master orchestrator for quality engineering that routes testing, observability, resilience, debugging, and documentation quality questions through 12 specialized QA skills, with explicit handoffs when the request is outside QA scope (implementation, docs authoring, deployment).
Quick Decision Tree
text
QA QUESTION
│
├─► "What tests do I need?" ──────────► qa-testing-strategy
│ └─► Test pyramid, coverage, risk-based
│
├─► "Write E2E tests" ────────────────► qa-testing-playwright
│ └─► Selectors, page objects, CI/CD
│
├─► "Test iOS app" ───────────────────► qa-testing-ios
│ └─► XCTest, simulators, device matrix
│
├─► "Test mobile app" ────────────────► qa-testing-mobile
│ └─► Cross-platform, Android + iOS
│
├─► "Test Android app" ──────────────► qa-testing-android
│ └─► Espresso, UIAutomator, Compose
│
├─► "Test API contracts" ─────────────► qa-api-testing-contracts
│ └─► OpenAPI, Pact, schema validation
│
├─► "Test LLM agent" ─────────────────► qa-agent-testing
│ └─► Scenarios, scoring, refusals
│
├─► "Debug this issue" ───────────────► qa-debugging
│ └─► Stack traces, logging, profiling
│
├─► "Setup monitoring" ───────────────► qa-observability
│ └─► OpenTelemetry, SLOs, tracing
│
├─► "Handle failures" ────────────────► qa-resilience
│ └─► Circuit breakers, retries, chaos
│
├─► "Refactor safely" ────────────────► qa-refactoring
│ └─► Characterization tests, seams
│
└─► "Check docs coverage" ────────────► qa-docs-coverage
└─► Gap analysis, runbook validation
Skill Registry (12 QA Skills)
Testing Skills (7)
| Skill | Purpose | Key Triggers |
|---|
| Test pyramid, risk-based testing, coverage | "test strategy", "what tests", "coverage" |
| E2E web testing with Playwright | "E2E test", "Playwright", "browser test" |
| iOS testing with XCTest/XCUITest | "iOS test", "XCTest", "simulator" |
| Android testing with Espresso/UIAutomator | "Android test", "Espresso", "UIAutomator", "Compose test" |
| Cross-platform mobile testing | "mobile test", "cross-platform", "device matrix" |
| API schema and contract testing | "API test", "contract", "OpenAPI", "Pact" |
| LLM agent and persona testing | "agent test", "LLM test", "refusal", "scoring" |
Quality Skills (5)
| Skill | Purpose | Key Triggers |
|---|
| Debugging, logging, profiling | "debug", "error", "stack trace", "profile" |
| Metrics, traces, logs, SLOs | "monitor", "tracing", "SLO", "OpenTelemetry" |
| Circuit breakers, retries, chaos | "circuit breaker", "retry", "chaos", "timeout" |
| Safe refactoring, tech debt | "refactor", "code smell", "tech debt" |
| Documentation quality gates | "docs coverage", "undocumented", "runbook" |
Canonical Registry (Source of Truth)
Use
frameworks/shared-skills/skills/router-qa/data/skill-registry.json
as the canonical list of QA skills, triggers, expected outputs, and routing rules.
Use
frameworks/shared-skills/skills/router-qa/data/sources.json
for optional web-search references (each specialized skill maintains its own sources as needed).
Domain Detection
Domain 1: Test Planning
Triggers: "what tests", "test strategy", "coverage", "test pyramid", "shift-left", "risk-based"
Example questions:
- "What tests do I need for this API?"
- "How do I prioritize testing?"
- "What's the right test coverage target?"
Domain 2: E2E & UI Testing
Triggers: "E2E", "end-to-end", "Playwright", "browser test", "UI test", "page object", "visual test"
Example questions:
- "Write Playwright tests for login"
- "How to handle flaky E2E tests?"
- "Best practices for page objects?"
Domain 3: Mobile Testing
Triggers: "iOS", "Android", "mobile", "XCTest", "XCUITest", "Espresso", "UIAutomator", "Appium", "simulator", "emulator", "device"
| Trigger | Route |
|---|
| iOS-only | |
| Android-only | |
| Cross-platform | |
Example questions:
- "Test iOS app on simulator"
- "Write Espresso tests for Android login"
- "Test Jetpack Compose UI"
- "Device matrix for Android testing"
- "Cross-platform mobile test strategy"
Domain 4: API & Contract Testing
Triggers: "API test", "contract test", "OpenAPI", "GraphQL test", "gRPC", "Pact", "schema validation"
Example questions:
- "Write contract tests for REST API"
- "Validate OpenAPI schema"
- "Consumer-driven contract testing"
Domain 5: Agent Testing
Triggers: "agent test", "LLM test", "persona", "refusal", "AI safety", "scoring rubric", "test harness"
Example questions:
- "Create test suite for chatbot"
- "Test LLM refusal boundaries"
- "Score agent responses"
Domain 6: Debugging
Triggers: "debug", "error", "bug", "crash", "stack trace", "logging", "profiling", "troubleshoot"
Example questions:
- "Debug memory leak"
- "Analyze this stack trace"
- "Setup structured logging"
Domain 7: Observability
Triggers: "monitor", "metrics", "tracing", "logging", "SLO", "SLI", "OpenTelemetry", "APM", "alert"
Example questions:
- "Setup OpenTelemetry for Node.js"
- "Define SLOs for API"
- "Distributed tracing strategy"
Domain 8: Resilience
Triggers: "circuit breaker", "retry", "timeout", "backoff", "chaos", "fault injection", "degradation", "health check"
Example questions:
- "Implement circuit breaker"
- "Retry strategy for external APIs"
- "Setup chaos engineering"
Domain 9: Refactoring
Triggers: "refactor", "code smell", "tech debt", "legacy code", "characterization test", "strangler fig"
Example questions:
- "Refactor this legacy code safely"
- "Add tests before refactoring"
- "Manage technical debt"
Domain 10: Documentation Quality
Triggers: "docs coverage", "undocumented", "runbook", "API docs audit", "stale docs"
If the user asks about CLAUDE.md/AGENTS.md/project memory/large codebase setup: route to
claude-code-project-memory
(supporting:
,
)
Example questions:
- "Audit documentation coverage"
- "Find undocumented APIs"
- "Validate runbooks"
- "Set up CLAUDE.md for large codebase"
- "Create AGENTS.md for cross-platform support"
Workflow Patterns
Pattern 1: Test-First Development
text
START
│
▼
qa-testing-strategy ────────► Define test pyramid
│
├─► Unit tests ──────────► Write inline
├─► Integration tests ───► Write with mocks
└─► E2E tests ───────────► qa-testing-playwright
│
▼
qa-api-testing-contracts ──► Contract tests (if API)
│
▼
TESTS COMPLETE
Pattern 2: Bug Investigation
text
BUG REPORTED
│
▼
qa-debugging ──────────────► Analyze logs, traces, stack
│
├─► Need more visibility? → qa-observability
├─► Failure mode issue? ──→ qa-resilience
└─► Code quality issue? ──→ qa-refactoring
│
▼
ROOT CAUSE IDENTIFIED
│
▼
qa-testing-strategy ───────► Add regression test
│
▼
BUG FIXED + COVERED
Pattern 3: Production Hardening
text
PRE-PRODUCTION
│
▼
qa-resilience ─────────────► Error handling, retries
│
▼
qa-observability ──────────► Metrics, tracing, SLOs
│
▼
qa-testing-strategy ───────► Smoke + E2E tests
│
▼
PRODUCTION READY
│
▼
qa-resilience ─────────────► Chaos experiments (post-launch)
Pattern 4: Legacy Modernization
text
LEGACY CODEBASE
│
▼
qa-refactoring ────────────► Characterization tests
│
▼
qa-testing-strategy ───────► Add missing test coverage
│
▼
qa-refactoring ────────────► Incremental refactoring
│
▼
qa-docs-coverage ──────────► Document updated code
│
▼
MODERNIZED
Pattern 5: LLM Agent Quality
text
AGENT DEVELOPMENT
│
▼
qa-agent-testing ──────────► Define test scenarios
│
├─► Must-ace tasks ──────► Core functionality
├─► Refusal tests ───────► Safety boundaries
└─► Scoring rubric ──────► Quality metrics
│
▼
qa-observability ──────────► Token usage, latency metrics
│
▼
VALIDATED AGENT
Pattern 6: Large Codebase Documentation (100K-1M LOC)
text
LARGE CODEBASE
│
▼
claude-code-project-memory ► Hierarchical CLAUDE.md setup
│ (root + subdirectory docs)
├─► Root CLAUDE.md ────────► Architecture, conventions
├─► Subdirectory docs ─────► Module-specific context
├─► AGENTS.md symlink ─────► Cross-platform support
│
▼
qa-docs-coverage ──────────► Audit existing documentation
│
▼
docs-codebase ─────────────► Fill critical gaps
│
▼
LLM-READY CODEBASE
Skill Chains
Chain: Complete QA Setup
qa-testing-strategy → qa-testing-playwright → qa-api-testing-contracts
↓
qa-resilience → qa-observability → qa-debugging
↓
qa-refactoring → qa-docs-coverage
Chain: Incident Response
qa-debugging → qa-observability → qa-resilience → qa-refactoring
Chain: Mobile App Testing
qa-testing-strategy → qa-testing-mobile → qa-testing-ios (if iOS) → qa-testing-android (if Android)
Quality Gates
Pre-Release Checklist
| Gate | Skill | Criteria |
|---|
| Test coverage | | Coverage targets aligned to risk and critical paths |
| E2E passing | | Critical paths green |
| API contracts | | Schema validation passing |
| Error handling | | Circuit breakers configured |
| Monitoring | | SLOs defined, alerts set |
| Docs | | API + README complete |
Post-Incident Checklist
| Gate | Skill | Action |
|---|
| Root cause | | Document findings |
| Regression test | | Add test for failure mode |
| Prevention | | Add/tune circuit breaker |
| Visibility | | Add missing traces/alerts |
Routing Matrix
| User Intent | Primary Skill | Supporting Skills |
|---|
| Plan tests | | , |
| Write E2E | | |
| Test mobile | , , or | |
| Test API | | |
| Test agent | | |
| Debug issue | | , |
| Setup monitoring | | |
| Add resilience | | |
| Refactor code | | |
| Audit docs | | |
| Large codebase setup | claude-code-project-memory
| , |
Cross-Router Handoffs
To router-engineering
When user needs implementation:
- "Build the feature" → Route to or
- "Implement the fix" → Route to relevant engineering skill
To router-operations
When user needs deployment/infra:
- "Deploy to production" → Route to
- "Setup CI/CD" → Route to
From router-operations
When operations router detects QA needs:
- "Test strategy" → Route here
- "Debug production issue" → Route here
- "Add resilience" → Route here
Quick Reference Commands
| Need | Do This |
|---|
| Test strategy | → |
| E2E tests | → |
| iOS tests | → |
| Android tests | → |
| Mobile tests | → |
| API tests | → |
| Agent tests | → |
| Debug issue | → |
| Monitoring | → |
| Resilience | → |
| Refactoring | → |
| Doc quality | → |
Related Routers
| Router | Relationship |
|---|
| Parent router; includes QA + DevOps + git |
| Handoff target for implementation tasks |
| Handoff target for business/product questions |