Inspiration

If you sell from home (candles, cakes, crafts, tutoring), your books probably live in chat messages and your memory. "Maria owes me thirty-six dollars" works until nobody remembers. Accounting apps fix that, but they want accounts, subscriptions, and your customers' details in someone else's cloud.

I wanted a tool where you just type what happened and the books stay yours. Hybrid AI turned out to be the reason that is possible: a small model on the device can do the private work, and a bigger cloud model can help only when you choose.

What it does

TabTidy is an offline-first ledger assistant for tiny and home businesses, in English and any currency.

  • Type a note, get a clean entry. "Sold 3 candles to Maria, $36, she'll pay Friday" becomes a sale with a customer, items, amount, currency, and due date. You always confirm before anything is saved.
  • On-device first. The first pass runs with Gemini Nano through Firebase AI Logic, so it works offline and your customer list stays on your device.
  • Cloud only with your approval. If the on-device result fails validation, TabTidy prepares a redacted prompt (names, phone numbers, emails and long IDs masked) and shows you exactly what would be sent. Cancel, and nothing is sent.
  • Private mode. One switch keeps every AI request on-device and turns cloud features off.
  • Honest accounting. Money is stored as exact whole units with a currency code, currencies are never mixed, and all maths runs in plain code, never in the AI. Edits keep a visible history, and voided entries are kept, not erased.
  • Ledger, People, Reports. Filter entries, see who owes you per currency, record payments, merge duplicate customers, and view weekly and monthly totals. "Write summary" sends only anonymous totals to the cloud, and only after you approve.
  • How this ran. A panel shows which path each request took (on-device or cloud), how long it took, and how many cloud calls were avoided.
  • Your data is portable. Export as JSON or CSV and import JSON.

How I built it

TabTidy is a Vite and vanilla JavaScript web app for desktop Chrome, with no framework and no accounts. Data lives in the browser behind a single storage module.

Firebase AI Logic hybrid inference is the core of the AI layer:

  • src/firebase.js initialises Firebase, App Check, and the AI instance.
  • src/ai/hybrid.js creates the model for each inference mode, initialises the on-device model from a user click, and reports which path served each response.
  • src/ai/parseNote.js turns a note into validated transactions using structured JSON output. It asks the model for a schema, then validates everything in code, converts amounts to integer minor units, applies the default currency, and flags ambiguous customer matches.

Routing is deliberate. The first attempt uses on-device only. If it fails or the result does not validate, the cloud is offered through a redacted preview and needs explicit approval. Private mode blocks the cloud entirely.

App Check protects the Firebase AI calls. Local development uses a debug provider; the hosted build uses reCAPTCHA Enterprise (Fraud Defense). If App Check is unavailable, the rest of the app keeps working and cloud features show a clear message.

A guided demo tour, with narration, drives the real UI and runs entirely on prepared results. It backs up your real data first and restores it afterwards, even if the tab is closed mid-tour. The project has an automated test suite covering parsing, money, balances, redaction, routing, and the tour's data safety.

Challenges

  • Silent fallback. A "prefer on-device" mode can quietly use the cloud if the model is not ready. For a privacy promise that is not acceptable, so the first pass is strictly on-device and the cloud sits behind a visible preview.
  • A small model that over-reads. For a note with one sale and a promised payment, the on-device model invented a second transaction. I tightened the prompt with examples and made validation drop empty or amount-less entries instead of failing the whole parse.
  • Single-turn inference. On-device inference has no chat memory, so every prompt carries its own context (today's date, default currency, known customers).
  • App Check on a hosted site. Getting production tokens working meant registering the right attestation provider, matching the site key everywhere, and allowing the hosting domains. The app was built so it degrades gracefully while that was being sorted out.
  • A demo that stays honest. The tour needed to be repeatable without touching real data or pretending a prepared result is a live model response, so it is labelled as prepared and the video also shows a real parse.

What I learned

Hybrid is not about using two models; it is about deciding what each one is allowed to see. Putting redaction, a preview, and an approval step between the device and the cloud made the app simpler to trust and easier to explain. I also learned how much of a reliable AI feature is validation code around the model.

Built during the submission period

TabTidy was built from scratch during the submission period (from Nov 11, 2026). Disclosures:

  • An AI coding assistant helped write the code.
  • The demo narration audio was generated with Cartesia text-to-speech from the script in the repository.
  • The guided demo-tour approach (a script that drives the real UI with a caption bar) is reused from my earlier project CampusSync; the code was rewritten for TabTidy.

Known limits and what is next

  • On-device AI needs desktop Chrome with Gemini Nano available (it may need a flag and a one-time model download); otherwise TabTidy uses the cloud with preview and approval, or Private mode is limited.
  • Data lives in browser storage, so use Export for backups. There is no sync between devices yet.
  • The demo site runs on a free host, so the first load can be slow while it wakes up.
  • Next: receipt photo import, a mobile version, and optional encrypted sync.

Try it

Live demo: https://tabtidy-m8kd.onrender.com. Open it in Chrome, press "Watch the demo" or "Load sample data", then try a note. Code (Apache-2.0): https://github.com/hafeza-zainab/tabtidy

Built With

  • cartesia
  • chrome-prompt-api
  • css3
  • firebase-ai-logic
  • firebase-app-check
  • gemini-api
  • gemini-nano
  • html5
  • javascript
  • node.js
  • recaptcha-enterprise
  • render
  • vite
  • web-storage-api
Share this project:

Updates

Submission history