skills/accelint-architecture-doc/SKILL.md
Generate or update an ARCHITECTURE.md living document for any codebase. Use this skill whenever a user mentions "architecture.md", "ARCHITECTURE.md", "document my architecture", "architecture overview", "system architecture", "generate architecture doc", "create architecture file", "update architecture", "architecture diagram", or wants a technical overview of how their project is structured. Make sure to use this skill whenever users want to document how their system works — even if they phrase it as "write up the system", "document the tech stack", "create a technical overview", or "help me describe the architecture". Always prefer this skill over ad-hoc architecture documentation.
npx skillsauth add gohypergiant/agent-skills accelint-architecture-docInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Generate or update a living ARCHITECTURE.md for the current codebase — a document that gives agents and engineers an instant, complete picture of how the system is structured, what it uses, and how it deploys.
<!-- TODO: fill in --> rather than guessing. Wrong infrastructure docs cause real confusion during incidents.node_modules, dist, .git, __pycache__) and annotate each entry with its architectural role.<!-- TODO --> — scan aggressively first. Most sections can be at least partially filled through inference. A document full of TODOs appears complete but misleads every reader.pnpm-workspace.yaml, turbo.json, nx.json, lerna.json, or workspaces field in package.json. If inside a package, check whether a root-level ARCHITECTURE.md already exists.Run both steps before any scanning or interview. Announce findings and confirm mode with the user.
Determine whether the current working directory is a monorepo root or a package inside a monorepo.
Monorepo signals to check:
| Signal | File |
|--------|------|
| PNPM workspaces | pnpm-workspace.yaml |
| npm/Yarn workspaces | package.json → workspaces field |
| Turborepo | turbo.json |
| Nx | nx.json |
| Lerna | lerna.json |
| Package inside monorepo | Parent dirs contain any of the above |
If at the monorepo root:
If inside a monorepo package:
"I found a root-level ARCHITECTURE.md at [path]. I'll use it as context and generate a package-specific doc here that references it rather than duplicating shared infra." The package-level doc should include a header reference:
<!-- Part of monorepo: see [relative path to root ARCHITECTURE.md] for system-wide architecture -->
If not a monorepo: proceed normally — ARCHITECTURE.md covers the whole project.
Before detecting ARCHITECTURE.md state, check for related onboarding documents:
This reduces scanning work and ensures consistency with the project's defined stack.
Does ARCHITECTURE.md exist at the target location?
│
├── No → MODE 1: Create
│ Run Phase 1 → Phase 2 → Phase 3 in full.
│
└── Yes → Read the file fully, then assess:
│
├── Empty or near-blank (< ~10 meaningful lines)?
│ → MODE 1: Create (confirm first)
│
├── Follows the template structure?
│ (Has ≥3 of: ## 1. Project Structure, ## 2. High-Level
│ System Diagram, ## 3. Core Components, ## 4. Data Stores,
│ ## 6. Deployment & Infrastructure)
│ → MODE 2: Refresh
│ Drift detection + targeted questions for changed or
│ missing sections only.
│
└── Has real content but does NOT follow the template?
→ MODE 3: Restructure (offer proactively — see below)
MODE 3: Restructure — When the file has real content in an unrecognised shape, surface this immediately and offer options before doing anything else:
"ARCHITECTURE.md exists but doesn't follow the standard template structure. I recommend restructuring it — this makes it consistent for agents and engineers onboarding to the codebase. How would you like to proceed?
(a) Restructure (recommended) — I'll import your existing content into the 11-section template, fill gaps with codebase scanning, and show a full preview before writing anything.
(b) Append — I'll add the missing template sections below your existing content without modifying what's already there.
(c) Dry run — I'll show exactly what the restructured doc would look like with no filesystem changes. Use this to evaluate fit before committing."
If (a) is chosen: carry all existing content forward into the appropriate template sections. Flag any content that doesn't map cleanly — present it to the user and ask where it belongs rather than silently dropping it.
Spawn discovery subagents in parallel — don't scan serially. Each agent focuses on one domain and returns structured findings. Wait for all agents to complete, then merge results before Phase 2.
Spawn these agents simultaneously:
Agent A — Project Identity & Structure
node_modules, dist, .git, __pycache__, .next, build)Agent B — Tech Stack & Components
package.json (frontend and backend deps), requirements.txt / pyproject.toml, go.mod, Cargo.toml, build.gradlenext.config.*, vite.config.*, nuxt.config.*, angular.json, svelte.config.*server.ts, app.py, main.go, Application.java, config/application.rbdocker-compose.yml — services, ports, environment vars, inter-service dependenciesAgent C — Infrastructure, CI/CD & Deployment
terraform/, pulumi/, cdk/, serverless.yml, k8s/ or kubernetes/Dockerfile* (per service), docker-compose.yml deployment config.github/workflows/, .circleci/, Jenkinsfile, .gitlab-ci.yml, Procfile*.aws.json, .aws/, gcp/, azure/, base images in DockerfilesAgent D — Data, Security & External APIs
prisma/schema.prisma, alembic/, migrations/, ORM config, DATABASE_URL in .env.example, Redis/Kafka/RabbitMQ deps.env.example key prefixes (STRIPE_, SENDGRID_, TWILIO_, OPENAI_, etc.), SDK packages in depsAgent E — Testing & Code Quality (can run concurrently with the others)
jest.config.*, vitest.config.*, pytest.ini, pyproject.toml [tool.pytest], Playwright config, Cypress config.eslintrc*, biome.json, .prettierrc*, mypy.ini, ruff.toml, sonar-project.propertiesMakefile, CONTRIBUTING.md, docker-compose.yml dev targetsAfter all agents complete: merge their findings into a unified discovery map. Tag each field as INFERRED [source] or UNKNOWN. Fields tagged UNKNOWN become Phase 2 interview questions.
Ask only about what discovery couldn't determine. Group related questions into natural conversational turns — never dump all questions at once.
Turn 1 — Gaps in Components (if services or components were unclear)
Turn 2 — Infrastructure & Deployment (only if cloud provider or deployment model is UNKNOWN)
Turn 3 — Security (only if auth mechanism is UNKNOWN)
Turn 4 — Roadmap & Future Plans (always ask — cannot be inferred)
Turn 5 — Identity & Glossary (if not found in README or package.json)
Show a labeled preview of the complete ARCHITECTURE.md before writing. Mark each field:
# inferred from [file] — for auto-detected values<!-- TODO: fill in --> — for unresolved fieldsAsk: "Does this look right? Any sections to correct before I write?"
After confirmation, write to ARCHITECTURE.md at the target location (root or package dir), stripping inference source comments — they are for review only, not the final file. For openspec/config.yml references: only include them if the file actually exists (checked in Step 1.5). Do not add references to files that don't exist.
Update agent behavior doc if present — if Agent A found AGENTS.md or CLAUDE.md, check whether it references ARCHITECTURE.md. If not, append a reference block to help agents understand the system structure (see instructions below).
Print a brief summary: what was inferred, what was answered directly, which <!-- TODO --> sections still need human input.
<!-- TODO --> markers is actionable. A doc with missing sections silently misleads.Load references/template.md for the full 11-section ARCHITECTURE.md skeleton.
Monorepo package docs: Include the following immediately after the opening heading:
<!-- Part of monorepo: see [../../ARCHITECTURE.md](../../ARCHITECTURE.md) for system-wide architecture -->
Adjust the relative path to point at the actual root ARCHITECTURE.md.
ARCHITECTURE.md is a pure technical document about system structure and should not reference agent behavior files. However, agent behavior files (AGENTS.md or CLAUDE.md) should reference ARCHITECTURE.md since understanding system architecture may inform agent behavior.
After writing ARCHITECTURE.md, if Agent A found AGENTS.md or CLAUDE.md (check in that order):
## System Architecture
For technical architecture details (components, deployment, data stores, tech stack), see [ARCHITECTURE.md](./ARCHITECTURE.md).
@AGENTS.md), update AGENTS.md instead — don't modify the pointer file.tools
Implement QRSPI-planned OpenSpec changes with intelligent parallelization. Use when the user wants to apply a QRSPI change, implement tasks with parallelization, or says "apply this QRSPI change", "implement with parallelization", "run the parallel slices". This skill is specifically designed for changes created via accelint-qrspi that include "Parallelization Strategy" sections in tasks.md. It orchestrates parallel sub-agent execution for independent task slices using OpenSpec CLI workflows. Make sure to use this skill when the user mentions applying QRSPI changes, running parallel implementation, or working on changes with vertical slices.
development
Automate the QRSPI + OpenSpec planning workflow (Questions → Research → Design → Structure) for spec-driven development. Use this skill when the user wants to plan a ticket, start a QRSPI workflow, create a change with QRSPI, or says "plan this with QRSPI", "use QRSPI to plan", "start QRSPI workflow", "create spec-driven change", or asks about planning a feature/change before implementation. This skill handles ONLY the planning phase — it does NOT implement code. After completion, the user continues with /opsx:apply for implementation.
development
Comprehensive TypeScript/JavaScript coding standards focusing on type safety, defensive programming, and code correctness. Use when (1) Writing or reviewing TS/JS code, (2) Fixing type errors or avoiding any/enum/null, (3) Implementing control flow, state management, or error handling, (4) Applying zero-value pattern or immutability, (5) Code review for TypeScript anti-patterns. Covers naming conventions, function design, return values, bounded iteration, input validation. For performance optimization, use accelint-ts-performance skill. For documentation, use accelint-ts-documentation skill.
development
Use when creating or editing a README.md file in any project or package. Recursively parses codebase from README location, suggests changes based on missing or changed functionality, and generates thorough, human-sounding documentation with copy-pasteable code blocks and practical examples.