Instructions to use odecide-models/laya with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Laya
How to use odecide-models/laya with Laya:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -15,9 +15,6 @@ tags:
|
|
| 15 |
|
| 16 |
The [Laya](https://huggingface.co/convaiinnovations/laya) System One decision model, 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 \
|
|
@@ -28,27 +25,25 @@ docker run --rm -p 8080:8080 \
|
|
| 28 |
docker run --rm --gpus all -p 8080:8080 \
|
| 29 |
-v ~/.cache/verdict:/root/.cache/verdict \
|
| 30 |
sgyaqing/verdict:0.2.0-cuda serve verdict-models/laya --host 0.0.0.0
|
| 31 |
-
```
|
| 32 |
|
| 33 |
-
|
| 34 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 35 |
|
| 36 |
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`).
|
| 37 |
|
| 38 |
## Performance
|
| 39 |
|
| 40 |
-
Measured on one machine (RTX 4090, AMD EPYC 7543
|
| 41 |
-
[`oha`](https://github.com/hatoo/oha) and an identical request body for both servers. The
|
| 42 |
-
baseline is the model author's own server (`laya-serve`, `LAYA_MODELS=english`); the Verdict
|
| 43 |
-
column is this package. Latencies are per-request P50 / P99 at the stated concurrency. The
|
| 44 |
-
ratios are oriented so that **above 1× means Verdict is ahead** in both: throughput ratio =
|
| 45 |
-
Verdict ÷ baseline, latency ratio = baseline ÷ Verdict.
|
| 46 |
|
| 47 |
-
| concurrency | Verdict rps | Verdict P50 / P99 | `laya-serve` rps | `laya-serve` P50 / P99 |
|
| 48 |
-
|---|---:|---:|---:|---:|
|
| 49 |
-
| 1 | 121.4 | 8.37 / 11.07 ms | 34.4 | 28.58 / 32.73 ms |
|
| 50 |
-
| 8 | 501.4 | 15.99 / 22.42 ms | 35.4 | 227.96 / 250.60 ms |
|
| 51 |
-
| 64 | 1353.0 | 46.71 / 65.19 ms | refused requests | — |
|
| 52 |
|
| 53 |
## Files
|
| 54 |
|
|
|
|
| 15 |
|
| 16 |
The [Laya](https://huggingface.co/convaiinnovations/laya) System One decision model, 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 |
```bash
|
| 19 |
# CPU host
|
| 20 |
docker run --rm -p 8080:8080 \
|
|
|
|
| 25 |
docker run --rm --gpus all -p 8080:8080 \
|
| 26 |
-v ~/.cache/verdict:/root/.cache/verdict \
|
| 27 |
sgyaqing/verdict:0.2.0-cuda serve verdict-models/laya --host 0.0.0.0
|
|
|
|
| 28 |
|
| 29 |
+
# ModelScope:
|
| 30 |
+
docker run --rm -p 8080:8080 \
|
| 31 |
+
-e VERDICT_USE_MODELSCOPE=1 \
|
| 32 |
+
-v ~/.cache/verdict:/root/.cache/verdict \
|
| 33 |
+
sgyaqing/verdict:0.2.0-cpu serve sgyaqing/laya --host 0.0.0.0
|
| 34 |
+
```
|
| 35 |
|
| 36 |
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`).
|
| 37 |
|
| 38 |
## Performance
|
| 39 |
|
| 40 |
+
Measured on one machine (RTX 4090, AMD EPYC 7543), end to end over HTTP, against the model author's own server (`laya-serve`):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 41 |
|
| 42 |
+
| concurrency | Verdict rps | Verdict P50 / P99 | `laya-serve` rps | `laya-serve` P50 / P99 |
|
| 43 |
+
|---|---:|---:|---:|---:|
|
| 44 |
+
| 1 | 121.4 | 8.37 / 11.07 ms | 34.4 | 28.58 / 32.73 ms |
|
| 45 |
+
| 8 | 501.4 | 15.99 / 22.42 ms | 35.4 | 227.96 / 250.60 ms |
|
| 46 |
+
| 64 | 1353.0 | 46.71 / 65.19 ms | refused requests | — |
|
| 47 |
|
| 48 |
## Files
|
| 49 |
|