# Mesh LLM

> Pools GPUs and memory across machines and exposes the result as one OpenAI-compatible endpoint

- Category: Models & Inference / Serving & Deployment
- Language: Rust
- Licence: Apache-2.0
- Repository: https://github.com/Mesh-LLM/mesh-llm
- Website: https://meshllm.cloud/
- Canonical page: https://ai-tldr.dev/tools/mesh-llm/
- Updated: 2026-07-11

## In short

Mesh LLM is a distributed inference runtime that turns several machines into one inference endpoint. It sits in the Serving & Deployment category of the Models & Inference tools and is open-source, written in Rust and licensed Apache-2.0. To get started: install.

## Overview

Mesh LLM is a distributed inference runtime that turns several machines into one inference endpoint. Start a node, and it exposes an OpenAI-compatible API at `http://localhost:9337/v1`; add more nodes, and the mesh decides for each request whether the model runs locally, routes to a peer that already hosts it, or is split into layer stages across several boxes. A web console runs alongside the API on port 3131.

Peer traffic — inference requests, responses and split-model activations — travels over QUIC and is end-to-end encrypted, with iroh relays forwarding packets they cannot read. Published meshes advertise themselves through Nostr discovery; private meshes stay invite-token based, joined with `--join <token>`. Operator configuration and inventory actions run on a separate control lane from the public mesh plane, so nodes on different versions stay compatible.

For models too large for any single machine, Mesh LLM uses what the project calls Skippy stage splits: a coordinator plans contiguous layer ranges, starts downstream stages first, waits for readiness, then publishes the stage-0 route. Layer packages contain a `model-package.json` plus GGUF fragments, so each peer downloads only the pieces its assigned stage needs. The CLI also has one-command hand-offs to coding agents — `mesh-llm goose`, `mesh-llm opencode`, `mesh-llm claude` and `mesh-llm pi`.

## What it does

- One OpenAI-compatible `/v1` API per node, with requests routed by the `model` field to whichever peer can serve it
- Single-machine fit first: if one node can host the whole model, it serves locally with no stage traffic
- Skippy stage splits spread a model too large for one box across contiguous layer ranges on several peers
- QUIC end-to-end encryption between nodes, with iroh relays forwarding encrypted packets without reading them
- Public mesh discovery over Nostr, or private invite-token meshes joined with a single flag
- A mixture-of-agents gateway: send `"model": "mesh"` to fan one prompt out to every model in the mesh
- Built-in launchers that point Goose, OpenCode, Claude Code or Pi at the mesh endpoint

## Getting started

Install the release executable, run setup once, then join or start a mesh. Packages, checksums, SBOMs and OCI images are produced by the separate Mesh-LLM/mesh-packaging repository.

1. Install

   Use the install script on macOS or Linux, the PowerShell script on Windows, or the Homebrew tap on Apple Silicon.

```bash
curl -fsSL https://raw.githubusercontent.com/Mesh-LLM/mesh-llm/main/install.sh | bash
# Apple Silicon: brew install Mesh-LLM/tap/mesh-llm
```

2. Finish setup

   Run the one-time setup command to create the node identity and configuration under ~/.mesh-llm.

```bash
mesh-llm setup
```

3. Join the public mesh and serve

   `--auto` picks a backend flavor, downloads a suitable model if needed, joins the best discovered public mesh, and starts the local API on port 9337 plus the web console on 3131. Add `--headless` on a server to hide the web UI.

```bash
mesh-llm serve --auto
```

4. Call it like any OpenAI endpoint

   List what the mesh can serve, then send a normal chat-completions request.

```bash
curl -s http://localhost:9337/v1/models | jq '.data[].id'

curl http://localhost:9337/v1/chat/completions \
  -H "Content-Type: application/json" \
  -d '{"model":"GLM-4.7-Flash-Q4_K_M","messages":[{"role":"user","content":"hello"}]}'
```

5. Start a private mesh or split a big model

   Serve a specific model to start a private mesh, publish it for public discovery, or use --split to run a model too large for one machine across stages.

```bash
mesh-llm serve --model Qwen3-8B-Q4_K_M
mesh-llm serve --model Qwen3-8B-Q4_K_M --publish
mesh-llm serve --model hf://meshllm/<repo>@<rev> --split
```

## When to use it

- Pool the GPUs already sitting in a team's workstations into one shared inference endpoint instead of buying a dedicated server
- Run a model that does not fit on any single machine you own by splitting its layers across several peers
- Give a coding agent a local, OpenAI-compatible endpoint backed by whatever hardware is currently online
- Share compute with a private group over an encrypted, invite-only mesh rather than a public API

## Version history

- 2026-07-11: Mesh LLM launched on iroh's peer-to-peer network, pooling GPUs across machines behind one OpenAI-compatible endpoint. The launch post describes three run modes: local, peer routing, and a split pipeline for models too big for any single box.
