Real-time American Sign Language alphabet recognition from webcam to text, powered by MediaPipe hand landmarks and a custom trained machine learning model.
Live Demo: https://huggingface.co/spaces/Suhailnasar/PalmScript
PalmScript converts ASL fingerspelling into text in real time using just a webcam. No special hardware needed — just your hand and a camera.
Sign letters → Watch them appear on screen → Build full words and sentences
Instead of training on raw pixels, PalmScript extracts 21 hand landmark points (x, y, z coordinates = 63 numbers) from each frame using MediaPipe and feeds them into a trained machine learning model.
Webcam → MediaPipe (21 hand landmarks) → ML Model → Predicted Letter → Sentence
This approach gives us:
- Lighting independence — landmarks don't care about shadows or background
- Fast inference — 63 numbers instead of thousands of pixels
- High accuracy — 99.38% on test set
- Real-time hand landmark detection via MediaPipe
- Custom trained Neural Network (99.38% accuracy)
- Supports full ASL alphabet — A to Z, space, delete
- Smart sentence builder — pause hand to separate words
- Auto punctuation — long pause adds period
- Backspace and clear buttons
- Dark themed professional UI
- Deployed as a public web app
| Purpose | Tool |
|---|---|
| Hand Detection | MediaPipe |
| Webcam Capture | OpenCV |
| Model Training | scikit-learn |
| Web Interface | Gradio |
| Deployment | Hugging Face Spaces |
| Model | Accuracy |
|---|---|
| Random Forest | ~96% |
| Neural Network | 99.38% |
Trained on 66,272 hand landmark samples extracted from 87,000 ASL alphabet images.
PalmScript/
├── model/
│ ├── asl_model.pkl
│ ├── scaler.pkl
│ └── label_encoder.pkl
├── app.py
├── requirements.txt
└── packages.txt
bash git clone https://github.com/suhailnasar/PalmScript cd PalmScript pip install -r requirements.txt python app.py
- Open the live demo link
- Allow camera access
- Show your hand and sign ASL letters
- Hold each sign steady for it to register
- Remove hand briefly to separate words
- Remove hand for 4 seconds to end sentence
Mohammed Suhail — GitHub · Hugging Face