Skip to content

v1.0.8

Choose a tag to compare

@mcp-tool-shop mcp-tool-shop released this 26 Oct 21:05
· 11 commits to main since this release
4eb1488

Fixed

  • A per-cell wall cap. request_timeout_s is clamped to 120 to 900 s per request, so a slow, fully resident c4 or c8 cell could take four passes of 900 s (an hour) plus up to six calibration calls, and a few such cells in a 3-quant window on an 80 or 96 GB card could pass Colab's roughly 4 h VM-loss line. A cell now has CELL_WALL_S = 1800 (settings.cell_wall_s on every generate-ladder row). After calibration, a cell whose projected wall, (1 warmup + repeats) x (ceil(3 x concurrency x t_verify_s) + 60) from the real unclamped estimate, is over the cap is refused before any timed pass and recorded as timeout (projected N s > cell wall 1800 s; not run). CELL_DEADLINE_S (2 x the cap) is the outer bound over the whole cell: whatever call is blocked, the cell ends as an unmeasured row and the ladder carries on. The harness cannot see the window's wall; the launcher's wall stays the outer bound of the window.
  • CALIBRATION_TIMEOUT_S is 300 s (was 900). A calibration call is a single request with a one-token reply. The slowest fully resident one on record is T4 r3's p16384 verify at 25.1 s (Ollama's Go side costs about 0.57 ms per prompt token on 2 vCPUs, so p32768 projects to about 70 s); the rig's 33k prefill takes 3.7 s. 300 s is more than four times the slowest projection, and a stuck cell's calibration is now bounded at 30 minutes instead of 90.
  • The T4 r4 hang: a VRAM sample has a deadline. After the c4 16k cell's host-RAM oom row the run sent nothing for 56 minutes and its run record stayed closed: false; the likely place is the NVML sample at the start of the next cell, which has no timeout of its own and ran just after the kernel's OOM killer took a CUDA process (not proven; the r4 run printed no per-phase marker). Every VRAM sample now runs on a daemon thread with SAMPLER_TIMEOUT_S = 30; on expiry the cell is unmeasured (VRAM sampler did not answer within 30 s) and the ladder continues, so a wedged NVML costs 30 s a cell, not the window. A sampler that fails (rather than hangs) is still a sampler_error; the first sample of a cell used to propagate its exception raw and now follows the same rule.
  • After the first NVML timeout the run samples through nvidia-smi. An NVML call abandoned on a daemon thread can leave pynvml wedged inside the process, so every later cell could wait out the 30 s deadline again for the rest of the run. The run's sampler (GuardedSampler, one per run) now switches, after its first timeout, to nvidia-smi --query-gpu=memory.used,memory.total run as a subprocess with a NVIDIA_SMI_TIMEOUT_S = 10 timeout: a hung nvidia-smi is killed, so a wedged driver costs at most 10 s a sample and cannot pin the process. If nvidia-smi is missing, fails, answers nonsense or times out, the cell is unmeasured with the real reason and the ladder continues. Each generate row records settings.vram_sampler (nvml, nvidia-smi, or nvidia-smi-fallback) and settings.vram_sampler_reason (why the run switched).
  • Phase markers. The harness writes one line per phase to stderr ([interlock HH:MM:SSZ] cell p32768 c4: start, sampling VRAM, each probe and verify sent, calibrated, each pass sent and answered, VRAM sampled, cell end), so the next hang names its own call.
  • No "margin of 0.0 MiB" clause. When Ollama gave the system memory in MiB there is no GiB rounding margin, and the host-RAM reason no longer prints one.

Added

  • A rig-check identity. The Linux ladder only accepted Colab identities, so rig checks of the harness had to pass a placeholder colab:L4 and their rows were labelled as L4 data. RemoteDeviceIdentity.rig(card, vram_mib, driver_version, cuda_version) is provider rig with a free-text card (RTX 5090), pool rig-local, and device rig:RTX5090. Every row built with it carries not_for_import: true. The routing-row schema allows the rig form only with not_for_import: true (a rig: row without it fails validation); Colab identities and rows are unchanged. interlock import refuses a rig row or a rig-provider envelope, naming not_for_import, and route excludes one that reaches a table with the new code rig_check (in the route-decision schema) and never ranks it.

  • route --concurrency N (default 1). A generate row is the pass aggregate across its N requests, so a c8 row and a c1 row answer different questions; before this, route ranked every shape of a model against every other and picked the c8 aggregate for a single caller (T4 r3: p512 c8, decode bound 115.67, where a c1 request gets about 67 tok/s). Generate rows are now ranked and floored only at the requested concurrency (a row with no settings.concurrency, the rig's single-stream harnesses, counts as 1). When no row matches, the refusal names the concurrencies that exist (Rows exist at concurrency 1, 4, 8; none at 2.). The decision, text and --json, records concurrency and ranked_field (decode_tok_s) and says so in notes. Other tasks ignore the flag. --concurrency below 1 (or not a whole number) is rejected at the flag with a usage error, not turned into a table refusal.

Changed

  • The margin is between distinct candidates. A candidate is a device, a model with its revision, and its quant. The margin is the winner's bound against the best row of the best other candidate, never against another shape of the same model (r3's "delta 18.343 over 97.325" was phi's c8 row against phi's own c4 row). With one candidate there is no margin: next_bound, delta and next_id are null and notes says no other candidate.
  • Fill-card rows never rank in generate. A fill-card row (max_resident_ctx, or the fill-card spec) is a load probe, not a generate shape. It is listed under excluded with the new code fill_card and takes no part in the ranking or the floors. The route-decision schema gains the fill_card code and the optional concurrency and ranked_field fields.
  • Another shape of the winner's own candidate is no longer listed under runners_up for generate (it is not an alternative to it), and a refusal gives each measured failure reason once with a count ((x20)) instead of repeating it for every row.
  • The pre-v3 guard is unchanged: a pre-v3 row's concurrency-above-1 throughput and ttft are still never used.

Docs

  • The handbook describes route --concurrency, the fill_card and rig_check exclusions, the per-cell wall cap, the nvidia-smi sampler fallback, the phase markers and the rig-check identity.