Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
108 commits
Select commit Hold shift + click to select a range
3e063bd
dasLLAMA: the bench env receipt names registered knobs alone
borisbat Dec 1, 2026
c7949b2
dasLLAMA: no CPU pass for a skipped round; the whole-ctx note on a MoE
borisbat Dec 1, 2026
10c2b9b
dasLLAMA: load_model_image maps with the asked home's tag by default
borisbat Dec 1, 2026
2d59967
dasLLAMA: CPU encoder scratch is sized for a CPU image alone
borisbat Dec 1, 2026
ab9b1a6
dasLLAMA tests: a verb cell skips without its exe; one skip summary
borisbat Dec 1, 2026
fe7c4bc
dasLLAMA docs: stale texts state the code as it is
borisbat Dec 1, 2026
255f16b
dasLLAMA: Metal vision chains decline another home's image at any quant
borisbat Dec 1, 2026
7ca1da9
dasLLAMA: an audio tower's exact pin never probes the q8 lane
borisbat Dec 1, 2026
a5c58f6
dasLLAMA: the drafter bind counts no codec pass; pass texts say fail
borisbat Dec 1, 2026
25ee464
dasLLAMA docs: a passed call fails by name; dead CPU-rail texts go
borisbat Dec 1, 2026
987856b
dasLLAMA: GigaAM's lane pin is read before its exact-lane probe
borisbat Dec 1, 2026
e2844ae
dasLLAMA tests: cells that expected a CPU serve assert the failure
borisbat Dec 1, 2026
29c8ff4
dasLLAMA docs: tutorial 13's pass counter lists calls not served
borisbat Dec 1, 2026
1869047
dasLLAMA: one audio lane read; the knob says once that it decides
borisbat Dec 1, 2026
486882c
dasLLAMA: no GPU tag is asked inside the CPU-home scope
borisbat Dec 1, 2026
742238b
dasLLAMA: the Metal vision chains open on tw_seat_gate; shared cells
borisbat Dec 1, 2026
0659ecf
dasLLAMA tests: failures by name pin each pass's words and count
borisbat Dec 1, 2026
928734a
dasLLAMA tests: a real child log's skips counted; argv files parsed
borisbat Dec 1, 2026
a43a52e
dasLLAMA: segment prefill walks by index; a failure leaves no lock
borisbat Dec 1, 2026
c5b72f5
dasLLAMA: a plan the card cannot hold names its reason at the load
borisbat Dec 1, 2026
d508c1e
dasLLAMA: load_model_cached reads the asked tag; CPU home has Metal off
borisbat Dec 1, 2026
078b93f
dasLLAMA tests: the role fixtures take dastest's compile_issues
borisbat Dec 1, 2026
ae6ccaa
dasLLAMA tests: a run missing a model file or fixture ends INCOMPLETE
borisbat Dec 1, 2026
9f96d62
dasLLAMA: create_scheduler refuses streams past the device regions
borisbat Dec 1, 2026
bf42639
dasLLAMA: a busy region pass fails with its own reason
borisbat Dec 1, 2026
51d3541
dasLLAMA tests: CPU-rail cells ask the CPU home for their loads
borisbat Dec 1, 2026
4c3798c
dasLLAMA tests: device cells take mirror sessions and a CPU-home twin
borisbat Dec 1, 2026
a0a3e7a
dasLLAMA tests: the GLM invariance cell keeps its plain load
borisbat Dec 1, 2026
14d338e
dasllama-server: the download rail moves to utils/common to be shared
borisbat Dec 1, 2026
7d8771a
dasLLAMA tests: run.das --list-missing names what a run opens and lacks
borisbat Dec 1, 2026
baa2528
dasLLAMA: fetch_models --run fetches what a test run names
borisbat Dec 1, 2026
8cfb0e6
dasLLAMA: the pod fleet fetches a run's models onto the volume first
borisbat Dec 1, 2026
0ac4cda
dasLLAMA docs: how a box gets the models a run names
borisbat Dec 1, 2026
54d390c
dasLLAMA tests: INCOMPLETE reads the fetch plan's gate and kinds
borisbat Dec 1, 2026
92ff029
dasLLAMA: a pod skips flash-next and glm45-air unless asked by name
borisbat Dec 1, 2026
c150ed6
dasLLAMA docs: INCOMPLETE by kind, the no-such- marker, pod categories
borisbat Dec 1, 2026
c3e542c
dasLLAMA tests: a run reads each source and stats each model path once
borisbat Dec 1, 2026
f18a819
dasLLAMA: pins for uploaded carriers, projectors and test vocabularies
borisbat Dec 1, 2026
61a37d8
dasLLAMA docs: one read a source a run, test fixtures in the plan
borisbat Dec 1, 2026
54301a9
dasLLAMA: a fleet run never starts into a disk its copies would fill
borisbat Dec 1, 2026
73bdcd9
dasLLAMA tests: the Q8_0 matrix cell loads the source file once
borisbat Dec 1, 2026
be6814a
dasLLAMA: five more expert-format rows, FORMATS_HF at the new head
borisbat Dec 1, 2026
ad2b988
dasLLAMA docs: fleet room check, disk floor, the folded Q8_0 cell
borisbat Dec 1, 2026
76dd49f
dasLLAMA tests: model-free reds under the fleet's environment
borisbat Dec 1, 2026
42f4169
dasLLAMA: the census sees the parity walker's rows; 29 more pins
borisbat Dec 1, 2026
55acfe6
dasLLAMA: CUDA refuses host layers under a pool with the stream off
borisbat Dec 1, 2026
500da3b
dasLLAMA: the IQ2 expert rows claim no recipe that cannot have made them
borisbat Dec 1, 2026
96ff7a1
dasLLAMA: the census sees hosted .bin files; rule skips said apart
borisbat Dec 1, 2026
7c4640d
dasLLAMA tests: the 35B NextN draft compares against the CPU form
borisbat Dec 1, 2026
964783f
dasLLAMA tests: the Omni exact poison leg asks the CPU home
borisbat Dec 1, 2026
21824d4
dastest: a failed test reports the panic that ended it, not a stale one
borisbat Dec 1, 2026
84e9209
dasLLAMA tests: the unbuilt-seats cell loads its model in its own frame
borisbat Dec 1, 2026
87be222
dasLLAMA tests: the 35B draft compare holds the head on the device carry
borisbat Dec 1, 2026
6b35f66
dasLLAMA tests: two Vulkan census blind spots are covered now
borisbat Dec 1, 2026
55eeb0c
dasLLAMA tests: the 26B k_cut parity cell counts its near-tie row
borisbat Dec 1, 2026
f368e06
dasLLAMA tests: the runner reads the spec table carrying no engine
borisbat Dec 1, 2026
ea19006
dastest: the recovered-panic note sits above its line
borisbat Dec 1, 2026
a092d5b
dasLLAMA tests: the llama2.c oracle's cells ask the CPU home
borisbat Dec 1, 2026
6fa66aa
dasLLAMA tests: a --das dry run reads no spec table
borisbat Dec 1, 2026
5199e67
dasLLAMA: CUDA's pool-only prompt windows are the host's, not a refusal
borisbat Dec 1, 2026
a2d824c
dasLLAMA tests: the CUDA stream-off pool control reads the pool's work
borisbat Dec 1, 2026
aa7af4c
dasLLAMA tests: three more Vulkan census blind spots are covered
borisbat Dec 1, 2026
08884cf
dasLLAMA tests: the runner reads the spec table as text, no child
borisbat Dec 1, 2026
9954253
Merge remote-tracking branch 'origin/master' into bbatkin/dasllama-fe…
borisbat Dec 1, 2026
69d5ad5
dasLLAMA tests: the Qwen3-Omni frozen-id pair asks the CPU home
borisbat Dec 1, 2026
8ec163d
dasLLAMA tests: the rotated-walk cell runs each format's KHR tile alone
borisbat Dec 1, 2026
ad8d33a
dasLLAMA: a load with the NextN head off takes the trunk alone
borisbat Dec 1, 2026
e9f8a50
dasllama-server: mtp = 0 loads the slot's model with no NextN head
borisbat Dec 1, 2026
da8e7ce
dasLLAMA docs: a format lands at the NextN head's and mixed sites too
borisbat Dec 1, 2026
1166e84
dasLLAMA: CUDA refuses host layers under a pool with the stream off
borisbat Dec 1, 2026
4f95bf5
dasLLAMA tests: the guide names the CUDA stream-off forms' no-pool ask
borisbat Dec 1, 2026
0cd45ba
dasLLAMA: the NextN head ask's facade wraps engine twins one to one
borisbat Dec 1, 2026
38f0da7
dasLLAMA: seven parity carriers pinned in the format repository
borisbat Dec 1, 2026
e1c7946
dasLLAMA tests: a name joined onto a scratch local is no model
borisbat Dec 1, 2026
fd1206d
dasLLAMA tests: the MoE census holds an all-host form's top-k at none
borisbat Dec 1, 2026
0f24a9b
dasLLAMA benchmarks: two Metal labs build their slot lists in place
borisbat Dec 1, 2026
4bf5c93
dasLLAMA: the plan sets the token table's room aside before the pool
borisbat Dec 1, 2026
d1602d0
dasLLAMA tests: the Qwen1.5-MoE format carriers on three-block cuts
borisbat Dec 1, 2026
96a97fd
dasLLAMA tests: the cut's format form pins the pool under its experts
borisbat Dec 1, 2026
8264aaa
dasLLAMA tests: six census blind spots the stocked matrix now dispatches
borisbat Dec 1, 2026
26d600c
dasLLAMA: snapshot tokenizers are fixtures the fetcher brings
borisbat Dec 1, 2026
58d05b4
dasLLAMA: a drafter's device scale plane reserves before it grows
borisbat Dec 1, 2026
0ec4c8e
dasLLAMA: the gemma-4 MXFP4 expert carriers are pinned files
borisbat Dec 1, 2026
27710e2
dasLLAMA tests: the drafter cell's codec control resets its pass
borisbat Dec 2, 2026
6eb6e2f
dasLLAMA tests: the gigaam kq lane's Metal ids hold but at near ties
borisbat Dec 1, 2026
3eab1ba
Merge remote-tracking branch 'origin/master' into bbatkin/dasllama-fe…
borisbat Dec 2, 2026
e6cb72a
dasLLAMA: the hc joint cell pins a like key split for both verifies
borisbat Dec 2, 2026
115d01d
dasLLAMA: the hc micro feed cell holds its rows to 0.40 of the row max
borisbat Dec 2, 2026
67b3d60
jobque: a panic out of with_job_status unlinks its wait group
borisbat Dec 2, 2026
0d1c1f9
Merge remote-tracking branch 'origin/master' into bbatkin/dasllama-fe…
borisbat Dec 2, 2026
9cfd383
jobque: bound a panicked wait group's wait, keep earlier job panics
borisbat Dec 2, 2026
2248628
dasLLAMA tests: model-free cells leave the stocked files
borisbat Dec 2, 2026
9fdcbc7
dasLLAMA tests: named skips, own-load reasons, held cut counts
borisbat Dec 2, 2026
53b49bd
dasLLAMA: the head-off announce, one speculation guard, a cap log
borisbat Dec 2, 2026
44b4f24
dasLLAMA docs: checklist corrections and ledger rows
borisbat Dec 2, 2026
ebfd388
dasLLAMA tests: the laid q8 read's control spans the widest row group
borisbat Dec 2, 2026
1d46860
dasLLAMA: a model keeps the NextN head ask its load ran under
borisbat Dec 2, 2026
82d53e7
dasLLAMA: a head-off load of an MLX snapshot copies no draft head
borisbat Dec 2, 2026
2f5f233
dasLLAMA: the NextN head ask is one lever, no forwarding layer
borisbat Dec 2, 2026
10f4f1b
dasLLAMA tools: one sha256, sidecar and disk-room rail in utils/common
borisbat Dec 2, 2026
f54f4e2
dasLLAMA tests: a Metal-mode cell puts the home back through its seat
borisbat Dec 2, 2026
b73199b
dasLLAMA harness: the fleet's fetch room rounds the used space up
borisbat Dec 2, 2026
a96f6a3
dasLLAMA tools: test seams for the pool plan, fetch exits and disk room
borisbat Dec 2, 2026
5695b60
dasLLAMA tests: cells for the loader batch's untested branches
borisbat Dec 2, 2026
fec0adf
dasLLAMA docs: a follow-up row for partials in the fetch room checks
borisbat Dec 2, 2026
b8a85df
utils, tests: the new lines keep to the folders' line lengths
borisbat Dec 2, 2026
e659f76
dasLLAMA: the assistant cap log moves to a cold-path helper
borisbat Dec 2, 2026
52f281a
dasLLAMA tests: the laid q8 read's repacked half needs a repack
borisbat Dec 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions dastest/suite.das
Original file line number Diff line number Diff line change
Expand Up @@ -1006,7 +1006,8 @@ def private test_any(name : string; func; args_num : int; // nolint:STYLE038 -
testLocation = "{loc}"
}
}
if (!empty(context.context.last_exception)) {
//! a recovered panic's text may be freed
if (empty(context.context.exception) && !empty(context.context.last_exception)) {
let loc = file_info_hr(context.context.exceptionAt, context.uriPaths)
errorOrBlue(context.expectFailure,
"{loc}: {context.indenting}{context.context.last_exception}")
Expand Down Expand Up @@ -1229,7 +1230,7 @@ def private run_benchmark(var suite_ctx : SuiteCtx; // nolint:STYLE038 - one pa
if (!empty(context.exception)) {
log::error("{file_info_hr(context.exceptionAt, file_ctx.uriPaths)}: {file_ctx.indenting}{context.exception}")
}
if (!empty(context.last_exception)) {
if (empty(context.exception) && !empty(context.last_exception)) {
log::error("{file_info_hr(context.exceptionAt, file_ctx.uriPaths)}: {file_ctx.indenting}{context.last_exception}")
}
}
Expand Down
20 changes: 20 additions & 0 deletions dastest/tests/_fixture_stale_recover.das
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
options gen2
options gc
options persistent_heap

require dastest/testing_boost public
require strings

[test]
def uncaught_panic_after_a_recovered_one(t : T?) {
let n = length(get_command_line_arguments())
var recovered = false
try {
panic("recovered panic {n}")
} recover {
recovered = true
}
t |> success(recovered)
unsafe(heap_collect(true, true))
panic("uncaught panic after the recovered one")
}
23 changes: 23 additions & 0 deletions dastest/tests/test_reports.das
Original file line number Diff line number Diff line change
Expand Up @@ -249,3 +249,26 @@ def failure_reports_outlive_the_test_heap(t : T?) {
}
delete_json(result)
}

//! Isolate the intentional panic in a child.
[test(description = "a test that recovers one panic and then dies on another reports the panic that ended it alone - the recovered panic's text, freed by then, is never read", timeout = 1200)]
def recovered_panic_is_not_reported(t : T?) {
let report = path_join(test_temp_dir(), "stale.json")
let arguments <- [get_host_binary(), "-dasroot", get_das_root(),
"-no-module-cache", path_join(get_das_root(), "dastest/dastest.das"),
"--", "--test", path_join(get_das_root(),
"dastest/tests/_fixture_stale_recover.das"), "--json-file", report]
var output : string
let code = run_and_capture(arguments, output, 120.0)
t |> equal(code, 1, output)
var error : string
var result = read_json(fread(report), error)
t |> strictEqual(error, "", output)
if (result == null) { return }
let entries = result?.tests?[0]?.messages
t |> success(entries.value is _array, output)
if (entries.value is _array) { t |> equal(length(entries.value as _array), 1, output) }
let message = result?.tests?[0]?.messages?[0] ?? ""
t |> success(find(message, ": uncaught panic after the recovered one") >= 0, message)
delete_json(result)
}
2 changes: 1 addition & 1 deletion doc/reflections/das2rst.das
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ def private dasllama_type_stanza(f : FILE const?; lab : string; tname : string;
def document_module_dasllama(_root : string) { // nolint:STYLE038 — flat doc-group list
var mod = [find_module("dasllama"), find_module("dasllama_core")] //! the facade re-exports the core module, which holds the documented functions
var groups <- array<DocGroup>(
group_by_regex("Model loading and sessions", mod, %regex~(load_model|load_model_on_cpu_home|with_cpu_home|create_session|create_kv_pool|default_kv_dtype|release_kv_pages|create_batch_workspace|setup_dasllama_jobque|with_dasllama_jobque|caps|mtp_drafter_sidecar|attach_mtp_drafter|attach_mtp_sidecar|detach_mtp_drafter|mtp_drafter_stats|mtp_capable|attach_block_drafter|detach_block_drafter|set_block_drafter_confidence|block_drafter_confidence|block_drafter_attached)$%%),
group_by_regex("Model loading and sessions", mod, %regex~(load_model|load_model_on_cpu_home|with_cpu_home|nextn_head|set_nextn_head|with_nextn_head|create_session|create_kv_pool|default_kv_dtype|release_kv_pages|create_batch_workspace|setup_dasllama_jobque|with_dasllama_jobque|caps|mtp_drafter_sidecar|attach_mtp_drafter|attach_mtp_sidecar|detach_mtp_drafter|mtp_drafter_stats|mtp_capable|attach_block_drafter|detach_block_drafter|set_block_drafter_confidence|block_drafter_confidence|block_drafter_attached)$%%),
group_by_regex("Prefix cache", mod, %regex~(create_prefix_cache|prefix_attach|prefix_insert|prefix_insert_snapshot|prefix_checkpoint_at|prefix_match_len|prefix_state_match_len|prefix_attach_state_split|prefix_state_touch|prefix_share_pages|prefix_take_spare|prefix_release|prefix_held_groups|prefix_chain_list|prefix_file_save|prefix_file_restore)$%%),
group_by_regex("Device-home streams and the host pool", mod, %regex~(gpu_resident_mtp_device_home|gpu_device_kv_claim|gpu_device_kv_checkpoint|gpu_device_kv_checkpoints|gpu_device_kv_checkpoint_rows|gpu_device_kv_snapshot|gpu_device_kv_parked_pos|gpu_device_kv_parked_snapshot|gpu_device_kv_victim_claims|gpu_device_kv_export|gpu_device_kv_import|gpu_device_kv_pool_armed|gpu_device_kv_pool_moves)$%%),
group_by_regex("Tokenizer", mod, %regex~(encode|decode|piece)$%%),
Expand Down
17 changes: 8 additions & 9 deletions doc/source/reference/tutorials/dasLLAMA_13_serving.rst
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,8 @@ backend can install its hooks, ``moe_gpu_weight_budget`` says how many bytes
of weights the armed backend will hold resident, and ``gpu_tier_status`` is
the running snapshot a status page reads. After the load,
``gpu_slot_capture`` moves the arm outcome into a ``GpuModelMarks`` holder
(``gpu_model_marks_init`` makes an empty one) and classifies it: ``"cpu"``,
``"gpu:rails"``, or ``"gpu:resident"``:
(``gpu_model_marks_init`` makes an empty one) and classifies it: ``"cpu"``
or ``"gpu:resident"``:

.. das-doc: given var s = Session()
.. code-block:: das
Expand All @@ -184,7 +184,7 @@ the running snapshot a status page reads. After the load,
print("budget {moe_gpu_weight_budget()} bytes on '{gpu_tier_status().device}'\n")
// ... load_model runs here ...
var slot = gpu_model_marks_init()
let outcome = gpu_slot_capture(slot) // "cpu" | "gpu:rails" | "gpu:resident"
let outcome = gpu_slot_capture(slot) // "cpu" | "gpu:resident"

A switch has two halves, and the order is the contract. Switch-out first:
``moe_gpu_hydrate_session`` pulls each live session's KV back to host memory
Expand Down Expand Up @@ -307,16 +307,15 @@ The scheduler does all of this per stream once we switch it with
it on only when every stream gets a region — ``gpu_device_sessions()`` is at
least the scheduler's stream count.

``gpu_cpu_passes`` is the honesty counter: every call the GPU path handed
back to the CPU, by reason, with the reason in plain words. Streams served
from the device keep it empty. Run this tutorial with the vulkan tier armed
and the counter lists the earlier sections' paged sessions — those keep their
cache on the host, so their calls ran on the CPU:
``gpu_cpu_passes`` is the honesty counter: every call the GPU path did not
serve, by reason, with the reason in plain words. The model on the GPU keeps
no weights in host memory, so such a call stops with an error that names the
reason. A run that gets this far lists none:

.. code-block:: das

for (p in gpu_cpu_passes()) {
print("{p.count} calls ran on the CPU: {p.words}\n")
print("{p.count} calls the device did not serve: {p.words}\n")
}

A block drafter
Expand Down
4 changes: 2 additions & 2 deletions doc/source/reference/utils/dasllama_server.rst
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ no default stands in for it. An argument no flag claims - a flag and its value p
* - ``--mtp``
-
- *off*
- MTP/NextN self-speculative decode. Unset, a slot leaves it off, except one that runs one stream (``streams = 1``) on a GPU the model's catalog row lists under ``serve_mtp`` (``modules/dasLLAMA/performance/model_specs.das``: the platforms, ``metal`` or ``vulkan``, where that model's self-speculation measured a win) --- Metal, or the whole model resident on a Vulkan device. A model with no catalog row, a model whose row lists another platform, several streams and the CPU decode plain: on the CPU the round's second verify row costs a second decode step, at several streams the plain batched step is faster. A MoE whose routed experts the resident driver sums on the host arms too. A NextN round on a Vulkan or CUDA home drafts three. A drafting Vulkan slot (``--gpu vulkan``) keeps its streams' caches on the card (device-home) where the whole-model driver runs the draft head, its verify and a rejected round's rollback on the device; where any of them stays on the host (the load log names which), the load is refused naming it. ``true`` / ``false`` set it outright. It needs a model with an in-file NextN head (the ``-MTP-`` GGUFs), or an assistant drafter GGUF beside the model file (gemma-4: ``mtp-<stem>-Q8_0.gguf``, ``<stem>`` the file name before its quant token, an unsloth ``-UD`` tag dropped; the catalog's gemma-4 26B card fetches it with ``"tower": "drafter"``), which the load attaches on Metal or on the Vulkan resident driver and which drafts at the box's ``runtime.mtp_depth_assistant`` depth on Metal and three a round on a Vulkan or CUDA home; on any other model the server logs one line and serves plain. Greedy requests are output-invariant; a sampled request draws each verify row with its own sampler and keeps the plain sampled distribution, at a lower acceptance rate. ``/v1/stats`` reports ``mtp_drafted`` / ``mtp_accepted``. A constrained reply (``response_format``, a forced ``tool_choice``) decodes plain.
- MTP/NextN self-speculative decode. Unset, a slot leaves it off, except one that runs one stream (``streams = 1``) on a GPU the model's catalog row lists under ``serve_mtp`` (``modules/dasLLAMA/performance/model_specs.das``: the platforms, ``metal`` or ``vulkan``, where that model's self-speculation measured a win) --- Metal, or the whole model resident on a Vulkan device. A model with no catalog row, a model whose row lists another platform, several streams and the CPU decode plain: on the CPU the round's second verify row costs a second decode step, at several streams the plain batched step is faster. A MoE whose routed experts the resident driver sums on the host arms too. A NextN round on a Vulkan or CUDA home drafts three. A drafting Vulkan slot (``--gpu vulkan``) keeps its streams' caches on the card (device-home) where the whole-model driver runs the draft head, its verify and a rejected round's rollback on the device; where any of them stays on the host (the load log names which), the load is refused naming it. ``true`` / ``false`` set it outright. ``false`` (``mtp = false`` on a ``[[models]]`` entry) also loads the model with no NextN head: no head plane is read or kept, and a head the home cannot serve (one whose layer mixes activation-quant forms at a site) never fails a slot that does not speculate. It needs a model with an in-file NextN head (the ``-MTP-`` GGUFs), or an assistant drafter GGUF beside the model file (gemma-4: ``mtp-<stem>-Q8_0.gguf``, ``<stem>`` the file name before its quant token, an unsloth ``-UD`` tag dropped; the catalog's gemma-4 26B card fetches it with ``"tower": "drafter"``), which the load attaches on Metal or on the Vulkan resident driver and which drafts at the box's ``runtime.mtp_depth_assistant`` depth on Metal and three a round on a Vulkan or CUDA home; on any other model the server logs one line and serves plain. Greedy requests are output-invariant; a sampled request draws each verify row with its own sampler and keeps the plain sampled distribution, at a lower acceptance rate. ``/v1/stats`` reports ``mtp_drafted`` / ``mtp_accepted``. A constrained reply (``response_format``, a forced ``tool_choice``) decodes plain.
* - ``--mtp-accept``
-
- *engine*
Expand Down Expand Up @@ -578,7 +578,7 @@ fits the card serves entirely from VRAM, and so do its streams - the driver
holds a K/V region per stream, the prompt prefills on the device in 512-token
windows, the streams decode in one batched step, and a conversation's next turn
picks up its earlier rows from the region they were left in. ``/v1/stats``
counts every call the device handed back to the CPU (``gpu_cpu_passes``); a
counts every call the device did not serve (``gpu_cpu_passes``); a
slot served this way keeps it empty. The control page's model card says which
of these a slot got (``served``) and why it got less when it did
(``served_note``). A recurrent (deltanet) model serves the same way, its
Expand Down
2 changes: 1 addition & 1 deletion modules/dasLLAMA/ARCHITECTURE_ENGINE.md
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ module gains five functions, each as visible as the getter:
- `with_X(v : T) { ... }` pins `v` for its block and puts back the pin it found however the block leaves: a panic
is re-raised once the pin is back (`with_put_back`, the restore the test cells' own pins return through too).

The engine's levers: `source_release` (`dasllama_gguf.das`), `image_save`
The engine's levers: `source_release` and `nextn_head_` (`dasllama_gguf.das`), `image_save`
(`dasllama_image.das`), `lane_read` and `gpu_kv_want`
(`dasllama_gpu_resident.das`), `kv_init` and `cpu_prefill` (`dasllama_common.das`; `allow_cpu_prefill` sets
it). `gpu_kv_want`'s body is a constant: the codec's knob has spellings that name none, so `resident_mirror_ask`
Expand Down
4 changes: 2 additions & 2 deletions modules/dasLLAMA/ARCHITECTURE_ENGINE_FORMATS.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ anchor.
single-sourcing them is generator-rail work, never a hand-merge. Float multiply order in the
builders is contractual (parity-pinned).
- **`dasllama_gguf.das`** - the GGUF container: KV/tensor descriptors, the byte-level reader, the
mapping, and the record writers and rewritten head a file written from another takes. Codecs live
in `dasllama_convert`; this file finds bytes, it does not decode them.
mapping, the record writers and rewritten head a file written from another takes, and the load's
NextN head ask. Codecs live in `dasllama_convert`; this file finds bytes, it does not decode them.
- **`dasllama_layout.das`** - disk-format -> compute-layout transforms at LOAD scope: the blob
transform, the CPU repack walkers, the GPU tier gathers, the per-region Q8_0 quants and
halfword scales -> Metal-34B block writer (`q8_region_to_metal_blob`), the GGUF Q8_0 blocks'
Expand Down
8 changes: 5 additions & 3 deletions modules/dasLLAMA/ARCHITECTURE_ENGINE_FORMATS_MLX.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ be 4-byte aligned - every plane is copied out, never viewed in place.
`hf_snapshot_meta` builds the `GGUFMeta` the GGUF loader already walks, so `load_gguf_parsed` runs on
it: tensors renamed to their GGUF names (`hf_gguf_stem`; a vision tower or draft head is not read), dims
reversed to GGUF order, and the config's geometry written as the `{arch}.*` KVs a converter writes. The
KVs, the chat template, the tokenizer KVs and the synthetic tensors (llama3's `rope_freqs.weight`) live in
one extra buffer, the meta's last shard: its bytes are the `bytes` every KV getter reads. The family a
KVs, the chat template and the synthetic tensors (llama3's `rope_freqs.weight`) live in one extra buffer,
the meta's last shard: its bytes are the `bytes` every KV getter reads. The family a
`model_type` loads as is `hf_family` (`llama`; `qwen3_5` as qwen35, `qwen3_5_moe` as qwen35moe and `qwen4_exp` as qwen4exp,
their geometry under `text_config`). A family that names a draft-head prefix (`mtp_prefix`) reads that head too.

Expand All @@ -30,7 +30,9 @@ the converter permutes them to adjacent pairs; the meta marks it (`hf_rope_halve
those rows as NEOX pairs, so no row moves. The streamed load does not arm on a snapshot (the transcode
reads three tensors per plane); the image mint converts eagerly.

The tokenizer is tokenizer.json written as the GGUF tokenizer KVs: the vocab padded to the model's
The tokenizer is a meta of its own (`with_hf_tokenizer`), built off config.json, tokenizer.json and
tokenizer_config.json with no weight file read, so a directory holding those three files is a tokenizer
source. It is tokenizer.json written as the GGUF tokenizer KVs: the vocab padded to the model's
`vocab_size` with UNUSED `[PAD<i>]` rows, the merges as `left right` strings, the converter's token types
(an added token is control where marked special or spelled `<|...|>`, user-defined otherwise), and the
pre-tokenizer its split regex names (`hf_bpe_pre`: `\p{N}{1,3}` is llama-bpe, `\p{M}` qwen35, `\p{N}`
Expand Down
4 changes: 3 additions & 1 deletion modules/dasLLAMA/ARCHITECTURE_ENGINE_MEMORY.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ per-layer embedding's projection is read off the gguf into the home's f16 rows (
then dropped (`load_gguf_live`); a re-arm's plan-load reads the rows again and lends them to its walk
(`resident_ple_rows_lend`). The load's log line names what put it on this
arm and the ask that turns it off. A re-arm streams the gguf again over the same model (`gguf_live_rearm`,
`gguf_live_loaded`): the model keeps its source's path (`rearm_source`), and the walk needs no host plane; a re-arm
`gguf_live_loaded`): the model keeps its source's path (`rearm_source`) and the NextN head ask its load ran under
(`Model.nextn_ask`), the re-parse runs under that ask whatever the process asks now, a re-parse whose head count is not
the model's fails the re-arm by name, and the walk needs no host plane; a re-arm
whose walk declines drops what it placed and answers `cpu`, the model then serving nothing - every call a panic by name.

### A mapped gguf's pages go as the next tensor's read begins {#gguf-source-release}
Expand Down
4 changes: 4 additions & 0 deletions modules/dasLLAMA/ARCHITECTURE_ENGINE_SERVING.md
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,10 @@ like any other's: its n-gram conv ring rides the region's checkpoint rows and th
is seeded from the tokens the scheduler keeps (`ple_window_seed`) at adoption (`parked_adopt`) and when a snapshot is filed
(`pool_keep`). An indexer model's pool holds the raw indexer keys as one more plane a page (`KVPool.qsa_plane`): an opening's
export writes them beside its K/V rows and its import brings them up (`ARCHITECTURE_GPU_VULKAN_HC_QSA.md#hc-qsa`).
A model that holds no weight plane on the host serves a stream from a device region alone, so a scheduler over it takes no
more streams than the armed driver's regions: `create_scheduler` refuses that shape at creation, by name
(`scheduler_regions_why`), in the sentence dasllama-server's slot refusal gives (`streams_regions_why`), and one stream on a
host-cached session in the mirror codec stays served.

- **Down.** A copy is made when the card is about to lose the state, not before: nothing crosses the bus before a stream's
first token, and a conversation that goes on in its own region copies nothing. Each checkpoint stop the region keeps
Expand Down
Loading
Loading