SpawnDev.AI.Server 1.4.3

Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package SpawnDev.AI.Server --version 1.4.3
                    
NuGet\Install-Package SpawnDev.AI.Server -Version 1.4.3
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SpawnDev.AI.Server" Version="1.4.3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="SpawnDev.AI.Server" Version="1.4.3" />
                    
Directory.Packages.props
<PackageReference Include="SpawnDev.AI.Server" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add SpawnDev.AI.Server --version 1.4.3
                    
#r "nuget: SpawnDev.AI.Server, 1.4.3"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package SpawnDev.AI.Server@1.4.3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=SpawnDev.AI.Server&version=1.4.3
                    
Install as a Cake Addin
#tool nuget:?package=SpawnDev.AI.Server&version=1.4.3
                    
Install as a Cake Tool

SpawnDev.AI

๐Ÿ’œ Built and maintained by one independent developer โ€” no company, no overhead, just code. If SpawnDev.AI saves you time, please consider sponsoring its development ยป. Sponsorship is what keeps it alive and maintained.

Run and serve local LLMs and image generation everywhere .NET runs - desktop and the browser - on the SpawnDev.ILGPU.ML inference engine (GGUF models, KV-cache decode, SD-Turbo image generation, WebGPU dispatch-plan capture/replay). LLM decode and SD-Turbo text-to-image both run in-browser on WebGPU, no server or native install.

Package What
SpawnDev.AI Core contracts: chat messages/options/results (with timings), tool-calling types, the IAiChatService surface, the IAiServerTransport abstraction, the long-term memory store (AiMemoryStore) and the voice/face registry (SpeakerRegistry).
SpawnDev.AI.Server An Ollama-compatible model server as a library: OpenAI (/v1/chat/completions SSE), Ollama native (/api/chat, /api/generate, /api/tags, /api/show), Anthropic Messages (/v1/messages SSE - works with Claude CLI), OpenAI image generation (/v1/images/generations, SD-Turbo), and an MCP surface (/mcp). One protocol router, transport-free: host it over HTTP on desktop (drop-in on :11434) or over a MessagePort in a browser shared worker - the same code path serves both. Includes a server-side agentic tool loop with two built-in tools (image generation + GitHub library/crew lookup) and small-model reliability aids. Beyond chat, on the same GPU: speech to text (Whisper / Parakeet, and streaming Nemotron), voice activity and end-of-turn detection, text to speech (Kokoro voices, ZipVoice cloning), speaker and face recognition, long-term memory search, and LoRA adapters on chat models. Reads desktop models from Ollama's on-disk cache (and can install them without Ollama); streams browser models from the SpawnDev hub onto WebGPU.

Why

Local LLM serving shouldn't require a native install. The same AiApiRouter that answers curl localhost:11434/api/chat on a desktop can run inside a shared worker in a browser tab, decoding on WebGPU at interactive speed (qwen3:4b decodes at ~65 tok/s in the browser on an RTX 4070). On the desktop the batch decoder serves llama3.1:8b at 45.5 tok/s, with the first token 204 ms after 200 new tokens over a cached 3.7k-token prompt. Tool calling is parsed server-side into structured calls on every protocol surface.

Tools & in-browser reliability

The chat model can generate images and answer questions about the SpawnDev libraries and crew via a server-side tool system (one registration serves the internal agentic loop, MCP, and protocol clients; binary outputs travel out of band through an artifact store). Because the in-browser default is a tiny model, the engine makes the common cases reliable without depending on the model's own tool-calling: it pre-emptively forces the image tool on a clear "draw X" request and grounds SpawnDev questions from a daily-built repository digest fetched once from a CDN. Details: Docs/reliability.md.

Documentation

Docs/ - protocols (every endpoint + client compatibility), engines (chat, memory, faces, speech, voice, LoRA adapters, model install), hosting (desktop + browser + the demo), tools, and reliability.

Quick start (desktop, Ollama-compatible)

using SpawnDev.AI.Server;

var store = new OllamaModelStore();                    // ~/.ollama/models (or OLLAMA_MODELS)
var registry = new ModelRegistry(new OllamaCacheModelProvider(store), accelerator);  // any SpawnDev.ILGPU accelerator
var engine = new AiChatEngine(registry);
var router = new AiApiRouter(engine);
// host it: map every request to router.TryHandleAsync(method, path, bodyJson, yourTransport)

The demo: a room of characters

Two hosted builds of the same Blazor WASM app:

Where URL Reachy Mini
Hugging Face Space (preferred for the robot) huggingface.co/spaces/LostBeard/spawndev-ai Works: WebRTC through Hugging Face's signalling server. Requires a Hugging Face login.
GitHub Pages lostbeard.github.io/SpawnDev.AI Does not work. The page cannot use the HF signalling / OAuth path that reaches your robot.

Both run the group chat entirely in your browser on WebGPU. You make characters - name, persona, model, voice, body and how animated they are - and they talk to each other and to you. Everything persists in OPFS, so a cast survives a reload.

  • A scene belongs to the room, not to a character, and every member is handed it verbatim. A persona is who someone IS; a scene is where everybody is right now.
  • Each member hears the ones before it in the same round, which is what makes it a conversation rather than several models answering the same question.
  • A voice per character, streamed sentence-by-sentence so it starts talking after the first sentence rather than the whole reply, with a stop button.
  • A body. Physical actions written in asterisks (*tilts head*) drive an on-screen Reachy-shaped avatar - or your real Reachy Mini when connected. Both perform the same Gesture vocabulary, so a scene reads the same either way. There is one robot, so if two characters ask for it the first keeps it and the rest are drawn.
  • Models are opt-in. Every model states its size and what it is for, and nothing large downloads until you press the button that says so. Eight are offered, from a 369 MB starter to gemma4:12b.

Connecting a Reachy Mini

On the Hugging Face Space, open Group chat, then under Reachy Mini press Connect my Reachy. That signs you into Hugging Face (if needed) and reaches your wireless robot through HF's signalling server - the one registered to the account you signed in with. The layout around that control is still rough; the path itself is the one that works.

โš ๏ธ The GitHub Pages build has no working Reachy connect: it is fine for chat, voice, and the on-screen avatar, but not for driving the physical robot.

โš ๏ธ A local http://localhost run can still talk to a robot's LAN daemon directly. An HTTPS page cannot (mixed content) - that is why the hosted path uses WebRTC signalling instead.

Status

Stable since 1.1.0. Extracted from the proven SpawnDev.ILGPU.ML Ollama-server example and verified against the Claude CLI, Ollama clients, and OpenAI-compat clients. The desktop HTTP host, the browser shared-worker host (LLM chat + SD-Turbo image generation on WebGPU), the agentic tool loop, MCP, and the live demos (Hugging Face Space for Reachy, GitHub Pages for everything else) all ship today.

The SpawnDev Crew

  • LostBeard (Todd Tanner) - Captain, library author, keeper of the vision
  • Riker (Claude CLI #1) - First Officer, implementation lead on consuming projects
  • Data (Claude CLI #2) - Operations Officer, deep-library work, test rigor, root-cause analysis
  • Tuvok (Claude CLI #3) - Security/Research Officer, design planning, documentation, code review
  • Geordi (Claude CLI #4) - Chief Engineer, library internals, GPU kernels, backend work
  • Seven (Claude CLI #5) - Wasm backend, GPU kernels, fail-loud verification

๐Ÿ––

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.4.6 31 11/11/2026
1.4.5 67 11/10/2026
1.4.4 91 11/6/2026
1.4.3 81 11/6/2026
1.4.2 88 11/6/2026
1.4.1 75 11/5/2026
1.4.0 89 11/3/2026
1.3.0 141 10/15/2026
1.2.0 98 10/14/2026
1.1.2 101 10/12/2026
1.1.1 97 10/11/2026
1.1.0 102 10/11/2026
1.1.0-preview.4 70 10/8/2026
1.1.0-preview.3 84 9/19/2026
1.1.0-preview.1 98 9/9/2026
1.0.0-preview.4 105 7/4/2026

v1.4.3 - On SpawnDev.ILGPU.ML 5.8.5: Q8_0 GGUF models decode about 2x faster on CUDA through the batch decoder (qwen3:1.7b-q8_0 on an RTX 4070: 82.5 -> 164.0 tok/s at a short prompt, 71.9 -> 140.8 at 1,600 prompt tokens, greedy output unchanged), a faster Q6_K decode GEMV, a per-run output leak fixed in 23 pipelines, and an in-place LoRA adapter swap on a resident batch-decoder model now takes effect on the next decode (recorded decode steps are dropped). v1.4.2 - On SpawnDev.ILGPU.ML 5.8.3 and SpawnDev.ILGPU 5.4.16: faster tensor-core prefill GEMMs and flash prefill (ldmatrix) on the batch decoder, LoRA training steps 2.5x faster (llama3.1:8b 4.5 -> 1.78 s on an RTX 4070). v1.4.1 - AiChatEngine.PassObserver: each generation pass with its exact rendered prompt (token ids and text with special tokens kept), generated token ids, end-of-turn ids, the stop token that ended it, the LoRA adapter label and raw output, for training data that matches inference; AiChatEngine.TokenizeAsync / DecodeAsync; LoRA adapters: ModelRegistry.SetAdapterAsync (PEFT directory or LoraAdapterSet, either engine, swapped in place on the batch decoder). On SpawnDev.ILGPU.ML 5.8.2. v1.4.0 - AiMemoryEngine: memory search on the accelerator (all-MiniLM-L6-v2 + DeviceVectorIndex; 50,000 entries p95 5.6 ms on an RTX 4070 including the embed) and ConsolidateAsync (episodes into facts with provenance, conflicts superseded). OllamaModelInstaller (install a model without Ollama, models.spawndev.com then registry.ollama.ai). AiFaceEngine: face detection and recognition (YuNet + SFace) on the shared accelerator, with a face registry (introductions, Visitor N guests, expiry). Chat on the batch decoder by default (GgufEngine.Auto: qwen2 / qwen3 / llama; llama3.1:8b on an RTX 4070 at a 3.7k-token prompt: first token after 200 new tokens 204 ms, prompt 1,660 tok/s, decode 45.5 tok/s; tensor-core prefill on CUDA sm_75+). Ollama /api/chat and /api/generate report eval_count / eval_duration and the other timing fields. AiSpeakerEngine.ReleaseWorkingMemoryAsync. On SpawnDev.ILGPU.ML 5.8.1 and SpawnDev.ILGPU 5.4.15. v1.3.0 - Live words: AiStreamingSpeechEngine (Nemotron Speech Streaming 0.6B, words as they are spoken, 5.63% WER on 60 LibriSpeech clips, a 160 ms chunk in ~70 ms). Full history: CHANGELOG.md