danieldekay/ai-ops/openspec-repository-audit-workflow
- community
Checking that the SKILL.md file is still in the repository.
End-to-end repository architecture audit workflow using OpenSpec changes: route catalog discovery, DRF viewset analysis, Clean Architecture layer validation, bridge file auditing, and spec-drift checks. Works with lean-ctx compressed token contexts across Django/Svelte (or similar layered) projects. Consolidates the former openspec-audit-repository-architecture skill.
Install
npx vskill@latest install danieldekay/ai-ops/openspec-repository-audit-workflowSKILL.md
OpenSpec Repository Audit Workflow
Consolidates the former openspec-audit-repository-architecture (identical description, drifted body). One audit workflow.
When to Use
Comprehensive repository architecture audits, analyzing OpenSpec changes, validating Clean Architecture boundaries, or systematically auditing layered Django/Svelte projects.
Procedure
1. Setup and Context
- Identify target repository and scope (modules or entire codebase).
- Check
openspec/changes/structure; read the change's context files
(design.md, proposal.md, specs/, tasks/).
- Load lean-ctx compressed token contexts for large codebases
(lean-ctx compose "<task>", token-efficient directory exploration).
2. Route Catalog Discovery
- Start discovery with
orient "<task>". - Inventory: schema, routes, env vars, UI components, middleware.
- Locate the root URL config and all
include()sub-routers and DRF
DefaultRouter registrations.
- Extract supported HTTP methods (metadata endpoints first; fall back to
class-level http_method_names inspection when absent).
- Build a Markdown route catalog: method, URL pattern, view class/function,
owning spec domain. Flag routes with missing method classifications.
3. DRF Viewset Analysis
- Proper inheritance (APIView/ViewSet), serializer usage and validation,
permission classes and authentication, queryset optimization, response formatting consistency.
4. Clean Architecture Validation
- Dependency rule: Domain ← Application ← Infrastructure/Presentation,
never reversed.
- Domain layer has zero framework imports; protocols in application layer;
repository implementations in infrastructure layer.
5. Bridge File Auditing
- Examine high-connectivity files crossing layer boundaries.
- Verify proper abstractions/interfaces; check circular dependencies;
confirm infrastructure doesn't leak into domain.
- Distinguish NECESSARY coupling from problematic coupling — bridge files
may serve legitimate purposes.
6. Spec-Gen Integration and Drift
- Review
.spec-gen/analysis/SUMMARY.mdfor architectural findings. - Validate spec inventory against the actual implementation; identify gaps.
- Run
check_spec_driftbefore finalizing the audit.
7. Documentation and Reporting
- Generate architecture violation reports and layer-boundary crossing docs.
- Produce a Clean Architecture compliance report with refactoring
recommendations and migration plans for problem areas.
- Update the OpenSpec change's task progress and remaining counts.
Pitfalls
- Context switching between Django and Svelte project contexts.
- Token compression: use lean-ctx modes appropriately to avoid information loss.
- DRF viewsets without metadata endpoints — fall back to class inspection.
- Missing OpenSpec changes directory structure; unvalidated API endpoints;
domain layer with framework imports; circular module dependencies.
Verification
check_spec_driftrun before finalizing.- All route mappings validated; no architecture violations unresolved.
- All imports follow the dependency rule.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/openspec-repository-audit-workflow/SKILL.md
Popularity
- Repository stars
- 1
- Repository forks
- 2
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/danieldekay/ai-ops/openspec-repository-audit-workflow)