Archived
radiance 2.0.0
Radiance becomes a multi-model engine: one process serves several models behind one port, loads each when a request names it, parks it in host memory or restores it from its container, and shares the cards between them (docs/MULTIMODEL.md). The configuration is one YAML file; the command line flags are gone (`radiance --config FILE`, hot reload on SIGHUP). Formats. IQ8R (rotated int8) and IQR-V4 replace FP8 and MXFP4 as whole-model formats, with an int8 KV cache (`kv-cache-dtype: i8`) in place of the fp8 one. Containers whose weights are block FP8, MXFP4, M2XFP4, NVFP4 or ParoQuant are refused at startup by the name of the first such weight. Not served until they have int8 containers: GLM-5.3-Flash, Ornith-1.5, Sage-A1.5, Nemotron-3.5-Bolt-74B, Ling-3.0-flash, drama-3 and Anima's FP8 container; Nemotron-3.5-Bolt-E4B, the Gemma 4 31B DFlash containers and MiniCPM5-2B bf16 serve without their drafter. 1.17.0 serves all of them. Speed. Chained launches for Qwen3.8-27B, Gemma 4, Gemma 3 and the small bf16 models, a new Qwen3.8-Flash-Next container (IQR-V4 experts, int8 trunk) with its decode step and prefill reworked, and a reworked adaptive draft window. Deployment. deploy/compose has two fleet files, tp1.yaml and tp2.yaml, each with its configuration beside it, in place of the per-model files. `host-pool-mib` is a model's host pool in all, split among its ranks. The dashboard is rebuilt: an hour of history kept by the server, each accelerator's memory by model, model states over time. Merged since 1.17.0: Nemotron-3.5-Bolt-74B-A9B by keptn42 (#339); GLM-5.3-Flash on four cards by AnimusNull (#397); chained launches for Flash-Next's decode step (#396) and preempted requests keeping their prefix and place (#405) by mici81; --prefill-interleave auto by Code000 (#410); eight more libr3d kernels and the w4a4 reference by RikshaDriver (#403, #407, #408); libr3d large-BAR and E4M3 decode fixes by neuromanMD (#438, #439); int4/int5 decode tiles by Kezi (#426); attention for Nanbeige 4.3 33B by everplays (#417); expert_stats_report.py by baKon (#431). Fixed: #398, #402, #419, #437 (dschmitz's patch); added the metrics of #392, and multi-model serving as asked for in #367 and #109. Plugin ABI 39: out-of-tree plugins need to be rebuilt. Thanks to @keptn42, @AnimusNull, @mici81, @Code000, @RikshaDriver, @neuromanMD, @Kezi, @everplays, @baKon and @dschmitz.
This commit is contained in:
1 parent
b4c04b6042
commit
ddcb9c69bb
696 files changed
+120770
-56596
No files matched your search
+33
-19
@@ -1,6 +1,6 @@
|
||||
# Static YaRN
|
||||
|
||||
A larger `--max-model-len` reserves a larger serving window; it does not change the model's rotary
|
||||
A larger `max-model-len` reserves a larger serving window; it does not change the model's rotary
|
||||
embedding. A checkpoint trained at 262144 positions can request static YaRN explicitly for a
|
||||
524288-token deployment. Whether the extension keeps useful accuracy must be measured on the model
|
||||
and workload.
|
||||
@@ -17,7 +17,7 @@ The factor convention is the config's, as vLLM and transformers read it: `factor
|
||||
`original_max_position_embeddings` 262144 reaches 524288 positions.
|
||||
|
||||
Validated: the Qwen3.8-27B and Qwen3.6-35B-A3B containers and both Flash-Next variants at factor 2,
|
||||
with retrieval at about 500K tokens, and TP3 perplexity with `--rope-scaling` within about ±1% of
|
||||
with retrieval at about 500K tokens, and TP3 perplexity with `rope-scaling` within about ±1% of
|
||||
the unscaled model at factor 2. The LLaMA plugins read the same keys and declare the same ops, but
|
||||
YaRN has not been run on a LLaMA model.
|
||||
|
||||
@@ -44,10 +44,11 @@ is valid only for the same source weights and recipe; it cannot mix weights from
|
||||
revisions.
|
||||
|
||||
```sh
|
||||
rad-convert /checkpoints/Qwen3.8-27B-FP8 \
|
||||
rad-convert /checkpoints/Qwen3.8-27B \
|
||||
--draft-model /checkpoints/Qwen3.8-27B-DFlash2 \
|
||||
--recipe data/recipes/q38-27b-fp8-df2.recipe \
|
||||
--reuse /models/qwen3.8-27b-fp8.rad \
|
||||
--recipe data/recipes/q38-27b-iq8r-rtn.recipe \
|
||||
--set quantization_config.quant_method=w8a8 --set quantization_config.fmt=fwht128 \
|
||||
--reuse /models/qwen3.8-27b-iq8r.rad \
|
||||
--set text_config.rope_parameters.rope_type=yarn \
|
||||
--set text_config.rope_parameters.factor=2 \
|
||||
--set text_config.rope_parameters.original_max_position_embeddings=262144 \
|
||||
@@ -55,32 +56,45 @@ rad-convert /checkpoints/Qwen3.8-27B-FP8 \
|
||||
--set draft.rope_parameters.factor=2 \
|
||||
--set draft.rope_parameters.original_max_position_embeddings=262144 \
|
||||
--max-ctx 524288 --kv-cache-dtype bf16 \
|
||||
-o /models/qwen3.8-27b-fp8-yarn2.rad
|
||||
-o /models/qwen3.8-27b-iq8r-yarn2.rad
|
||||
```
|
||||
|
||||
Run it with `--plan-only` first. `--max-ctx` is the converter's graph bound; it replaces neither
|
||||
the YaRN metadata nor the server's `--max-model-len`. A `.rad` is not a converter input, so keep
|
||||
the YaRN metadata nor the server's `max-model-len`. A `.rad` is not a converter input, so keep
|
||||
the source checkpoints. After conversion, check the target and draft keys with `rad-info --meta`.
|
||||
|
||||
Serve on enough memory for the requested window:
|
||||
|
||||
```sh
|
||||
radiance --model /models/qwen3.8-27b-fp8-yarn2.rad \
|
||||
--tp 4 --max-model-len 524288 --max-num-seqs 32 --kv-cache-dtype bf16
|
||||
```yaml
|
||||
# radiance.yaml
|
||||
models:
|
||||
qwen3.8-27b-iq8r-yarn2:
|
||||
model: /models/qwen3.8-27b-iq8r-yarn2.rad
|
||||
tp: 4
|
||||
max-model-len: 524288
|
||||
max-num-seqs: 32
|
||||
kv-cache-dtype: bf16
|
||||
```
|
||||
|
||||
`--kv-cache-dtype` sets both the target's and the drafter's KV cache. Check the startup capacity
|
||||
and real long requests; the command guarantees neither concurrency nor accuracy. Keep the
|
||||
```sh
|
||||
radiance --config radiance.yaml
|
||||
```
|
||||
|
||||
`kv-cache-dtype` sets both the target's and the drafter's KV cache. Check the startup capacity
|
||||
and real long requests; the configuration guarantees neither concurrency nor accuracy. Keep the
|
||||
unmodified model and serving setup until long-context quality and speed meet the deployment's
|
||||
requirements.
|
||||
|
||||
## Serving an existing container: `--rope-scaling`
|
||||
## Serving an existing container: `rope-scaling`
|
||||
|
||||
The same metadata can be applied when the container is loaded instead of at conversion:
|
||||
|
||||
```sh
|
||||
radiance --model /models/qwen3.8-next-flash-fp8.rad \
|
||||
--rope-scaling yarn:2 --max-model-len 409600
|
||||
```yaml
|
||||
models:
|
||||
qwen3.8-next-flash:
|
||||
model: /models/qwen3.8-next-flash-iqr-v4.rad
|
||||
rope-scaling: yarn:2
|
||||
max-model-len: 409600
|
||||
```
|
||||
|
||||
`yarn:FACTOR[:ORIG]` (FACTOR above 1) sets `rope_type = yarn`, `factor` and
|
||||
@@ -101,11 +115,11 @@ Startup logs the rotary:
|
||||
rope: YaRN factor 2 over 262144 trained positions -- the rotary reaches 524288; --max-model-len 409600 (--rope-scaling)
|
||||
```
|
||||
|
||||
It warns when `--max-model-len` is past what the rotary covers, and, with no scaling, past the
|
||||
It warns when `max-model-len` is past what the rotary covers, and, with no scaling, past the
|
||||
trained length.
|
||||
|
||||
Use the flag to try a factor, or to serve a container whose source checkpoints are not at hand. A
|
||||
deployment that settles on a factor can convert it in as above and drop the flag.
|
||||
Use the key to try a factor, or to serve a container whose source checkpoints are not at hand. A
|
||||
deployment that settles on a factor can convert it in as above and drop the key.
|
||||
|
||||
## Kernel and test contract
|
||||
|
||||
|
||||
Reference in new issue
Block a user