Spaces:
Sleeping
Sleeping
| title: DaisyChain-Infer | |
| emoji: ❄️ | |
| colorFrom: blue | |
| colorTo: gray | |
| sdk: docker | |
| app_port: 7860 | |
| license: mit | |
| short_description: One model split across your devices, P2P in the browser | |
| hf_oauth: true | |
| hf_oauth_scopes: | |
| - read-repos | |
| hf_oauth_expiration_minutes: 480 | |
| # ❄ DaisyChain-Infer — one model, split across your devices | |
| Part of **DaisyChain** → https://huggingface.co/DaisyChainAI | |
| Pick a Hugging Face model, open this page on two or more of your devices, and | |
| each one takes a **slice of the model's layers**. A token is produced by passing | |
| the hidden state around the ring, peer-to-peer over WebRTC. Every multiply runs | |
| through **verified INT8 units** — WebGPU where available, the identical math on | |
| CPU where not. | |
| The group can run a model that **no single device could hold**, because each | |
| device downloads only its own layers. | |
| > **Project files, guide and test suites:** | |
| > https://huggingface.co/DaisyChainAI/DaisyChain-Infer | |
| ## How to use it | |
| 1. **Create a room** and open the invite link on your other devices. You approve | |
| each device before it joins. (There is no automatic grouping here — see | |
| *Privacy* below.) | |
| 2. On **one** device, type a model repo id and press **Load**. That device | |
| becomes the **head**. | |
| 3. Press **Generate**. Each device fetches its own layers from the Hub, reports | |
| ready, and the ring starts. | |
| Models it can run: any `.safetensors` repo that is **Llama-style** (Llama, | |
| Mistral, Qwen2/2.5, SmolLM, TinyLlama) or **GPT-2-style**. Try | |
| `HuggingFaceTB/SmolLM-135M`, `openai-community/gpt2`, or `Qwen/Qwen2.5-0.5B`. | |
| Anything else is **refused by name**, not approximated — running an unknown | |
| block shape through these kernels would produce fluent, confident, wrong text. | |
| ## Nothing is downloaded to this Space | |
| This Space is a **WebSocket signaling server and a static file host**. It never | |
| sees a weight, an activation, your prompt, or the generated text. Weights go | |
| from the Hugging Face CDN **straight to each browser**, using HTTP range | |
| requests against the byte offsets in the safetensors header — so a device | |
| transfers only the layers it owns, and pressing *Load* costs a few tens of KB | |
| regardless of the model's size. | |
| ## Signing in | |
| Public models need no sign-in at all. | |
| For **gated or private** models, use **Sign in with Hugging Face**. You are | |
| redirected to huggingface.co and back, and this page receives a scoped, | |
| expiring token (read access to repositories, nothing more) held **in memory for | |
| that tab only** — never written to storage, never logged, and never sent to | |
| another device. Each device signs in for itself, because each device downloads | |
| its own layers. | |
| There is deliberately **no box to paste a personal access token** here. Typing | |
| a PAT into a page served by someone else is a bad habit even when the code is | |
| honest, because you cannot verify that it is. If you would rather not sign in at | |
| all, clone the project and run it locally — the local build accepts a token | |
| directly, because there the page is served from your own machine. | |
| One honest caveat: the OAuth code exchange requires a client secret, so it | |
| happens on the server, which means this Space briefly handles your access token | |
| during that exchange. It is not stored or logged, and it is handed to your | |
| browser in the URL fragment (which browsers never send to servers) and stripped | |
| from history on arrival. That is the smallest exposure the flow allows — it is | |
| not zero. | |
| ## Privacy and trust | |
| - **Rooms are private by invitation.** This deployment disables the LAN | |
| auto-grouping the local build uses, because on a public URL two strangers | |
| behind the same CGNAT or on the same campus network share a public IP and | |
| would otherwise be placed in one ring together. | |
| - **Peers connect directly**, so devices in your ring can see each other's IP | |
| addresses. | |
| - A middle stage never receives the embedding table, so **it never sees the | |
| vocabulary** — it passes floats it cannot interpret. But it does see the | |
| hidden states going through it, and the head sees your prompt and output. | |
| - **Activations are not authenticated.** A malicious stage that runs correct | |
| arithmetic but returns a crafted activation is not caught by anything here. | |
| The verification proves the *computation* is right on every honest device; | |
| trust in the participants is yours to establish. | |
| **Ring only with devices and people you trust. This is a proof of concept, not | |
| a hardened service.** | |
| ## Honest limits | |
| - **Latency, not bandwidth, is the cost.** Every token pays one round trip per | |
| stage, so tokens/sec *falls* as you add devices. More stages buy capacity, not | |
| speed. | |
| - **No KV cache** — every token re-runs the whole window, which is also what | |
| keeps a split run bit-comparable against an unsplit one. | |
| - **Weights are held as f32**, so budget ~4 bytes per parameter across the | |
| group. The ring plan shows each device's cost before you start. | |
| - **Needs WebGPU or a patient CPU**, and a secure context (this Space is HTTPS, | |
| so that is fine). | |
| - The **head is a single point of failure**; a stage that drops stalls the ring. | |
| Press Generate again to re-plan around whoever is still connected. | |
| --- | |
| **License:** MIT · **Author:** Dean Byrne (Quazim0t0) · **Org:** DaisyChainAI | |
| Built on [DaisyChain-Train](https://huggingface.co/DaisyChainAI/DaisyChain-Train) | |
| and [DaisyChain-Web](https://huggingface.co/spaces/Quazim0t0/DaisyChain-Web) — | |
| the verified INT8 units, the WGSL kernels and their exact gates, and the WebRTC | |
| mesh are carried over unchanged. | |