You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Schedule multi-turn conversational requests using estimated KV load latency and GPU/host residency in hanzo-engine / Enso. Measure p95 TTFT and goodput across mixed warm/cold workloads.
Scope & Canonical Architecture
Complements hanzoai/engine#56; targets residency-aware request ordering rather than generic batching.
Canonical stack boundaries MUST stay intact (vfs -> hanzoai/s3 -> visor, Cloud owning lifecycle & billing, Enso routing models, Zen generating outputs, Kai returning structured non-generative decisions). Reported figures in referenced FAST/conference papers belong strictly to the original authors' environments and MUST NOT be treated as Hanzo expectations until reproduced here.
Research-to-PR Acceptance Contract (0 of 6 requirements)
1. Paper & License Audit: Link primary paper/code, summarize design, and verify license compatibility (prefer Apache-2.0/MIT for production merges; clean-room implementation or research-only report otherwise) and patent restrictions.
2. Matched Baselines: Provide reproducible upstream baseline and identical Hanzo baseline scripts/configs.
3. Falsifiable Hypothesis: Document target metrics and expected failure modes up front.
4. Deliverable: Submit bounded implementation PR (Implementation Bounty) or documented reproducible experiment including valid negative results (Research Bounty).
5. Evidence & Safety: Include correctness, concurrency, multi-tenant isolation, security, and regression tests appropriate to the subsystem.
6. Measurements & HIP Update: Publish raw before/after measurements, methodology, and status update against HIP-1345.
Draft: #108 — residency-scheduler-research on breezesamuel/engine. Bounded clean-room implementation of Bidaw's first mechanism (compute→storage awareness: tier separation + size-ranked reordering) at the hanzo-kv-fabric scheduling-policy layer, with FIFO as the matched baseline on the identical workload.
Contract coverage (6-point)
Paper & license audit — Bidaw (Hu, Zhang, Zhou, Wei, Zhong, Chen; FAST '26): two-tier KV storage for interactive multi-turn serving; latency −3.58× / throughput +1.83× are the authors' testbed numbers, not Hanzo expectations (per the bounty's own caveat). No public reference code; nothing ported — clean-room from the abstract. MIT OR Apache-2.0 dual license.
Matched baselines — FIFO arrival order vs residency order, identical 24-request mixed warm/cold workload (8 resident / 8 host / 8 SSD, KV 16 MiB–2 GiB, interleaved arrival), identical sequential-server simulation; two SSD-bandwidth scenarios (2 GB/s and 500 MB/s). Both schedules committed as hanzo-kv-fabric/results/residency-scheduler-results.json.
Falsifiable hypotheses — S1: FIFO's cold-load head-of-line blocking inflates mean/warm TTFT (expected failure: uniform load latencies make ordering irrelevant); S2: tier separation + size rank cuts mean and warm-tier TTFT with unchanged total load bytes (expected failure: fast-tier-first bias starves cold requests — per-tier worsts are reported to make that visible, and the cold tier does absorb the wait, by design); S3: ordering cost is negligible vs load latency. Observed values in the results file.
Deliverable — one module (residency_scheduler: tier model, ordering policy, deterministic sequential-server simulation, 5 tests) + bench example + results JSON + HIP update. Lib change: one pub mod line.
Evidence — 5 tests: ordering lock (tier→size→arrival), resident-tier zero-load invariant, determinism + accounting identity (ttft = wait + load + prefill), residency-beats-FIFO on the cold-head-of-line case (mean + warm-wait), empty-input zeroing. cargo test green on windows/amd64, stdlib-only.
Bidaw mechanism 2 (response-predicted eviction) and mechanism 3 (selective storage-efficient caching) — need response content and storage traces a scheduling policy does not see; real two-tier I/O (configured rates until Hanzo-hardware measurement); GPU batching interplay; admission control/backpressure; hanzoai/engine#56 integration.
Happy to rebase on whichever of #100/#104/#105 merges first. — breezesamuel
Production integration priority #1156. Existing hanzo-router/docs/HIP-1346-bidaw.md documents opt-in tier cost model and deterministic trace, not deployed results. Wire server and authorized KV fabric telemetry (gpu/host/nvme/peer tokens, measured load, queue, pressure, actual prefill/restore latency), feed observe_tiered_residency, distinguish 300s hint expiry from durable cache retention. Compare measured residency vs 2xx hints; enable canary only after real workloads and isolation/rollback checks. No synthetic measurements marketed as production.
Activity
breezesamuel commentedon Nov 17, 2026
Claiming this bounty (Wave 1 -- implementing solution). Will open draft PR shortly.
breezesamuel commentedon Nov 18, 2026
Draft PR opened — 108 (single-node half of §2.3)
Draft: #108 —
residency-scheduler-researchon breezesamuel/engine. Bounded clean-room implementation of Bidaw's first mechanism (compute→storage awareness: tier separation + size-ranked reordering) at thehanzo-kv-fabricscheduling-policy layer, with FIFO as the matched baseline on the identical workload.Contract coverage (6-point)
hanzo-kv-fabric/results/residency-scheduler-results.json.residency_scheduler: tier model, ordering policy, deterministic sequential-server simulation, 5 tests) + bench example + results JSON + HIP update. Lib change: onepub modline.ttft = wait + load + prefill), residency-beats-FIFO on the cold-head-of-line case (mean + warm-wait), empty-input zeroing.cargo testgreen on windows/amd64, stdlib-only.results/HIP-1345-update.mdproposes the §2.3 addendum. Metric honesty note: on a strictly sequential server the last request always waits the full makespan regardless of order, so max/p99 TTFT are order-invariant and are reported as such — the win is mean TTFT and warm-tier p95 TTFT (fast tiers never waiting behind cold loads), which is the interactive-serving claim. §2.3 scope split: this is the single-node half (Bounty perf(ci): dev profile opt-level 3->1 (faster test builds) #13); the Enso/distributed half (Bounty Native-stack campaign: ROCm PagedAttention + decode graphs + Metal fixes #18) is already covered by cloud PR NPU-native low-bit inference for phones and AI PCs #48 (Preble).Out-of-scope (explicit)
Bidaw mechanism 2 (response-predicted eviction) and mechanism 3 (selective storage-efficient caching) — need response content and storage traces a scheduling policy does not see; real two-tier I/O (configured rates until Hanzo-hardware measurement); GPU batching interplay; admission control/backpressure;
hanzoai/engine#56integration.Happy to rebase on whichever of #100/#104/#105 merges first. — breezesamuel
zeekay commentedon Nov 21, 2026
Duplicate of #86; continue there. Open PRs are retargeted.
zeekay commentedon Dec 2, 2026
Production integration priority #1156. Existing hanzo-router/docs/HIP-1346-bidaw.md documents opt-in tier cost model and deterministic trace, not deployed results. Wire server and authorized KV fabric telemetry (gpu/host/nvme/peer tokens, measured load, queue, pressure, actual prefill/restore latency), feed observe_tiered_residency, distinguish 300s hint expiry from durable cache retention. Compare measured residency vs 2xx hints; enable canary only after real workloads and isolation/rollback checks. No synthetic measurements marketed as production.