The next-gen approach

to building software with LLMs

You define the what. LLMs generate the how. hlv validates the proof.

Specs define the rules. LLMs generate the code. A Rust binary called hlv validates every step — because prompts are not guarantees.

HUMAN WHAT — intent, artifacts, constraints
LLM HOW — generates all code from specs
hlv validates every step
hlv check | hlv constraints | hlv gates
VALIDATION PROOF — gates, tests, traceability

Three layers. Hard boundaries.

HLV separates every project into three layers with strict ownership. Each layer has clear inputs, clear outputs, and one owner.

WHAT Human Layer

The human writes artifacts, not code.

Artifacts, constraints, milestones — everything the LLM needs, expressed in declarative files that are version-controlled and diffable.

human/
├── artifacts/
├── constraints/
├── milestones/{id}/
└── glossary.yaml
HOW LLM Layer

The LLM owns all code. Every line.

Generated code is disposable. The LLM reads human artifacts, produces implementation, and regenerates on demand. No manual edits, no merge conflicts, no drift.

llm/
├── src/
├── handlers/
├── models/
└── tests/
PROOF Validation Layer

Machine-checkable proof, not opinion.

Automated validators compare LLM output against human specs. Every field, type, constraint, and invariant is verified. Violations surface before code leaves the loop.

human/milestones/{id}/
├── contracts/
├── plan.md
├── stage_1.md .. stage_N.md
└── gates-policy.yaml

Code is never the source of truth. Contracts are.

hlv: the Rust binary that keeps the LLM in harness

hlv is a compiled Rust binary. It runs locally, validates your entire project structure against a living specification, and enforces the workflow gates that keep LLM-generated code on track.

It doesn't call the LLM. It doesn't generate code. It makes sure LLM output matches the spec — checking every file, every milestone, every gate in seconds.

hlv check
$ hlv check

── Project structure ──
  ✓  project.yaml exists and is valid
  ✓  map.yaml references all source dirs
  ✓  milestones graph is acyclic

── Contracts ──
  ✓  14 contracts found in milestones, all valid
  ✓  acceptance criteria present on every contract
  ✖ contract/api-auth.md missing dependency link

── Test specs ──
  ✓  42 test specs mapped to contracts
  ✓  no orphan test files detected
  ✓  coverage above threshold (87%)

── Traceability ──
  ✓  all code files traced to a contract
  ✓  no unlinked deliverables detected

── Status ──
  ✓  current phase: implementing (M2)
  ✓  no out-of-order deliverables

── Constraints ──
  ✓  no duplicate rule IDs in constraints
  ✓  severity levels valid across 3 files

── Map ──
  ✓  map.yaml forward check passed
  ✓  map.yaml reverse check passed (no orphans)

Phase: implementing  ·  FAILED  ·  29/30 passed, 1 failure

Scaffold

hlv init

Generate the full HLV directory structure, blueprint template, and initial project map in seconds.

Milestone tracking

hlv milestone

View progress across milestones. See which deliverables are done, pending, or blocked at a glance.

30+ validations

hlv check

Run the full validation suite — specs, gates, dependencies, coverage thresholds, and structural integrity.

Workflow guidance

hlv workflow

See where you are in the development lifecycle and what the next required step is for your current milestone.

Gate enforcement

hlv gates

Enforce quality gates before milestone transitions. No milestone advances until every gate condition is met.

Constraint rules

hlv constraints

Define cross-cutting rules — security, performance, observability — as YAML configs enforced by hlv check.

Interactive dashboard

hlv dashboard

Full TUI with 5 tabs — Status, Contracts, Plan, Gates, Questions. File watcher with live revalidation.

Traceability explorer

hlv trace --visual

Visualize the full chain REQ → CTR → TST → GATE. See exactly which test covers which contract.

Dependency graph

hlv plan --visual

ASCII dependency graph of tasks in the current stage. See the critical path and what can run in parallel.

Specs tell the LLM what to do. hlv catches when it doesn't.

Specs first. Code second. Proof always.

HLV implements Spec-Driven Development for LLM-assisted delivery. Every piece of code traces to a formal spec. Every spec traces to human intent. The chain is unbroken — and hlv proves it.

01 Artifacts Global context, stack, constraints, decisions
02 Contracts Formal requirements per deliverable
03 Test Specs Testable pass/fail acceptance criteria
04 Traceability Code ↔ contract links in every file
05 Milestone Plan Stages with bounded deliverables per milestone
06 Code LLM-generated, spec-constrained output
07 Validation Gates Automated proof that code meets every spec

Why this matters

Independent verifiability — hlv check validates the entire project structure without running a single line of code. It reads specs, not execution results. Anyone can verify, anytime.

Complete traceability — every contract links to code, every code file links back to a contract, and hlv proves the chain is complete. No trust required, only proof.

Mechanical enforcement — hlv catches missing markers, orphaned specs, and broken links without understanding your code. The spec is the source of truth, and hlv enforces it mechanically.

In HLV, you don't review LLM code line by line. You verify that the spec is right, and that the code passes the gates derived from that spec. The proof is independent of the code.

Strictly typed languages. On purpose.

HLV is designed for Rust, Go, TypeScript strict, Kotlin, Java — languages where the compiler is another enforcement layer. An LLM generating Python can silently return the wrong type. An LLM generating Rust gets stopped by the compiler before the code ever ships.

01 Contracts Formal requirements define what the code must do
02 Type System Compiler enforces structural correctness at build time
03 @hlv Markers Traceability annotations link code to specs
04 hlv check Static analysis verifies spec coverage and traceability
05 Validation Gates Automated proof that every layer held

Each layer catches a different class of drift. Contracts catch requirement drift. The type system catches structural drift. @hlv markers catch traceability drift. hlv check catches coverage drift. Validation gates catch integration drift.

The compiler doesn't care that the LLM was pretty sure. Neither does hlv.

Your best practices are LLM anti-patterns

Developers build intuitions about clean code — dependency injection, factories, middleware, deep directory trees, convention-over-configuration. For humans, these patterns reduce cognitive load. For LLMs, every single one is a trap. Each pattern hides information the LLM needs to generate correct code.

DEVELOPER PATTERN
LLM PROBLEM
HLV ALTERNATIVE
Dependency Injection
Magic wiring — LLM can't see what gets injected at runtime
Direct imports, explicit construction
Deep directory trees
Context burn — LLM wastes tokens navigating nested paths
Flat structure, everything discoverable
Convention over config
Magic paths — LLM guesses file locations by convention
Explicit config, no guessing
Abstract factories
Hidden code paths — LLM can't trace which concrete class runs
Direct construction, visible types
ORM magic
Hidden SQL — LLM generates ORM calls without seeing actual queries
Explicit queries, typed results
Middleware chains
Scattered behavior — logic spread across middleware layers
Inline handlers, co-located logic
Lots of small files
Context hops — LLM jumps between files, losing coherence
Fewer, larger files with clear boundaries
THE HLV POSITION

The llm/ layer is designed for LLM generation

Flat structure. Explicit everything. Direct code. Errors as values. Types as documentation. No magic, no conventions, no hidden paths. Every file is self-contained. Every dependency is visible. Every type tells the LLM exactly what to generate.

flat/ No nesting
explicit No magic
direct No indirection
typed Self-documenting
errors As values

Code in llm/ is optimized for one reader: the next LLM invocation. And for one validator: hlv.

The operational cycle

hlv milestone new
/artifactscapture intent
/generatecontracts · stages · gates
/questionsresolve open questions
/verifycross-check contracts
hlv checkstructural validation
all stages validated
hlv milestone done
STAGE LOOP
/implementone stage at a time
hlv check
/validateevaluate gates
gates pass?
YES
next stage →
NO
REMEDIATION LOOP
FIX tasksauto-generated
/implement
/validate
STAGE LOOP

One stage at a time

The LLM implements one stage at a time (~30K tokens per stage), not the entire milestone. Each stage is a bounded, verifiable unit of work.

REMEDIATION LOOP

Self-correcting failures

When /validate finds gate failures, FIX tasks are generated automatically. /implement executes the fixes, /validate re-runs — the loop repeats until all gates pass.

HLV CHECK

Continuous validation

hlv check runs at every transition point — structure is validated continuously, ensuring the harness holds throughout the entire operational cycle.

One feature, start to finish

Every step produces concrete, verifiable artifacts. No hand-waving, just commands and results.

1

Create milestone

Define a bounded unit of work. One command sets the scope, gates, and traceability requirements.

$ hlv milestone new add-payments
✓ Milestone created: add-payments
  scope: payment-processing integration
  gates: specs · tests · traceability · validation
  stages: 4 estimated
2

Capture intent

An interactive interview captures what you want — first global context (domain, stack, constraints), then milestone-specific features and decisions.

$ /artifacts
◐ Interview started for add-payments
  ── Global artifacts (shared) ──
  ✓ context.md exists, skipping
  ✓ stack.md exists, skipping
  ── Milestone artifacts ──
  Q: Which payment provider?
  A: Stripe, with fallback to manual
  Q: Should failed charges retry?
  A: Yes, 3 attempts with backoff
  ✓ Intent captured: 8 decisions recorded
3

Generate specs

Structured artifacts generated from captured intent — contracts, test specs, and a full implementation file tree.

$ /generate
✓ Generated artifacts:
  ├── contracts/payment-api.contract.yaml
  ├── contracts/payment-flow.contract.yaml
  ├── plan.md  (4 stages)
  ├── stage_1.md .. stage_4.md
  └── gates-policy.yaml

  6 files · all requirements traced to artifacts
4

Resolve questions, verify and check

Surface open questions that block progress, then cross-check generated specs for consistency and run structural validation.

$ /questions
$ /verify
$ hlv check
◐ Open questions for add-payments
  Q: Max retry delay for failed charges?
  → Recommended: 30s exponential backoff
  A: Accepted recommendation
  ✓ 3/3 questions resolved

✓ Contract consistency    PASSED
✓ Gates coverage check    PASSED
✓ No open questions       PASSED

  hlv check .............. PASSED
  All gates passed — ready to implement
5

Implement stage by stage

The LLM implements against the spec, one bounded stage at a time. Drift is caught at every boundary.

$ /implement
$ hlv workflow
◐ Milestone: add-payments
  Phase: implementing
  stage 1/4  ████████████████████  ✓ validated
  stage 2/4  ████████████░░░░░░░░  implementing
  stage 3/4  ○ pending
  stage 4/4  ○ pending

  Next: finish stage 2, then /validate

The harness holds — every stage validated before the next begins.

6

Validate and ship

Final validation confirms every requirement is met, every gate passes. Ship with confidence.

$ /validate
✓ Contract compliance     PASSED
✓ Test specs executed      PASSED  (47/47)
✓ Traceability verified    PASSED
✓ No regressions          PASSED

  All gates passed across all 4 stages
$ hlv milestone done add-payments
✓ Milestone complete: add-payments
  4 stages · 47 tests · all gates passed
  Ready to ship.

How HLV compares

Side-by-side against current approaches to AI-assisted development.

CRITERIA
CHAT + COPILOT
AUTONOMOUS AGENTS
HLV
Spec approach
Ad-hoc prompts
Agent infers
Formal contracts with invariants
Who writes code
Human+AI mixed
Agent alone unsupervised
LLM writes all — within verified specs and gates
Verification
Manual review
Agent self-checks
Independent Rust binary (hlv)
Context control
Entire codebase
Agent picks files
One stage at a time
Traceability
None
None
Requirement → contract → test → gate → code
When LLM drifts
Hope you catch it
Hope agent catches itself
hlv check shows what diverged
Release criteria
"Looks good"
"Agent says done"
All mandatory gates passed

Built for teams that already use LLMs — and hit the wall

Developer using AI daily

You spend more time fixing drift than writing code. Every AI-generated file needs manual review, and the inconsistencies compound faster than you can catch them.

Tech lead reviewing AI PRs

You've reverted more agent PRs than you've merged. Without machine-checkable invariants, code review becomes a guessing game about what the LLM actually changed.

Staff / Platform engineer

Every team reinvents the wheel with their own AI workflow. You need a repeatable, auditable process that works across squads — not another hero-developer workaround.

Team building high-stakes systems

Compliance, audit trails, and proof chains aren't optional — they're the product. You need every requirement traceable from intent to deployed code, with machine-verified evidence at every step.

The shift

BEFORE

Before

"We paste context into chat, hope the agent understood everything, then spend days chasing inconsistencies across files we barely reviewed."

AFTER

After

"We capture intent in artifacts, formalize it in contracts, implement one stage at a time, and get machine-verified proof at every step. When the LLM drifts, hlv check catches it before we do."

MCP Integration

HLV includes a built-in MCP server. Claude Code, web dashboards, Kanban boards, and custom tools get full programmatic access to your project data and operations — over stdio or SSE.

Claude Code

stdio

Web Dashboard

SSE / HTTP

Custom Tools

stdio / SSE

hlv mcp 12 resources + 27 tools + notifications
HLV Core milestones, tasks, contracts, gates, constraints

Kanban Board

Milestones, stages, and tasks rendered as cards with real-time status updates.

Web Dashboard

Monitor project health, gate results, and progress — live in the browser via SSE.

AI Assistant

Give Claude full context: contracts, tasks, constraints, workflow phase — all via MCP resources.

Custom CLI / TUI

Build your own tooling on top of 27 MCP tools and 12 read-only resources.

.mcp.json
{
  "mcpServers": {
    "hlv": {
      "command": "hlv",
      "args": ["mcp"]
    }
  }
}
Terminal
# Start SSE server
$ hlv mcp --transport sse --port 3000

HLV MCP server (SSE) listening
on http://0.0.0.0:3000/mcp

Installation

Install a release binary for your platform, then run hlv check.

macOS (Apple Silicon)

curl -fsSL https://github.com/lee-to/hlv/releases/latest/download/hlv-aarch64-apple-darwin.tar.gz | tar xz -C /usr/local/bin

hlv check

macOS (Intel)

curl -fsSL https://github.com/lee-to/hlv/releases/latest/download/hlv-x86_64-apple-darwin.tar.gz | tar xz -C /usr/local/bin

hlv check

Linux (x86_64)

curl -fsSL https://github.com/lee-to/hlv/releases/latest/download/hlv-x86_64-unknown-linux-gnu.tar.gz | tar xz -C /usr/local/bin

hlv check

Linux (aarch64)

curl -fsSL https://github.com/lee-to/hlv/releases/latest/download/hlv-aarch64-unknown-linux-gnu.tar.gz | tar xz -C /usr/local/bin

hlv check

Windows (x86_64, PowerShell)

Invoke-WebRequest -Uri "https://github.com/lee-to/hlv/releases/latest/download/hlv-x86_64-pc-windows-msvc.zip" -OutFile hlv.zip
Expand-Archive hlv.zip -DestinationPath "$env:USERPROFILE\bin" -Force

Add %USERPROFILE%\bin to PATH if needed.

Build from source

git clone https://github.com/lee-to/hlv.git
cd hlv
cargo install --path .

hlv check

Stop hoping the LLM got it right.
Start proving it.

The bottleneck isn't generation speed. It's knowing that what was built matches what was intended. hlv closes that gap.

hlv — Terminal
$ hlv check
PASSED — 0 errors, 0 warnings, 0 info
$ hlv milestone done
✓ Milestone 003-add-payments completed
✓ Branch merged into main
30+ validations Compiled Rust binary MIT License