Lease Desk — the lease accountant your finance team can hire today

Tracks: Hyphenate · Anthropic · SpacetimeDB · Microsoft (Azure)

Lease Desk: $443,255.70. The amendment was in the mailbox. The books were still running the old schedule.

Try it: https://lease-desk-ten.vercel.app/welcome — open the desk, sign in as [email protected], password demo, and open the July hold on LEASE-01.


The $443,255.70 that was hiding in an inbox

Northbay Physical Therapy runs clinics across the Bay Area. Every clinic sits in a rented suite, every suite has a lease, and every month every landlord sends a bill.

In June, the Daly City clinic changed its lease. The new deal: pay a little less each month, but stay three more years. The signed copy arrived by email to the facilities team. They filed it. Nobody told accounting.

In July the landlord's bill showed the new rent: $17,400 instead of $19,626.65. A smaller bill looks like good news. But three extra years of rent means the company now owes far more in total, and accounting rules require that total to appear on the balance sheet as a debt. The books were still showing the old, shorter lease, so $443,255.70 of debt was missing.

This is not an exotic failure. Lease accounting (ASC 842) depends on documents that live outside every system: PDFs, scanned amendments, and emails from a landlord's property manager. A finance team finds these mistakes at audit time, if it finds them at all.

Lease Desk found it in the July run, explained it, and proposed the fix. Then it waited for a person to sign.

Tracks

Track Why it fits
Hyphenate An autonomous finance agent for lease accounting. It learns from documents, history and people, runs the month on its own, escalates only judgment calls to the right person, and documents every step
Anthropic Claude used for exactly what it's best at, reading messy documents, with structured outputs, citations checked against the page, and replayable answers. Never on the critical path of a calculation
SpacetimeDB A live projection of the books and the agents' work: approvals and agent steps stream to every open screen. Postgres stays the system of record
Microsoft Hosted on Azure Container Apps, with limits enforced in code and in the database, separation of duties, and a verifiable audit trail

What it does

Lease Desk fills the lease accountant's seat, and checks every rent bill before the AP clerk pays it.

  1. Reads every lease. Claude reads each lease PDF into 13 structured terms (rent schedule, escalations, CAM share, renewal options, notice address, authorized representative). Every term carries the exact sentence it came from and its page, and that quote is checked against the page before any number is used.
  2. Builds the books. A deterministic ASC 842 engine turns those terms into liability and right-of-use schedules. No model touches the math.
  3. Checks every bill. Each landlord charge is compared with what the lease supports. Correct charges are queued for payment; wrong ones are held, and only the wrong part is held, with the clause that proves it.
  4. Investigates on its own. When a bill doesn't match, the investigation agent searches the mailbox for the reason. It ranks sources by trust: a countersigned amendment outranks a property manager's email, which outranks the invoice. It found the June amendment, remeasured the lease, and proposed four balanced adjusting entries.
  5. Acts on the outcome. When a manager upholds a hold, the agent drafts the dispute letter to the landlord's authorized representative from facts on record. When the letter goes out, it proposes the receivable for the controller.
  6. Never signs its own work. People approve; a gateway posts. Every action, including every refusal, lands on a hash-chained audit trail anyone can verify.

Why hire this agent

Any business that rents its locations (clinics, stores, offices) carries a lease accounting job that's hard to automate, because its source of truth isn't in any system. It's in PDFs and in somebody's inbox. Finance teams already automate payables, receivables and the general ledger; leases are usually still a spreadsheet and a person.

Lease Desk takes that seat. Here is the job description it was built against, and what it does in each part.

It learns the job

  • From day one, it reads the documents. Five leases read, 65 of 65 fields correct, each cited to its page.
  • From the company's history. On onboarding, the policy learner reads 2025's payment history and proposes rules for the habits it finds ("pay this landlord's base rent when it matches last month's payment"). It backtests each rule against every charge on record before proposing it.
  • From its people. When a manager answers a question, such as "yes, suite 110 is ours", the agent proposes a policy from that one answer, scoped no wider than the answer supports.

It executes without being asked

  • The month runs as jobs: ingest, read, check, re-check, investigate, draft disputes, track obligations such as renewal-notice deadlines.
  • In January it checked 12 charges, held exactly the 5 planted errors with zero false holds, flagged $25,736.36 to the cent, and cited the clause behind each hold.
  • In July it found the amendment and produced the remeasurement and four balanced journal entries before anyone opened the exception.

It gets better on its own (self-learning)

  • A controller approves a learned policy once; from then on the checker decides matching charges under it and cites the policy on every decision. The next month needs fewer questions.
  • It remembers what it was told no. A rejected policy is never proposed again unless new evidence shows up, and the agent says whose rejection it is respecting and why.

Autonomy, with a person only where it counts

  • The agent does the reading, matching, searching, remeasuring, drafting and follow-up. A person makes exactly the decisions a controller would want to make: approve the entries, uphold the hold, send the letter.
  • It escalates to the right person, not just a person. Landlord facts go to the clinic's regional manager; money goes to the controller. Nobody approves their own proposal, and the agent can't approve anything.
  • It recovers on its own. We killed the worker twice mid-run with SIGKILL. It restarted and finished with identical results: same rows, same journal, same audit trail.

The wow moment

One click on Run investigation: the agent searches 10 emails, finds the June amendment (trust rank 1, a countersigned document), remeasures the lease from $559,665.35 to $1,002,921.05, and proposes four balanced entries. Then it stops and waits for the controller. +$443,255.70 recovered onto the balance sheet, with every number traceable to the sentence it came from.

Why it's safe to hire

  • Limits are database grants, not promises. The agent's database role cannot write to the ledger. We prove it in the demo: three forbidden attempts, all refused, all on the record.
  • Untrusted documents can't give orders. Instructions planted inside emails and PDFs are ignored: 3 of 3 unauthorized sources refused.
  • It never pays and never signs. A gateway is the only writer to the books, and it re-checks the approval before posting.

How we built it

  • Claude (Anthropic) reads leases and searches the mailbox, and nothing else. Structured outputs, versioned prompts, per-claim citations checked against the page, an explicit list of what it wasn't sure about (sent to a person), and untrusted text fenced off. Every answer is cached and replayable, so the whole demo reruns byte for byte with no API key.
  • ASC 842 engine in plain, tested Python: present value at the incremental borrowing rate, straight-line cost, remeasurement on modification, catch-up entries for months already closed.
  • Postgres 16 with four roles (agent, gateway, API, auditor), a work-item state machine, a hash-chained audit_event table nobody can rewrite, and a job queue with idempotency keys.
  • SpacetimeDB mirrors every committed approval live (desk_status) and every agent step (agent_step), so an approval on one screen turns another screen green with no refresh. Postgres stays the system of record.
  • Next.js 15 web app on Vercel: the money screen shows the invoice and the lease side by side, with the disputed line and the clause boxed.
  • Microsoft Azure Container Apps run the API, worker and Postgres for the live demo.

How we know it works

Scored against an answer key we didn't write by hand: a generated company with planted errors, a held-out company from a seed never used in development, real SEC EDGAR lease exhibits, and adversarial documents.

Result
Checking 5 / 5 planted errors held, 0 false holds, $25,736.36 flagged exactly
Citations 5 / 5 holds cite the clause that proves them
Extraction 65 / 65 lease fields correct, each cited to its page
Investigation July variance settled to the amendment, 7 / 7 checks, confidence 100%
Safety 3 / 3 unauthorized sources refused
Held-out company 18 clinics from an unseen seed, 4 / 4 invariants hold
Recovery worker killed twice mid-run, identical results
Tests 1,100+ in CI, most against a real Postgres 16

Challenges we ran into

  • Keeping the model off the math. It's tempting to let the model "calculate the liability". We split the work: the model decides what the lease says, the code decides what it costs. The citation check stops a model that invents a number before it reaches a schedule.
  • Trust between documents. The amendment email, the original lease and the invoice disagree. We built an explicit trust ranking (executed amendment > original lease > authorized representative > property manager > invoice > payment history) and made the agent show which one it believed and why.
  • Autonomy without a blank cheque. Every new capability had to answer: who approves it, what can't the agent touch, and where is it recorded.

What we're proud of

  • The July moment runs live, from raw documents to balanced entries, with no hand-wired steps.
  • Zero false holds: the agent holds only money that's actually wrong.
  • Refusals are first-class. The audit trail shows what the agent tried and was stopped from doing, not just what it did.

What's next

  • Real lease portfolios: extraction on more SEC exhibits, optional fields for terms a lease is silent on.
  • Finance leases, variable and percentage rent.
  • Plugging into the rest of a finance stack: lease entries into the general ledger, approved rent into payables as AP bills.

Built With

Share this project:

Updates

Submission history