Gold Metal Shop

Decision API: The Missing Layer Between Your Application and the Decisions It Has to Make

Most software teams do not struggle to generate text, classify a sentence, or call a model. They struggle with the last mile: turning messy real-world state into a structured, trustworthy decision that ordinary code can branch on without a human babysitting every response. That is the gap a decision api is built to close. Instead of prompting a chat model and hoping the JSON parses, you send state and questions to a single HTTPS endpoint and receive schema-valid, typed answers with calibrated confidence attached.

For developers, product teams, and operations engineers, this shift matters more than it first appears. A decision API is not a wrapper around a language model. It is a purpose-built inference surface where the questions are defined in code, the answer types are fixed, and the response is deterministic. DecisionNode is an example of this category: a “System One” decision model that returns decisions rather than prose, exposed through POST /v1/decide and supported by SDKs for TypeScript, Python, Go, Ruby, curl, MCP tools, webhooks, and AI agents.

What a Decision API Is — and Why “Reply in JSON” Doesn’t Qualify

The common shortcut today is to ask a general-purpose chat model to “respond only in JSON” and then parse the result. It works in demos and fails in production for predictable reasons. Output drifts in shape, keys get renamed, values arrive as strings where you expected numbers, and the model occasionally invents a label that was never in your enum. Every one of those failures lands in your error budget and in someone’s on-call rotation.

A decision API inverts that contract. You define the question and its answer space in code — a fixed set of labels, an ordered scale, a probability, a numeric grid, a coordinate in an image — and the endpoint returns an answer that is guaranteed to fit that shape. There is no parsing layer to defend, no retry-on-malformed-JSON loop, and no prompt engineering to keep the model inside the lines. The constraints live in the request schema, not in a paragraph of instructions the model may or may not follow.

Two properties separate this from text generation. The first is typed output. A decision API returns a choice (exactly one of your labels), a score (a level on an ordered scale), a truth value (a calibrated probability between 0.00 and 1.00), a number (a value on a grid), or a location on an image expressed as a point or a box. Those are the primitives your application actually branches on. The second is determinism: the same request returns the same answer. That single property makes decisions testable, replayable in a debugger, and safe to cache — none of which is true of a stochastic chat completion.

The practical consequence is architectural. Teams replacing hand-written rule engines get a decision surface that expresses soft judgments without collapsing into thousands of nested if-statements. Teams replacing chat-LLM classifiers get a real API contract with stable latency, predictable cost, and outputs that a type system can enforce. Both are moving from “something that usually works” to “something the compiler and the test suite can reason about.”

Anatomy of a Decision Request: State In, Typed Answers Out

Every decision request has two halves: the state describing the situation, and the questions describing what you want to know about it. On DecisionNode, both go to one HTTPS endpoint in a single call, and the answers come back in one pass — no chained calls, no second round trip to format the output, no separate extraction step.

The state is where decision APIs diverge sharply from text-only pipelines. You can send plain text, structured JSON, or up to 16 images and video frames in a single request. That multimodal input is what makes the model useful for physical and visual operations, not just document and message triage. A warehouse exception can arrive as a scanned label plus a photo of a pallet. A production-line check can arrive as three frames of the same unit. A moderation queue can arrive as a message plus an attached screenshot.

The questions are declared in code, which is the part engineers tend to appreciate most. Instead of describing output format in natural language, you specify the answer space directly: the enumerated labels for a routing decision, the ordered scale for a severity or quality score, the numeric grid for an estimated quantity, the probability question for a risk gate, or the point and box questions for locating something inside a frame. Because the answer space is part of the request contract, the response is schema-valid by construction.

This structure also makes the integration boring, in the best sense. You define a request schema once, generate or hand-write a typed client, and call the endpoint wherever your code currently branches. The same request shape works for a ticket-triage service, an order-eligibility check, and a quality-control gate on a production line — only the labels and the state payload change. And because every answer carries a calibrated confidence value, the response is not just a label but a label plus the information your code needs to decide whether to act on it.

Calibrated Confidence: Making Automated Decisions Safe to Ship

The hardest question in any automated decision system is not “what is the answer” but “how much should I trust this answer right now.” Most ML integrations answer the first question and leave the second to guesswork: a softmax score that is not calibrated, a model that is confidently wrong, or a threshold plucked from a dashboard and never revisited.

A decision API that returns calibrated confidence changes the shape of the surrounding code. When a probability of 0.94 genuinely means the answer is correct about 94% of the time on comparable inputs, you can write a threshold gate with an actual risk model behind it. Above the threshold, the system acts immediately: the ticket is routed, the order is held, the frame is flagged, the agent proceeds. Below the threshold, the code takes a defined safe path — re-check with additional state, escalate to a human reviewer, queue for asynchronous inspection, or fall back to a conservative default.

That two-tier pattern is where decision APIs earn their place in production. It turns automation from a binary bet into a graded system with an explicit uncertainty budget you can tune per workflow. High-volume, low-stakes routing might act above 0.70. Financial or safety-adjacent gates might require 0.98 and send everything else to review. Because the confidence is part of the typed response rather than an afterthought, it can be logged, monitored for drift, and used to drive alerting when the distribution of confident answers shifts.

DecisionNode also exposes optional boosters for specific perception tasks — human age estimation, AI-generated image detection, face detection and recognition, OCR, and depth and segmentation. These let a team answer a narrow visual question precisely instead of hoping a general model happens to be good at it, while keeping the same request-and-response contract across every workflow.

Latency, Cost, and Throughput: Choosing the Right Decision Model

Decision APIs live inside request paths, so latency is a design constraint rather than a benchmark curiosity. DecisionNode ships two models aimed at different points on that curve. DecisionNode Flash runs at roughly 5 ms server-side and 19 ms end to end, priced at $0.035 per 1M input tokens. DecisionNode MoE runs at roughly 9 ms and $0.042 per 1M input tokens for cases where the extra capacity is worth a few milliseconds. Output tokens are always free, batch discounts are available, and there is a free daily tier for development and evaluation.

The cost model is worth pausing on, because it is unusual. Paying only for input means that widening the answer space — asking six questions instead of one, or requesting both a score and a location — does not multiply the bill the way multiple chat completions would. Teams consolidating five separate classifier calls into one decision request often find that the single call is both faster and cheaper than the pipeline it replaces.

Throughput has a similar story. Standard request-response handles the overwhelming majority of product and ops workflows. For control loops that need to exceed roughly 10 decisions per second — drones, robots, simulators, continuous machine monitoring — DecisionNode offers sessions over WebSocket, which keep the connection warm and remove per-request overhead from the loop. This is the difference between a decision API used as a service call and a decision API used as a control primitive inside a real-time system.

Real-World Decision Patterns Across Product, Ops, and Agents

The most reliable way to evaluate a decision API is to map it against recurring patterns rather than abstract capabilities. A handful show up again and again across teams adopting DecisionNode.

Support and ticket triage. State is the ticket text plus any attachments; questions are the queue label, a priority score on an ordered scale, and a probability that the customer is at churn risk. Confidence above threshold triggers auto-routing; below threshold sends the ticket to a human queue with a suggested label attached.

Fraud and promo abuse. State is the order JSON, account history, and device signals; questions are a choice between allow, review, and block, plus a calibrated risk probability. The deterministic response makes the decision auditable and reproducible when a customer disputes it — a property that matters enormously in regulated environments and is essentially unavailable with generative pipelines.

Moderation and gating. State includes text, images, and video frames; questions combine a policy-violation choice with a severity score. Because the model accepts up to 16 images per request, a review of a post and its media happens in one call rather than a fan-out of parallel services.

Physical and visual operations. Quality control on production lines, warehouse monitoring, and traffic observation lean on the point, box, and number output types alongside boosters such as OCR, depth, and segmentation. A line-side system asks whether a unit passes, where the defect is located in the frame, and how confident the model is — then either rejects the unit or forwards it for inspection.

AI agents that decide before acting. Agent frameworks increasingly need a cheap, typed gate before a tool call: should this action be taken, which of these five tools applies, is the retrieved context sufficient. Routing each of those through a decision API keeps the agent’s control flow in typed code with a confidence floor, instead of relying on the language model to self-report whether it is sure. Whether the caller is a TypeScript service, a Go worker, or an MCP-connected agent, the integration surface stays the same: one endpoint, declared questions, typed answers, and a threshold your code can defend.