Skip to content

feat: add learned partial mirror planner#536

Open
bherald wants to merge 1 commit into
JustVugg:devfrom
bherald:contrib/partial-mirror-planner
Open

feat: add learned partial mirror planner#536
bherald wants to merge 1 commit into
JustVugg:devfrom
bherald:contrib/partial-mirror-planner

Conversation

@bherald

@bherald bherald commented Jul 22, 2026

Copy link
Copy Markdown

Summary

  • add a learned partial-mirror planner driven by .coli_usage
  • inspect safetensor headers directly and retain gate-projection dependencies for selected expert shards
  • enforce copy budget and free-space reserve, reject unsafe/duplicate paths and malformed metadata, and fail closed without usage evidence
  • stage copies atomically, fsync, verify SHA-256, and publish a readiness receipt without moving or deleting authoritative shards

Why

Very large disk-streamed MoE models may span multiple volumes. Mirroring the empirically hottest complete shard/dependency set onto a faster or less contended volume can be tested safely without changing the authoritative model layout.

Validation

  • complete native suite plus 150 Python tests passed, 10 skipped, after rebasing onto JustVugg/colibri:dev revision cd278c227cf515b1f123c5fcc6bcf3c4820eafc9
  • focused planner tests cover learned ranking, direct safetensor metadata, dependency inclusion, missing-usage refusal, traversal rejection, copy, receipt readiness, and full hash verification
  • read-only real-model plan observed 1,369,800 selections and admitted 71 shards / 188,562,803,696 bytes under a 200-GiB budget while preserving a 100-GiB reserve

No model files were copied for the real-model validation; planning alone never activates a mirror.

@JustVugg

Copy link
Copy Markdown
Owner

Thanks — a learned mirror planner for dual-SSD is a sensible tool, and it's cleanly isolated (Python mirror_plan.py + launcher + test, no engine core touched), so it's low-risk. But it's +636 lines of a feature that isn't on the current critical path (the focus is getting the large models running on a single box), and I haven't given it the deep review that size deserves. So I'm parking it as not-priority-now rather than merging on a surface pass — it stays open and mergeable. When the dual-SSD path (#421) is something we're actively tuning, this is the natural companion. No rush on your side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants