The coherence layer
for AI agents.
Invariant sits beneath your agents and humans. It ingests observations, claims, and tool outputs — reconciles them into a persistent state graph, detects contradictions, preserves conflicting branches, and blocks unsafe actions before they execute.
npm install @invariant/sdk-node
content_copy
The Step 47 Problem
Agentic workflows fail silently. An agent makes a small assumption at Step 4, forgets a constraint at Step 22, and by Step 47, it's executing code that contradicts your core business logic.
Most tools try to fix this with better prompts. Invariant fixes it with math.
Silent Degradation
Hallucinations compound across long-running autonomous sessions.
Constraint Blindness
Context windows lose track of system invariants during complex reasoning.
What Invariant Does
The first real-time formal verification engine for LLM agents.
Continuous World State Monitoring
Invariant maintains a high-fidelity graph of every fact, variable, and claim made during an agent's execution lifecycle. If a new action contradicts a previous fact, the engine flags it in microseconds.
Invariant Policy Enforcement
Define "Unbreakable Laws" for your agents using standard TypeScript or Python. If an agent tries to delete a production DB or bypass MFA, Invariant kills the process before the packet leaves the network.
Sub-millisecond Latency
Built in Rust and deployed as a sidecar, Invariant adds less than 2ms of overhead to your agentic calls. It's security that doesn't feel like a speed bump.
World State Graph
Live Session ID: px-992-alpha
How It Works
Three operations. One coherent world state.
Ingest
Push observations, tool outputs, and claims from any source via REST or SDK. Invariant extracts assertions and builds the world state graph in real time.
POST /claims
Reconcile
The settling loop runs: detect contradictions → branch conflicting state → propagate dependencies → evaluate constraints → recompute confidence. Repeat until fixed point.
Φ(G) → fixed point
Validate
Before any agent executes an action, call /actions/validate. Get back admissibility (VALID / RISKY / BLOCKED), ΔΦ, Ψ score, and exact reasons.
→ VALID | RISKY | BLOCKED
Ship in minutes,
not months.
Five lines of initialization. Then assert claims and validate actions anywhere in your agent stack. The SDK handles serialization, retries, and streaming — you handle logic.
import { InvariantClient } from '@invariant/sdk-node';
const client = new InvariantClient({ baseUrl: 'http://localhost:3000' });
// Assert a claim from a sensor or tool output
await client.claims.create({
entityId: 'battery-bp1',
predicate: 'temperature',
value: 95,
sourceId: 'sensor-array-3'
});
// Validate an action before executing
const result = await client.actions.validate({
agentId: 'planner-1',
actionType: 'proceed_to_launch',
impactedEntityIds: ['launch-review-lr1']
});
if (result.admissibility === 'BLOCKED') {
console.log('Action blocked:', result.reasons);
}
Built for production AI
Invariant is infrastructure — not a feature. It belongs wherever autonomous systems make decisions that matter.
Multi-Agent Orchestration
When multiple agents act in parallel, their world views diverge. Invariant maintains a shared state graph that all agents read and write to — detecting conflicts the moment they arise, before a downstream agent acts on stale truth.
LLM Tool-Use Safety
Wrap any LLM with tool access and route every proposed tool call through Invariant first. High-risk calls — deleting data, writing production configs, calling external APIs — are blocked if current world state makes them inadmissible.
Autonomous Systems
Pre-flight validation for robots, drones, and autonomous vehicles. Assert sensor readings and system health claims, then let Invariant gate each actuation command against the live constraint set before the packet reaches the motor controller.
Mission-Critical Decision Support
Go/no-go decisions in aerospace, defense, and surgical systems require proof, not probability. Invariant produces a formal admissibility verdict with a complete dependency trace — every constraint evaluated, every claim cited.
Distributed Knowledge Management
Track claims from sensors, APIs, models, and human operators simultaneously. When sources conflict, Invariant preserves both views as independent branches rather than overwriting — giving downstream consumers full visibility into what is known, disputed, or uncertain.
Compliance & Audit Trails
Every action validated by Invariant is logged with its full provenance chain: which claims were evaluated, which constraints fired, what the Ψ score was, and why the decision was VALID, RISKY, or BLOCKED. Export-ready for regulators, auditors, and incident reviews.
Invariant
for Mac.
A native menubar app that connects to your local or cloud Invariant instance. Watch coherence in real time, get notified when contradictions spike, and inspect the world state without opening a browser.
- check_circle Live Φ score in your menu bar — always visible
- check_circle Native macOS notifications on contradiction detection
- check_circle Connects to localhost or invariant.me cloud
- check_circle One-click world state snapshot and export
v1.0.1 · Requires macOS 13 Ventura+
Coherence Score
98.1
42
Entities
2
Conflicts
128
Edges
Latest Contradiction
Claim #152 ↔ Claim #104 — STATUS_CONFLICT
2s ago · score 0.81
Secure your agentic future.
npm install @invariant/sdk-node
content_copy