prebuilt llama-cpp wheel index + field notes
Browse files- FIELD_NOTES.md +83 -0
- README.md +1 -1
- requirements.txt +3 -2
FIELD_NOTES.md
ADDED
|
@@ -0,0 +1,83 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Field Notes: GODSEED β the god grants one wish at a time
|
| 2 |
+
|
| 3 |
+
*Build log for [GODSEED](https://huggingface.co/spaces/build-small-hackathon/godseed) β Build Small Hackathon, Thousand Token Wood track.*
|
| 4 |
+
|
| 5 |
+
## The idea
|
| 6 |
+
|
| 7 |
+
Type a wish. A tiny Nemotron god reads it aloud β you watch its thoughts stream β then
|
| 8 |
+
terraforms **one persistent WebGL planet shared by every visitor**. No level select, no
|
| 9 |
+
reset button. Your wish lands on the same small world as everyone else's, forever.
|
| 10 |
+
|
| 11 |
+
The pitch fits in one line: **3.2B active parameters. One shared world.**
|
| 12 |
+
|
| 13 |
+
## Architecture: the model owns nothing
|
| 14 |
+
|
| 15 |
+
The design rule I refused to break: *the deterministic engine owns every fact; the model
|
| 16 |
+
only interprets, narrates, and chooses.* The god picks from a DSL of exactly 8 tools
|
| 17 |
+
(`raise_terrain`, `spawn_flora`, `place_water`, `set_sky`β¦). The engine validates every
|
| 18 |
+
call, clamps every number, seeds every feature, and feeds terse observations back:
|
| 19 |
+
|
| 20 |
+
```
|
| 21 |
+
{"thought":"The tower. The lamp. The long patience.",
|
| 22 |
+
"call":{"tool":"place_structure","args":{"kind":"lighthouse","lat":26,"lon":-64,...}}}
|
| 23 |
+
β ok: lighthouse placed at (26,-64)
|
| 24 |
+
```
|
| 25 |
+
|
| 26 |
+
Because every feature carries its seed, the whole planet is a pure function of an
|
| 27 |
+
append-only feature list. That one decision bought three things for free: the landing
|
| 28 |
+
page renders the entire world client-side with **zero GPU**, any wish in history can be
|
| 29 |
+
**replayed deterministically** in the Genesis Log, and the agent traces published to the
|
| 30 |
+
[dataset](https://huggingface.co/datasets/AndresCarreon/godseed-world) are complete
|
| 31 |
+
evidence of every plan-act-observe loop.
|
| 32 |
+
|
| 33 |
+
## Things that went wrong (the good part)
|
| 34 |
+
|
| 35 |
+
**The planet was a black void.** My first renderer pass had gorgeous typography, a
|
| 36 |
+
glowing atmosphere rim, golden inscription rings β wrapped around a planet rendered at
|
| 37 |
+
5% luminance with no light rig. Obsidian-dark albedo Γ almost-no-light = a hole in
|
| 38 |
+
space. The fix was cinematography, not brightness: a palette-tinted key sun, an
|
| 39 |
+
atmosphere-colored rim light behind the dark limb, and a low bounce from below-front so
|
| 40 |
+
the shadow side reads as deep violet instead of dead pixels. Dark worlds still need
|
| 41 |
+
three-point lighting.
|
| 42 |
+
|
| 43 |
+
**The god got stuck raising the same mountain six times.** Wish: *"raise a mountain
|
| 44 |
+
crowned with a shrine, where embers drift like prayers."* The 4B model raised terrain at
|
| 45 |
+
(38,-102)⦠then again⦠six times, before finally placing the shrine. The trace showed
|
| 46 |
+
why: every turn got back the **identical observation** β `ok: mountains risen at
|
| 47 |
+
(38,-102)` β so the context never changed, and a small model in an unchanging context
|
| 48 |
+
loops. I didn't fix it with prompt engineering. The engine now refuses an identical
|
| 49 |
+
consecutive call with a new observation: `rejected: already done; change something, or
|
| 50 |
+
say done`. The context changes, the loop breaks, deterministically. Small models don't
|
| 51 |
+
need bigger prompts; they need environments that push back.
|
| 52 |
+
|
| 53 |
+
**The free CPU tier dream died with a stopwatch.** Plan A was llama.cpp + the 4B GGUF on
|
| 54 |
+
the free CPU tier β a god that runs on two vCPUs, fully off-grid. Then I timed it: 183
|
| 55 |
+
seconds per wish *on an M-series Mac*. The Space's CPU would be several times slower.
|
| 56 |
+
You can call queue latency "liturgical pacing" β and I do, the god grants one wish at a
|
| 57 |
+
time β but ten minutes is not liturgy, it's an outage. The live Space runs the same
|
| 58 |
+
grammar-constrained loop on ZeroGPU; the llama.cpp mode survives as the documented local
|
| 59 |
+
config (`GODSEED_BACKEND=llamacpp`), where the whole god is a single ~2.5GB GGUF.
|
| 60 |
+
|
| 61 |
+
**The deploy stack fought back.** Three build failures in an hour: the Spaces image
|
| 62 |
+
force-installs its own gradio and rejects your pin (`sdk_version` in the README is the
|
| 63 |
+
real control); `mamba-ssm` won't source-build under pip's build isolation (its setup.py
|
| 64 |
+
imports torch β use the prebuilt cu12 wheels from GitHub releases); and the
|
| 65 |
+
transformers-v4 line caps `huggingface-hub<1.0` while new gradio wants β₯1.0, so the two
|
| 66 |
+
must be version-matched deliberately. If you're shipping a NemotronH model to ZeroGPU
|
| 67 |
+
this week: `sdk_version: 6.16.0`, `transformers>=4.56,<5`, wheel-pinned mamba kernels.
|
| 68 |
+
|
| 69 |
+
## Moderation, because one bad forest ends everything
|
| 70 |
+
|
| 71 |
+
A shared persistent world during judging week is an invitation. Wishes pass three layers
|
| 72 |
+
before a single tool runs: charset/length limits, a normalized wordlist (NFKC,
|
| 73 |
+
confusables, leetspeak folding), and an LLM judgment with **default-deny on any parse
|
| 74 |
+
failure**. Rejections are final and polite: *the god declines this wish.*
|
| 75 |
+
|
| 76 |
+
## What I'd tell you to try
|
| 77 |
+
|
| 78 |
+
Open the Space, read the planet's history in the Genesis Log, then wish for something
|
| 79 |
+
the world doesn't have yet. Watch the thoughts stream. Watch the camera glide to the
|
| 80 |
+
exact latitude the god chose. That moment β the plan becoming terrain in front of you β
|
| 81 |
+
is the whole project.
|
| 82 |
+
|
| 83 |
+
*Speak, and it will be made.*
|
README.md
CHANGED
|
@@ -122,7 +122,7 @@ guardrails, geometry, and archive.
|
|
| 122 |
- **Llama Champion** β the shipped backend is llama.cpp (`llama-cpp-python`).
|
| 123 |
- **Off-Brand** β fully custom WebGL frontend; Gradio serves the altar console.
|
| 124 |
- **Tiny Titan** β the 4B GGUF configuration runs the whole experience.
|
| 125 |
-
- **Field Notes** β build log
|
| 126 |
- **Sharing is Caring** β live agent traces published as a public dataset.
|
| 127 |
|
| 128 |
## π¦ Submission links
|
|
|
|
| 122 |
- **Llama Champion** β the shipped backend is llama.cpp (`llama-cpp-python`).
|
| 123 |
- **Off-Brand** β fully custom WebGL frontend; Gradio serves the altar console.
|
| 124 |
- **Tiny Titan** β the 4B GGUF configuration runs the whole experience.
|
| 125 |
+
- **Field Notes** β build log: [FIELD_NOTES.md](./FIELD_NOTES.md) (org blog post coming).
|
| 126 |
- **Sharing is Caring** β live agent traces published as a public dataset.
|
| 127 |
|
| 128 |
## π¦ Submission links
|
requirements.txt
CHANGED
|
@@ -6,8 +6,9 @@ gradio>=5
|
|
| 6 |
pydantic>=2.7
|
| 7 |
huggingface_hub>=0.30
|
| 8 |
# llama.cpp runtime for the Nemotron-3-Nano-4B GGUF backend (GODSEED_BACKEND=llamacpp).
|
| 9 |
-
#
|
| 10 |
-
#
|
|
|
|
| 11 |
llama-cpp-python>=0.3.8
|
| 12 |
|
| 13 |
# ---------------------------------------------------------------------------
|
|
|
|
| 6 |
pydantic>=2.7
|
| 7 |
huggingface_hub>=0.30
|
| 8 |
# llama.cpp runtime for the Nemotron-3-Nano-4B GGUF backend (GODSEED_BACKEND=llamacpp).
|
| 9 |
+
# Source build KILLS the Spaces builder (June 12: died mid-compile) β use the
|
| 10 |
+
# project's prebuilt CPU wheel index instead.
|
| 11 |
+
--extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cpu
|
| 12 |
llama-cpp-python>=0.3.8
|
| 13 |
|
| 14 |
# ---------------------------------------------------------------------------
|