DEDUPED Hot AI repos. Real use cases. What people build. Get the Monday 5

How to watch a local Snake agent make live decisions with Laya MLX

Run the terminal Snake demo where Laya picks every move on your Mac.

Short answer: Install the demo extra: pip install 'laya-mlx[demo]'; then download the multilingual checkpoint before the offline demo: hf download aac6fef/laya-multilingual-mlx; open a terminal of at least 104 × 35 cells and start the game: laya-snake. All steps.

Who it is forA developer or curious user who wants to see typed decisions running in real time before building with them.

The problemIt is hard to judge what a typed decision runtime does until you watch it act in a loop.

The outcomeA terminal Snake game in which each move comes from a local Laya decision, with speed controls.

What you need first

  • An Apple Silicon Mac running macOS 14 or later
  • Python 3.11 or later
  • Internet access for the first checkpoint download, after which inference is fully local

Steps

  1. Install the demo extra: pip install 'laya-mlx[demo]'
  2. Download the multilingual checkpoint before the offline demo: hf download aac6fef/laya-multilingual-mlx
  3. Open a terminal of at least 104 × 35 cells and start the game: laya-snake
  4. Use Space to pause, the up and down arrows to change speed, R to reset and Q to quit.
  5. Optionally run laya-snake --optimize --max-speed to try the compiled and prefix-reuse path.

Prompt for your agent

In the laya-mlx repo (github.com/mizorewww/laya-mlx), install the demo extra and start the laya-snake terminal game in a terminal of at least 104 by 35 cells. Report the moves per second shown and whether any safety intervention occurred. Verify that the game runs without an external API key or network call during play.

Caveat. The Snake frame time is not the one-question latency benchmark, and the README reports its own speed results from one paired M3 Max test.

Use this in your AI agent

Ask your agent

Using the Deduped MCP, get the setup steps for mizorewww/laya-mlx and "Watch a local Snake agent make live decisions"

Add Deduped to Claude Code once

claude mcp add --transport http deduped https://dedupedai.com/mcp

Cursor, ChatGPT, others

Share: X LinkedIn Hacker News Email Copy link

Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer