Laya on MLX

laya-mlx is an independent MLX port of Laya that runs the original weights on the Apple Silicon GPU with no PyTorch or Transformers runtime. It keeps upstream prompt formatting, calibration and output schema, and it is the base for many Mac demos, agents and benchmarks.

140 projects

laya-mlx

mizorewww

Runs Laya typed-decision models locally on Apple Silicon using MLX

6.3k·GitHub repo

laya-ultrafast

ipenywis

Runs a browser automation agent using local Laya decisions through MLX

181·GitHub repo

laya-vs-jev

virajbhartiya

A side-by-side T-Rex game compares local Laya and hosted Jev decision models

100·GitHub repo
A

laya-mlx

aac6fef

An MLX FP16 conversion of Laya for native inference on Apple silicon

90·HF model

sys1

alvarobartt

Serves Laya decision models through a Rust System One API with CPU, CUDA, and Metal support

43·GitHub repo

arbiter

0xBakeer

Serves Laya and other typed-decision models locally with a Jev-compatible API

29·GitHub repo
A

laya-multilingual-mlx

aac6fef

Converts the multilingual Laya decision model to MLX for Apple silicon

12·HF model

laya-jev-lab

yibie

Compares Jev and Laya decision models and evaluates a local-first inference cascade

9·GitHub repo

laya-apple

tc3oliver

Runs Laya locally on Apple Silicon with MLX GPU and Apple Neural Engine support

8·GitHub repo

fast-jev-compaction-laya

kaiyes

Compacts OpenCode context using decisions from a locally served Laya model

7·GitHub repo
A

laya-typed-decisions-mlx

aac6fef

Runs Laya typed-decision inference natively on Apple silicon with MLX

5·HF model

laya-fast

DJLougen

Runs Laya typed decisions on Apple Silicon with MLX and optional Core ML execution

5·GitHub repo

deqio

ILuce

Serves multiple typed-decision models, including Laya, through a local API and browser UI

5·GitHub repo
C

MacJev-322M-4K-Laya

chaoliangUNSW

Fine-tunes Laya for long-context local Mac agents and compares it with the base model

4·HF model

jev-laya-benchmark

harrymunro

Benchmarks local MLX Laya against TypeSafe's hosted Jev on synthetic decision tasks

4·GitHub repo

laya-mlx-voice-browser

aryanbhujade

Uses a local Laya-MLX model to turn spoken commands into browser actions on Mac

4·GitHub repo

jev-tests

schacon

Compares Laya, Jev, Kev, and Claude in three macOS typed-decision demos

4·GitHub repo

doomLaya

azalio

Trains and compares Laya and Jev agents playing FreeDoom with reproducible results

3·GitHub repo

laya-mcp

wsargent

Runs local Laya inference on Apple Silicon and exposes typed-decision tools through an MCP server

2·GitHub repo

laya-router-skill

wangmiaozero

Adds local Laya decision routing to coding agents through skills and MCP

2·GitHub repo

laya-as-judge

rbrus

Uses Laya-MLX to evaluate models and agents with typed-decision judgments

2·GitHub repo

laya-vs-jev

zaferayan

Benchmarks multilingual Laya against hosted Jev across 900 cases, three tasks, and six languages

2·GitHub repo

SnakeGame_Laya

Okbatti

Uses a fine-tuned Laya model to choose moves in a Snake game

2·GitHub repo

oh-my-laya

leo1394

Installs local Laya tools for classification, scoring, and routing in coding agents

2·GitHub repo

Install

Requirements from the laya-mlx README: Apple Silicon, Python 3.11+, macOS 14+.

pip install laya-mlx

Pre-converted FP16 checkpoints are on Hugging Face: aac6fef/laya-mlx, aac6fef/laya-multilingual-mlx and aac6fef/laya-typed-decisions-mlx. You can also load the original convaiinnovations/laya IDs.

Router and CLI

The port includes the upstream language router and presets:

from laya_mlx import Router, triage_questions

router = Router(dtype="float16", max_loaded=2)
result = router.predict({"message": "发票被重复扣款,请退款。"}, triage_questions())
print(result["routing"])  # multilingual

For the terminal demo, where Laya plays Snake:

pip install 'laya-mlx[demo]'
hf download aac6fef/laya-multilingual-mlx
laya-snake

Reported numbers

On an M3 Max, FP16, one short question: 13.42 ms P50 for the 421M English model and 7.39 ms for the 322M multilingual model. The README states that all three checkpoints matched the upstream answer on 63/63 validation questions in FP32 and FP16. That measures port fidelity, not task accuracy.

Projects built on laya-mlx

Caveats

This is not an official Convai Innovations release. Training and fine-tuning stay in the upstream project. BF16 can be requested but is not part of the published validation.

More ways to use Laya