Sruja — context engineering for software changes
Capture knowledge, retrieve context, verify changes. Sruja scans code, links decision context, reports structural drift, and plugs into Cursor and other agents via MCP. Optional repo.sruja is reviewed intent in Git, not the primary product.
Why Sruja?
The Problem
Most architecture tools make you choose:
- Visual-only tools (Draw.io) – no code, no version control, hard to maintain
- Code-only tools (Mermaid, PlantUML) – no validation, manual diagram updates
- Stale diagrams – architecture drifts from reality, documentation gets outdated
Our Solution
Sruja gives AI assistants and humans evidence-backed context for software changes:
| Feature | What you get |
|---|---|
| Structural scan | Cycles, layer violations, god modules — file-level evidence |
| Task context | focus, ai, and MCP for targeted retrieval |
| Built-in gates | Drift, verification, CI-friendly outputs |
| Optional reviewed intent | repo.sruja when teams want durable intent in Git |
| Derived outputs | Markdown, Mermaid, and other exports when communication needs them |
Who It's For
- Engineering teams who want shared knowledge and safer AI-assisted changes
- Tech leads who want decisions to stay visible at change time
- Platform engineers building guardrails for distributed teams
- AI agents that need grounded repo context before editing
The Core Loop
- Install CLI —
curl -fsSL https://sruja.ai/install.sh | bash - Scan —
sruja start -r .thensruja drift -r . --structural-only --advisory - Retrieve context —
focus,ai, or MCP before edits - Verify —
verify-taskafter edits - Optional — reviewed intent in Git with
repo.sruja
We're ultra simple – minimal surface area, no unnecessary apps or frameworks – and highly functional – what we ship works reliably for its scope.
Stack
- Rust – CLI, engine, LSP, WASM (single language for core)
- VS Code extension – Editor integration (briefing, validation, diagnostics)
- Docs – This book (mdBook, Rust-based; no TypeScript/Node)
New here? Quick start: install CLI, scan current structure, retrieve context, and verify changes. Add reviewed intent only when you want
repo.srujain Git. Optional learning lives separately under Navigate; press/orSto search.
Sruja "Show diagram" in code blocks: Run
just wasm(ormake wasm) from the repo root once, then runjust book-serve(ormake book-serve, or./serve.shfrom the book directory) so the WASM files are copied into the book output.