Decision API for AI applications and agents

Fast decisions. Your rules.

Turn your business rules into decisions, amounts and deadlines your AI app can use. AI drafts the model; the engine runs the rules you reviewed. Test a change before you ship it.

Approved accounts include credits to test your own policy in the console and API.

Using Jev? Bring your request format →

Should we pay this invoice? How much—and by when?

Watch an original invoice policy become working rules, then test the cutoff and a new discount. Pause or skip to any step.

aityx0.98
Balance $10.00API docsAPAlex ⌄
Playground / New decision
Examples+ NewLoad modelDownload modelDownload receipt
QuestionsDescribe model
Define your questions, with one key per answer.
{
  "payment_action": {
    "type": "choice",
    "instructions": "Unapproved invoices go to review. Approved invoices get 2% off if payment_on is within 10 calendar days of invoice_date (inclusive); otherwise pay in full.",
    "criteria": {"discount":"Pay at the discount rate.","full":"Pay the full amount.","review":"Needs approval."}
  },
  "payable_amount": {
    "type": "number",
    "instructions": "Return USD payable: zero for review; 98% of invoice_amount for discount; otherwise invoice_amount. Round to cents.",
    "criteria": {"unit":"USD","range":">= 0"}
  },
  "discount_by": {
    "type": "date",
    "instructions": "Return the last discount date: invoice_date plus 10 calendar days."
  }
}
JSONVisual
☰ Fields{ } JSON Schema
+ Add ⌄Suggestions as you typeSuggest ⌃Space
InputJSON
Questions · System Two ⌄
▶ Create & run ⌘↵
{
  "invoice_amount": 25000,
  "invoice_date": "2026-10-01",
  "payment_on": "2026-10-11",
  "approved": true
}
AnswersInputsRaw
Run to see answers

Start with your invoice and payment terms. Create the rules, then inspect the calculated amount and deadline.

$25,000 invoice: $24,500.00 by October 11Matching JSON: 6 ms recorded executionDiscount revision: 3 of 6 recorded test results change

Built by Aletyx, a team with nearly two decades of enterprise decision experience.Meet the team →

Why aityx

A plausible answer isn’t enough
when your app moves money.

You need a calculation you can verify and a rule you can explain. aityx executes your reviewed model and returns the inputs and the rules that fired with the answer.

Inspect the recorded answer and receipt
{
  "model": {
    "content": {
      "name": "Invoice Payment Terms",
      "inputs": {
        "approved": {
          "type": "boolean",
          "desc": "Has the invoice been approved?",
          "from": "approved"
        },
        "invoice_amount": {
          "type": "number >= 0",
          "desc": "What is the invoice amount in USD?",
          "from": "invoice_amount"
        },
        "invoice_date": {
          "type": "date",
          "desc": "What is the invoice date?",
          "from": "invoice_date"
        },
        "payment_on": {
          "type": "date",
          "desc": "On what date will payment occur?",
          "from": "payment_on"
        }
      },
      "decisions": {
        "payment_action": {
          "desc": "Unapproved invoices go to review. Approved invoices get 2% off if payment_on is within 10 calendar days of invoice_date (inclusive); otherwise pay in full.",
          "table": [
            [
              "approved",
              "payment_on >= invoice_date and payment_on <= discount_by",
              "=> discount|full|review",
              "# why"
            ],
            [
              "false",
              "-",
              "review",
              "Unapproved invoices require review regardless of payment date."
            ],
            [
              "true",
              "true",
              "discount",
              "Approved invoices paid from the invoice date through the tenth calendar day qualify for 2% off."
            ],
            [
              "-",
              "-",
              "full",
              "Approved invoices outside the inclusive discount window are payable in full."
            ]
          ]
        },
        "payable_amount": {
          "desc": "Return USD payable: zero for review; 98% of invoice_amount for discount; otherwise invoice_amount. Round to cents.",
          "table": [
            [
              "payment_action",
              "=> number >= 0",
              "# why"
            ],
            [
              "review",
              "0",
              "An invoice awaiting approval has zero payable amount."
            ],
            [
              "discount",
              "round cents(invoice_amount * 0.98)",
              "The discount reduces the invoice amount by 2%, rounded to cents."
            ],
            [
              "-",
              "round cents(invoice_amount)",
              "The full invoice amount is payable, rounded to cents."
            ]
          ]
        },
        "discount_by": {
          "type": "date",
          "desc": "Return the last discount date: invoice_date plus 10 calendar days.",
          "expr": "invoice_date + duration(\"P10D\")"
        }
      },
      "functions": {
        "round cents": {
          "params": {
            "amount": "number >= 0"
          },
          "returns": "number >= 0",
          "body": "decimal(amount, 2)"
        }
      }
    },
    "questions": {
      "payment_action": {
        "type": "choice",
        "instructions": "Unapproved invoices go to review. Approved invoices get 2% off if payment_on is within 10 calendar days of invoice_date (inclusive); otherwise pay in full.",
        "criteria": {
          "discount": "Pay at the discount rate.",
          "full": "Pay the full amount.",
          "review": "Needs approval."
        }
      },
      "payable_amount": {
        "type": "number",
        "instructions": "Return USD payable: zero for review; 98% of invoice_amount for discount; otherwise invoice_amount. Round to cents.",
        "criteria": {
          "unit": "USD",
          "range": ">= 0"
        }
      },
      "discount_by": {
        "type": "date",
        "instructions": "Return the last discount date: invoice_date plus 10 calendar days."
      }
    }
  },
  "input": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "title": "Invoice Payment Terms",
    "type": "object",
    "properties": {
      "approved": {
        "type": "boolean",
        "description": "Has the invoice been approved?",
        "x-jev-from": "approved"
      },
      "invoice_amount": {
        "type": "number",
        "minimum": 0,
        "description": "What is the invoice amount in USD?",
        "x-jev-from": "invoice_amount"
      },
      "invoice_date": {
        "type": "string",
        "format": "date",
        "description": "What is the invoice date?",
        "x-jev-from": "invoice_date"
      },
      "payment_on": {
        "type": "string",
        "format": "date",
        "description": "On what date will payment occur?",
        "x-jev-from": "payment_on"
      }
    },
    "required": [
      "approved",
      "invoice_amount",
      "invoice_date",
      "payment_on"
    ],
    "additionalProperties": false
  },
  "answers": {
    "payment_action": {
      "type": "choice",
      "choice": "full",
      "confidence": 1,
      "probabilities": {
        "discount": 0,
        "full": 1,
        "review": 0
      }
    },
    "payable_amount": {
      "type": "number",
      "number": 25000,
      "confidence": 1
    },
    "discount_by": {
      "type": "date",
      "date": "2026-10-11",
      "confidence": 1
    }
  },
  "receipt": {
    "state": {
      "kind": "json"
    },
    "given": {
      "approved": true,
      "invoice_amount": 25000,
      "invoice_date": "2026-10-01",
      "payment_on": "2026-10-12"
    },
    "read": {},
    "decisions": {
      "payment_action": {
        "value": "full",
        "rule": 3,
        "rows": "xxF",
        "columns": {
          "payment_on >= invoice_date and payment_on <= discount_by": false
        },
        "cells": [
          "FT",
          "TF",
          "TT"
        ]
      },
      "payable_amount": {
        "value": 25000,
        "rule": 3,
        "rows": "xxF",
        "cells": [
          "F",
          "F",
          "T"
        ]
      },
      "discount_by": {
        "value": "2026-10-11"
      }
    },
    "receipt": "18e93cef-a415-4dc3-9255-0a981115439a",
    "model": "Invoice Payment Terms",
    "mode": "defined",
    "created_at": "2026-10-05T04:45:05.450664Z",
    "latency_ms": 5,
    "reader": null,
    "answers": {
      "payment_action": {
        "type": "choice",
        "choice": "full",
        "confidence": 1,
        "probabilities": {
          "discount": 0,
          "full": 1,
          "review": 0
        }
      },
      "payable_amount": {
        "type": "number",
        "number": 25000,
        "confidence": 1
      },
      "discount_by": {
        "type": "date",
        "date": "2026-10-11",
        "confidence": 1
      }
    },
    "provider_usage": {
      "input_tokens": 0,
      "output_tokens": 0
    },
    "billing": {
      "currency": "USD",
      "estimated": false,
      "complete": true,
      "cost_usd": 0.000028896,
      "estimated_cost_usd": 0.000028896,
      "priced_cost_usd": 0.000028896,
      "items": [
        {
          "category": "system_one",
          "operation": "execution",
          "status": "completed",
          "token_source": "api",
          "input_tokens": 688,
          "output_tokens": 1117,
          "usage_complete": true,
          "provider_calls": 0,
          "input_usd_per_million": 0.042,
          "output_usd_per_million": 0,
          "cost_usd": 0.000028896,
          "estimated_cost_usd": 0.000028896,
          "includes_execution": false
        }
      ],
      "balance": {
        "currency": "USD",
        "balance_usd": 9.976565312,
        "reserved_usd": 0,
        "available_usd": 9.976565312
      }
    },
    "call_usage": {
      "input_tokens": 688,
      "output_tokens": 1117
    },
    "usage": {
      "input_tokens": 688,
      "output_tokens": 1117
    }
  },
  "cache_hit": false,
  "provider_usage": {
    "input_tokens": 0,
    "output_tokens": 0
  },
  "usage": {
    "input_tokens": 688,
    "output_tokens": 1117
  },
  "billing": {
    "currency": "USD",
    "estimated": false,
    "complete": true,
    "cost_usd": 0.000028896,
    "estimated_cost_usd": 0.000028896,
    "priced_cost_usd": 0.000028896,
    "items": [
      {
        "category": "system_one",
        "operation": "execution",
        "status": "completed",
        "token_source": "api",
        "input_tokens": 688,
        "output_tokens": 1117,
        "usage_complete": true,
        "provider_calls": 0,
        "input_usd_per_million": 0.042,
        "output_usd_per_million": 0,
        "cost_usd": 0.000028896,
        "estimated_cost_usd": 0.000028896,
        "includes_execution": false
      }
    ],
    "balance": {
      "currency": "USD",
      "balance_usd": 9.976565312,
      "reserved_usd": 0,
      "available_usd": 9.976565312
    }
  }
}

This payment missed the discount cutoff by one day. The receipt records the full-payment rule that fired. Keep the complete model, original input and receipt together in your application.

How it works

Build the rules once.
Use them for every new case.

Keep the complete model, send it with each case, and switch rules when your tests say it’s ready.

1Create & review

Review the rules you’ll use.

Inspect the draft and try a boundary case. Keep the rules that match your policy.

Download the complete model as JSON.

2Execute

Run each case against those rules.

Your app sends that model with each new case. Get the decision, calculated values and receipt back together.

Matching JSON runs directly; text may need AI extraction.

3Compare & adopt

Check a change before switching.

Run the same cases against both models. Adopt the revision when the results meet your expectations; keep the original for rollback.

Your application controls which model it submits.

Use cases

Know what to approve, pay, or send for review.

Build payments, approvals and review queues around your own policy. The invoice example is recorded; the other applications are illustrative.

Finance operations · recorded example

Pay the right amount, on time.

Apply your payment terms to return the payable amount, discount deadline and approval outcome.

Test the exact cutoff and compare a new discount before it affects a payment.

See the example input and answer
Input
{ "invoice_amount": 25000, "invoice_date": "2026-10-01", "payment_on": "2026-10-11", "approved": true }
Answer
{ "payment_action": "discount", "payable_amount": 24500, "discount_by": "2026-10-11" }

Teams building AI agents

Check the agent’s action before it acts.

Have your agent check a proposed refund or discount against your policy before your application carries it out.

Return allow or deny, the applicable limit, and whether approval is needed.

Illustrative input and answer
Input
The proposed action and the account state.
Answer
{ "allowed": true, "max_discount": 21, "needs_vp": false }

Illustrative values, shown without the API envelope. Your policy defines the limits and outcomes.

Finance operations

Send the right expenses for review.

Approve, reject, or route an expense to a manager using your thresholds and submission window.

Calculate cost per person and elapsed days in the model. Compare saved cases before changing a limit.

Illustrative input and answer
Input
{ "amount": 184, "people": 3, "expense_date": "2026-03-02", "submitted_on": "2026-04-12" }
Answer
{ "disposition": "manager", "cost_per_person": 61.33, "elapsed_days": 41 }

Illustrative values, shown without the API envelope. Your policy defines the limits and outcomes.

More applications: travel compensation, rental income, and SLA credits

Illustrative applications. Write and test the rules from your own policy.

Calculate travel compensation.

Calculate payouts from delay duration, cause, loyalty tier, and meal or hotel caps.

Apply time windows and capped sums as explicit rules.

Apply your rental-income policy.

Calculate qualifying rental income, debt-to-income ratio, and reserves from your policy.

Compare recorded cases across policy versions before switching.

Calculate the service credit owed.

Return the credit percentage and amount from monitoring data or an incident report.

Apply uptime calculations, maintenance exclusions, and submission deadlines together.

Already have access? Open the console examples →

Get started

Start with the questions or policy
you already have.

Follow the invoice quickstart, or choose the starting point closest to your work.

Using Jev? Bring your request format.

Keep your state-and-questions format. Inspect the returned rules and review confidence behavior before using them in your app.

Coming from Jev →

Write or edit the rules yourself.

Write compact JSON or edit a generated model. Validate your rules before executing them.

Define a model by hand →

Pricing

Build once. Run from $0.042
per million input tokens.

Use AI to build or revise your rules. Execute the reviewed model at the lower rate with matching JSON inputs.

Run your model

System One rate
$0.042input
Freeoutput

per 1M input tokens

Send your complete model with matching JSON. Input billing includes the model and case; answers and the receipt have no output charge.

Ask, create or revise

System Two rate
$4input
$20output

per 1M tokens, input · output

Create or revise rules, ask questions with state, or extract facts with AI. Questions-based calls use this rate even when a cached model is reused.

The recorded invoice execution cost <$0.001 with the complete model and matching JSON.

The request determines the rate: sending questions stays at System Two pricing, even on a cache hit. Sending your model with matching JSON uses System One pricing. AI input extraction adds a separate System Two charge. Each call shows its usage and charge. Prices in USD.

Integration questions

Know what you can rely on.

Will the same inputs give the same answer?

Yes, for the same decision model and validated inputs. Matching JSON runs directly on the decision engine. Text is read into typed inputs first, so the receipt separates facts you supplied from facts the AI reader extracted. You can inspect that reading as well as the rule that fired.

Can I inspect the rules before my app uses them?

Yes. Build a model in the console or through System Two, read and edit its JSON or diagram, and test it with sample cases. Keep the definition you reviewed and send it with each execution. If you start by sending questions through System One, aityx creates or reuses a model and returns it with the answer so you can inspect the rules.

What happens when a required fact is missing?

aityx attempts to read unresolved inputs from the data you supplied. A required fact that is absent, unsupported, or below its confidence threshold returns invalid_state before execution. Your application can ask for the missing information or route the case for review.

What does AI do, and what does the engine do?

AI creates and revises the model, and reads text into typed inputs when needed. The aityx decision engine executes the model’s rules to produce the answer. You keep the model and a receipt of the execution, so you can check both the inputs and the decision logic.

What changes if I already use Jev?

You can keep the systemone request format and use your aityx base URL and API key. The response includes answers and usage, plus a decision model you can keep and an execution receipt. Confidence now reflects a result executed from a model and its inputs, rather than Jev’s classification signal. Review any confidence-based routing before switching. You can also add number and date questions.

Can I start from a document?

Yes. System Two accepts a prompt with PDFs, images, spreadsheets, Word documents, or text files, plus an optional result format. It returns a model definition you can inspect, edit and test before your application uses it.

Does aityx save my models and receipts?

The tech preview returns models and receipts for you to keep. The console holds decision data during the current session; download it before refreshing or leaving. aityx may reuse generated models through a temporary cache, but that cache is not a saved-model library. Account, access and billing records are retained separately.

Who is behind aityx?

aityx is built by Aletyx, the team behind Aletyx Platform. It brings the team’s experience building enterprise decision systems to a focused API and console for AI applications and agents.

Can it run in our environment?

The tech preview is hosted. Contact the team to discuss private deployment requirements.

Tech preview

Try one decision before you build around it.

Try the worked invoice example, then test your own rules before integrating. Approved preview accounts include credits for console and API calls.