Use this skill as the root router for a language-agnostic code quality workflow.
Public Workflow Surface
Expose only two primary workflows:
feature-buildfeature-review
Do not present internal helpers, detectors, or scanners as primary user-facing workflows.
Source Of Truth
Always read and update these project artifacts first:
.codeguard/REPORT.md.codeguard/PLAN.md.codeguard/TASKS.md.codeguard/feature-specs/*.spec.md.codeguard/reviews/*.review.md
Never rely on chat history as the workflow memory.
Workflow Routing
For building a new feature from scratch:
- read
subskills/feature-build/SKILL.md
For reviewing, improving, refactoring, or fixing an existing feature:
- read
subskills/feature-review/SKILL.md
Internal Helpers
Use internal scripts for detection and analysis:
scripts/codeguard_workflow.py— main orchestratorscripts/language_detector.py— detect language, framework, toolchainscripts/dependency_auditor.py— audit deps for risk, cost, weight, deprecationscripts/pattern_scanner.py— scan for anti-patterns per languagescripts/performance_analyzer.py— find N+1 queries, missing pagination, heavy importsscripts/security_scanner.py— find hardcoded secrets, injection patterns, misconfigsscripts/cost_estimator.py— detect pay-as-you-go services, unbounded calls, scaling trapsscripts/test_analyzer.py— evaluate test coverage, quality, and missing tests
Use references as domain knowledge:
references/anti-patterns.mdreferences/dangerous-dependencies.mdreferences/performance-rules.mdreferences/testing-standards.mdreferences/cost-risk-catalog.mdreferences/security-checklist.md
Non-Negotiables
- Persist all findings into
.codeguard/artifacts. - Detect language and framework before running any analysis.
- Load only the rules relevant to the detected stack.
- Always check for dangerous dependencies, cost traps, and security holes.
- Generate actionable tasks, not vague warnings.
- Every finding must have a severity (critical, warning, info) and a fix suggestion.
- Read current code before generating recommendations.
- Keep helper commands internal; the visible experience is
feature-buildandfeature-review. - Let the Python scripts do the heavy detection work before asking any questions.
- Update
.codeguard/TASKS.mdso a fresh agent can resume safely. - Before building any feature, the agent MUST read
.codeguard/REPORT.mdto understand known risks. - Every feature spec must include a quality checklist derived from the scan findings.