Repository navigation
2.6.0
Release 2.6.0
Date: 2026-02-14
This release adds free-form lasso selection, polygon-masked OCR capture, and configurable default selection mode for both resident and run-once flows.
Highlights
- Added lasso selection mode in the Windows overlay (
Spacetoggles between rectangle and lasso). - Added close-loop completion rule for lasso (release mouse near start point).
- Added polygon masking before OCR: outside-lasso pixels are filled white.
- Added
DEFAULT_MODEconfig and--default-modeargument. - Added embedded custom lasso cursor for lasso mode.
- Improved resident key handling reliability for
SpaceandEscape.
.env and Environment Variables
The app loads configuration from:
.envin the executable directory.- If that file does not exist, path from
SCREEN_OCR_LLM(must point to a.env-style file).
Example .env:
OPENROUTER_API_KEY=<your_api_key>
MODEL=qwen/qwen3-vl-235b-a22b-instruct
# Optional
OPENROUTER_API_KEY_FILE=/run/secrets/api_keys/openrouter
HOTKEY=Ctrl+Alt+Q
ENABLE_FILE_LOGGING=true
PROVIDERS=chutes/bf16,phala,fireworks,parasail/fp8
OCR_DEADLINE_SEC=20
DEFAULT_MODE=rectangle
SINGLEINSTANCE_PORT_START=49500
SINGLEINSTANCE_PORT_END=49550DEFAULT_MODE accepted values:
rectanglerectlasso
Any invalid value falls back to rectangle.
CLI Arguments
Supported arguments in 2.6.0:
--run-once--api-key-path <path>--default-mode <rect|rectangle|lasso>
Legacy single-dash long forms are still normalized:
-run-once-api-key-path-default-mode
Examples:
# Resident mode
./screen-ocr-llm.exe
# One-shot mode
./screen-ocr-llm.exe --run-once
# One-shot with API key file override
./screen-ocr-llm.exe --run-once --api-key-path /run/secrets/api_keys/openrouter_key
# One-shot with lasso default mode
./screen-ocr-llm.exe --run-once --default-mode lassoPrecedence Rules
Config File Source Precedence
- Executable-local
.env SCREEN_OCR_LLMpath (only when executable-local.envis missing)
API Key File Path Precedence
- Built-in default:
/run/secrets/api_keys/openrouter - Process env:
OPENROUTER_API_KEY_FILE - Loaded
.env:OPENROUTER_API_KEY_FILE - CLI arg:
--api-key-path(highest)
API Key Value Precedence
- Content read from resolved API key file path (if file exists and is non-empty)
OPENROUTER_API_KEY
Default Selection Mode Precedence
- CLI arg:
--default-mode DEFAULT_MODEfrom environment/config- Fallback:
rectangle
Delegation Behavior (Run-Once vs Resident)
If --run-once finds an active resident instance, it delegates the request and exits.
In delegated mode, resident configuration remains authoritative. Client-side --api-key-path and --default-mode do not override the resident process config.
Upgrade Notes
- No breaking API changes for OCR/LLM payloads: images sent to model APIs remain rectangular.
- Lasso improves OCR quality by masking outside pixels while preserving existing pipeline contracts.
- Existing rectangle behavior remains default unless overridden.