Hubfiscal: invoice auditing for accounting firms
Tax-authority collection · tax-code classification · desktop app with a local vault
Accounting firms audit invoices by hand. Before that, someone has to gather them — and pulling XML files from the tax authority, company by company, already eats half a day. Then comes checking tax classification across thousands of line items, repetitive work where the mistake only shows up once it has become a penalty.
The challenge
The digital certificate cannot go to the cloud
It is the fiscal credential of the firm and of its clients. Storing it on our server would concentrate a risk that isn't ours to hold.
Classifying with AI is expensive at scale
Calling a language model for every line of every invoice multiplies cost by volume — and volume is exactly the problem.
A flag without justification is useless
The accountant needs to know which rule flagged what, or they will re-check everything by hand anyway.
How we solved it
- 01
A desktop app with a local vault
The web triggers, the desktop injects. The certificate stays on the firm's machine and only the result of the operation travels. The app auto-updates, so it never depends on a user installing a new version.
- 02
Our own classifier, model only on doubt
Tax-code classification runs first through a token-based engine inside the database. The language model is only called when that classifier isn't confident — the common path stays cheap and deterministic.
- 03
Exception reports, with the rule cited
Every discrepancy comes out with the item, the rule applied and the reasoning. The accountant reviews exceptions, not the whole base.
- 04
A multi-tenant platform with white-label
The firm, the firm's client and the audited company are three distinct things in the data model — a distinction that prevents the cross-account data leak that kills this kind of product.
The outcome
- Invoices arrive on their own: collection stops being manual work
- Review shifts from invoice-by-invoice to exception-based, with a rule trace on each flag
- The fiscal credential never leaves the client's machine
- Tax status can also be queried over WhatsApp, on the same backend
What this architecture teaches
The "expensive model only on doubt" pattern solves two problems at once: it cuts cost per item and increases auditability, because the common path is deterministic and explainable. It applies to almost any classifier in production — AI comes in as the exception, not the rule.
Stack
- Next.js
- n8n
- PostgreSQL
- LLM
- C# / Avalonia
- Digital certificate
- Multi-tenancy
Facing something similar?
Tell us the process you want to automate. You leave the conversation with a technical path — no commercial proposal in between.