Mesh LLM:基于 iroh 的分布式 AI 计算
Mesh LLM: distributed AI computing on iroh

原始链接: https://www.iroh.computer/blog/mesh-llm

Mesh LLM 为中心化、昂贵且不透明的商业大模型供应商提供了一种替代方案。Mesh LLM 无需依赖大型数据中心和按量计费的 API,而是允许企业将现有的硬件资源——从办公电脑到闲置的 GPU——整合到一个统一的私有或公共计算网格中。 该软件提供标准的 OpenAI 兼容 API(`localhost:9337/v1`),这意味着它可以与现有工具无缝集成。在底层,它利用 iroh 网络库通过经过身份验证的 QUIC 隧道连接各个机器。这种架构实现了灵活的模型执行:请求可以在本地运行、路由到有可用算力的对等节点,或者在多台机器之间拆分(“Skippy”模式),从而运行单台设备无法承载的大型模型。 通过利用去中心化的 Gossip 协议和点对点流水线,Mesh LLM 为团队提供了对数据、隐私和基础设施的完全掌控。它消除了对供应商的依赖,通过最大化利用闲置硬件降低了成本,并提供了一种可插拔、可扩展的方式来运行从小型模型到 235B 参数巨型模型的各类应用,而无需昂贵的中心化硬件。

Hacker News 最新 | 往日 | 评论 | 提问 | 展示 | 招聘 | 提交 登录 Mesh LLM:基于 iroh 的分布式 AI 计算 (iroh.computer) 6 点,由 tionis 发布于 21 分钟前 | 隐藏 | 往日 | 收藏 | 2 条评论 帮助 jmercouris 1 分钟前 | 下一条 [-] 我也考虑过这一点,但网络吞吐量非常慢。对于交互式使用来说是不可行的。 回复 turtleyacht 10 分钟前 | 上一条 [-] 听起来 iroh 可以在无需折腾定制硬件的情况下实现分布式计算。 回复 准则 | 常见问题 | 列表 | API | 安全 | 法律 | 申请 YC | 联系 搜索:
相关文章

原文
Distributed Model Inference: a mesh of laptop, GPU rig, mini PC, server, workstation, and cloud nodes connected directly to each other

When people picture running a large language model, they picture a data center. Racks of GPUs that belong to someone else, a metered API, and a bill that grows every month you succeed. You send your prompts off to a black box and hope the price, the model, and the privacy policy all stay the way they were when you signed up.

For a lot of teams that is a bad trade. You give up control over when models change, where your data goes, and what hardware runs your workloads. And as usage grows, so does the bill, with no lever to pull except "pay more."

Mesh LLM is a different shape. It pools the GPUs and memory you already have, across as many machines as you want to add, and exposes the whole thing as one OpenAI-compatible API. Start one node. Add more later. Let the mesh decide whether a model runs on the box in front of you, routes to a peer, or splits across several machines.

The popular models are monoliths. Most people reach them through a UI or an API key and pay a large provider to run everything. That is convenient, and it is also a surrender. You do not control when the model gets updated, what memory it runs in, or what hardware sits underneath.

Plenty of businesses and services that depend on these models want the opposite: more control, more pluggability, lower cost. They have GPUs sitting in offices, in closets, under desks. What they are missing is a way to make those machines act like one.

The pitch is simple. Run bigger models without buying bigger GPUs. Share compute privately with your team, or publicly with the world, to power agents and chat. Point any OpenAI client at http://localhost:9337/v1 and stop caring where the work actually happens.

Under the hood, Mesh LLM distributes model compute across a mesh of iroh endpoints. A request can be served three ways:

  • Run it locally, on this machine's GPU.
  • Route it to a peer that already has the model loaded.
  • Split a model too big for any single box across several machines, as a pipeline.

The architecture is pluggable. Plugins declare what they provide in a manifest, the runtime starts them, routes calls, and exposes their capabilities over MCP, HTTP, inference, and mesh events. The catalog ships with 40+ models, from half-a-billion-parameter models that fit on a laptop to 235B mixture-of-experts giants.

For the giants, Mesh LLM has a split mode (internally, "Skippy"). A model gets partitioned by layer ranges into stages: layers 0 to 15 on one node, 16 to 31 on the next, and so on down the pipeline. Activations flow from one stage to the next, so several modest machines can run a model none of them could hold alone. The OpenAI client never sees any of this. It still just talks to localhost.

Every node, whether it serves models or only sends requests, boots an iroh endpoint. That endpoint is the node's identity, a public key, and its only network surface. There is no central server. iroh handles the hole-punching, NAT traversal, and relay fallback needed to open a direct, authenticated QUIC connection between any two nodes, wherever they sit.

To keep that working across the open internet, Mesh LLM runs two iroh relays in different regions, so nodes that cannot reach each other directly always have a fallback path nearby.

The whole protocol rides on QUIC's ALPN negotiation. There are three:

ALPNWhat it carries
mesh-llm/1Main mesh: gossip, routing, HTTP tunnels, plugin channels
mesh-llm-control/1Owner control plane (config sync, ownership attestation)
skippy-stage/2Latency-sensitive activation transport for split models

Inside the main mesh-llm/1 connection, everything is a bidirectional QUIC stream tagged with a single leading byte that says what kind of stream it is. One connection carries gossip, inference, route queries, and peer-lifecycle events, all demuxed by that first byte:

ByteStream typeDescription
0x01GOSSIPpeer announcements (models, GPU, RTT, capabilities)
0x04TUNNEL_HTTPinference requests proxied to a peer
0x05ROUTE_REQUEST"which models do you host?"
0x06PEER_DOWNdead-peer notification
0x07PEER_LEAVINGgraceful shutdown
0x08PLUGIN_CHANNELplugin RPC
0x0eDIRECT_PATH_REQUESTshare direct addresses for NAT traversal

The neat part is what this buys you. iroh gives authenticated, NAT-traversing QUIC between any two machines, addressed by public key. So "route to a peer" and "stream activations to the next pipeline stage" become the same primitive as "talk to localhost," just with a different endpoint ID. The networking stops being something you have to think about.

iroh provides the secure transport. Mesh LLM builds its own gossip layer on top, so it controls exactly who gets admitted to the mesh, which versions are compatible, and which peers to trust.

Users can install the lightweight software (about 18 MB) and either join the public mesh or configure private deployments. The system presents itself as localhost:9337/v1 to any standard OpenAI client.

A mobile app is coming, built on iroh's Swift SDK. The plan is to speak ACP, the emerging agent standard, so other clients can join the mesh too. The throughline is the same one that motivated the whole project: more peer to peer, fewer closed servers, and no lock-in.

Iroh is a dial-any-device networking library that just works. Compose from an ecosystem of ready-made protocols to get the features you need, or go fully custom on a clean abstraction over dumb pipes. Iroh is open source, and already running in production on hundreds of thousands of devices.
To get started, take a look at our docs, dive directly into the code, or chat with us in our discord channel.
联系我们 contact @ memedata.com