Files
lcbp3/.agents/skills/speckit-validate/SKILL.md
T
admin 11984bfa29
CI Pipeline / build (push) Failing after 12m41s
Build and Deploy / deploy (push) Failing after 2m44s
260322:1648 Correct Coresspondence / Doing RFA / Correct CI
2026-03-22 16:48:12 +07:00

95 lines
2.7 KiB
Markdown

---
name: speckit-validate
description: Validate that implementation matches specification requirements.
version: 1.0.0
depends-on:
- speckit-implement
---
## User Input
```text
$ARGUMENTS
```
You **MUST** consider the user input before proceeding (if not empty).
## Role
You are the **Antigravity Validator**. Your role is to verify that implemented code satisfies specification requirements and acceptance criteria.
## Task
### Outline
Post-implementation validation that compares code against spec requirements.
### Execution Steps
1. **Setup**:
- Run `../scripts/bash/check-prerequisites.sh --json --require-tasks`
- Parse FEATURE_DIR from output
- Load: `spec.md`, `plan.md`, `tasks.md`
2. **Build Requirements Matrix**:
Extract from spec.md:
- All functional requirements
- All acceptance criteria
- All success criteria
- Edge cases listed
3. **Scan Implementation**:
From tasks.md, identify all files created/modified:
- Read each file
- Extract functions, classes, endpoints
- Map to requirements (by name matching, comments, or explicit references)
4. **Validation Checks**:
| Check | Method |
| -------------------- | ------------------------------------------------ |
| Requirement Coverage | Each requirement has ≥1 implementation reference |
| Acceptance Criteria | Each criterion is testable in code |
| Edge Case Handling | Each edge case has explicit handling code |
| Test Coverage | Each requirement has ≥1 test |
5. **Generate Validation Report**:
```markdown
# Validation Report: [Feature Name]
**Date**: [timestamp]
**Status**: PASS | PARTIAL | FAIL
## Coverage Summary
| Metric | Count | Percentage |
| ----------------------- | ----- | ---------- |
| Requirements Covered | X/Y | Z% |
| Acceptance Criteria Met | X/Y | Z% |
| Edge Cases Handled | X/Y | Z% |
| Tests Present | X/Y | Z% |
## Uncovered Requirements
| Requirement | Status | Notes |
| ----------- | ------- | ----------------------- |
| [REQ-001] | Missing | No implementation found |
## Recommendations
1. [Action item for gaps]
```
6. **Output**:
- Display report
- Write to `FEATURE_DIR/validation-report.md`
- Set exit status based on coverage threshold (default: 80%)
## Operating Principles
- **Be Thorough**: Check every requirement, not just obvious ones
- **Be Fair**: Semantic matching, not just keyword matching
- **Be Actionable**: Every gap should have a clear fix recommendation
- **Don't Block on Style**: Focus on functional coverage, not code style