Commit Graph
6 Commits
Author SHA1 Message Date
LLMsherpa 5c8519eefa fix: handle V4.1 placement, readouts, and export memory 2026-10-25 13:10:12 -04:00
Joseph MaglyandClaude Opus 5.5 c9a40af719 fix: address review findings (72b-placement)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-18 20:29:39 -04:00
Joseph MaglyandClaude Opus 5.5 97d042c71c feat(gpu): 72B capacity planner and bounded export for split runs
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-18 20:17:47 -04:00
Joseph MaglyandClaude Opus 5.5 c7f45460eb test: cut slow CPU integration tests below the per-test budget (#304)
Tiny-model pipeline tests were dominated by fixed per-step costs, not
arithmetic: the pipeline's gc.collect() after each verify prompt rescans
every long-lived object the session imported (~0.2 s per call), and
intra-op thread fan-out makes each 16-dim forward slower on loaded runners.

- conftest: add an opt-in tiny_model_runtime fixture (one intra-op thread,
  gc.freeze() of pre-test objects, both restored afterwards). Objects the
  test creates remain collectable, so pipeline behaviour is unchanged.
  Applied to test_offline_integration and the concept_* integration modules.
- test_disk_offloaded_fused_moe_surgery_matches_live_surgery: bound verify
  free-form completions to 4 tokens; every diagnostic still runs through
  the disk-offload hooks and no assertion depends on generated text.
- test_disk_offloaded_subprocess_rss_bound: measure native and legacy export
  in one subprocess on the same offloaded model, resetting VmHWM (after GC
  and malloc_trim) before each mode; native is measured first. Same three
  assertions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-14 16:53:10 -04:00
Joseph MaglyandClaude Opus 5.5 c43a8a5c70 fix: fall back to full-gather export for offloaded tied weights
With accelerate cpu_offload, tied parameters become separate meta
placeholders that hide their shared backing storage, so tie removal on
metadata kept lm_head.weight and the native export diverged from the
legacy checkpoint. Decline the native plan whenever a declared tie
(transformers' expanded tied-weight keys, or the embedding tie contract
as a fallback) involves a meta tensor, and document that partial offload
follows model order rather than the legacy resident-first gather order.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 12:02:23 -04:00
Joseph MaglyandClaude Opus 5.5 97201d6f10 fix: bound native checkpoint export by per-shard staging
Plan native Hugging Face export from state_dict metadata without
materializing offloaded weights, then stage, verify and promote one
safetensors shard at a time inside the existing atomic checkpoint
directory, checking cancellation and the host budget before each shard.
Unsupported models (quantized, PEFT, TP/FSDP, remote code, custom
state_dict hooks, shared meta aliases) keep the legacy full-gather path.

native_export_host_demand() reports the per-shard peak host demand so a
REBIRTH-boundary admission can consume it.

Closes #247

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 11:38:22 -04:00