Prime Radiant / Phase 4 — Reasoning
pending — blocked on Phase 3 close

Phase 4 — Reasoning & Primitive Grammar

Gemma 3 4B (local, via llama.cpp) receives the HippoRAG-lite subgraph as context and generates inline primitive-grammar tokens constrained to the retrieved card references. Two interaction modes: query (explain coupling X→Y) and story (Calvino-layer narrative constrained by subgraph).

← Back to site map

Seven primitives — the reasoning grammar

Token Meaning Example emission
<|machine|> Reference to a specific Machine Card <|machine|> amsterdam-bourse-1602
<|coupling|> Named coupling between two machines <|coupling|> substrate_provision
<|signal|> Observable state-variable signal <|signal|> zombie_persistence_index=0.71
<|stress|> Landscape pressure or coupling stress <|stress|> pace_layer_mismatch_stress
<|transition|> Succession event with typology break <|transition|> adaptation 1971–1980
<|trace|> PageRank traversal path in the subgraph <|trace|> A → B → C
<|new_machine|> Novel machine proposal (queued to proposals/) <|new_machine|> {stub card JSON}

Model config

ParameterValue
ModelGemma 3 4B (Q8 GGUF via llama.cpp)
Config keyLLAMA_CPP_BIN, GEMMA_MODEL_PATH
Context window~4096 tokens (subgraph + system prompt)
Grammar constraintInline primitive token vocabulary enforced via llama.cpp grammar
Output parsingprime_radiant/parse.py — validates card refs + queues proposals