Wire Alternating, Weighted, Marathon FillStrategies into schedule engine dispatch #3

Closed
opened 2026-07-12 05:47:15 +00:00 by GKaszewski · 0 comments
Owner

Parent

#2

What to build

The fill algorithm implementations for Alternating, Weighted, and Marathon already exist in the domain crate, but the schedule engine's resolve_block function may not dispatch to them yet. Wire the three new FillStrategy variants so they are actually used during schedule generation.

Verify the dispatch in resolve_block handles all 6 variants. Seed the InMemoryLibraryRepository with multi-series data and generate schedules that exercise each strategy. The Alternating strategy cycles through N series round-robin per day. Weighted favors fresh (unplayed) content. Marathon burns through one series from episode 1 in a single block.

Expose the new strategies via the MCP tools so an agent can create channels using them.

Acceptance criteria

  • resolve_block dispatches to all 6 FillStrategy variants (BestFit, Sequential, Random, Alternating, Weighted, Marathon)
  • Integration test: Alternating with 2 series produces interleaved episodes across days
  • Integration test: Weighted surfaces never-played items before recently-played ones
  • Integration test: Marathon fills a block with consecutive episodes from episode 1
  • MCP create_channel / update_channel accepts the new strategy variants

Blocked by

None — can start immediately

## Parent #2 ## What to build The fill algorithm implementations for Alternating, Weighted, and Marathon already exist in the domain crate, but the schedule engine's `resolve_block` function may not dispatch to them yet. Wire the three new FillStrategy variants so they are actually used during schedule generation. Verify the dispatch in `resolve_block` handles all 6 variants. Seed the InMemoryLibraryRepository with multi-series data and generate schedules that exercise each strategy. The Alternating strategy cycles through N series round-robin per day. Weighted favors fresh (unplayed) content. Marathon burns through one series from episode 1 in a single block. Expose the new strategies via the MCP tools so an agent can create channels using them. ## Acceptance criteria - [ ] `resolve_block` dispatches to all 6 FillStrategy variants (BestFit, Sequential, Random, Alternating, Weighted, Marathon) - [ ] Integration test: Alternating with 2 series produces interleaved episodes across days - [ ] Integration test: Weighted surfaces never-played items before recently-played ones - [ ] Integration test: Marathon fills a block with consecutive episodes from episode 1 - [ ] MCP create_channel / update_channel accepts the new strategy variants ## Blocked by None — can start immediately
GKaszewski added the ready-for-agent label 2026-07-12 05:47:15 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: GKaszewski/k-tv#3