ArchSutra AI GitHub

ArchSutra AI / Start here

Get started in 5 minutes

From zero to a readable architecture report in five minutes: pick your path, run one command, open the report, then bring in your AI IDE and CI.

Version 0.1.5 · Source: docs/guides/getting-started.md

By the end of this page you will have an audit report you can open in a browser, you will know what each part means, and you will know the next step for your situation. You do not need an account, an API key or network access for the first four steps.

Tip. Short on time? Run step 1 and step 2, then read Reading a report. That alone is a useful 3 minutes.

Pick your path#

Start from what you want, not from the tool.

flowchart TD
  start(["What do you want?"]) --> q1{"Do you already<br/>have code?"}
  q1 -- "Yes, I need to understand it" --> audit["Run: archsutra audit .<br/>then open the HTML report"]
  q1 -- "No, I am designing something new" --> design["Install the skills,<br/>ask Prime to design it"]
  audit --> q2{"What next?"}
  q2 -- "Stop it getting worse" --> ci["Add the CI gate<br/>(step 5)"]
  q2 -- "Fix the big problems" --> mod["Ask Prime for a<br/>phased roadmap"]
  q2 -- "Is this part safe?" --> tm["Use the threat-modeling skill"]
  design --> adr["You get options, an ADR,<br/>diagrams and a thin-slice plan"]
Diagram (Mermaid). If it does not render, the source is shown above.

Step 1. Run your first audit#

You need Node.js 20 or newer. From the root of any project:

npx archsutra-ai audit .

On Windows npx archsutra-ai works from version 0.1.3. The command reads your files, never runs them, never uses the network, and prints a report. Here is the real output for the small sample project in this repository:

Real output. Trimmed from archsutra audit fixtures/brownfield-monolith.
# Architecture Audit Report

## Summary
- Files scanned: 7
- Stack observed: TypeScript, Node.js
- Findings: 12 (critical 0, high 3, medium 7, low 2, info 0)

## Scorecard
| Category        | Rating       |
|-----------------|--------------|
| Security        | weak         |
| Maintainability | adequate     |
| Operability     | adequate     |
| Supply chain    | adequate     |
| Reliability     | not assessed |
| Performance     | not assessed |
| Cost            | not assessed |
Why it matters. Notice not assessed. A static scan cannot see traffic, incidents or your cloud bill, so it says so instead of guessing. A tool that scores everything is a tool that makes things up.

Step 2. Open the report as a web page#

Reports that people can open are reports that get read. Write the full set, Markdown and HTML:

npx archsutra-ai audit . --output arch-report
  index.html
  current-state.md
  current-state.html
  audit-report.md
  audit-report.html
  findings.json
  findings.sarif
  architecture-register.json
Open index.html in a browser. Each report also has a Markdown file beside it.

Open arch-report/index.html. You get severity cards, a filter by severity, and collapsible findings. Use the Markdown files in pull requests, the JSON in scripts, and the SARIF in GitHub code scanning.

flowchart LR
  A["archsutra audit . --output arch-report"] --> H["audit-report.html<br/>for people"]
  A --> M["audit-report.md<br/>for pull requests"]
  A --> J["findings.json<br/>for scripts"]
  A --> S["findings.sarif<br/>for code scanning"]
  A --> C["current-state.html and .md<br/>maps and diagrams"]
Diagram (Mermaid). If it does not render, the source is shown above.
Note. --output must stay inside the project folder. That is a safety rule: the tool will not write outside the project you pointed it at.

Step 3. Understand what you are looking at#

Every finding has the same shape, so you can learn it once.

Anatomy of one finding: stable ID, severity and confidence, evidence with file and line, impact, fix, verification and acceptanceAnatomy of one finding: stable ID, severity and confidence, evidence with file and line, impact, fix, verification and acceptance
Anatomy of one finding: stable ID, severity and confidence, evidence with file and line, impact, fix, verification and acceptance

Read it top to bottom: what (title), how bad (severity), how sure (confidence), where (file and line), so what (impact), now what (fix), how do I know (verify and accept). If you cannot open the cited line and see the problem, treat the finding as wrong and tell us (false-positive report).

Step 4. Add your AI IDE (optional, where the depth is)#

The CLI gives evidence. Your IDE's own model adds judgment: why a design is risky, what to change first, what to design next. ArchSutra's skills tell the model how to do that without making things up.

Pick one host (several hosts read the same folders, so installing more than one duplicates skills):

Your IDECommand
Claude Codenpx archsutra-ai install --host claude --target .
Cursornpx archsutra-ai install --host cursor --target .
OpenAI Codexnpx archsutra-ai install --host codex --target .
GitHub Copilotnpx archsutra-ai install --host copilot --target .
Gemini CLInpx archsutra-ai install --host gemini --target .

Preview first with --dry-run; undo any time with uninstall. Then ask:

ArchSutra Prime: audit this repository's architecture. Establish what the code actually does first, then give findings with file and line evidence, severity and confidence, prioritized fixes and a phased roadmap. Stay read-only and label unknowns.
sequenceDiagram
  participant You
  participant IDE as Your AI IDE
  participant Prime as ArchSutra Prime
  participant CLI as archsutra CLI
  You->>IDE: Ask for an architecture audit
  IDE->>Prime: Loads the architecture-audit skill
  Prime->>CLI: archsutra audit . --json
  CLI-->>Prime: Evidence (offline, read-only)
  Prime->>Prime: Opens each cited file and line, drops what it cannot reproduce
  Prime-->>You: Report with evidence labels, roadmap and open questions
Diagram (Mermaid). If it does not render, the source is shown above.
Warning. Layouts for all five IDEs follow each vendor's documentation, but a live session in each has not been recorded yet. If a skill does not appear, run archsutra doctor . and tell us which IDE and version; we track it in the smoke test log.

Step 5. Stop regressions in CI#

Add one line to your pipeline so the same problems cannot come back:

- run: npx --yes archsutra-ai audit . --fail-on high

The step passes when there are no high or critical findings and fails (exit code 1) when there are. On a codebase that already has findings, start with a baseline instead so only new problems fail the build; see CI recipes.

If something goes wrong#

What you seeWhyFix
archsutra is not recognized on WindowsOlder version of the packageUse npx archsutra-ai ... with version 0.1.3 or newer
--output must stay inside the project directorySafety ruleUse a relative folder such as arch-report
Blocked: N conflicting file(s) on installA file already exists and was not installed by ArchSutraRun with --dry-run, then --force (originals are backed up)
Skill not found in your IDELayout or version mismatcharchsutra doctor ., then open a smoke-test report
Report says TRUNCATEDRepository is larger than the scan limitsAudit a subfolder, or see scan limits

Where to go next#

Edit this page on GitHub