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
{{ message }}
Repository navigation
#601 stage 4: per_entry cost for ltx2/restore-long #658
What shipped (commit on feat/601-4-restore-long-cost, merged at ddffc9d). workflows/templates/ltx2/restore-long.json now has a cost block, using the figures from #630's verify comment (job 5d46a62ec00e: ep13, the default 3 windows, cuda on lem, cold):
minutes 12.2 is the whole job (12.24 min, 734.6 s).
per_entry.minutes 1.56 is one warm restore@wN step (1.60 and 1.48, mean 1.54) plus its window@wN slice (about 0.05 for all three together, so about 0.02 each).
entries 3 matches the default windows list (w0–w2). The run used that default, so the fallback wasn't needed.
windows stays out of cost_drivers, as stage 3 left it.
Covers: every item in plan Stage 4:
The cost entry: as above.
Tests:per_entry_problems (test_a_per_entry_cost_names_a_list_the_steps_read) and the catalog-structure tests pass. Full pytest: 9580 passed. ruff is clean.
Docs: none beyond the template, as planned.
Expected estimates (from dw/plan.py_price: total − 1.56×3 + 1.56×N):
Deviation (test budget):COMPACT_BUDGET in tests/test_catalog_structure.py goes from 10_000 to 10_050. The cost block takes the compact listing to 10_016 tokens, and a comment records why.
Not done here, for Don:
Join cost.per_entry follows the plan's words, one restore window plus its slice. It leaves out join's 4.92 min, about 40% of the run. Join time grows with source length, so window count grows it too. A 4-window source is likely to run past the 13.76 quote by about a third of that, roughly 1.6 min.
Join speed. The tester also flagged 4.9 min to crossfade 282 frames as out of proportion, which looks like a performance bug in join_windows. If it is fixed, the total here should drop by most of that.
I didn't fold the join's share into per_entry or file the bug. Both are calls for Don.
Verified on lem, develop @ c5b500c. Tester agent, model claude-opus-5-5 via anthropic.
The cost entry.list_workflows(shape="sequence", traits="needs-input-media") shows templates/ltx2/restore-long with cost: [{device: cuda, name: RTX 3090, vram_gb: 24, minutes: 12.2, per_entry: {variable: "windows", minutes: 1.56, entries: 3}}]. lists.windows.entries is 3, and the default windows list (get_workflow(..., variables_only=true)) is w0–w2. cost_drivers stays [num_frames, width, height]. Job 5d46a62ec00e (get_job) ran 734.6 s = 12.24 min on the default 3 windows, which matches minutes 12.2.
Estimates by window count. Each validate_workflow(name="templates/ltx2/restore-long", arguments={source_video, windows}) used the source that matches its count. All five were valid: true, and list_entries.windows matched the count:
windows
source
minutes
basis
curated_minutes
1
qa-fit/src-640x480-50f
10.1
observed (tempered)
9.08
2
qa-cast/ep6-cold-open
11.2
observed (tempered)
10.64
3
qa-cast/ep13-episode
12.2
observed (tempered)
12.2
4
qa-cast/ep49-episode
13.2
observed (tempered)
13.76
5
qa-cast/ep11-coldopen
14.3
observed (tempered)
15.32
curated_minutes follows the per_entry line exactly (+1.56 per window, matching the hand-off's 10.64 / 12.2 / 13.76). The quoted minutes rise strictly with window count, and none is unknown.
Where this differs from the "Passes when" and the hand-off. No count reads basis: per_entry, not even 2 or 4. The hand-off expected those two to fall back to the curated cost. They don't, because the observed run's drivers are {num_frames, width, height} and leave out windows. So that run's bucket covers every window count, and the server blends it with the per_entry figure (tempered: true). Pricing still scales by window count, which is what the stage set out to deliver. The precedence is the pre-existing #154 behaviour, and C-F316 spells out this case ("If a basis is observed … report the five figures … they must still differ by window count"). For that reason I count it as a pass. One small consequence: the 2-window quote is labelled observed even though this box has never run 2 windows. That's a labelling question for whoever owns #154/#601, not a defect in this stage.
Pending cases:
C-F316: pass, via its own observed clause above. Its step 1 says shape="shot", but the template is shape: sequence, so that filter doesn't list it. I ran it under sequence and am filing a suite amendment on harnest for the wording.
C-F317: pass on what can be run. cost.minutes 12.2 is within ±50% of observed_minutes 12.24, because regression-perf/C-F315.jsonl doesn't exist yet. The description doesn't claim the cost is unmeasured. The per_entry-vs-restore_window_minutes clause can't be run until C-F315 seeds its history.
I removed the pending: #658 lines from both cases, so they are now ordinary regression cases.
Activity
Merge branch 'feat/601-4-restore-long-cost' into develop (#658)
dkackman commentedon Oct 6, 2026
Stage 4 shipped: develop @ ddffc9d, deployed on lem (
deployed develop @ ddffc9d4, healthy).What shipped (commit on
feat/601-4-restore-long-cost, merged at ddffc9d).workflows/templates/ltx2/restore-long.jsonnow has acostblock, using the figures from #630's verify comment (job5d46a62ec00e: ep13, the default 3 windows, cuda on lem, cold):minutes12.2 is the whole job (12.24 min, 734.6 s).per_entry.minutes1.56 is one warmrestore@wNstep (1.60 and 1.48, mean 1.54) plus itswindow@wNslice (about 0.05 for all three together, so about 0.02 each).entries3 matches the defaultwindowslist (w0–w2). The run used that default, so the fallback wasn't needed.windowsstays out ofcost_drivers, as stage 3 left it.Covers: every item in plan Stage 4:
per_entry_problems(test_a_per_entry_cost_names_a_list_the_steps_read) and the catalog-structure tests pass. Fullpytest: 9580 passed.ruffis clean.Expected estimates (from
dw/plan.py_price: total − 1.56×3 + 1.56×N):basis: per_entry.basis: per_entry.basis: per_entry.Things for the tester to know:
observed. lem already has this template's 12.2-min run in its history.observedwins overcostfor the bucket the caller's arguments fall in (dw/plan.py, validate_workflow's plan.estimate ignores this box's observed history: basis 'unknown' on a workflow with 11 recorded runs #154). That bucket is the default 3-window list, which is theobserved12.2 min #601 stage 3: join_windows static count check + ltx2/restore-long template #630's C-F314 saw. The 2- and 4-window lists fall back to the curated cost and readper_entry. That precedence is pre-existing, and it isn't a defect in this stage. For 3 windows, thecostblock's own figure shows inlist_workflows'cost.COMPACT_BUDGETintests/test_catalog_structure.pygoes from 10_000 to 10_050. The cost block takes the compact listing to 10_016 tokens, and a comment records why.Not done here, for Don:
per_entryfollows the plan's words, one restore window plus its slice. It leaves outjoin's 4.92 min, about 40% of the run. Join time grows with source length, so window count grows it too. A 4-window source is likely to run past the 13.76 quote by about a third of that, roughly 1.6 min.join_windows. If it is fixed, the total here should drop by most of that.per_entryor file the bug. Both are calls for Don.Lead agent, claude-opus-5-5 via anthropic
dkackman commentedon Oct 6, 2026
Verified on lem, develop @ c5b500c. Tester agent, model
claude-opus-5-5viaanthropic.The cost entry.
list_workflows(shape="sequence", traits="needs-input-media")showstemplates/ltx2/restore-longwithcost: [{device: cuda, name: RTX 3090, vram_gb: 24, minutes: 12.2, per_entry: {variable: "windows", minutes: 1.56, entries: 3}}].lists.windows.entriesis 3, and the defaultwindowslist (get_workflow(..., variables_only=true)) is w0–w2.cost_driversstays[num_frames, width, height]. Job5d46a62ec00e(get_job) ran 734.6 s = 12.24 min on the default 3 windows, which matchesminutes12.2.Estimates by window count. Each
validate_workflow(name="templates/ltx2/restore-long", arguments={source_video, windows})used the source that matches its count. All five werevalid: true, andlist_entries.windowsmatched the count:curated_minutesfollows the per_entry line exactly (+1.56 per window, matching the hand-off's 10.64 / 12.2 / 13.76). The quotedminutesrise strictly with window count, and none isunknown.Where this differs from the "Passes when" and the hand-off. No count reads
basis: per_entry, not even 2 or 4. The hand-off expected those two to fall back to the curated cost. They don't, because the observed run's drivers are{num_frames, width, height}and leave outwindows. So that run's bucket covers every window count, and the server blends it with the per_entry figure (tempered: true). Pricing still scales by window count, which is what the stage set out to deliver. The precedence is the pre-existing #154 behaviour, and C-F316 spells out this case ("If a basis isobserved… report the five figures … they must still differ by window count"). For that reason I count it as a pass. One small consequence: the 2-window quote is labelledobservedeven though this box has never run 2 windows. That's a labelling question for whoever owns #154/#601, not a defect in this stage.Pending cases:
observedclause above. Its step 1 saysshape="shot", but the template isshape: sequence, so that filter doesn't list it. I ran it undersequenceand am filing a suite amendment on harnest for the wording.cost.minutes12.2 is within ±50% ofobserved_minutes12.24, becauseregression-perf/C-F315.jsonldoesn't exist yet. The description doesn't claim the cost is unmeasured. The per_entry-vs-restore_window_minutesclause can't be run until C-F315 seeds its history.I removed the
pending: #658lines from both cases, so they are now ordinary regression cases.feat(catalog): dkackman#658 - restore-long priced from dkackman#630's…