05Personal project2026Live
English Class
کلاس زبان
An app for my own English class: the book’s vocabulary, a homework planner, pronunciation, and a scanner that reads the words I highlighted.
- Role
- Brief, product decisions, daily use in class
- Built
- Sep 18, 2026 – Sep 25, 2026
- Type
- Personal project
- Status
- Live
- Stack
- JavaScript
- Tesseract.js
- Web Speech API
- Canvas
- Netlify
My class works through four books. I started with one book’s word list and kept adding what I actually needed while studying. It’s open to anyone now, right here on this site.
Built with AI coding agents, under my direction. How I work
In numbers
- 24units
- 930words and phrases
- ~1,700offline dictionary entries
- 5highlighter colours recognised
What’s inside
- 24 units of Tactics for Listening vocabulary, 587 words and 343 phrases with Persian meanings, and a practice mode that hides the meanings until you tap.
- An offline English–Persian dictionary of about 1,700 common words with simple stemming, so “running” still finds “run”.
- Pronunciation from the browser’s own speech engine: slow, three times, letter by letter, and a reader that highlights each sentence as it speaks.
- A homework planner on the Persian calendar that knows which days class meets and counts down to each deadline.
The scanner
Photograph a page and the app reads it in the browser with Tesseract.js, finds the words I marked with a highlighter, and gives me their meanings and a read-aloud of the text.
Highlighter ink confuses OCR, so the image is cleaned first: bright, saturated pixels (the marker) are pushed toward white while dark ink stays dark, then the contrast is normalised along a soft S-curve. After OCR, the pixels inside each word’s box are sampled in HSV to decide whether it was highlighted: yellow, green, orange, pink or blue.
Translation that degrades gracefully
Whole-text translation tries an optional Claude API key first, then Google Translate, and finally falls back to word-by-word meanings from the offline dictionary. It never just fails.