Skip to main content
Glama
fincon

fincon

by Abishai95141

Close the books with a proof, not a plug.

fincon.astutecomputer.com

FinCon reconciles what your payment gateway says it paid out against what the bank actually received, writes the double entry, and hands back what is left — ranked, priced and routed to a desk. Every match carries arithmetic an auditor re-derives without us.


The problem

Reconciliation software already matches 90–99% of transactions. Trintech publishes 99%+. NetSuite ships N:M rules with a confidence-scoring assistant. That problem is solved, and anything pitching "our AI matches better" is competing on the one dimension nobody needs help with.

Two costs survive automation, and neither is a matching problem.

The tail comes back with no reason attached. Bank-feed automation cuts a reconciliation from roughly 47 minutes to exception handling only — which is the whole story in one statistic: the matched records were never the cost. But the 1–10% that fails returns as a flat queue, and the controller re-derives the context by hand, row by row. Volume fell. Cost per item did not.

And the rate decays. Auto-match rates are maintained, not achieved. A new vendor format silently degrades matching until somebody writes a rule, and rule authoring is gated behind engineering — so the person who understands the exception is never the person who can fix it.

What a controller does today: pull three exports, match at payout level because row level is impossible, book the difference as a plug, spend three days in Excel when it does not tie, hand-type the journal, and watch the identical tail come back next month.


Related MCP server: dingdawg-finance-agent

The solution

Open intake, verified commit. The model proposes. A deterministic engine proves. A named human decides.

The AI does three jobs, and they are the three that need it

This is not a rules engine with a chatbot bolted on, and it is not a model guessing at arithmetic. The model is pointed at exactly the work no deterministic system can do:

Reads a format nobody configured

A settlement file in a layout we have never seen. The model reads twelve raw lines and authors the parse spec — delimiter, header row, minor units, a non-ISO date. It ingests with no integration project.

Names the tail

What the arithmetic could not resolve goes to the model with the near misses the engine derived, and comes back with a code, a hypothesis and cited evidence in about 2.1s.

Writes tomorrow's rule

You resolve a break in your own words; the model induces a deterministic rule that would have prevented it. R-DUP-06 was written this way, from a controller's sentence, and fires on every close since.

The system gets more deterministic over time, not more agentic. That is the opposite of how agent products usually age, and it is the entire thesis.

And it is fenced, which is why you can switch it on

Language models collapse from 95.6% on lookups to near zero on multivariate calculation, and they fail confidently. So the model is kept off the arithmetic by construction — every boundary below is a test that fails if someone removes it:

  • No model call in a close. Six stages, zero model calls, and the receipt says so.

  • A proposal cannot overwrite a derived answer. P2 at best, and it may not overwrite P0 ARITHMETIC — an item the engine derived is never even offered.

  • No generated code is executed. No eval, no exec. Adapters are declarative specs read by a closed vocabulary of parse verbs.

  • No tool carries authority. Not one MCP tool accepts a policy, a tolerance, a sign convention or a rule set — checked against the generated schemas.

Proof on every row, and four honest endings

Every accepted match emits an arithmetic object, not a confidence score: both sides' record ids, the residual closing to zero, the tolerance consumed, the rule that fired. A match without a passing proof is not a match and does not appear in the match count.

match M-0412   tier T2 subset-sum   rule R-017@v3
  payout    BANK/2026-08-14/CR         +4,378.21
  charges   87 × settlement rows       +4,612.90
  refunds    4 × settlement rows         -118.40
  fees     162 × settlement rows         -114.02
  ────────────────────────────────────────────
  residual                                  0.00    tolerance used 0.00 / 0.50
  verdict   PROVEN      provenance  P0 ARITHMETIC

Everything left over is ranked by cash impact × age and routed to a desk. Each item ends in double entry — book it, carry it forward, chase it, or write it off — under your name, bounded twice by signed policy.


Impact

Measured against labels authored before the engine existed, and re-derived from the decision log alone:

Auto-match

90.9% — 20 of 22 anchors, by tier T0=17 T1=2 T4=1

False matches

0.00%

Exception coverage

6 / 6 — every planted defect found

Classification

4 / 6 correct

Ambiguity

1 / 1 detected and refused rather than guessed

Journal

23 entries, balanced — and the beancount export is re-loaded by beancount itself

Close time

about 1.4s, with zero model calls

The generality is measured, not asserted. A second reconciliation — Form 26AS from the Income Tax Department against a TDS receivable ledger, matched on TAN + section + quarter over an April–March year — runs on the same engine with zero changes to it, asserted byte-for-byte by its gate.

Where it says it does not know. Three of seven items in a real close are E14 — the engine cannot say why — and that is printed at the top of the tail rather than smoothed into a plausible guess routed to the wrong desk. E09 is the one to pause on: two distinct subsets sum to the same credit within tolerance, so there is no correct answer to pick, and every tool that returns the first subset it finds is confidently wrong there.


Point an assistant at it — MCP

FinCon is a Model Context Protocol server. Ask "what is blocking the October close, biggest first?" and it reads the record, runs a deterministic close, verifies a proof, resolves an item and signs off — as you, because it holds a token you issued.

// Claude Desktop, Claude Code, or any MCP client
{
  "mcpServers": {
    "fincon": { "url": "https://fincon.astutecomputer.com/mcp" }
  }
}

OAuth via Cognito, discovery at the origin per RFC 9728, dynamic client registration. Or run it on stdio against your own files: make mcp.

21 tools; 4 of them write. An assistant is not a stranger — it carries your credential, and the sub on that token is the same string your browser session resolves to. So it can do what you can do, and every decision records the door it came through, so a year from now you can tell which items you read and which you delegated. The bounds that matter — the write-off ceiling, the budget, the balance check, items nobody has opened — were never questions about who was calling, and they bind an agent identically.


Architecture

The model proposes → the engine proves → a human decides. Nothing crosses a boundary without a proof or a name.

  SOURCES                    ENGINE  (no model, ever)                 RECORD
  ─────────                  ────────────────────────                 ──────
  bank CAMT.053 ┐            ┌──────────────────────┐
  settlement    ├─ intake ──▶│ block → match         │──▶ verify ──┐
  order register┘   │        │ T0 exact              │   re-derive │
  Form 26AS     ┘   │        │ T1 tolerant           │   from raw  │
                    │        │ T2 subset-sum         │   records   │
              5 proofs       │ T4 declared           │             ▼
              row count      └──────────┬───────────┘      ┌──────────────┐
              control total             │                  │ double entry │
              roll-forward         unmatched               │ + balance    │
              type/domain              │                   │   assertion  │
              idempotence              ▼                   └──────┬───────┘
                              ┌────────────────┐                  │
                              │ near-miss      │                  ▼
                              │ diagnosis      │           hash-chained
                              │ (arithmetic)   │           decision log
                              └───────┬────────┘                  │
                                      │ genuinely unexplained     │
                                      ▼                           │
                        ╔═════════════════════════╗               │
                        ║  MODEL  (proposes only) ║               │
                        ║  adapter synthesis      ║               │
                        ║  classification         ║               │
                        ║  rule induction         ║               │
                        ╚═══════════╤═════════════╝               │
                                    │ P2 at best, never overwrites P0
                                    ▼                             │
                        ┌───────────────────────┐                 │
                        │  HUMAN decides        │◀────────────────┘
                        │  book · carry · chase │
                        │  · write off · sign   │
                        └───────────┬───────────┘
                                    ▼
                          close pack · journal.csv
                          journal.beancount · POST /v1/verify

Proof tiers, because a real close contains items nobody can derive from arithmetic alone. The rule is never move silently, not refuse what you can't prove:

P0 ARITHMETIC re-derivable by anyone · P1 RULE a promoted, regression-tested rule fired · P2 ATTESTED a named human approved it · P3 DECLARED accepted with a stated gap.

Hosted on AWS

Live at https://fincon.astutecomputer.com — one CloudFormation stack in ap-south-1. Full breakdown, including the four decisions worth arguing about and what this estate deliberately lacks, in docs/14-AWS.md.

   Cloudflare DNS ──▶ ALB (ACM, TLS 1.3) ──▶ ECS Fargate ──┬─▶ EFS  runs + uploads
                       :80 → :443           1 task          ├─▶ Cognito   identity
                       /healthz 30s         256cpu/512mb    ├─▶ Secrets Manager
                                            screens · API   └─▶ CloudWatch Logs
                                            · MCP /mcp

EFS rather than S3 because the decision log is append-only and hash-chained and the writer takes a POSIX lock — and flock silently does not work on EFS, which nearly ended the choice. Public subnets, no NAT — a $32/month gateway for a single-task estate, traded for a security group that admits only the ALB. Images tagged by commit sha, never latest, so a rollback is nameable.


Run it

make setup     # uv sync
make gen       # regenerate the synthetic batches from a seed
make verify    # every green gate
make serve     # → http://127.0.0.1:8000/
make eval      # 4 ablation arms, 9 metrics, batches A and B
make mcp       # MCP on stdio

make test and make verify need no API key — the model-backed gates are excluded and named in the output, because a silently skipped gate that reads as green is the failure this whole repository is about.


Verify it without us

The claim is not "trust our numbers". Hand an auditor the decision log and the source files, and they re-derive every match on a public endpoint that needs no account and touches none of our state:

curl -X POST https://fincon.astutecomputer.com/v1/verify \
     -H 'content-type: application/json' -d @docs/sample-proof.json

docs/sample-proof.json is a real one, lifted out of batch A's decision log — a proof and the 23 records it cites. It answers "proven": true. Change one amount in it and it comes back refuted, with the recomputed residual and the leg whose subtotal stopped adding up:

{"proven": false, "recomputed_residual": "-50.00", "reasons": [
  "leg 'settlement': claimed subtotal 51990.42 but its 22 record(s) sum to 52040.42 (delta 50.00)",
  "claimed residual 0.00 but the records give -50.00 (delta -50.00)"]}

Your own proofs come out of GET /v1/runs/{id}/export, which returns every decision in a close beside the records it rests on.

Every verdict names the policy it was produced under and stamps whether that policy was in force or caller-supplied — because a verdict produced under a policy somebody brought with them must never come back indistinguishable from one produced under ours.


Documentation

CLAUDE.md

Standing context — the rules, the vocabulary, the eight invariants

STATUS.md

Live build state, with the command output that proves each gate

docs/01-DECISION-SPEC.md

Problem, solution, trade-offs

docs/08-AS-BUILT.md

What actually runs today

docs/10-THE-USER-FLOW.md

The flow, and what it is worth

docs/13-THE-SCREENS.md

Every screen, and the question it answers

docs/14-AWS.md

The AWS estate, in full

docs/15-DEMO.md

The demo film — how it is shot, cut and re-shot

docs/16-SCRIPT.md

The voiceover, timed against the cut

docs/decisions/

ADRs — two of them irreversible

Try FinCon →  ·  Contact

Available Tools

21 tools
accept_classificationA

Accept a proposed code for an exception, under your name.

propose_reclassification asks whether a code would be admissible and writes nothing. This is the other half: it records that somebody accepted it. Same checker, same refusals — a proposal may still not overwrite a code the engine derived, because a guess does not outrank arithmetic no matter who signs for it.

Inputs: code (required), run_id (required), rationale (required), exception_id (required). Returns: object

audit_exportA

Everything needed to re-derive a close, and nothing that requires us.

Every decision with its proof, the rule version that fired, the human who approved the authority, the source document hashes and the adapter spec ids that read them. how_to_verify spells out the four steps; none of them touch our database or our network.

Inputs: run_id (required), limit, offset. Returns: object

dispose_exceptionA

End an exception in a journal entry: book, carry_forward, chase, write_off.

This moves money, and it is meant to. The item leaves the worklist, double entry is written, and the record carries your name and the fact that an agent put it there.

What it will still refuse, all of it from the loop's signed policy and none of it from you: a write-off above the per-item ceiling, one that would exhaust the close's write-off budget, a book on a code the taxonomy has not promoted, and any second disposition of an item already ended. There is no ceiling parameter and no chart parameter, so there is nothing to widen.

due_on is YYYY-MM-DD and applies to chase only.

Inputs: run_id (required), rationale (required), disposition (required), exception_id (required), +2 more. Returns: object

explain_exceptionC

One exception with its evidence, its records and what it is allowed to do.

E14 unexplained means no strategy matched and the engine cannot say why. It carries the facts it has and leaves classification open on purpose: "I do not know" out loud beats a plausible guess routed to the wrong desk.

Inputs: run_id (required), exception_id (required). Returns: object

fetch_recordsD

The records a loop reads, a budget at a time.

Here for completeness, and worth skipping: verifying our arithmetic against records we handed you proves the sum and not the honesty. The source files, the adapter specs and the policy are all published — ingest them yourself and verify against those.

Inputs: loop (required), source_set (required), limit, offset. Returns: object

get_authorityB

The policy, vocabulary and promoted rules governing a loop — and who signed.

Codes carry their lifecycle state: naming one grants nothing, and only a promoted code may direct a posting. Rules carry the human who approved them and the policy that approval was granted under; an approval is re-checked against the policy in force wherever the rule acts, so a rule approved under an old policy does not quietly keep its permissions.

Inputs: loop (required). Returns: object

get_closeA

A recorded close, rebuilt from its decision log.

Match rate with its tier split and its proof-tier split, what is blocked, what is waiting on a human, which authority it ran under and whether that authority's signature held. Blocking recall is reported absent rather than zero: it is measured against labelled true pairs and production has no labels — a zero there would be a claim we did not earn.

detail="summary" (the default) names each match and its proof_id without inlining twenty proofs; get_proof returns the one you want to read. detail="full" inlines them all and is ~59 KB. A projection, not a permission — it changes how much of the answer travels, never what it is.

Inputs: run_id (required), detail. Returns: object

get_contractsA

JSON Schema for the public, semver'd shapes — Record, Proof, Policy, Event.

Published so another system can build on them. They are versioned under ADR-002: a field change is a version bump, not an edit, because an independently-written verifier that stops working is the one failure this design cannot survive.

Inputs: no named parameters. Returns: object

get_eventsB

The typed decision log, event by event, hash-chained.

Append-only in the only sense a file can be: each event carries the hash of the one before it, so an edit, a deletion or a reorder breaks the chain and verify_journal says where. It does not prove custody — someone able to rewrite the whole file can recompute the chain over anything. What it closes is the partial edit and the truncated tail.

Paged: 62 events for a 22-payout month is 114 KB. total is always the real total, so "here is the log" and "here is the start of the log" stay distinguishable — which a bare list could not manage.

Inputs: run_id (required), limit, offset. Returns: object

get_proofA

One match with its full proof — every leg, its record ids and its subtotal.

What a verifier reads before calling verify_proof. The subtotals here are claims made by whatever produced the match; recomputing them from the records is the entire job, and verify_proof refuses a proof whose legs do not add up to what it says.

Inputs: run_id (required), match_id (required). Returns: object

get_worklistB

The exception queue, ranked by cash impact x age and routed to an owner.

This is the tail, and the tail is the product. An item whose code has not been ratified carries a note saying so — a proposed category rendered identically to a promoted one would hide the one thing you need in order to know how much to trust it.

Inputs: run_id (required). Returns: result

list_loopsA

The reconciliation loops this controller can close.

Each carries the policy and taxonomy governing it, the strategies it matches with in the order it tries them, the source files it expects, and any promoted rules in force. Read it before asking for a close: the loop decides what a "side", a "counterparty" and a "tolerance" mean, and nothing here is hardcoded in the engine.

Inputs: no named parameters. Returns: result

list_runsC

Closes already recorded, by run id.

A run id is derived from the source bytes and the authority in force, so re-closing identical inputs under an unchanged policy reuses the id rather than creating a second record of one event.

Inputs: no named parameters. Returns: result

list_source_setsB

Which periods' source files are on disk, complete or not.

Incomplete ones are listed with the missing filenames named. A close over a half-arrived period would report a clean month over rows that never came, so it is refused — but the fact that October is short one file is the useful answer, not an empty list.

Inputs: loop (required). Returns: result

propose_reclassificationA

Ask whether a proposed code for an exception would be admissible.

Nothing is written. The proposal goes through the same checker the live triage path uses: the code must resolve in the registry and be assignable, the hypothesis must exist, the evidence must cite a record the exception actually names, and the exception's own label must not already rest on stronger evidence than a proposal can carry. A derived E09 — one the engine proved by enumerating two valid subsets — outranks any proposal and is refused here, which is the rule that stopped a model overwriting a proven answer with a guess.

A verdict of admissible: true means the proposal is well-formed and permitted, not that it is right. Making it so is accept_classification, which writes under the name on your credential.

Inputs: code (required), run_id (required), evidence (required), hypothesis (required), +1 more. Returns: object

reverify_closeA

Re-derive a whole recorded close from the source files on disk.

Re-ingests the sources with the published adapter specs, checks each document's sha256 against the hash the record pinned, and re-derives every proof in the log against those fresh records. Nothing is read from the memory of the process that ran the close, so this is the same thing an outside auditor does — done by us, on demand.

Three failure modes, reported apart because they mean different things. sources_match false means you pointed it at different bytes than the close ran on: your mistake, not our finding. refuted means the arithmetic does not hold: our finding. missing_proofs means the record has no proof to check, which is a gap in the evidence and deliberately does not pass.

Inputs: run_id (required), source_set (required). Returns: object

run_closeA

Close one period: match, verify, post, record.

Note what this does not take. There is no policy argument, no tolerance, no rule set and no chart of accounts — a caller picks which loop and which period and nothing else, and everything that decides whether an answer is permitted is loaded from the loop's own signed bundles. You cannot widen a tolerance through this tool because there is no parameter through which to try.

Every posting it writes descends from a proof that was re-derived from raw records before anyone saw it; a match that fails re-derivation is dropped and its refusal recorded. The return value is read back out of the decision log the close just wrote, so what you see is what an auditor holding that file would see.

Inputs: loop (required), source_set (required). Returns: object

run_matchA

Match one period and return the proofs — no posting, no ledger, no log.

The matching stage on its own, for a caller that wants to check our arithmetic rather than have us close the books. Returns proven matches with their full proofs, everything the verifier refused, and the exceptions raised.

The records are not inlined — 543 rows of this toy corpus is ~342 KB, most of a context window. fetch_records pages them. But ignore them: ingest the same source files with the published adapter spec and verify against your own records. That is what verify_proof is for and it is the only version of this that proves anything about our honesty.

Matches page too, proofs included, because a caller here is calling for the proofs. match_page.next_offset is the cursor; it is null when you have them all, and total is always the real total.

Inputs: loop (required), source_set (required), limit, offset. Returns: object

sign_off_closeB

Accept the close. The terminal decision, and the strongest claim here.

Three refusals stand, and they bind an agent exactly as they bind a person at a screen, because none of them was ever a question about who was calling: books that do not balance, blocking items nobody has opened, and an unnamed signer. Delegating to an agent does not make an unopened item opened — read the worklist first, the same as anyone would.

The pack records that this signature arrived through an agent. That is not a hedge against you; it is what lets a reader a year from now tell the difference between a close somebody read and a close somebody automated.

Inputs: run_id (required), note. Returns: object

verify_journalB

Check a decision log's hash chain and its terminator.

The terminator states how many events precede it and what was decided; those are claims by the writer, and this checks them against the stream. A valid chain over a truncated log is still a valid chain, which is exactly why the terminator has to be there.

Inputs: run_id (required). Returns: object

verify_proofA

Re-derive one proof from records you hold. Stateless, and it trusts nothing.

The verifier fetches each record by id, recomputes every leg subtotal and the residual from those records, and compares against what the proof claims. It reads no stored residual, takes its sign convention from policy rather than from the proof, and refuses a proof whose claimed tolerance exceeds the policy ceiling. A proof that names a record you did not supply is refuted, not excused.

Name a loop to verify under that loop's published policy, or hand in a policy of your own. Exactly one — there is no default, because a verification that silently chose a policy would be deciding your constraints for you. The verdict says which you used: a lenient policy you brought along yields a verdict about your constraints and is stamped caller-supplied so it cannot be quoted back as ours.

This call is how you check our work without trusting us. Take a proof out of audit_export, ingest the source files yourself with the published adapter spec, and run it. If it disagrees with us, that is a finding about us.

Inputs: proof (required), records (required), loop, policy. Returns: object

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.3/5.0

    Scored across 21 tools

    Disambiguation5/5

    Each tool targets a distinct resource and action: proofs, records, worklists, exceptions, loops, runs, closes, events, classifications, and authorities are all cleanly separated. Even the multiple verify tools are clearly differentiated by object type (proof, close, journal).

    Naming Consistency4/5

    Nearly all tools follow a clear verb_noun pattern like get_proof, list_runs, run_close, and verify_journal. The one minor exception is audit_export, which reads as a noun phrase rather than a verb_noun action, but this does not create real confusion.

    Tool Count3/5

    At 21 tools, the set is on the heavy side and sits at the boundary of being too large for easy navigation. The tools are individually purposeful and the financial-close domain is broad, but the count still feels dense rather than tight.

    Completeness5/5

    The surface covers the full lifecycle: configuration discovery, source ingestion, matching, closing, exception handling, classification, verification, audit export, and journal integrity. There are no obvious dead ends, and the refusal semantics are consistently exposed where human or policy sign-off is required.

    Maintenance

    ActivityStale
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      An accounting-ops agent that reconciles payments against open orders, auto-books provably safe payments through a deterministic policy gate, and escalates exceptions to a human queue with audit trails.
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Enables AI assistants to perform financial analysis, budget forecasting, compliance checks, expense categorization, and risk assessment, returning structured JSON with audit-ready governance receipts.
      5
      102 npm
      1
      Business Source 1.1
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI IDEs to perform financial reconciliation through five native tools for matching invoices, detecting bundled payments, and handling bank fee variances.
      MIT
    • A
      license
      Not graded
      quality
      Not graded
      maintenance
      Enables parsing of structured financial receipts, invoices, and bank statements, tolerance-based three-way reconciliation, detection of tax calculation drift and duplicate claims, and synthesis of double-entry bookkeeping journal entries.
      MIT