Skip to content

refactor(planning): the training plan and the serving floor live in inference/planning, so serving and training read one need - #4985

Merged
joelteply merged 2 commits into
canaryfrom
c8165aa6/park-no-fit-and-training-plan
Oct 12, 2026
Merged

joelteply merged 2 commits into
canaryfrom
c8165aa6/park-no-fit-and-training-plan

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

Agreed with Codex and Fable on #4984 and 3b8fb153. The serving planner must reserve one
learning context beside serving, and that reserve has to be the trainer's own calculation.
Exporting it from genome::fine_tuning would add the upward edge the crate peel (#4981) is
removing, so the pure planner moves to the lower owner instead:

  • genome/fine_tuning/engine_plan.rs -> inference/planning/training_plan.rs (git mv,
    unchanged apart from visibility).
  • MIN_SERVE_CTX, its one upward reference, moves with it to inference/planning. All ~40
    callers are migrated; no alias is left behind.
  • training_plan::need(whole_run, lower_bound, predicted) -> Need{bytes, source}. The source
    (WholeRun | LowerBound | Predicted) stays explicit. Footprints::need is now storage-only
    and calls it.

Adds no inference -> cognition/genome/modules/persona edge (training_plan references only
super::MIN_SERVE_CTX). Card c8165aa6; parking and the wake come next on the same card.

Co-Authored-By: Claude Opus 5.5 (1M context) [email protected]
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

…nference/planning, so serving and training read one need

Agreed with Codex and Fable on #4984 and 3b8fb153. The serving planner must reserve one
learning context beside serving, and that reserve has to be the trainer's own calculation.
Exporting it from genome::fine_tuning would add the upward edge the crate peel (#4981) is
removing, so the pure planner moves to the lower owner instead:

- genome/fine_tuning/engine_plan.rs -> inference/planning/training_plan.rs (git mv,
  unchanged apart from visibility).
- MIN_SERVE_CTX, its one upward reference, moves with it to inference/planning. All ~40
  callers are migrated; no alias is left behind.
- training_plan::need(whole_run, lower_bound, predicted) -> Need{bytes, source}. The source
  (WholeRun | LowerBound | Predicted) stays explicit. Footprints::need is now storage-only
  and calls it.

Adds no inference -> cognition/genome/modules/persona edge (training_plan references only
super::MIN_SERVE_CTX). Card c8165aa6; parking and the wake come next on the same card.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
…own and calibrates, never leased as the need

Codex on #4985: lower bounds can disqualify a shape but cannot establish that a reserve is
enough. #4984 (merged 9f0f3d4) had the trainer lease a graph-only bound that sat under
governed free as if it were the whole run's need. Before #4984 such a shape calibrated,
leasing everything free. Need::decides returns the bytes only where the evidence decides;
a bound under free returns None, so the shape calibrates as before.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
@github-actions github-actions Bot added size: L and removed size: M labels Oct 12, 2026
@joelteply
joelteply merged commit 55c7994 into canary Oct 12, 2026
6 checks passed
@joelteply
joelteply deleted the c8165aa6/park-no-fit-and-training-plan branch October 12, 2026 16:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant