--- title: whatfirst small emoji: ๐Ÿ—‚๏ธ colorFrom: indigo colorTo: blue sdk: docker app_port: 7860 pinned: true license: apache-2.0 models: - ggml-org/Qwen2.5-VL-3B-Instruct-GGUF tags: - track:backyard - achievement:offgrid - achievement:llama - achievement:fieldnotes - achievement:tiny-titan thumbnail: >- https://cdn-uploads.huggingface.co/production/uploads/67a39e9465c06c95d452bd6d/Z_pvYNAWsx5oR24zkUFZg.png --- # whatfirst ยท small **Dump everything on your mind โ€” get back what to do *first*, with the math shown.** ### [โ–ถ Try the live demo](https://huggingface.co/spaces/build-small-hackathon/whatfirst-small) ๐Ÿค **3B params** (โ‰ค 4B โ€” *Tiny Titan*)  ยท  ๐Ÿ”Œ **runs 100% offline** โ€” no internet required  ยท  ๐Ÿฆ™ llama.cpp [๐Ÿ“ฃ Launch post](https://x.com/tbd_ntbd/status/2066222870657692128)  ยท  [what-first.com](https://what-first.com)  ยท  Apache-2.0 A small **local** vision-language model (Qwen2.5-VL-3B, ~2 GB, running on llama.cpp) reads a messy brain-dump or a photo of a to-do list and turns each line into a structured task โ€” impact, readiness, effort, deadline. A **deterministic, transparent scoring engine** then ranks them and tells you the one thing to start now, showing every number behind the call. No cloud, no API keys, runs on a laptop. Built for the [Hugging Face Build Small hackathon](https://huggingface.co/build-small-hackathon) (Backyard AI track). ๐Ÿ““ **Field notes:** [an honest write-up of what worked and what didn't](submission/whatfirst-small-writeup.md) โ€” the small-model story, including where a 3B model wobbles and how the design absorbs it. ## Demo [![Watch the whatfirst-small demo](https://huggingface.co/spaces/build-small-hackathon/whatfirst-small/resolve/main/demo/out/whatfirst-small-demo-poster.jpg)](https://huggingface.co/spaces/build-small-hackathon/whatfirst-small/resolve/main/demo/out/whatfirst-small-demo-loud.mp4) โ–ถ **[Watch the demo video](https://huggingface.co/spaces/build-small-hackathon/whatfirst-small/resolve/main/demo/out/whatfirst-small-demo-loud.mp4)**  ยท  **[Try the live Space](https://huggingface.co/spaces/build-small-hackathon/whatfirst-small)** ## Why this exists Deciding *what to do first* is a real, daily problem โ€” and most "AI to-do" apps answer it with a black box. This one keeps the AI where it earns its keep (turning vague human language into structured fields) and makes the prioritization itself **legible**: two competing scores (do-it-now vs. de-risk-first), an urgency curve that explodes as a deadline nears, a quick-win boost for short, high-impact tasks, and deadlines treated as a hard constraint rather than a number folded into a blob. The problem โ€” and the prioritization approach โ€” come from **[what-first.com](https://what-first.com)**, a full web app the same team built in June 2026. There, a frontier cloud model (Claude) does the language work โ€” reading your tasks and proposing their impact, readiness, and effort โ€” and a deterministic engine ranks them. This entry asks a smaller question: can a **3B model running offline on a laptop** do that same language work? The ranking engine here is a clean-room Python reimplementation with its own tests, not a copy of the original. ## How it works ``` brain-dump / photo โ”€โ”€โ–ถ Qwen2.5-VL-3B (llama.cpp, localhost) โ”€โ”€โ–ถ structured tasks โ”‚ score.py (deterministic) โ”‚ ranked list + "do this first" ``` - `score.py` โ€” the scoring + deadline-ranking engine (pure standard-library math). - `llm.py` โ€” client for the local llama.cpp server (brain-dump parse, image extract, single-task re-score). Each call is grammar-constrained to a JSON object; every model output is re-clamped before scoring. - `prompts.py` โ€” the system prompts that ask for strict-JSON output and define the scoring scales. - `app.py` โ€” the Gradio UI: capture, ranked table, and sliders to correct any score and re-rank live. ## Run it locally ```bash docker build -t whatfirst-small . docker run -p 7860:7860 whatfirst-small # first boot downloads ~3.3 GB (model + vision projector) ``` Then open http://localhost:7860. On a CPU-only box, expect a few seconds per task โ€” that's the cost of staying fully on the grid-less side. Tests: ```bash python -m pytest test_score.py # or: python test_score.py ``` ## Notes - **Model:** [`ggml-org/Qwen2.5-VL-3B-Instruct-GGUF`](https://huggingface.co/ggml-org/Qwen2.5-VL-3B-Instruct-GGUF) (Q4_K_M + f16 mmproj), โ‰ค 32B and laptop-runnable. - **Off the grid:** all inference is local llama.cpp over localhost; nothing leaves the box at runtime. --- ๐Ÿ““ **See the full story in our [field notes](submission/whatfirst-small-writeup.md)** โ€” what worked, where a 3B model wobbles, and how the design absorbs it.