2026-11-27 16:22 UTC

STROT compiles decision tasks into local-model pipelines

state: expiredheat: lowuncertainty: mediumrelevance: mediumlocal-inference decision-compilation edge-deployment compile-time-llm conformal-predictionstrot-aisolohunter001

What is this?

STROT is an open-source Python tool that uses an LLM at compile time to turn a decision task—such as classification, scoring, or routing—into a frozen pipeline. At runtime it still uses a small local 144M-parameter model, rather than eliminating models altogether, and returns bounded, typed decisions with confidence-based abstention. Its maintainers report roughly 60 ms per record and benchmark improvements over a naive setup using the same model. These are project-reported results; the supplied evidence does not independently validate them. The proposed conformal error guarantee is also conditional, not a promise of correctness on every record or distribution.

Why it matters

STROT is a useful example of shifting LLM work from every request to a one-time build step: a small local model still handles runtime decisions, with fixed-format outputs and abstention for uncertain cases. If its reported results hold on users’ own data, this could suit high-volume, well-defined routing or classification where latency, offline operation, and predictable inference costs matter. It is not model-free, and the supplied evidence is mainly the project’s own GitHub claims and its author’s Show HN post; broader independent validation and deployment evidence are absent.

Current assessment

Newly surfaced as a Show HN project on Oct. 19, 2026, STROT offers `run()` and `decide()` APIs for classification, scoring, routing, and other bounded decisions. The project says an LLM synthesizes the pipeline at compile time; runtime uses a small local 144M-parameter Julia-1 model, reportedly about 60 ms per record on CPU, with no per-record LLM calls. Its README reports 92.5% versus 74.8% on a 398-record routing benchmark and 86.7% versus 72.7% on AG News against a naive integration using the same model. These are maintainer-reported results; the repository links benchmark scripts and losses, but the supplied sources do not provide independent reproduction or enough detail to judge how representative the tasks and data are. The author says split conformal calibration allows low-confidence cases to abstain and offers a marginal error guarantee; this should not be read as per-case certainty or a guarantee under distribution shift. Practical fit is likely narrow, high-volume tasks with a stable schema and known-answer checks; changing intent or data may require recompilation, and runtime still depends on a model. Track independent benchmark replication, abstention coverage, calibration under drift, and resource requirements before treating this as a general edge-deployment pattern.

Measured heat

no measured readings yet — the hourly heat pass fills this in

How the heat travelled

10-18 13:00⭐ origin echo-reconstructedSTROT compiles LLM intent once at compile time (synthesize labels, golden-gate validation, teacher labeling, calibrate confidence thresholds
strot-ai on github (echo) · attributed from hn.story.50148396
—
10-19 04:32first on hacker news · published · +15.5hShow HN: Strot – Compile an LLM's intent once, run decisions locally forever
solohunter001
—
10-19 04:32amplified on hacker news 👑hn.story.50148396
solohunter001
peak 23 · 14 comments · 100% of case engagement
10-19 05:21our radar first saw it · +16.4hdiscovery anchor: hn.story.50148396—

Evidence (2) — ⭐ canonical anchor

sourceobjectauthorscorecomments
🟧 hnShow HN: Strot – Compile an LLM's intent once, run decisions locally forever
Retrieved article excerpt

Open article · Retrieved 2026-10-19T05:22:45.812020+00:00

# ⬢ STROT

### The open decision compiler

**Compile your intent once with an LLM. Then decide on every record forever** —
classification, scoring, routing — as type-safe JSON with probabilities and
confidence, on your own hardware, at **zero marginal cost**.

[PyPI](https://pypi.org/project/strot-ai/)
[License](https://github.com/strot-ai/Project-STROT/blob/main/LICENSE)
[Tests](https://github.com/strot-ai/Project-STROT/blob/main/tests)
[Python](https://github.com/strot-ai/Project-STROT/blob/main/pyproject.toml)

[**Website**](https://strot.ai) · [**Docs**](https://github.com/strot-ai/Project-STROT/blob/main/DEVELOPERS.md) · [**Benchmarks**](https://github.com/strot-ai/Project-STROT/blob/main/benchmarks) · [**PyPI**](https://pypi.org/project/strot-ai/)

```
Agents at compile time.  Never at runtime.
```

---

```
pip install strot-ai
```

```
import strot

result = strot.run(
    tickets,
    query="Triage incoming support tickets into the correct workflow.",
    action_registry={
        "billing_dispute":  "Refunds, invoice corrections, double charges",
        "technical_defect": "Crashes, bugs, broken behavior",
    },
    llm="anthropic/claude-opus-4-8",   # used once, on first compile only
)

for o in result.outcomes:
    print(o["action"], round(o["confidence"], 2))
# billing_dispute 0.97
# technical_defect 0.94
```

The LLM runs **once**, at compile time. Production is a frozen, self-contained
Python artifact: a small local decision model arbitrates every record, nothing
is generated, every output is bounded, and low-confidence records abstain
instead of guessing.

```
STROT = Agentic Schema Intent + Compiler & State + Code + Execution + NLU
                      ⟹  JSON Decisions
          (classification · scoring · routing · typed answers)
```

## How it works

```
            COMPILE  (once per intent + schema)
  intent + sample ─▶ synthesize ─▶ golden gate ─▶ teacher labels ─▶ calibrate
                     (labels,      (your known      (annotate         (fit the
                      projection,   answers must     a sample,         confidence
                      handlers)     pass)            once)             threshold)
                                        │
                                        ▼
                             frozen artifact  (.py)

            RUNTIME  (every record, forever)
  record ─▶ projection ─▶ decision model ─▶ confidence gate ─▶ typed JSON
            (compiled)     (144M, CPU,        (decide or         decision
                            ~60 ms)            abstain)
```

## Two surfaces

**`run()`** — route each record to an action and execute the compiled handler.

**`decide()`** — answer typed questions (choice / score / boolean) per record:

```
result = strot.decide(records, questions={
    "is_bug_report":     {"type": "boolean", "instructions": "mentions crashes/errors?"},
    "customer_sentiment":{"type": "score", "min": 1, "max": 5, "instructions": "1 angry, 5 happy"},
    "routing_bucket":    {"type": "choice", "options": ["billing", "engineering", "spam"]},
})
# → {"booleans": {...}, "scores": {...}, "choices": {...}}  with probabilities + confidence
```

## Measured

Real model (SupersonicLabs/Julia-1, 144M, CPU), real datasets, clean Docker containers:

|  | Result |
| --- | --- |
| Grounded routing accuracy (398 records) | **92.5%** compiled vs 74.8% naive — the compiler is worth +18pp on the same model |
| Semantic text (AG News, unseen labels) | **86.7%** compiled vs 72.7% naive (+14pp) |
| Typed decisions vs the leading hosted decision API's own example | near-identical (sentiment 1.79 vs 1.8) |
| Latency / marginal cost / LLM calls per record | **~60 ms · $0 · 0** |

Reproduce everything: [`benchmarks/`](https://github.com/strot-ai/Project-STROT/blob/main/benchmarks) — with the losses published too.

## What makes it different

- **Compile once, decide forever** — content-addressed artifact cache; schema drift triggers exactly one recompile.
- **Golden-record promotion** — artifacts must pass your known answers before they serve.
- **Fitted guarantees** — temperature scaling + split conformal prediction, baked in: dispatched decisions are wrong ≤ α of all records (marginal); the rest abstain.
- **Measured, not guessed** — the compiler scores labelings, and can train a distilled head, keeping only what beats the baseline on held-out data.
- **0% structural hallucination** — output is selection + computation over your registry; nothing is generated at runtime.
- **Model-independent** — the decision model is a slot (`nlu=`): local Julia-1 by default, hosted APIs, or any drop-in specialist.

## Install

```
pip install strot-ai            # core: pure stdlib
pip install strot-ai[local]     # + the local decision model (torch/transformers)
pip install strot-ai[hosted]    # + openai, for a hosted decision runtime
pip install strot-ai[anthropic] # + anthropic, for the synthesizer
```

Bake the local model into your image for offline production:

```
RUN pip install strot-ai[local] \
 && python -c "import strot; strot.prefetch_nlu(local_dir='/opt/julia-1', install=True)"
ENV STROT_NLU_CHECKPOINT=/opt/julia-1
```

(Never `pip install julia` — unrelated package.)

## Documentation

[**DEVELOPERS.md**](https://github.com/strot-ai/Project-STROT/blob/main/DEVELOPERS.md) — architecture, compile lifecycle, calibration
semantics and caveats, deployment, model swapping, full API reference.

## License

MIT. Default decision model: Apache-2.0 ([SupersonicLabs/Julia-1](https://huggingface.co/SupersonicLabs/Julia-1)). Implements ideas from STROT (arXiv:2505.01636).
solohunter0012314
🟧 echo.github ⭐STROT compiles LLM intent once at compile time (synthesize labels, golden-gate validation, teacher labeling, calibrate confidence thresholdsstrot-ai——

Interpretation history

Decision trace