An AI-powered enterprise document classification system built using Vision Transformer (ViT), PyTorch, FastAPI, and Gradio.
✔ Vision Transformer (Google ViT) ✔ 16 Document Classes ✔ FastAPI REST API ✔ Gradio Frontend ✔ Real-time Inference ✔ Confidence Score ✔ Checkpoint Loading ✔ Image Preprocessing ✔ Enterprise-ready Architecture
- Python
- PyTorch
- Transformers (HuggingFace)
- FastAPI
- Gradio
- Torchvision
- Pillow
RVL-CDIP Dataset 16 Enterprise Document Categories
- Advertisement
- Budget
- File Folder
- Form
- Handwritten
- Invoice
- Letter
- Memo
- News Article
- Presentation
- Questionnaire
- Resume
- Scientific Publication
- Scientific Report
- Specification
(project tree)
(screenshots)
pip install -r requirements.txt
PYTHONPATH=src uvicorn api:app --reload
PYTHONPATH=src python src/gradio_app.py
POST /predict
Returns
{ "predicted_class": "...", "confidence": 99.86 }
Docker GPU Deployment Top-3 Predictions Batch Inference Cloud Deployment