What I Built
InvoicePilot AI is a privacy-first, local-first AI assistant that extracts structured data from invoices and receipts in PDFs and images. It validates arithmetic and exports sanitized CSV/XLSX reports.
It uses Gemma 2B through Ollama for AI extraction, with a regex-based fallback when the model is unavailable. The application has a React frontend and FastAPI backend.
Key Features
- AI-powered invoice and receipt extraction
- PDF parsing and OCR for scanned documents
- Local inference using Ollama and Gemma 2B
- Regex-based fallback extraction
- Arithmetic validation and confidence scoring
- Batch document uploads and inline editing
- Sanitized CSV and XLSX exports
Who Would Pay for It?
- Freelancers who want to automate invoice processing.
- Small agencies managing multiple vendor invoices.
- Organizations that prioritize privacy and local data processing.
Tech Stack
- Frontend: React, TypeScript, Vite
- Backend: Python, FastAPI
- AI: Gemma 2B, Ollama
- OCR and Parsing: PyMuPDF, Tesseract
- Database: SQLite, SQLAlchemy
- Exports: CSV, XLSX
- Deployment: Docker, Docker Compose
Quick Setup
Clone the repository:
git clone https://github.com/aBhishek-jAm/HactoberFestProj.git
cd HactoberFestProj
Start Ollama (optional):
ollama pull gemma:2b
ollama serve
Set up the backend:
cd backend
python -m venv .venv
Activate the virtual environment, then run:
pip install -r requirements.txt
python -m uvicorn app.main:app --reload --port 8000
Start the frontend in a separate terminal:
cd frontend
npm install
npm run dev
Frontend: http://localhost:5173
API documentation: http://localhost:8000/docs
How It Works
- Upload invoice or receipt documents.
- Extract text using PDF parsing or OCR.
- Process the text using Gemma 2B or the regex fallback.
- Validate totals and flag inconsistencies.
- Review extracted data and export reports.
Why Open Innovation Matters
InvoicePilot AI combines open-weight AI with deterministic validation to support transparent, customizable, privacy-conscious document processing. Users can run inference locally, inspect the source code, and experiment with alternative models.
Demo and Repository
- GitHub: https://github.com/aBhishek-jAm/HactoberFestProj
- README: https://github.com/aBhishek-jAm/HactoberFestProj/blob/main/README.md
- Submission: https://github.com/aBhishek-jAm/HactoberFestProj/blob/main/SUBMISSION.md
Future Improvements
- Accounting software integrations
- Additional export formats
- Improved multi-currency support
- Better extraction accuracy for complex invoices
Hacktoberfest Categories
- Side Hustle / Productivity
- Open Source AI Tools / Best Use of Open Weights
InvoicePilot AI demonstrates how open-weight models, OCR, and deterministic validation can automate invoice processing while giving users greater control over their data.
Top comments (0)