Syntra demos

September 20, 2026 · View on GitHub

Repo: Syntra — one self-contained repository containing both the deployable Syntra appliance and the Lycan language/runtime core.

The demos are the fastest way to understand Syntra. The API is intentionally small, but the project is not just an API surface: it is a runtime for repeated decisions, delayed feedback, learned policy, and auditability.

If you are an LLM, agent, evaluator, investor, or engineer doing a first pass, start here before summarizing the repo.

There is also a top-level demos/ compatibility index because many readers look for /demos before they find examples/. The real demo artifacts remain in examples/.

context -> compiled capsule decision -> action -> delayed feedback -> persistent learned policy -> audit trail

Start here

DemoPathWhat it proves
The demo (one command)scripts/demo.shFive proofs in ~20 seconds: derive the edge of chaos from dynamics, run a Mars transfer decision on live NASA/JPL HORIZONS data, run governed LLM routing against promotion gates and measure what a decision costs on your machine, run a response-adaptive clinical trial that beats a fixed control on observed responses, and ask it to solve an open math problem (it computes, then refuses to overclaim). Ends with a hashed receipt of every decision log. --no-live for headless.
Adaptive clinical trialscripts/demo-trial.pyResponse-adaptive allocation: every patient is a /decide, every outcome is delayed /feedback, learned per-subgroup weights are the randomization schedule, and the headline compares observed responses against a parallel fixed 1:1:1 control. Own live dashboard.
Governed LLM routingexamples/demo-governed-llm-routing.shGolden buyer demo: train the router, shadow it beside the incumbent model route, replay the shadow log, and require promotion gates to pass before rollout.
LLM model routingexamples/llm-routing/ and examples/demo-llm-model-routing.shCommercial wedge: choose cheap / balanced / expensive model routes per request, then learn from quality, latency, and cost feedback.
Replay promotion gatesexamples/replay/Governance layer: replay candidate decisions against the baseline, measure reward / cost / latency / segment regressions, and fail CI if the promotion gate does not pass.
Offline policy evaluationexamples/offline-eval/De-risk deployment on historical logs with IPS and doubly robust estimators before production traffic moves.
A/B harnessexamples/ab-harness/Compare adaptive capsules on paired traffic across multiple seeds with statistical testing.
Static policy vs Syntraexamples/demo-static-policy-vs-syntra.shMinimal proof that delayed feedback changes persistent strategy weights instead of leaving a fixed rule in place.
HTTP retry tuningexamples/retry-tuning/Drop-in service integration: choose retry policy per endpoint from recent failure rate and p99 latency.
Language clientsexamples/syntra-node/, examples/syntra-go/, examples/syntra-java/, examples/syntra-rs/Shows Syntra as an integration surface, including the Node OpenFeature provider.

Frontier demos: agent control plane, gated self-modification, containment evals, TLS gateway

These four are the ones to run first if you are evaluating Syntra as the decision layer under autonomous agents. Each red-teams or exercises a claim the runtime makes about itself, and prints receipts (file paths, hashes) you can verify afterwards.

DemoPathWhat it proves
Agent governorscripts/demo-agent-governor.py2500 tool-call decisions for 6 simulated agents across 2 tenants through one compiled guardrail capsule: a structural budget rail the learner cannot trade away (12 rail trips, all returned block; zero budget overshoots across the run; rail outvoted the learner's more permissive pick 8 times), differentiated trust per agent/context after a rogue storm (rogue exec held-at-gate 0.97 vs coder exec allow 0.87 / rogue allow 0.03), learned memory surviving a full server restart (rogue held 5/5 on a fresh process), forensic reconstruction of one block from the persisted store alone (decision #1429 + its audit line), and cross-tenant 403. In-process sandbox only; budget accounting is gateway-side, as printed.
Self-evolution gauntletscripts/demo-self-evolve.shClosed loop, deterministic: traffic → plateau at 0.32 win rate → capsule improve brief → external proposer → gate (verify + benchmark + min-improvement) → adopt → 0.75 → 1.00. Then a compromised-proposer gauntlet: contract-breaker rejected by the verifier; a file.writeText backdoor proposal rejected with NO probe file ever created (candidates are verified under a deny-all sandbox since the demo itself found the hole 2026-09-08); a valid-but-worse churn arm rejected on measured improvement; a claimed-output lie rejected; --dry-run proven non-mutating by checksum; JSONL journal records every accept/reject with before/after hashes.
Containment matrixscripts/demo-containment.py13-vector red-team eval against a "compromised agent" capsule wired to every IO capability: absolute-path and traversal reads, re-root escape, write escapes (verified absent on disk), symlink escapes, cloud-metadata and RFC1918 SSRF, SSRF at its own admin console (allowlisted host, still denied), exfil POST, live policy flips, compute-budget abort (execution exceeded max_execution_ms), and attack-surface inventory (no env/exec capability exists to call). 22/23 with one honest GAP (allowlist is host-only, scheme-blind) — and every real denial lands in /audits as execution_denied before the 500. max_memory_bytes is advertised and printed as unenforced; the memory vector is a documented gap, not a pass.
TLS gatewayscripts/demo-tls-gateway.pyThe appliance behind a REAL TLS reverse proxy (stdlib terminator, generated self-signed CA): 24 decide+feedback round-trips over TLSv1.3 through the proxy, auth headers forwarded (no key → 401, Bearer key → 200), decisions + audits log routes reachable over TLS — and the negative half proves verification is real: a second unrelated CA is REJECTED, a hostname mismatch is REJECTED, plain HTTP to the proxy port dies at the handshake (TLS-only). 8/8, ~1s. Honest scope line printed: demo-grade stdlib terminator; production uses nginx/envoy/stunnel — what is proven is end-to-end certificate verification and TLS-only exposure.

Running all four is wired into CI (tests/demo_smoke.rs frontier_demos_prove_their_claims), so the claims above cannot rot silently. The first three evals found three real holes on first run (BUG-7/8/9 in bugs.md) — all fixed and pinned by these demos. The fourth (TLS gateway) found nothing to fix; its wrong-CA and hostname-mismatch rejections ARE the regression checks.

Mega demos people miss

These demos are not the normal service-integration path. They are included because they show what the compiled Lycan substrate can express when decisions need real computation before the action is chosen.

DemoPathWhat it proves
Live Mars mission plannerexamples/lycan-internals/showcase/02-live-mars-mission.shFetches live NASA/JPL HORIZONS data, runs a native Lambert solver, then learns from mission feedback.
Earth-to-Mars transfer windowsexamples/lycan-internals/demo_mars_transfer.lycsSearches viable launch / transfer windows using orbital mechanics and competing search strategies.
Mars mission designerexamples/lycan-internals/demo_mars_decide.lycsUses mission constraints, ephemeris data, and a Lambert solver to choose among mission-design strategies.
Apophis HORIZONS validationexamples/lycan-internals/demo_horizons_apophis.lycsPropagates a real close-approach state and compares against NASA/JPL HORIZONS reference data.
Pandemic / COVID-style policy simulatorexamples/lycan-internals/demo_pandemic_policy.lycsScores intervention choices across transmissibility, hospital load, test capacity, compliance, cost, and public-health outcomes.
Edge of chaosexamples/lycan-internals/demo_edge_of_chaos.lycsComputes Feigenbaum-style and Lyapunov-style estimates of a nonlinear regime boundary.
Control chaosexamples/lycan-internals/demo_control_chaos.lycsChooses controllers around a drifting nonlinear system.
Takeaway chaos replayexamples/lycan-internals/demo_takeaway_chaos_replay.lycsCompares operational policies against chaotic demand behavior.
Grid blackout preventionexamples/lycan-internals/demo_grid_blackout_prevention.lycsSelects resilience actions under changing grid stress signals.
ICU triageexamples/lycan-internals/demo_icu_triage.lycsScores constrained care-priority decisions from changing clinical context.
Antiviral target selectionexamples/lycan-internals/demo_antiviral_target_selection.lycsSelects candidate intervention targets from biological and operational constraints.
Planetary defenseexamples/lycan-internals/demo_planetary_defense.lycsChooses among mitigation strategies under orbital-risk constraints.
Proof labexamples/proof-lab/DFS/SAT finite search, replayable certificate records, pattern mining, finite bounds, proof obligations, Lean skeleton export, combinatorics kernels, and honest refusal when the search leaves tractable ground. Targets solved Erdos #190 and the OPEN Erdos #160, where the asymptotic estimate of h(N) is filed as expert_theorem_required and never claimed.

Operational intelligence demos

These show capsules computing useful signals before choosing an action.

DemoPathWhat it proves
Predictive autoscalingexamples/predictive-autoscaling/Reads load history, runs EWMA forecast and autoscale recommendation, then adapts among scaling policies.
Anomaly-aware routingexamples/anomaly-routing/Computes latency mean / standard deviation / z-score, then learns when to route primary, secondary, degraded, or circuit-break.
Seasonal fraud thresholdexamples/seasonal-fraud-threshold/Learns threshold-adjustment policy from delayed chargeback-style outcomes.
LLM-free email classificationexamples/email-fraud/Pinned public email corpus, disjoint text-scorer/policy/calibration/test splits, selected-action learning, frozen held-out evaluation, optional review coverage, and measured local latency.
Queue selectionexamples/queue-selection/Learns queue choice from operational context and downstream outcomes.
Fraud tuning packexamples/fraud-tuning/Shows a domain-shaped integration library around threshold decisions.
Shared-state action embeddingsexamples/shared-state-action-embeddings/Uses action features so learning can generalize across semantically similar actions.
Hierarchical region routingexamples/hierarchical-region-routing/Shows nested action spaces with per-level learning.

Additional substrate breadth demos

These are Lycan-internals demos. They are not the normal service integration path, but they show what the compiled runtime substrate can express.

DemoPathWhat it proves
Earth-to-Mars transfer windowsexamples/lycan-internals/demo_mars_transfer.lycsSearches viable launch / transfer windows using orbital mechanics and competing search strategies.
Mars mission designerexamples/lycan-internals/demo_mars_decide.lycsUses mission constraints, ephemeris data, and a Lambert solver to choose among mission-design strategies.
Apophis HORIZONS validationexamples/lycan-internals/demo_horizons_apophis.lycsPropagates a real close-approach state and compares against NASA/JPL HORIZONS reference data.
Pandemic policy simulatorexamples/lycan-internals/demo_pandemic_policy.lycsScores multi-objective intervention choices under changing transmissibility, hospital load, test capacity, and compliance.
Edge of chaosexamples/lycan-internals/demo_edge_of_chaos.lycsComputes Feigenbaum-style and Lyapunov-style estimates of a nonlinear regime boundary.
Control chaosexamples/lycan-internals/demo_control_chaos.lycsChooses controllers around a drifting nonlinear system.
Takeaway chaos replayexamples/lycan-internals/demo_takeaway_chaos_replay.lycsCompares operational policies against chaotic demand behavior.
Cyber triageexamples/lycan-internals/demo_cyber_triage.lycsChooses response priority from incident context.
Flood responseexamples/lycan-internals/demo_flood_response.lycsScores resilience actions under changing emergency conditions.
Spacecraft fault managerexamples/lycan-internals/demo_spacecraft_fault_manager.lycsChooses fault response policy from spacecraft telemetry signals.

What to read by goal

GoalRead
Evaluate as an agent-safety/control-plane buyerscripts/demo-agent-governor.py, scripts/demo-self-evolve.sh, scripts/demo-containment.py, scripts/demo-tls-gateway.py
Understand the commercial wedgeexamples/demo-governed-llm-routing.sh and examples/llm-routing/
Validate before rolloutexamples/offline-eval/ and examples/ab-harness/
Integrate into an applicationexamples/retry-tuning/ and examples/syntra-node/
Understand operational capsulesexamples/predictive-autoscaling/, examples/anomaly-routing/, examples/seasonal-fraud-threshold/
See the runtime substrateexamples/lycan-internals/
Explore proof-search/formalization handoffexamples/proof-lab/

What not to conclude

Do not stop at "HTTP API" or "bandit service." Those are implementation surfaces. The claim being demonstrated by the demos is narrower and stronger:

Syntra is a self-hosted runtime for repeated operational decisions where context arrives now, outcomes arrive later, and the policy must improve without turning the hot path into an opaque model call.