v1 plan: Chooser free slots are per model (task 05 rule corrected, task 08 step 1b); note the finding
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
@@ -53,7 +53,11 @@ func (h *Hosts) SetDraining(name string, on bool)
|
||||
|
||||
// Chooser adapts config, health and limiter to lease.Chooser using choose.Best:
|
||||
// Info{Healthy, Draining: false (the lease table already filtered), Loaded: model in Loaded,
|
||||
// CanServe: cfg.Serves, Free: lim.FreeSlots(host), Queued: lim.Queued(host, model), Weight}.
|
||||
// CanServe: cfg.Serves, Free: free slots FOR THIS MODEL on this host =
|
||||
// cfg.Hosts[host].Models[model].Parallel - lim.InFlight(host, model) (never below 0; 0 when the
|
||||
// host does not list the model), Queued: lim.Queued(host, model), Weight}.
|
||||
// (Corrected 2026-09-25: an earlier version said lim.FreeSlots(host), which sums every model's
|
||||
// slots and let a host win on slots the requested model cannot use.)
|
||||
func Chooser(cfg *config.Config, h *health.Table, l *limiter.Limiter) lease.Chooser
|
||||
|
||||
func New(cfg *config.Config, h Health, leases *lease.Table, lim *limiter.Limiter, rec Recorder, log *slog.Logger) *Handler
|
||||
|
||||
Reference in New Issue
Block a user