SYSTEM TOPOLOGY · BLUEPRINT v1.5

End-to-End Closed-Loop Architecture

From a plain-language prompt to an atomic fast-forward merge: your coding agent works inside an isolated Git worktree while the Go binary enforces 42 sub-400ms AST gates before anything touches main.

⚡ The 3-Stage Deterministic Workflow Natural Language Intent ⇄ Compiled Go Engine

From Natural Language Intent to AST-Verified Done

Experience deterministic AI engineering rails without changing how your team builds. You prompt in plain English with zero custom slash commands; your AI agent operates the compiled Go engine underneath.

01 IDLE → PLAN
Invisible Harness & Git Defense Hooks

Install & Initialize Once

Run the 1-liner to install the Go substrate and execute nomos init once in your repo. Scaffolds AGENTS.md / CLAUDE.md, ambient SessionStart hooks (.agents/hooks.json), and self-healing Git defense hooks with zero custom slash commands.

One-Time Repo Bootstrap
curl -fsSL https://sophialabs.ca/install | sh
$ nomos init
▼ substrate execution
$ SessionStart hook → nomos handshake (auto)
🛡️ Machine-Enforced Invariants
  • Trunk branch (main) locked physically read-only
  • Zero custom slash commands or workflow files to memorize
  • Subconscious Nomos Mneme semantic memory rehydrated automatically
02 EDIT → REVIEW
Sandboxed TDD & 42 DoD Gates

Hermetic Worktree & AST Gates

Describe your task in natural language. Your agent automatically mounts an isolated hermetic Git worktree (worktrees/<repo>-<task>), executes the TDD loop, and passes all 42 Go AST quality gates before any code touches staging.

Human PO Intent
chat > "Fix issue #42: add CapBAC token gate"
▼ substrate execution
$ nomos task start SUB-42 → worktrees/repo-SUB-42
nomos verify (42 DoD Gates Passed)
🛡️ Machine-Enforced Invariants
  • Zero branch drift: 100% sandboxed in hermetic worktree
  • TDD Assertion: failing test required before logic changes
  • AST complexity (< 15) & docstring density (>= 10%) enforced
03 REVIEW → SYNC
PO Consent & Atomic Fast-Forward

Walkthrough Review & 2PC Sync

Review the agent's structured walkthrough diff in chat and type "approve". Upon consent, Nomos executes an atomic Two-Phase Commit (2PC) release: fast-forward merge to root, cryptographic Git Notes receipt generation, and hermetic worktree teardown.

Human PO Consent
chat > approve
▼ substrate execution
$ nomos task sync SUB-42 -F .tmp/walkthrough.md
🛡️ Machine-Enforced Invariants
  • Zero unapproved modifications escape to protected trunk
  • Atomic 2PC release with cryptographic Git Notes receipt
  • Hermetic sandbox automatically pruned and cleaned

Beyond Prompt-Based AI: Deterministic Rails vs. Stochastic Prompts

Why prompting an LLM to "follow rules" fails in production, and how compiled binary tooling enforces guaranteed architectural boundaries.

Engineering DimensionUngoverned Agents (Claude Code, Cursor, OpenCode)Nomos & SophiaLabs (Deterministic Harness)
Enforcement Substrate How rules are appliedStochastic Prompt Suggestions (Honor System): The agent is given markdown instructions ("Please run tests", "Please don't edit main"). If the context window degrades, the model skips them without notice.Compiled Go Substrate & OS Hooks: Git pre-commit hooks and machine-enforced gates physically block forbidden mutations. If nomos verify fails, code cannot be checked in.
Working Tree Isolation Multi-agent safetyLive "Dirty" Working Tree: Agents edit files directly inside your active checkout, colliding with human edits, dirtying branches, and breaking running local dev servers.Hermetic Sandboxed Git Worktrees: Every task mounts an isolated directory (worktrees/repo-SUB-123) auto-linked via go.work/workspaces. Parallel agents execute in complete isolation.
Phase Discipline Plan vs. Execution lockUnrestricted Arbitrary Writes: The agent can jump from planning straight into refactoring or deleting source files on a whim without human sign-off.Cryptographic Phase State Locks: Repository files are locked read-only in PLAN. No source file can be touched until a valid phase transition token is issued by the human PO.
Definition of Done (DoD) Quality & Regression GatesLLM Self-Evaluation ("Vibe Check"): The model evaluates its own code in prose ("All requirements met!"), masking reward-hacked tests, hollow shims, or dead code.42 Strict Binary Verification Gates: Zero-tolerance Go & WASM Tree-sitter AST analysis enforcing cyclomatic complexity (<= 15), file LOC (<= 400), anti-shim checks, and TDD assertion density (>= 10%).
Inference Efficiency Token spend & model viabilityContext Thrashing & Retry Tax: Blind edits lead to broken builds. The agent re-reads 100k+ token contexts across 10-turn retry loops ($2.50+ per feature) and forces reliance on expensive frontier cloud APIs.85%+ Lower Token Spend & $0 Local SLMs: Sandboxed worktrees keep contexts under 8k tokens. 12ms AST line diagnostics resolve errors in 1 turn, unlocking production viability for fast, private local models.
The 90-Day Velocity Curve Speed vs. Long-Term HealthDay 1 Speed ➔ Day 90 Sludge: 10x code output feels fast initially, but unconstrained drift results in 80% of human time spent untangling AI spaghetti, dead imports, and phantom bugs.Compound Acceleration ("Slow Down to Go Fast"): Spending 15 seconds executing sandboxed TDD and AST gates ensures code is written once, verified immediately, and never regressed.

"The Cognitive Layer explores, designs, and refactors; the Substrate Kernel enforces, verifies, and guarantees. We never rely on an LLM to 'remember' constraints if those constraints can be compiled into deterministic verification gates."

The Core Axiom — Harness Over Model
Read Full Essay →
⚡ Interactive Verification Simulator

Stochastic Chaos vs. Deterministic Go Rails

Drag the slider to test how unmanaged prompt loops fail at scale versus physical AST-enforced compiler gates.

🔒 42 DoD AST Gates Locked

Nomos Go Deterministic Substrate

Zero drift, instant 12ms AST verification, 100% hermetic worktrees linked via go.work.

0% Vibe Drift 50% Prompts 100% Nomos Go
Verification Strictness: 100% [PASS]
AST Cyclomatic Complexity
6 (<= 15 Target)
Test Suite Regression Status
✓ 100% PASS
Token Burn / Turn
$0.00 (Local SLM)
Git Workspace State
Isolated worktrees/nomos-SUB-4
AST Compiler Sandbox Continuous Verification

Real-Time AST Definition of Done Sandbox

Type or paste code to test cyclomatic complexity, docstrings, security invariants, and empty blocks in sub-10ms.

22 lines • 725 chars
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

Why Engineering Teams Choose Nomos

Moving from unanchored prompt-based AI coding to machine-verified deterministic software engineering.

The Status Quo: Unanchored AI Agents

Stochastic Vibe Coding & Silent Regressions

When AI coding assistants write code without deterministic verification, codebases degrade into unmaintainable bloat:

  • Direct Protected Commits: Agents commit half-finished experiments directly to master or main.
  • Interleaved Multi-Agent Collisions: Parallel sessions run git add . and corrupt each other's staged files.
  • Tautological Tests: Agents write tests after implementation, silently testing inverted logic.
  • Runaway Complexity: Functions balloon with unvetted nested branches and orphaned dead code.
The Nomos Paradigm: Machine-Enforced Invariants

Autonomous Engineering OS & 42 Definition of Done Gates

Nomos acts as a rigorous Go harness that governs all autonomous agent actions inside machine-enforced rails:

  • Hermetic Worktree Isolation: Every task executes in an isolated sandbox; zero branch pollution.
  • Mandatory Test-First TDD: Agents must write failing tests before touching application logic.
  • Automated AST Quality Audits: Cyclomatic complexity (< 15), docstrings, and imports checked on every change.
  • Human-in-the-Loop Release Gates: Structured walkthroughs signed before fast-forward merges.

Built for Data Sovereignty, Low Inference Spend & Institutional Rigor

Designed from first principles for on-premises security, 85%+ lower token burn, and pristine codebases.

📉

85%+ Lower Inference Spend

Hermetic worktrees and 12ms Go AST diagnostics eliminate context thrashing and 10-turn retry loops, slashing token burn and making $0 local SLMs viable in production.

🔒

100% On-Premises & Local Inference

Compatible with local Small Language Models (SLMs) via Ollama and vLLM. Your source code and architectural knowledge never leave your infrastructure.

⚡

Compiled Go Core Engine

Sub-millisecond static AST parsing, SQLite transactional state, and instant pre-commit hooks ensure zero IDE latency.

📦

Universal Language Support

Pre-configured verification profiles for Go, TypeScript/SvelteKit, Python, and Rust with native lint and test runners.

Ask SophiaRTX 4080 Sophia AI · Live Architecture Concierge (Local RTX 4080)