Documentation

OCR Support

Answer with photos of handwritten notes.

Installation

pip install learnlock[ocr]

Installs EasyOCR and Pillow.

Usage

During study, provide an image path instead of typing:

Challenge: How does backpropagation update weights?

> /home/user/notes/backprop.jpg

Extracting text from image...
Checking relevance...
Extracted: "Backpropagation uses chain rule..."

[Coach analyzes the extracted text]

Supported Formats

  • .png
  • .jpg / .jpeg
  • .webp
  • .bmp
  • .gif

OCR Engines

LearnLock tries in order:

  1. EasyOCR - Better accuracy, works offline
  2. Tesseract - Fallback (requires pytesseract)

Tips for Better OCR

  • Good lighting - avoid shadows
  • High contrast - dark ink on white paper
  • Clear handwriting - print style works best
  • Straight alignment - keep paper flat
  • Crop tightly - remove background

Troubleshooting

No OCR engine available

pip install learnlock[ocr]

Image content not related

The extracted text does not match the concept. Check the image or try clearer notes.

No text found

Try better lighting, higher resolution, or clearer handwriting.