GUIDE

What is SQL-first AI accounting?

What is SQL-first AI accounting?

Short answer: SQL-first AI accounting is an approach in which every reported number (a match, a tie-out, a total, a variance, a ratio) is computed by a saved SQL query, and AI is used only to read, draft and explain. Because the query is saved with the result, anyone with the same data can rerun it and get the same number.

The principle in four words: AI explains, SQL computes. The result: every number explains itself.

Why not let the AI calculate?

Short answer: Language models are probabilistic. The same prompt can give slightly different output on different runs, and the model can't show a reviewer a reproducible method. That's acceptable for a draft memo. It isn't acceptable for a reconciliation difference, an accrual or a covenant ratio that someone has to sign.

Generative-first ("the AI did it")SQL-first (Yoraito)
Who computes the numberThe modelA saved SQL query
Same inputs, same output?Not guaranteedYes
How a reviewer checksRe-does the work or trusts itReads the query and reruns it
How an auditor testsRe-performs by handReruns the query on the same data
Where AI helpsEverywhere, including numbersReading documents, drafting rules, writing explanations
What happens when unsureMay guessFlags the item for a person

What does deterministic mean here?

Deterministic means the same inputs always produce the same outputs. In Yoraito, matching, classification and validation run as SQL against a DuckDB engine. Approved rules run on fresh data each month without the model in the loop, so totals don't drift from one run to the next.

How does a reviewer or auditor rerun a number?

  1. Open the figure and select View SQL.
  2. Read the query: which accounts, dates, filters and matching rule it uses.
  3. Check the inputs it ran against: source, row counts and totals.
  4. Rerun the query on the same data. The result should match to the cent.
  5. Check the sign-off: preparer and reviewer, recorded separately with dates.

Illustrative: a prepaid reconciliation shows a $7,500.00 difference. Q06 rebuilds the expected balance from the schedule, Q08 finds an expired insurance policy still carrying $4,500.00, Q09 finds a $3,000.00 software prepayment missing from the schedule, and Q10 returns an unexplained difference of $0.00. An auditor reruns Q06 to Q10 and gets the same answers.

Where does AI fit in a SQL-first close?

AI doesAI doesn't
Reads invoices, statements and contracts (with rule-based checks on what it read)Type any reported number
Drafts close rules from your history for a person to approveApprove its own rules
Writes variance and reconciling-item notes, citing transactionsPost to the ledger
Labels each draft Evidenced, Likely or Needs ownerHide uncertainty
Proposes entriesTreat text inside a document as an instruction

Is SQL-first the same as "no AI"?

No. SQL-first keeps AI where it is strong and keeps it out of the arithmetic. Teams get faster preparation and faster review, because the reviewer checks a query rather than rebuilding the work. AI drafting can also be switched off for a close, and the approved SQL still runs.

What should we ask a vendor to test whether it is SQL-first?

  1. Show me the query behind this reconciled balance.
  2. Run it twice. Is the result identical?
  3. Can my auditor rerun it without your product?
  4. Which numbers on this screen came from a model?
  5. When a rule changes, who approved it and when?

Frequently asked questions

What is SQL-first AI accounting?

An approach where saved SQL queries compute every reported number and AI only reads, drafts and explains, so each figure can be rerun and reproduced.

Is deterministic AI safer for the close than generative AI?

For numbers, yes: deterministic computation gives the same answer every time and can be reperformed. Generative AI is useful for language tasks, under review.

Do reviewers need to know SQL?

No. Matching rules are written in plain terms your team can read and approve verify: whether query views carry plain-language labels. Auditors and technical reviewers can read and rerun the SQL itself.

Which product uses SQL-first AI accounting?

Yoraito is built on this approach for the close, AP and AR. > FAQPage note: Mark up all four Q&As. Also mark "SQL-first AI accounting" as a DefinedTerm.

See your close with the SQL behind every number.

A 30-minute call with your ERP, entity count and close calendar in front of us.