hugging-apps/kev-decision-model-demo
kev-0.5b — a decision model
`jaredpalmer/kev-0.5b` is a LoRA adapter (r=16) plus a pointer readout head on top of a frozen `Qwen/Qwen2.5-0.5B` backbone. It reads a document once and answers many typed questions about it in parallel, in a single prefill pass with no decoding.
- The state and every question are packed into one token sequence.
- A block-causal mask lets each question attend to the state, but never to a sibling question.
- A pointer head scores each option's
</opt>hidden state against the question's<decide>hidden state and applies a softmax. Those probabilities are the output — trained with cross-entropy against labelled outcomes, not generated as text.
Three question types: noul (yes/no), choice (2–255 named options), score (ordered levels). The API mirrors TypeSafe's POST /v1/systemone contract.
This Space
Runs the checkpoint in fp32 on ZeroGPU (the model card's numbers are fp32-exact; the whole thing is ~2 GB). The Advanced → branch-isolation check option re-asks every question in its own forward pass and reports the largest probability difference between the packed and separate answers — it should be ~1e-6.
The example presets are the ones shipped with the project's own playground (playground/src/lib/kev.ts), including the Isolation probe and Boundary forgery experiments.
Credits & licence
Model, inference code (kev_core/model.py, kev_core/api.py, vendored verbatim) and the playground presets are by Jared Palmer, Apache-2.0 (source). Architecture reconstruction by Archer Hume; API contract from TypeSafe. The base model is distributed under the Qwen licence.
Research prototype. The author trained kev-0.5b on a laptop and calls it "not a production model": 0.712 accuracy in-distribution, 0.575 out of domain, calibration fitted in-distribution only. The larger kev-4b / kev-8b checkpoints in the kev collection are substantially better.
