Back to directory

mac-local-vision

A single Swift binary that gives AI agents and end-to-end tests zero-token, on-device computer vision on Apple Silicon, including OCR, pixel-exact UI targeting, and face grouping.

mac-local-vision

mac-local-vision is a pure Swift command-line tool built on Apple's own Vision and FoundationModels frameworks, with no Node, Python or other runtime dependency. It performs OCR that extracts text and layout locally, returns the exact pixel center of a word for end-to-end test click targeting, decodes and generates QR and barcodes, straightens a photographed document into a flattened scan, classifies an image against a large label taxonomy, and clusters photos by the person in them without uploading anything.

Because everything runs on-device through Apple's frameworks, each call avoids the network round-trip, per-call cost and token spend of a cloud vision API, completing in roughly a third of a second end to end on recent Apple Silicon hardware. It also exposes a beta multimodal ask command for on-device reasoning about an image, which needs a newer macOS beta.

More in Testing

See all 69
  • Canary

    runcanary.ai

    An independent testing service, backed by Y Combinator, that runs an application and tries to break every change an AI coding agent makes, reporting what would have reached production.

  • MoEWatch

    github.com

    A diagnostic and audit library for Mixture-of-Experts models in HuggingFace Transformers that instruments router modules to catch expert collapse, routing entropy collapse and load imbalance during training.

  • Mockwave

    github.com

    An open-source, multi-protocol mock server for HTTP, GraphQL, SOAP, and gRPC, with weighted traffic splitting, dynamic JavaScript responses, chaos-testing fault injection, and an MCP server so an AI assistant can generate mock rules directly.