Ollaya package for hiteshluke/arbiter-4b
Browse files- 4b/calibration.json +9 -0
- 4b/decision.json +137 -0
- 4b/model-fp32.onnx +3 -0
- README.md +47 -0
4b/calibration.json
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"temperature": [
|
| 3 |
+
1.0,
|
| 4 |
+
1.0,
|
| 5 |
+
1.0
|
| 6 |
+
],
|
| 7 |
+
"temperature_by_options": {},
|
| 8 |
+
"source": "no fitted temperature ships with the checkpoint (T = 1)"
|
| 9 |
+
}
|
4b/decision.json
ADDED
|
@@ -0,0 +1,137 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"engine": "onnx",
|
| 3 |
+
"family": "arbiter",
|
| 4 |
+
"layout": "arbiter-fixed-v1",
|
| 5 |
+
"upstream": {
|
| 6 |
+
"repo": "hiteshluke/arbiter-4b",
|
| 7 |
+
"revision": "0c44271c59f89758e3cae17b032e98a9140093e9",
|
| 8 |
+
"base": "unsloth/gemma-3-4b-it",
|
| 9 |
+
"base_revision": "bf46152c47f5dd20b896357cb51abc4c03b8ee8c",
|
| 10 |
+
"code": {
|
| 11 |
+
"repo": "https://github.com/CodekinsTech/arbiter",
|
| 12 |
+
"commit": "e1cb30fd3019cf91d2631a2d1004abd858b8e4fa",
|
| 13 |
+
"script": "training_v3_6/train.py"
|
| 14 |
+
},
|
| 15 |
+
"lora": {
|
| 16 |
+
"r": 16,
|
| 17 |
+
"alpha": 32,
|
| 18 |
+
"scaling": 2.0,
|
| 19 |
+
"merged": false
|
| 20 |
+
}
|
| 21 |
+
},
|
| 22 |
+
"contract": {
|
| 23 |
+
"inputs": {
|
| 24 |
+
"input_ids": {
|
| 25 |
+
"dtype": "int64",
|
| 26 |
+
"shape": [
|
| 27 |
+
"rows",
|
| 28 |
+
"seq"
|
| 29 |
+
],
|
| 30 |
+
"note": "one row per question; seq a multiple of 64; right-pad with any id (pad)"
|
| 31 |
+
},
|
| 32 |
+
"last_pos": {
|
| 33 |
+
"dtype": "int64",
|
| 34 |
+
"shape": [
|
| 35 |
+
"rows"
|
| 36 |
+
],
|
| 37 |
+
"note": "position of the row's last token"
|
| 38 |
+
}
|
| 39 |
+
},
|
| 40 |
+
"outputs": {
|
| 41 |
+
"scores": {
|
| 42 |
+
"dtype": "float32",
|
| 43 |
+
"shape": [
|
| 44 |
+
"rows",
|
| 45 |
+
24
|
| 46 |
+
],
|
| 47 |
+
"note": "raw scores of the head's 24 slots; a question's option logits are the scores at its slots"
|
| 48 |
+
}
|
| 49 |
+
},
|
| 50 |
+
"seq_multiple": 64,
|
| 51 |
+
"positions": "0..seq-1, implicit",
|
| 52 |
+
"attention": "causal (sliding layers: the last 1024 positions); no mask input"
|
| 53 |
+
},
|
| 54 |
+
"max_row_tokens": 8192,
|
| 55 |
+
"special_tokens": {
|
| 56 |
+
"bos": 2,
|
| 57 |
+
"pad": 0
|
| 58 |
+
},
|
| 59 |
+
"num_slots": 24,
|
| 60 |
+
"slots": {
|
| 61 |
+
"noul": [
|
| 62 |
+
1,
|
| 63 |
+
0
|
| 64 |
+
],
|
| 65 |
+
"choice": [
|
| 66 |
+
2,
|
| 67 |
+
3,
|
| 68 |
+
4,
|
| 69 |
+
5,
|
| 70 |
+
6,
|
| 71 |
+
7,
|
| 72 |
+
8,
|
| 73 |
+
9,
|
| 74 |
+
10,
|
| 75 |
+
11,
|
| 76 |
+
12,
|
| 77 |
+
13,
|
| 78 |
+
14,
|
| 79 |
+
15,
|
| 80 |
+
16,
|
| 81 |
+
17
|
| 82 |
+
],
|
| 83 |
+
"score": [
|
| 84 |
+
18,
|
| 85 |
+
19,
|
| 86 |
+
20,
|
| 87 |
+
21,
|
| 88 |
+
22,
|
| 89 |
+
23
|
| 90 |
+
]
|
| 91 |
+
},
|
| 92 |
+
"max_options": 16,
|
| 93 |
+
"score_levels": 6,
|
| 94 |
+
"verbalizers": [
|
| 95 |
+
"T",
|
| 96 |
+
"F",
|
| 97 |
+
"A",
|
| 98 |
+
"B",
|
| 99 |
+
"C",
|
| 100 |
+
"D",
|
| 101 |
+
"E",
|
| 102 |
+
"F",
|
| 103 |
+
"G",
|
| 104 |
+
"H",
|
| 105 |
+
"I",
|
| 106 |
+
"J",
|
| 107 |
+
"K",
|
| 108 |
+
"L",
|
| 109 |
+
"M",
|
| 110 |
+
"N",
|
| 111 |
+
"O",
|
| 112 |
+
"P",
|
| 113 |
+
"0",
|
| 114 |
+
"1",
|
| 115 |
+
"2",
|
| 116 |
+
"3",
|
| 117 |
+
"4",
|
| 118 |
+
"5"
|
| 119 |
+
],
|
| 120 |
+
"templates": {
|
| 121 |
+
"row": "[bos] tok(\"State: {render(state)}\\n\\nQuestion: {render(instructions)}\\n\\nOptions:\\n{block}\\n\\nAnswer:\"); the head is read at the last token",
|
| 122 |
+
"noul_block": "T. Yes / True\nF. No / False",
|
| 123 |
+
"choice_block": "{letter}. {option}, one line per option, letters A..P",
|
| 124 |
+
"choice_option": "{name} | {name}: {render(description)}",
|
| 125 |
+
"score_block": "0\n1\n2\n3\n4\n5",
|
| 126 |
+
"render": "None->'', scalars->Python str(), list->'- item' lines, dict->'key: value' lines, 2-space nesting",
|
| 127 |
+
"add_special_tokens": false
|
| 128 |
+
},
|
| 129 |
+
"option_logits": {
|
| 130 |
+
"noul": "scores[row, [1, 0]] (false = F, true = T)",
|
| 131 |
+
"choice": "scores[row, 2 + j] for option j < 16",
|
| 132 |
+
"score": "scores[row, 18 + level] for level < 6"
|
| 133 |
+
},
|
| 134 |
+
"opset": 20,
|
| 135 |
+
"precision": "fp32 compute; base weights and head BF16, widened by Cast (at load, or per forward pass with weights_in_memory bf16); adapter F32",
|
| 136 |
+
"weights_in_memory": "bf16"
|
| 137 |
+
}
|
4b/model-fp32.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c3b48e33801f9fb97d4b14a716c473ff8dc4d974cdcb5bc1866ae44f6d57a74d
|
| 3 |
+
size 11370721
|
README.md
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: other
|
| 3 |
+
license_name: apache-2.0-and-gemma
|
| 4 |
+
license_link: https://ai.google.dev/gemma/terms
|
| 5 |
+
base_model:
|
| 6 |
+
- hiteshluke/arbiter-4b
|
| 7 |
+
- unsloth/gemma-3-4b-it
|
| 8 |
+
library_name: onnx
|
| 9 |
+
tags:
|
| 10 |
+
- ollaya
|
| 11 |
+
- onnx
|
| 12 |
+
- decision-model
|
| 13 |
+
- system-one
|
| 14 |
+
pipeline_tag: text-classification
|
| 15 |
+
---
|
| 16 |
+
|
| 17 |
+
# arbiter for Ollaya
|
| 18 |
+
|
| 19 |
+
[Ollaya](https://github.com/ollaya-dev/ollaya) package of **[hiteshluke/arbiter-4b](https://huggingface.co/hiteshluke/arbiter-4b)** and **[unsloth/gemma-3-4b-it](https://huggingface.co/unsloth/gemma-3-4b-it)** by Codekins Pvt Ltd · Zyot Lab.
|
| 20 |
+
Ollaya runs open decision models locally, the way Ollama runs LLMs: typed questions in,
|
| 21 |
+
calibrated answers out, behind a TypeSafe-compatible API.
|
| 22 |
+
|
| 23 |
+
```sh
|
| 24 |
+
ollaya run arbiter
|
| 25 |
+
```
|
| 26 |
+
|
| 27 |
+
## What is in this repository
|
| 28 |
+
|
| 29 |
+
This repository holds only the files Ollaya derives, with no weights. Each graph is an ONNX export of the
|
| 30 |
+
original model whose weights **reference the authors' own weight files by byte offset**,
|
| 31 |
+
so `ollaya pull` downloads the weights from the upstream repositories, unmodified and pinned to a
|
| 32 |
+
commit, and verifies their sha256.
|
| 33 |
+
|
| 34 |
+
| Tag | Upstream | Files |
|
| 35 |
+
|---|---|---|
|
| 36 |
+
| `arbiter:4b` | [hiteshluke/arbiter-4b@0c44271](https://huggingface.co/hiteshluke/arbiter-4b/tree/0c44271c59f89758e3cae17b032e98a9140093e9), [unsloth/gemma-3-4b-it@bf46152](https://huggingface.co/unsloth/gemma-3-4b-it/tree/bf46152c47f5dd20b896357cb51abc4c03b8ee8c) | `4b/model-fp32.onnx`, `4b/decision.json`, `4b/calibration.json` |
|
| 37 |
+
|
| 38 |
+
Each tag has an fp32 graph, used on CPU and GPU. Each tag also has `decision.json` (sequence layout, special tokens) and
|
| 39 |
+
`calibration.json` (temperatures).
|
| 40 |
+
|
| 41 |
+
## Parity
|
| 42 |
+
|
| 43 |
+
Ollaya's Rust runtime matches the reference (transformers' Gemma 3 with the authors' LoRA and head, fp32, the training script's prompts) on 420 questions from 127 requests, on CPU and CUDA (RTX 4090): identical token rows, the same 121 rejected requests, the same decision on every question, slot scores within 8.5e-5 and probabilities within 1.0e-5.
|
| 44 |
+
|
| 45 |
+
## License
|
| 46 |
+
|
| 47 |
+
Same as the upstream model (Apache-2.0 (LoRA adapter and head) and the Gemma Terms of Use (Gemma 3 base model)). Ollaya itself is Apache-2.0.
|