Ask AI for a value, not an essay.

Ten typed operations for the work most apps actually need from a language model: pick a label, pull a field, rank a list, flag PII. Each one returns a value from a space you define, runs on-device or on your backend, and finishes 10–50× faster than a frontier model writing it out.

you call
final result = await runOp(
  op: EmbeddedOps.op('classify'),
  params: {'labels': ['sports', 'politics', 'technology']},
  input: 'The senate passed the budget bill after a late-night vote.',
  generator: generator,
);
you getConfident
{
  "status": "confident",
  "value": {
    "label": "politics"
  }
}

One label from your list, plus “unsure”.

A closed set of ten.

The set stays small on purpose. An op only gets in if it passes all four tests below. Everything else waits until it can.

OpReturns
classifyOne label from your list, plus “unsure”
extractA value per field you define. Nullable, and only spans or derivations of the input
rankA permutation of your item ids. Nothing invented
routeOne action from your registered set. An intent, never an effect
frameText derived from the input, length-bounded. The one generative op
matchClusters of equivalent items over your ids (dedup)
detectSpans matching a category you name: PII, secrets, toxicity…
verifysupported, contradicted or unclear, against evidence you supply
scoreAn ordinal label on your rubric. No free numbers
chooseThe single best option for a criterion, plus “unsure”

The membership test

Closed output
The answer comes from a set the caller defined.
Domain-blind
The op knows nothing about news, wallets or photos.
Two-app rule
At least two unrelated apps would call it.
Degradable
There's always a sensible non-AI fallback.

What happens in one call.

  1. 1/6

    Inject

    Your params are written into the op's JSON schema: your labels become the enum, your ids become the only legal values.

  2. 2/6

    Compose

    The op's scaffold turns params and input into a prompt.

  3. 3/6

    Generate

    The schema compiles to a grammar and decoding is constrained to it, so malformed output can't happen.

  4. 4/6

    Abstain

    If the model picked the unsure sentinel, you get a clean fallback rather than a guess.

  5. 5/6

    Validate

    Per-op checks a grammar can't express: a ranking is a full permutation, extracted values are really in the input, frames stay under length.

  6. 6/6

    Seal

    A confidence threshold you set, then one sealed result: Confident(value) or Fallback(reason).

Confident
{ "status": "confident",
  "value": { "label": "politics" } }
Fallback
// "It was a pleasant, unremarkable afternoon."
{ "status": "fallback", "reason": "abstained" }

Safe to hand to a small model.

Typed output, every time

Each op compiles to a grammar applied before top-k and top-p in the sampler. Even a 0.6B model emits valid JSON, and invalid output is structurally impossible.

Never authors a fact

The model selects from a space you defined. It can't invent an id, a label, a number or a side effect. route returns an intent; your code decides what happens.

Fallback is first-class

Every call returns Confident or Fallback with a machine reason. You always supply a non-AI default, so your UI never waits to learn whether AI ran.

Ops are data

An op is a folder: schema, params, scaffold and test cases. Adding or tuning one needs no recompile.

Run once, ever

Results are cached by op, model, input and params, across restarts. Abstentions are cached too; transient failures retry.

10–50× faster than frontier models

A typed answer is a handful of tokens, generated next to your data. No round-trip, no essay, no per-token bill.

The engine underneath.

Runtimes give you raw capability: generate, embed, a grammar. Apps want judgment: classify this, rank that. The engine is the translation layer between them, and it runs wherever the model does, on the device in your user’s hand or a server in your own network.

It’s the engine behind Brink Compute, which runs private AI on companies’ own infrastructure, and the agents on Brink Cube.

  1. Your app
    calls runOp and gets a sealed result
  2. Compute Primitives engine
    inject, compose, validate, cache. Pure Dart today
  3. Generator adapter
    one interface over any local runtime
  4. Native runtime
    grammar-constrained decoding on device GPUs, or on your servers

Where it’s at.

Shipped

  • 10 ops, data layer and validators
  • Dart reference engine, 62/62 tests
  • Grammar-first native substrate
  • Persistent result cache and conformance harness

Next

  • Native binaries for iOS, macOS, Android and Windows
  • TypeScript engine on WebLLM
  • Accuracy on larger models

Designed

  • Patterns: profile, recall, gate, digest
  • High-care: grounded answer, propose-then-execute compute

Want typed AI in your product?

We’re onboarding early teams now.

Get early access