Verdict-ready von package (onnx, independent_options)
Browse files- .gitattributes +1 -0
- .ms_upload_cache +1 -0
- README.md +70 -0
- SHA256SUMS +6 -0
- model.json +21 -0
- tokenizer/tokenizer.json +0 -0
- tokenizer/tokenizer_config.json +24 -0
- von.onnx +3 -0
- von.onnx.data +3 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
von.onnx.data filter=lfs diff=lfs merge=lfs -text
|
.ms_upload_cache
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"version": 3, "repo_id": "sgyaqing/von", "files": {"von.onnx|1791768534.0|2958691": {"hash": "daa80b0720198922f89eae98a3f41a8e16777b80580a29ea75c79d99718ef289", "size": 2958691, "status": "c"}, "tokenizer/tokenizer.json|1792031265.0|3583486": {"hash": "bb637767e8dfb8044597df6c58243bff2e592ae9e3b310c0bbdb8591f6ac543d", "size": 3583486, "status": "c"}, "von.onnx.data|1791768534.0|1581240320": {"hash": "d5b804c5ceb8f096daf516cccf0fce7a77028b25ec3031ba9cff09a3a663e121", "size": 1581240320, "status": "c"}, "SHA256SUMS|1792069764.0|497": {"hash": "e32411e9daba590a3ae99f1ccda97c3ddb6f0d5680d3ab9afb4d60be9a015fe5", "size": 497, "status": "c"}, "README.md|1792069656.0|3258": {"hash": "617d6ebc7e045fc51fb61721f334cfb2a07339d2538a0e2a4b83459bfbbaee88", "size": 3258, "status": "c"}, "model.json|1792055637.0|464": {"hash": "1d0beb3f1d96a63a8a12a7904bf51ac99bd926838821657b60bb3b99e90d53d2", "size": 464, "status": "c"}, "tokenizer/tokenizer_config.json|1792031265.0|571": {"hash": "4d2a485d5fd1ee514db180744fc00807c11da34012ac3666744c0377f6c23731", "size": 571, "status": "c"}}}
|
README.md
ADDED
|
@@ -0,0 +1,70 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
base_model: wfzyx/von
|
| 4 |
+
pipeline_tag: zero-shot-classification
|
| 5 |
+
tags:
|
| 6 |
+
- verdict
|
| 7 |
+
- onnx
|
| 8 |
+
- system-one
|
| 9 |
+
- decision-models
|
| 10 |
+
- von
|
| 11 |
+
- serving
|
| 12 |
+
---
|
| 13 |
+
|
| 14 |
+
# Von (Verdict-ready)
|
| 15 |
+
|
| 16 |
+
The [Von](https://huggingface.co/wfzyx/von) System One decision model (ModernBERT-large, 395M, English, 8192-token context), exported to ONNX fp32 and packaged for [Verdict](https://github.com/sgyaqing/verdict) -- a high-performance serving engine for System One decision models. Serve it with one command:
|
| 17 |
+
|
| 18 |
+
Pick the image that matches the host. The `-v` mounts cache the model, so only the first
|
| 19 |
+
run downloads it.
|
| 20 |
+
|
| 21 |
+
```bash
|
| 22 |
+
# CPU host
|
| 23 |
+
docker run --rm -p 8080:8080 \
|
| 24 |
+
-v ~/.cache/huggingface:/root/.cache/huggingface \
|
| 25 |
+
-v ~/.cache/verdict:/root/.cache/verdict \
|
| 26 |
+
sgyaqing/verdict:0.2.0-cpu serve verdict-models/von
|
| 27 |
+
|
| 28 |
+
# GPU host
|
| 29 |
+
docker run --rm --gpus all -p 8080:8080 \
|
| 30 |
+
-v ~/.cache/huggingface:/root/.cache/huggingface \
|
| 31 |
+
-v ~/.cache/verdict:/root/.cache/verdict \
|
| 32 |
+
sgyaqing/verdict:0.2.0-cuda serve verdict-models/von
|
| 33 |
+
```
|
| 34 |
+
|
| 35 |
+
Add `-e VERDICT_USE_MODELSCOPE=1` and use `sgyaqing/von` to fetch from ModelScope instead of the
|
| 36 |
+
hub; add `-e HF_ENDPOINT=https://hf-mirror.com` if the hub is slow or unreachable.
|
| 37 |
+
|
| 38 |
+
Endpoints: the standard decision protocols `POST /v1/systemone` and `POST /v1/decisions`, native `POST /v1/choice | /v1/score | /v1/noul`, plus an OpenAI-compatible layer (`/v1/chat/completions`, `/v1/models`).
|
| 39 |
+
|
| 40 |
+
## Performance
|
| 41 |
+
|
| 42 |
+
Measured on one machine (RTX 4090, AMD EPYC 7543, 16 threads), end to end over HTTP with
|
| 43 |
+
[`oha`](https://github.com/hatoo/oha) and an identical request body for both servers. The
|
| 44 |
+
baseline is the model author's own server (`von serve`, von-sdk, `--no-chains`); the Verdict
|
| 45 |
+
column is this package. Latencies are per-request P50 / P99 at the stated concurrency. The
|
| 46 |
+
ratios are oriented so that **above 1× means Verdict is ahead** in both: throughput ratio =
|
| 47 |
+
Verdict ÷ baseline, latency ratio = baseline ÷ Verdict.
|
| 48 |
+
|
| 49 |
+
| concurrency | Verdict rps | Verdict P50 / P99 | `von` rps | `von` P50 / P99 | ratio rps | ratio P50 / P99 |
|
| 50 |
+
|---|---:|---:|---:|---:|---:|---:|
|
| 51 |
+
| 1 | 113.8 | 8.61 / 11.98 ms | 46.4 | 22.89 / 28.46 ms | 2.45× | 2.66 / 2.38× |
|
| 52 |
+
| 8 | 536.4 | 14.86 / 16.61 ms | 31.2 | 250.91 / 435.99 ms | 17.2× | 16.9 / 26.2× |
|
| 53 |
+
| 64 | 1476.1 | 42.58 / 53.24 ms | 22.3 | 2848.80 / 3333.40 ms | 66.1× | 66.9 / 62.6× |
|
| 54 |
+
|
| 55 |
+
## Files
|
| 56 |
+
|
| 57 |
+
| File | Purpose |
|
| 58 |
+
|---|---|
|
| 59 |
+
| `model.json` | manifest: graph file name, budgets, family recipe (`independent_options`), calibration map |
|
| 60 |
+
| `von.onnx` + `von.onnx.data` | the ONNX graph (fp32, external weights) |
|
| 61 |
+
| `tokenizer/tokenizer.json` (+ `tokenizer_config.json`) | the tokenizer |
|
| 62 |
+
| `SHA256SUMS` | checksums for every file above |
|
| 63 |
+
|
| 64 |
+
## Provenance & fidelity
|
| 65 |
+
|
| 66 |
+
Weights are unchanged from `wfzyx/von`; this repo adds only the ONNX export and the serving manifest. Conversion and serving are verified against the official model (von-sdk 1.3.7): identical answers on CPU (29-case golden corpus, logit parity ≤ 4.6e-5) and on CUDA (RTX 4090, logit parity ≤ 7.4e-5, batch invariance bitwise).
|
| 67 |
+
|
| 68 |
+
## License
|
| 69 |
+
|
| 70 |
+
Apache-2.0, inherited from the base model. Credit for the model itself belongs to the [original author](https://huggingface.co/wfzyx); this repository only repackages it for serving.
|
SHA256SUMS
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
617d6ebc7e045fc51fb61721f334cfb2a07339d2538a0e2a4b83459bfbbaee88 README.md
|
| 2 |
+
1d0beb3f1d96a63a8a12a7904bf51ac99bd926838821657b60bb3b99e90d53d2 model.json
|
| 3 |
+
daa80b0720198922f89eae98a3f41a8e16777b80580a29ea75c79d99718ef289 von.onnx
|
| 4 |
+
d5b804c5ceb8f096daf516cccf0fce7a77028b25ec3031ba9cff09a3a663e121 von.onnx.data
|
| 5 |
+
bb637767e8dfb8044597df6c58243bff2e592ae9e3b310c0bbdb8591f6ac543d tokenizer/tokenizer.json
|
| 6 |
+
4d2a485d5fd1ee514db180744fc00807c11da34012ac3666744c0377f6c23731 tokenizer/tokenizer_config.json
|
model.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"family": "independent_options",
|
| 3 |
+
"runtime": "ort",
|
| 4 |
+
"graph": "von.onnx",
|
| 5 |
+
"max_len": 8192,
|
| 6 |
+
"cls_token": "[CLS]",
|
| 7 |
+
"sep_token": "[SEP]",
|
| 8 |
+
"mask_token": "[MASK]",
|
| 9 |
+
"pad_token": "[PAD]",
|
| 10 |
+
"sliding_window": 64,
|
| 11 |
+
"calibration_formula": {
|
| 12 |
+
"bias": 2.0151,
|
| 13 |
+
"entropy": -3.2369,
|
| 14 |
+
"log_tokens": 11.4916,
|
| 15 |
+
"n_options": -3.5574,
|
| 16 |
+
"lo": 0.3,
|
| 17 |
+
"hi": 12.0
|
| 18 |
+
},
|
| 19 |
+
"noul_band": {"edge": 0.8, "slope": 0.1},
|
| 20 |
+
"noul_prior": {"a": -0.5, "b": 0.3}
|
| 21 |
+
}
|
tokenizer/tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer/tokenizer_config.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"backend": "tokenizers",
|
| 3 |
+
"clean_up_tokenization_spaces": true,
|
| 4 |
+
"cls_token": "[CLS]",
|
| 5 |
+
"is_local": true,
|
| 6 |
+
"local_files_only": false,
|
| 7 |
+
"mask_token": "[MASK]",
|
| 8 |
+
"max_length": 2048,
|
| 9 |
+
"model_input_names": [
|
| 10 |
+
"input_ids",
|
| 11 |
+
"attention_mask"
|
| 12 |
+
],
|
| 13 |
+
"model_max_length": 8192,
|
| 14 |
+
"pad_to_multiple_of": null,
|
| 15 |
+
"pad_token": "[PAD]",
|
| 16 |
+
"pad_token_type_id": 0,
|
| 17 |
+
"padding_side": "right",
|
| 18 |
+
"sep_token": "[SEP]",
|
| 19 |
+
"stride": 0,
|
| 20 |
+
"tokenizer_class": "TokenizersBackend",
|
| 21 |
+
"truncation_side": "right",
|
| 22 |
+
"truncation_strategy": "longest_first",
|
| 23 |
+
"unk_token": "[UNK]"
|
| 24 |
+
}
|
von.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:daa80b0720198922f89eae98a3f41a8e16777b80580a29ea75c79d99718ef289
|
| 3 |
+
size 2958691
|
von.onnx.data
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d5b804c5ceb8f096daf516cccf0fce7a77028b25ec3031ba9cff09a3a663e121
|
| 3 |
+
size 1581240320
|