Universal Cross-Agent Engineering Framework for AI Coding Agents
Sagarithm Kit encodes the collective wisdom, disciplined practices, and architectural rigor of experienced software architects and engineers into an agent-agnostic framework. It equips AI coding agents with the engineering environment, protocol tools, and boundary policies required to produce production-grade software.
- 🌐 Official Website & Live Studio: kit.sagarithm.in
- 📦 npm Registry: npmjs.com/package/sagarithm-kit
- 📦 GitHub Packages: @sagarithm/sagarithm-kit
- ☕ Support: paypal.me/thesagarithm
AI coding agents should not enter a codebase with only a user prompt. They should enter with:
- Truth-Driven Ideation: Stress-testing feasibility, non-goals, and operational bottlenecks before code generation begins.
- Project Context & Topology: Understanding existing abstractions, modules, call topologies, and public APIs.
- Engineering Principles & Coding Standards: Strict adherence to architectural invariants and clean code paradigms.
- 17 Core Engineering Skills & 99 Specialist Personas: Modular, discipline-specific procedural knowledge and autonomous specialist agent roles.
- Behavioral Policies: Non-negotiable constraints preventing redundant folder creation, unvetted dependencies, and architectural drift.
- Disciplined Workflows: Phased lifecycles (Understand -> Plan -> Implement -> Verify -> Document) with hard verification gates.
- Native Protocol Interfaces (MCP): Providing runtime tools directly to LLMs for verification, entropy secret scanning, and AST queries.
- Production Mindset: Favoring reliability, security, maintainability, and operational correctness over quick-and-dirty generation.
Run directly without installation via npx:
# Turnkey starter init: auto-provisions 116 skills & 99 specialist personas into .agents/
npx sagarithm-kit init --starter
# Run the native Model Context Protocol (MCP) server for Claude Desktop / Cursor
npx sagarithm-kit mcp
# Stress-test an idea before building (Truth-Driven Engineering)
npx sagarithm-kit validate "Decentralized real-time multiplayer state engine"
# Compute the 100-point Codebase Health Index
npx sagarithm-kit health
# Apply a curated engineering preset (fullstack-web, api-backend, systems-core, ai-agentic)
npx sagarithm-kit preset apply fullstack-web
# Compile canonical specifications into native agent configurations
npx sagarithm-kit sync
# Run the Zero Assumed Success verification gate
npx sagarithm-kit verifyOr install globally:
npm install -g sagarithm-kit
sagarithm --helpGoogle Antigravity is the development environment, NOT the target platform. Sagarithm Kit must not become dependent on Antigravity-specific functionality.
Sagarithm Kit maintains a single canonical source of truth that compiles down to configurations for any supported target agent:
- Google Antigravity
- Cursor
- Claude Code & Claude Desktop
- VS Code / GitHub Copilot
- Windsurf
- OpenAI Codex
- Any Model Context Protocol (MCP) Client
- Canonical Engineering Knowledge - Architectural principles, domain models, coding standards.
- Canonical Skills & Personas - 17 core disciplines & 99 specialist personas (116 skills in
.agents/skills/). - Canonical Policies - Non-negotiable boundaries answering "What must or must not be done".
- Canonical Workflows - Temporal lifecycles answering "What sequence of steps and gates to follow".
- Project Context - Workspace manifests, dependency topologies, and AST coupling analytics.
- Agent-Specific Adapters - One-way compilation pipelines translating canonical specifications into native agent configurations.
- Model Context Protocol (MCP) Server - Stdio JSON-RPC 2.0 interface exposing runtime architectural tools directly to AI models.
For the complete architectural design, see ARCHITECTURE.md.
The foundational laws governing all agent interactions are codified in the Engineering Constitution:
- Engineering Principles
- Architecture Principles
- Coding Standards
- Testing Principles
- Security Principles
- Documentation Standards
- Git Standards
- Release Standards
The complete suite of 17 core canonical skills is cataloged in skills/README.md:
| Domain | Skill | Identifier | Description |
|---|---|---|---|
| Ideation | Idea Validation & Truth-Driven Engineering | ideation.idea-validation |
Stress-tests concepts; forbids blind AI compliance; demands truth on feasibility and non-goals. |
| Architecture | Specification-Driven Architecture | architecture.spec-driven-development |
Formal bounded contexts, contract interfaces, state machines, and acceptance criteria. |
| Architecture | System Design & Modularity | architecture.system-design |
Highly cohesive, loosely coupled modules with explicit public interfaces and acyclic graphs. |
| Frontend | Frontend Architecture & UI/UX Engineering | frontend.ui-engineering |
Component architecture, state machines, accessibility (WCAG 2.2 AA), and Core Web Vitals optimization. |
| Backend | Backend Architecture & Distributed Systems | backend.distributed-systems |
Resilient backend architectures, strict API contracts, idempotent operations, and failure tolerance. |
| Database | Database Architecture & Data Modeling | database.architecture-and-modeling |
Relational & document schemas, zero-downtime migrations, B-Tree/GIN indexing, and ACID boundaries. |
| DevOps / SRE | DevOps, SRE & Cloud Deployment Governance | devops.sre-observability |
Deployment lifecycles, hermetic containerization, CI/CD verification gates, and OpenTelemetry observability. |
| AI / ML | Applied AI Systems & RAG Architecture | ai.systems-and-rag |
Production AI architectures, deterministic tool calling, token conservation, and RAG pipelines. |
| Performance | Systems Performance & Profiling Engineering | performance.profiling-and-optimization |
Performance bottlenecks, CPU hotspots, memory leaks, and algorithmic complexity optimization. |
| Lifecycle | Atomic Planning & Task Breakdown | lifecycle.planning-and-task-breakdown |
Hermetic, sequentially verifiable implementation slices with rollback checkpoints. |
| Quality | Clean Code & Quality Standards | quality.coding-standards |
Expressive, type-safe code with strict error handling, discriminated unions, and concurrency safety. |
| Quality | Rigorous Code Review & Quality Defense | quality.code-review-and-quality |
Senior-engineer scrutiny, zero-leak defense, minimal blast radius, anti-rationalization pushback. |
| Security | Secure Development & Vulnerability Prevention | security.secure-development |
Defense-in-depth, input sanitization, Shannon entropy secret isolation ( |
| Testing | STLC & Enterprise Quality Assurance | testing.stlc-quality-assurance |
Full Software Testing Life Cycle execution, test pyramid governance, mutation testing, regression gates. |
| Testing | Test-Driven Verification | testing.test-driven-verification |
Deterministic automated test suites, property-based invariants, and mutation verification. |
| Documentation | Architectural Decision Records | documentation.architectural-decision-records |
MADR 3.0 decision matrices capturing consequential choices, alternatives, and trade-offs. |
| Delivery | Production Shipping & Release Governance | delivery.shipping-and-launch |
Verification gates, SemVer versioning, changelog synchronization, and CI/CD attestation. |
Autonomous Specialist Roster: In addition to the 17 core skills, Sagarithm Kit v1.2.0 includes 99 specialized agent personas (AI data remediation, API platform, firmware, security, identity, mobile, etc.) auto-provisioned to
.agents/skills/,.agents/agents/, and.copilot/agents/.
The project-wide boundary policies are cataloged in policies/README.md:
- Directory Creation Policy
- File Creation Policy
- Dependency Management Policy
- Change Scope Policy
- Testing Enforcement Policy
- Security Boundary Policy
- Documentation Synchronization Policy
Sagarithm Kit includes a native Model Context Protocol (MCP) server operating over standard input/output (stdio JSON-RPC 2.0). It equips AI models directly with 6 architectural tools:
{
"mcpServers": {
"sagarithm": {
"command": "npx",
"args": ["-y", "sagarithm-kit", "mcp"]
}
}
}-
sagarithm_verify: Run empirical multi-vector verification gate (Static, Security, Architecture, Behavioral, Documentation). -
sagarithm_scan_secrets: Scan source code for Shannon entropy leaks ($H \ge 4.5$ ) and credential signatures. -
sagarithm_query_graph: Inspect AST symbols, calculate blast-radius, and evaluate Martin instability. -
sagarithm_validate_idea: Stress-test concepts against operational bottlenecks and anti-goals. -
sagarithm_health: Return composite 100-point codebase health index. -
sagarithm_get_skill: Retrieve canonical skill instructions and anti-rationalization tables.
Empirical multi-vector verification gate enforcing the constitutional Zero Assumed Success principle:
- Validation Specification: Verification state machine (
ASSUMED->IMPLEMENTED->TESTED->VERIFIED). - Canonical Rules:
- Secret Hygiene Patterns (Shannon entropy scanner + token regex).
- Architectural Fitness Rules (anti-pattern directory blocker, graph cycle detector).
- Verification Vectors (Static, Security, Architecture, Behavioral, Documentation).
- Execution Harness:
sagarithm audit --deep: Full repository secret and architectural fitness audit.sagarithm verify --strict: Multi-vector execution gate with empirical evidence collection and.sagarithm/audit-report.jsongeneration.
Decentralized distribution and turn-key engineering profiles for AI coding agents:
- Registry Specification: Architecture, package anatomy, and SHA-256 integrity governance.
- Registry Documentation: Presets, search, and packaging workflows.
- Curated Presets:
fullstack-web: Next.js, React, Node, Web APIs, Tailwind, Client/Server state.api-backend: Resilient REST, GraphQL, Outbox pattern, Pact contract testing.systems-core: High-integrity systems, low-latency, zero-alloc, exhaustive typing.ai-agentic: Multi-agent orchestration, prompt isolation, blast-radius containment.
The @sagarithm/cli tool is documented in cli/README.md:
sagarithm init [--starter]: Workspace manifest generation and turnkey skill initializationsagarithm mcp [--config <target>]: Stdio Model Context Protocol serversagarithm validate "<idea>": Truth-driven feasibility and bottleneck stress-testingsagarithm health: 100-point composite codebase health dashboardsagarithm preset: List, inspect, and apply curated engineering presets (list,show,apply)sagarithm sync: Multi-agent compiler (--target cursor,--target claude, etc.)sagarithm context: Project graph generator and AST topology query engine (stats,find,blast-radius,orphans)sagarithm doctor: Structural sprawl and repository health checksagarithm audit: Pre-commit policy, secret, and architectural fitness scanner (--deep,--strict,--json)sagarithm verify: Zero-Assumed-Success multi-vector execution verification gate (--strict,--suite,--json)sagarithm registry: Search canonical catalog and package artifacts with SHA-256 integrity (search,pack)
- Canonical Terminology & Taxonomy
- Canonical Meta-Specification
- Contribution Guidelines
- Security Policy
Apache License 2.0. See LICENSE for details.