JacobLinCool Codex commited on
Commit
9601bb7
·
1 Parent(s): dd2f7c9

docs: revise article with academic framing

Browse files

Co-authored-by: Codex <codex@openai.com>

Files changed (1) hide show
  1. docs/article.md +73 -54
docs/article.md CHANGED
@@ -6,81 +6,100 @@ Live app: <https://build-small-hackathon-hackathon-advisor.hf.space>
6
  Repository: <https://github.com/JacobLinCool/hackathon-advisor>
7
  Space: <https://huggingface.co/spaces/build-small-hackathon/hackathon-advisor>
8
 
9
- ## The Problem
10
 
11
- Build Small moves fast. Every builder is trying to make something local, useful, strange, or delightful under a strict
12
- model budget, but the field changes hour by hour. A good idea can already be crowded. A quiet niche can be invisible.
13
- Quest and sponsor fit can be buried in READMEs, model cards, and app files. The result is that builders spend too much
14
- of their scarce time guessing where their project sits.
15
 
16
- Hackathon Advisor turns the hackathon itself into the starting point. It is a live atlas of public
17
- `build-small-hackathon` Spaces and a small-model originality coach that helps a builder ask: what exists, what is nearby,
18
- what is still unwritten, and how could this idea become a focused submission?
 
19
 
20
- ## The Experience
21
 
22
- The app opens on the Idea Map, not a chatbot. Each point is a public hackathon Space. Clusters show the shape of the
23
- field; nearest-neighbor links show which projects echo each other. A builder can search for a theme, filter by quest,
24
- open a project, and inspect evidence before asking the advisor for help.
 
25
 
26
- The advisor side is called The Unwritten Almanac. It compares an idea against the current project atlas, cites nearby
27
- projects, proposes whitespace, scores the idea, and drafts a build plan. The workspace can export field notes, an
28
- Almanac chapter, a page PNG, a demo bundle, and LoRA training materials.
 
29
 
30
- There is also an "Ask the atlas" drawer. It uses the base MiniCPM5-1B model's native tool calling to answer questions
31
- about the dashboard. Verified tool results render before the prose, and map actions can highlight or filter the atlas.
32
 
33
- ## The Implementation
 
 
34
 
35
- The visible Space is a Gradio `gradio.Server`, which is a FastAPI server with Gradio API endpoints. The frontend is a
36
- custom HTML/CSS/JS interface served from `static/`; the engine in `hackathon_advisor/` stays UI-agnostic.
 
 
37
 
38
- The runtime model stack is fully open-weight and local to the Space:
 
 
39
 
40
- - Advisor planning: `openbmb/MiniCPM5-1B` plus a public advisor LoRA.
41
- - Quest classification: `openbmb/MiniCPM5-1B` plus a public quest-classifier LoRA.
 
 
 
 
 
 
 
 
42
  - Retrieval: `ggml-org/embeddinggemma-300m-qat-q8_0-GGUF` through llama.cpp.
43
  - Voice input: `nvidia/nemotron-speech-streaming-en-0.6b` through NVIDIA NeMo ASR.
44
 
45
- The advisor deliberately keeps the 1B model's job small. MiniCPM chooses one tool call per turn. Python then handles the
46
- deterministic orchestration: search, whitespace, scoring, planning, profile handling, exports, and response templates.
47
- This keeps behavior inspectable and avoids asking a tiny model to run an uncontrolled multi-hop ReAct loop.
48
-
49
- The atlas refresh path crawls public Spaces in the hackathon organization, reads each README and declared app file,
50
- rebuilds the llama.cpp embedding index, runs quest analysis, validates the dashboard payload, and swaps the result
51
- atomically into the mounted Space cache. A failed refresh leaves the last validated dashboard in place.
52
 
53
- ## What Was Hard
 
 
 
54
 
55
- The hardest part was not drawing a map. It was making the map trustworthy enough for judges and builders.
56
 
57
- MiniCPM and llama.cpp can clash on OpenMP when loaded into the same hot path, so query embedding on macOS runs in a
58
- worker subprocess and dashboard refresh builds the GGUF index in a subprocess before returning to MiniCPM quest analysis.
 
59
 
60
- Quest classification also needed discipline. A prompt-only classifier would rename quests, emit extra prose, or award
61
- Off the Grid to projects that used remote inference APIs. We built a supervised dataset from real public Spaces,
62
- fine-tuned a MiniCPM LoRA, and kept schema validation plus hard invariants in the refresh path.
 
63
 
64
- Finally, the Space needed to be useful even when GPU quota is tight. The atlas, search, exports, cached dashboard, and
65
- many inspection routes remain available without loading the heavy models.
 
66
 
67
- ## How Codex Helped
68
 
69
- Codex acted as the engineering partner across the project. It helped inspect the codebase, break the work into
70
- implementation slices, build the dashboard storage and search paths, add quest evidence UI, write and adjust tests,
71
- debug deployed Space behavior, prepare commit history, publish redacted build traces, and turn the project into a
72
- submission-ready story.
73
 
74
- The project also uses Codex as evidence. Redacted Codex session traces are published at
75
- <https://huggingface.co/datasets/build-small-hackathon/hackathon-advisor-codex-traces>, and commits in the public GitHub
76
- repo include Codex co-author trailers.
77
 
78
- ## Why It Fits Build Small
79
 
80
- Hackathon Advisor is small in the way the hackathon asks for: every model is under 4B, the full stack is far below the
81
- 32B cap, and the runtime uses open weights instead of proprietary inference APIs. It is also complete: a public Space,
82
- a public repo, a demo video, a model/data trail, a custom interface, and a clear use case.
 
83
 
84
- The project belongs in Thousand Token Wood because it turns a hackathon into a navigable, AI-native landscape. The map,
85
- Almanac, quest evidence, and exports make the field feel alive while still grounding every suggestion in real public
86
- projects.
 
6
  Repository: <https://github.com/JacobLinCool/hackathon-advisor>
7
  Space: <https://huggingface.co/spaces/build-small-hackathon/hackathon-advisor>
8
 
9
+ ## Overview
10
 
11
+ Hackathon Advisor is a live atlas of the Build Small Hackathon and a small-model originality coach for builders. It
12
+ turns the public `build-small-hackathon` organization into an evidence surface: every public Space contributes to a map
13
+ of the field, a searchable project index, quest-evidence summaries, and an advisor that helps a builder test where a new
14
+ idea may still have room to grow.
15
 
16
+ The project addresses a practical problem in compressed creative work. During a hackathon, builders need to understand
17
+ the surrounding field quickly. They need to know which ideas are crowded, which themes are emerging, which quests a
18
+ project might satisfy, and how a proposal can become more specific before time runs out. Hackathon Advisor makes those
19
+ questions answerable from the public work already being built around them.
20
 
21
+ ## Contribution
22
 
23
+ The central claim of the project is simple: originality improves when builders can see the field they are entering. The
24
+ app presents that field first. A full-screen Idea Map places projects by embedding similarity, draws nearest-neighbor
25
+ links, and exposes clusters that would be difficult to infer from a feed of individual Spaces. Search and filters make
26
+ the same evidence usable for targeted questions, such as "voice assistants", "local-first", or "quest classifier".
27
 
28
+ The advisor, called The Unwritten Almanac, uses the same project snapshot to compare a proposed idea against nearby
29
+ work. It cites overlapping projects, identifies whitespace, scores the idea with a deterministic rubric, and drafts a
30
+ build plan. The output is meant to be useful before implementation begins: it helps a builder sharpen the audience,
31
+ choose a tractable scope, and reduce accidental duplication.
32
 
33
+ ## User Experience
 
34
 
35
+ The experience begins with exploration. A builder can search the atlas, inspect a cluster, open a project card, and see
36
+ the evidence behind detected quest matches. The map is intentionally the first surface because it gives the advisor's
37
+ later recommendations visible context.
38
 
39
+ When the builder opens The Unwritten Almanac, the app shifts from field reading to idea development. The workspace keeps
40
+ an idea board, profile constraints, score seals, whitespace candidates, and export actions in one place. A session can
41
+ produce field notes, an Almanac chapter, a shareable PNG, a demo bundle, and LoRA training materials. These artifacts
42
+ become reusable records for review and submission.
43
 
44
+ The "Ask the atlas" drawer adds a second mode of interaction. It lets a builder ask structured questions about the
45
+ current dashboard. Verified repository results appear before the model-written answer, and map actions can highlight or
46
+ filter projects directly. The model's prose is grounded in a compact digest of the verified result.
47
 
48
+ ## Technical Design
49
+
50
+ Hackathon Advisor is deployed as a Gradio `gradio.Server`, a FastAPI application with Gradio API endpoints. The visible
51
+ interface is a custom HTML, CSS, and JavaScript frontend served from `static/`; the engine in `hackathon_advisor/`
52
+ remains UI-agnostic.
53
+
54
+ The runtime model stack is open-weight and local to the Space:
55
+
56
+ - Advisor planning: `openbmb/MiniCPM5-1B` with a public advisor LoRA.
57
+ - Quest classification: `openbmb/MiniCPM5-1B` with a public quest-classifier LoRA.
58
  - Retrieval: `ggml-org/embeddinggemma-300m-qat-q8_0-GGUF` through llama.cpp.
59
  - Voice input: `nvidia/nemotron-speech-streaming-en-0.6b` through NVIDIA NeMo ASR.
60
 
61
+ The advisor gives the 1B model a narrow, inspectable role. MiniCPM selects one advisor action per turn; Python then
62
+ carries out the deterministic sequence over search, whitespace discovery, scoring, planning, profile constraints, and
63
+ exports. This design keeps the user-facing response tied to retrieved evidence while preserving the small-model
64
+ discipline of the hackathon.
 
 
 
65
 
66
+ The atlas refresh method crawls public Spaces in the hackathon organization, reads each README and declared app file,
67
+ builds a llama.cpp embedding index, runs quest analysis, validates the dashboard payload, and atomically swaps the new
68
+ snapshot into the mounted Space cache. The last validated atlas remains available when a refresh fails, and many
69
+ inspection routes remain usable while heavier models are unloaded.
70
 
71
+ ## Validation Challenges
72
 
73
+ The main engineering challenge was trust. A map is useful only when builders and judges can understand where its signals
74
+ come from. The refresh process therefore preserves project metadata, README evidence, app-file evidence, embedding
75
+ provenance, quest-analysis outputs, and manifest data for each validated snapshot.
76
 
77
+ Quest classification required additional care. Early prompt-only runs could rename quests, emit explanatory prose, or
78
+ misread local-inference criteria. The final classifier is a supervised MiniCPM LoRA trained on real public Spaces, with
79
+ a strict JSON schema and invariant checks behind every refresh. The write-up in
80
+ [`docs/quest-classification-lora.md`](docs/quest-classification-lora.md) describes the dataset and validation path.
81
 
82
+ The runtime also had to separate MiniCPM's PyTorch stack from llama.cpp on systems where OpenMP runtimes conflict. Query
83
+ embedding on macOS runs in a worker subprocess, and dashboard refresh builds the GGUF index in a subprocess before
84
+ returning to MiniCPM quest analysis.
85
 
86
+ ## Codex Development Record
87
 
88
+ Codex acted as an engineering collaborator throughout the build. It helped inspect the codebase, turn requirements into
89
+ implementation slices, add the dashboard storage and search paths, build the quest-evidence UI, run tests, review
90
+ deployed Space behavior, prepare the demo materials, and refine the submission documents.
 
91
 
92
+ The project also preserves Codex's contribution as evidence. The public Git history includes Codex co-author trailers,
93
+ and redacted Codex session traces are published at
94
+ <https://huggingface.co/datasets/build-small-hackathon/hackathon-advisor-codex-traces>.
95
 
96
+ ## Fit For Build Small
97
 
98
+ Hackathon Advisor fits the Build Small constraints through its model budget and its product form. Every runtime model is
99
+ under 4B parameters, the full stack is far below the 32B cap, and inference runs from open weights inside the Space
100
+ process. MiniCPM is central to the advisor and quest classifier, llama.cpp powers retrieval, Nemotron supports voice
101
+ input, Modal supports development compute, and Codex is part of the documented build record.
102
 
103
+ The project is submitted for Thousand Token Wood because it makes the hackathon field navigable as an AI-native
104
+ landscape. The atlas, Almanac, quest evidence, and exports give builders a way to see the surrounding work and produce a
105
+ more deliberate idea from that evidence.