Support new `LiveText` OCR

Open
#61 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
30/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
macos, swift
Domain
cli

Research direction

The repository description says the tool converts bitmap subtitles with the macOS Vision framework, so start by finding where it runs the Vision text recognition request and how it returns recognized lines. Work out how a second recognizer, based on VisionKit's ImageAnalyzer (LiveText), could plug into that point, and check the minimum macOS version the project targets. Done means a user can choose LiveText as an OCR source and get output comparable to the Vision path, which the maintainer would need to confirm first.

Written by the indexing model from the issue text.

Description

It looks like LiveText is suited and designed for real-time subtitles. However, since different models or pipelines are used at the bottom layer, the recognition effect should be different, which can be used as another source to facilitate finding and revising errors.

The following is summarized by AI:


Apple’s Vision Framework OCR and LiveText OCR are two different on-device text recognition systems from Apple, with LiveText being the newer and more accurate option for natural scenes.

Key Differences
Feature Vision Framework OCR LiveText OCR
Availability macOS 10.15+ (Catalina), iOS 13+ macOS 14+ (Sonoma), iOS 15+
OCR Precision Good Excellent, optimized for natural scenes deepwiki
Speed Options Yes (fast / accurate modes) deepwiki No (single mode only) deepwiki
Confidence Scores Yes (returns confidence per result) deepwiki No (always returns 1.0) deepwiki
Bounding Box Level Line-based Character-based (more precise) deepwiki
Rotated Text Limited Better recognition deepwiki
Vertical Text (CJK) Not handled properly Supports vertical East Asian text libraries
Character-Level Details No Yes deepwiki
What to Know
  • Vision Framework uses VNRecognizeTextRequest and is more mature, available on older devices. deepwiki
  • LiveText uses the newer VKCImageAnalyzer (ImageAnalyzer API) and is "stronger than VisionKit OCR" for real-world photos. github
  • LiveText is the default on macOS 13+ for many tools because of its superior accuracy. libraries
  • LiveText does not support automatic language detection (und). libraries

For most modern use cases (especially photos with rotated/vertical text), LiveText is better. If you need confidence scores or run on older macOS/iOS, use Vision Framework.

Vision Framework LiveText / VisionKit
VNRecognizeTextRequest ImageAnalyzer().analyze(image, configuration:)
VNImageRequestHandler ImageAnalyzer
Available: iOS 13+, macOS 10.15+ Available: iOS 15+, macOS 12+ (Monterey)

https://developer.apple.com/documentation/vision/locating-and-displaying-recognized-text

Dominant language
Swift
Stars
42
Forks
9
Avg merge
9h 30m
Merged PRs (30d)
4

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ecdye/macSubtitleOCR

All issues in ecdye/macSubtitleOCR

Similar issues

More Swift issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.