radiance 1.7.0

- every model serves without a GPU: libavx covers every op, so `--kernels libavx` alone serves
  every shipped container
- Qwen3-ASR (zivius): speech to text on /v1/audio/transcriptions and live over /v1/realtime
- /v1/messages works with Claude Code as it ships (gearwave00001)
- a long agent conversation keeps its cached history when the client rewrites its last turn
  (manueloverride)
- a stream's first event goes out with the first token, so llama-benchy measures prefill right
- opt-in --prefill-interleave (Smellyyyy, baKon) and --prefill-span (keptn42)
- four-rank TP releases the link early; four-rank selftests and docs/TP4.md (goodman-b)
- NVFP4 and FP8 compressed-tensors imports (devmilan); tools/rad-export for finetunes and LoRA
  adapters (baKon)
- many fixes, among them lost tokens on stop strings under concurrency, keep-alive, MiniCPM5 tool
  arguments and the CPU's vision and audio encoders
- plugin ABI 17 and changed op schemas: out-of-tree plugins must be rebuilt
This commit is contained in:
Deadcode committed 2026-10-16 18:25:18 +02:00
1 parent b068190326
commit 1e968f6e1d
739 files changed
+128447 -84632

No files matched your search

+22 -40
View File
@@ -1,29 +1,20 @@
# Architecture plugins. One directory each, one .so each, linking only rad_abi -- an architecture
# plugin does not link the core.
# Architecture plugins: one directory and one .so each, linking only rad_abi, never the core.
#
# qwen35 covers the Qwen3.5, Qwen3.6 and Qwen3.8 dense models, which all report that id, and
# qwen35moe is the same graph with a routed FFN. See docs/ARCHITECTURES.md for the geometry.
# One plugin per (architecture, quantisation) -- spec §2.4, and the pair is the selection key, so
# qwen35_bf16 and qwen35_fp8 both claim "qwen35" and are told apart by the container's quantisation
# descriptor. See rad_arch_quant in abi/rad_builder.h.
# qwen35 covers the Qwen3.5, Qwen3.6 and Qwen3.8 dense models, which all report that id; qwen35moe
# is the same graph with a routed FFN (docs/ARCHITECTURES.md). There is one plugin per
# (architecture, quantisation) pair, which is the selection key (spec §2.4): qwen35_bf16 and
# qwen35_fp8 both claim "qwen35" and are told apart by the container's quantisation descriptor
# (rad_arch_quant in abi/rad_builder.h).
#
# The plugins are discovered, not listed. A hand-written list can name a plugin that has no
# directory, and a name in a build file that resolves to nothing is worse than no name: it is a
# plugin an operator will look for and not find, with no error anywhere to say it was never built.
# With discovery, what is in the tree is what is built, and what is not in the tree does not appear
# in a list.
#
# Globbed the way libref/CMakeLists.txt globs its translation units, and SORTED, because
# file(GLOB) returns directory order and an unsorted list makes the link order -- and therefore the
# plugin load order, which is the hierarchy that decides which architecture wins a tie -- depend on
# the filesystem.
# Plugins are discovered, not listed, so the build is exactly what is in the tree. The glob is
# sorted because file(GLOB) returns directory order, and the link order sets the plugin load order,
# which decides which architecture wins a tie.
file(GLOB RAD_ARCH_DIRS CONFIGURE_DEPENDS LIST_DIRECTORIES true ${CMAKE_CURRENT_SOURCE_DIR}/*)
list(SORT RAD_ARCH_DIRS)
# THE INCLUDE SPELLING IS THE INSTALLED ONE. arch/common/ installs as <include>/radiance/arch/, so a
# plugin built against an installed radiance writes `#include <arch/rad_arch.h>`; the plugins in
# this tree write the same, through a directory in the build tree whose arch/ is this common/.
# A plugin here that could only be built here would not be a plugin like any other.
# In-tree plugins use the installed include spelling. arch/common/ installs as
# <include>/radiance/arch/, so plugins write `#include <arch/rad_arch.h>`; in this tree that
# resolves through a build-tree directory whose arch/ links to common/.
set(RAD_ARCH_INCLUDE_ROOT ${CMAKE_BINARY_DIR}/rad_include)
file(MAKE_DIRECTORY ${RAD_ARCH_INCLUDE_ROOT})
if(NOT EXISTS ${RAD_ARCH_INCLUDE_ROOT}/arch)
@@ -36,37 +27,28 @@ foreach(d ${RAD_ARCH_DIRS})
continue()
endif()
get_filename_component(a ${d} NAME)
# common/ is the shared header library every plugin includes, not a plugin. It is excluded by
# name, and that is the only directory with special treatment.
# common/ is the shared header library, not a plugin.
if(a STREQUAL "common")
continue()
endif()
if(EXISTS ${d}/CMakeLists.txt)
# Every plugin carries its own build rules, the ones it would be built with out of this tree.
# Each plugin's own build rules, the same ones it uses out of tree.
add_subdirectory(${a})
else()
# Named rather than skipped in silence. A directory under arch/ with no CMakeLists.txt is
# either a plugin missing its build file or a directory that does not belong here, and both of
# those are things somebody wants to be told about at configure time rather than discovering
# from an architecture the engine cannot find.
# Reported at configure time rather than skipped silently: either a plugin is missing its build
# file or the directory does not belong here.
message(STATUS
"arch: '${a}' has no CMakeLists.txt -- not an architecture plugin, skipped")
endif()
endforeach()
# arch/common/ ships. abi/rad_builder.h tells a plugin author, in the ABI header itself, to use the
# grp_layer()/grp_expert()/grp_model() inline functions in arch/common/rad_arch.h rather than the
# rad_group_*() macros beneath that note, because those macros are C compound literals and C++
# accepts them only as a GNU extension -- and an architecture plugin in C++ is the norm. Without
# this install the shipped header would point at a file that is not shipped, and the one documented
# way to write a conforming plugin would be available only inside this tree.
# arch/common/ ships: abi/rad_builder.h directs C++ plugin authors to the grp_*() helpers in
# arch/common/rad_arch.h instead of the rad_group_*() compound-literal macros (a GNU extension in
# C++).
#
# Installed FLAT into arch/, which is what makes it work without touching a single #include:
# these headers include each other by bare basename ("rad_arch.h", "rad_fp8.h"), which resolves
# relative to the including file in both trees, and rad_arch.h's own "rad_builder.h" resolves
# against the include root that radiance::abi puts on the path. Every plugin, in this tree or out of
# it, writes `#include <arch/rad_arch.h>` -- see RAD_ARCH_INCLUDE_ROOT above for how that resolves
# here.
# Installed flat into arch/. These headers include each other by bare basename, which resolves
# relative to the including file in both trees, and rad_arch.h's "rad_builder.h" resolves against
# the include root that radiance::abi provides.
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/common/
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/radiance/arch
FILES_MATCHING PATTERN "*.h")