dispatchAI/tiny-model-dungeon
0
1---2title: Tiny Model Dungeon3emoji: ⚔️4colorFrom: indigo5colorTo: blue6sdk: static7app_file: index.html8pinned: true9tags:10- game11- webgpu12- on-device13- mobile-ai14- text-adventure15---16 17# ⚔️ Tiny Model Dungeon18 19An AI-powered text adventure game where the **entire AI runs in your browser** — no server, no cloud, no API costs.20 21## The pitch22 23> *This whole game's AI fits in 200MB.*24 25The dungeon master is a **360M parameter model** (SmolLM2-360M-Instruct) running entirely on your device via WebGPU. Every room description, monster encounter, and treasure find is generated in real-time by a model smaller than a single photo album.26 27## How it works28 291. On page load, the model (~200MB ONNX) downloads once and is cached by your browser302. WebGPU accelerates inference on your GPU (falls back to WASM on older browsers)313. Every player action generates a unique AI narration — no scripted responses324. The game never contacts a server after the initial model download33 34## Why?35 36This is dispatchAI's thesis made tangible: **small models are powerful enough for real applications.** A 360M model generating creative dungeon descriptions proves that mobile-sized AI is not a toy — it's a product.37 38## Tech39 40- **Model**: [SmolLM2-360M-Instruct](https://huggingface.co/dispatchAI/SmolLM2-360M-Instruct-mobile)41- **Inference**: [transformers.js](https://github.com/xenova/transformers.js) v3.7.042- **Backend**: WebGPU (with WASM fallback)43- **Hosting**: Static HuggingFace Space (free forever)44- **Cost**: $045 46---47 48*Built by [dispatchAI](https://huggingface.co/dispatchAI) — mobile AI that moves at the speed of need.*49 