Hacker News front page2625882138434761 min readtutorialintermediate
Laya (OS Jev) on Mac M4 CoreML Offline (45 decisions per second)
Summary
A short walkthrough showing how to install and run the Laya‑CoreML demo (a multilingual language model) on a Mac M4 using the uv package manager, with a video of the UI, memory‑usage snapshot, and a sample Cloudflare JEv API call that returns a single urgency score.
- Installation is a three‑step uv workflow: `uv init`, `uv add 'laya-coreml[demo]'`, and `uv run laya-coreml-snake` after downloading the model from Hugging Face.
- The demo runs at ~45 decisions per second on an M4, using ~560 MiB RAM (peak ~780 MiB).
- A simple HTTP POST to the public `laya.inference.zaitlabs.com` endpoint returns a JSON with a probability‑like score (e.g., 0.7894 for urgency).
Shows that on‑device CoreML can serve a multilingual LLM with sub‑second latency on consumer‑grade Apple silicon, useful for privacy‑preserving or edge AI deployments.
3/10



