| name | stacks |
| description | Stack-Aware Intelligence — auto-detects project tech stack (Python, TypeScript,
Rust, PHP) from manifest files, routes context to domain-relevant skills, and
selects specialist review agents. Covers detection, context routing, knowledge
profiles, and enforcement agents. Trigger keywords: stack detection, context
router, language profile, framework checklist, specialist agent, stack awareness.
|
| user-invocable | false |
| disable-model-invocation | false |
Stack-Aware Intelligence System
Auto-detects project tech stack and loads domain-relevant context for reviews, audits, planning, and work.
Architecture (4 Layers)
Layer 0: Context Router — computeContextManifest() decides WHAT to load
Layer 1: Detection Engine — detectStack() scans manifests for evidence
Layer 2: Knowledge Skills — 20 reference docs (languages, frameworks, databases, libraries, patterns)
Layer 3: Enforcement Agents — 13 specialist reviewers with unique finding prefixes
How It Works
-
Detection: detectStack() scans manifest files (pyproject.toml, package.json, Cargo.toml, composer.json) to identify languages, frameworks, databases, and libraries with a confidence score (0.0-1.0).
-
Routing: computeContextManifest() classifies changed files into domains (backend, frontend, database, testing, infra, docs), then selects which reference docs and agents to load based on the detected stack and task type.
-
Loading: Selected reference docs are passed as Read() directives to workers and reviewers. Only domain-relevant docs are loaded (e.g., a frontend-only PR won't load Python/SQLAlchemy skills).
-
Enforcement: Specialist agents (python-reviewer, fastapi-reviewer, design-system-compliance-reviewer, etc.) are conditionally summoned when their stack is detected AND domain matches, producing findings with unique prefixes (PY-, FAPI-, etc.).
Key Functions
detectStack(repoRoot)
See detection.md for the full algorithm.
Input: Repository root path
Output: { primary_language, languages[], frameworks[], databases[], libraries[], tooling[], confidence, evidence_files[] }
computeContextManifest(task_type, file_scope, detected_stack, task_description)
See context-router.md for the full algorithm.
Input: Workflow type (review/audit/plan/work/forge), changed files, detected stack, task description
Output: { domains, skills_to_load[], skills_excluded{}, agents_selected[], loading_strategy }
Supported Stacks
See stack-registry.md for all supported languages, frameworks, databases, and libraries.
| Category | Supported |
|---|
| Languages | Python, TypeScript, Rust, PHP |
| Frameworks | FastAPI, Django, Laravel, SQLAlchemy, React, Vue.js, Next.js, Vite |
| Databases | PostgreSQL, MySQL |
| Libraries | Pydantic, dry-python/returns, Dishka, Pinia, Vue Router |
| Patterns | TDD, DDD, DI |
Configuration
stack_awareness:
enabled: true
confidence_threshold: 0.5
max_stack_ashes: 3
References
- detection.md — Stack detection algorithm
- stack-registry.md — Supported stacks registry
- context-router.md — Smart context loading algorithm
- languages/ — Language profiles (Python, TypeScript, Rust, PHP)
- frameworks/ — Framework checklists (FastAPI, Django, Laravel, SQLAlchemy, React, Vue.js, Next.js, Vite)
- databases/ — Database patterns (PostgreSQL, MySQL)
- libraries/ — Library patterns (Pydantic, Returns, Dishka)
- patterns/ — Cross-cutting patterns (TDD, DDD, DI)