Spaces:
Sleeping
Sleeping
title: Answer Evaluation App | |
emoji: π§ | |
colorFrom: blue | |
colorTo: green | |
sdk: docker | |
app_port: 7860 | |
# Answer Evaluation App βοΈ | |
# π Handwritten Answer Evaluation App using OCR + XLNet | |
An end-to-end machine learning application that extracts handwritten answers from images and evaluates them using a custom XLNet model trained on semantic similarity. | |
--- | |
## π Live Demo | |
π [Try it on Hugging Face Spaces](https://yeswanthvarma-answer-evaluation-app.hf.space) | |
--- | |
## π Project Overview | |
This app takes images of handwritten answers and performs: | |
1. **OCR** to extract text from question, student answer, and reference answer. | |
2. **Similarity scoring** using a custom-trained XLNet model. | |
3. **Bonus logic** to adjust the final score based on thresholds. | |
4. **User interface** to upload images and view the evaluated score. | |
--- | |
## π§ Core Technologies | |
- **FastAPI**: Web framework | |
- **EasyOCR**: For extracting handwritten text | |
- **Hugging Face Transformers**: XLNet model | |
- **Custom Training**: Trained on Q-A-R triplets | |
- **Docker**: For containerized deployment | |
- **Hugging Face Spaces**: Live hosted app | |
--- | |
## π¦ Folder Structure | |
``` | |
answer-evaluation-app/ | |
βββ app.py # FastAPI application | |
βββ requirements.txt # Dependencies | |
βββ Dockerfile # For Hugging Face deployment | |
βββ utils/ | |
β βββ image_processor.py # EasyOCR + preprocessing | |
β βββ xlnet_model.py # Model load and prediction | |
βββ templates/ | |
β βββ index.html # Frontend HTML | |
βββ static/ | |
β βββ css/style.css # UI styling | |
β βββ js/main.js # JS for client interaction | |
β βββ uploads/ # Uploaded image storage | |
``` | |
--- | |
## π Model Details | |
- **Base Model**: `xlnet-base-cased` (Hugging Face) | |
- **Custom Trained On**: Question, student answer, reference answer, and human-evaluated scores | |
- **Loss**: MSELoss | |
- **Output**: Score from 0 to 100 | |
--- | |
## βοΈ Sample Use Case | |
- Upload 3 images: | |
- Question image | |
- Student handwritten answer | |
- Reference answer | |
- App will: | |
- Extract text | |
- Score similarity using model | |
- Apply bonus logic | |
- Display final score and extracted text | |
--- | |
## π§βπ» Author | |
**Yeswanth Varma Gottumukkala** | |
- Email: yeswanthvarma.g@gmail.com | |
--- | |
## π License | |
This project is for educational and research purposes. | |
Model and app are freely available to explore on Hugging Face Spaces. |