Repository navigation
Studio: improve memory estimate spacing, alignment, and guidance - #10591
danielhanchen merged 19 commits into
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
@codex review |
|
Codex Review: Didn't find any major issues. 👍 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
@codex review |
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
@codex review |
|
Codex Review: Didn't find any major issues. 👍 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
The value pill was 92px to match the numeric inputs beside it, but those right-align their contents while this one centres, so the fixed width read as padding around the number rather than alignment. Narrow it to 80px and trim the surrounding gaps; the row is justify-between, so the right edges still line up with the Auto and dtype controls.
These verdicts are measured against what is FREE right now, not against capacity, but the copy said only "Memory is tight". On a 64 GB machine holding a 25 GB load that reads as false, and the note never said which memory it meant. Name the pool and the fact that it fits, so the reading is about the moment rather than the machine. Not "does not fit what is free": pressure starts at 85% of free, where the load does still fit, and the existing guard on that wording stays green.
Studio unloads the resident model before the replacement allocates, so the memory it holds returns to the pool first. The free-memory verdicts charged it anyway, which counted a model against itself: opening Run settings for the model already loaded warned that its footprint would not fit the memory that same footprint was occupying. On a 64 GB Mac a 25.61 GiB load saw 25.53 GiB free and read as exceeding it. Price the resident copy at the settings it loaded with and credit it to the free-memory questions. Capacity is untouched, since unloading frees memory rather than adding any, and growth over what comes back still warns. Only settled estimates are credited, so a stale price cannot silence a real warning. Reloading the same model somewhere else is unaffected: switching to a DIFFERENT model still charges the outgoing one, which needs the resident footprint from the backend.
|
Pushed three commits after testing this on a 64 GB M-series machine. Spacing. The value box was 92 px to match the numeric inputs beside it, but those right-align their contents while this one centers, so the fixed width read as padding around the number rather than alignment. Narrowed to 80 px and trimmed the gap above the figures. The row is "Memory is tight" was misleading. With a 25.61 GiB load on a 64 GB machine the panel said memory was tight. The verdict is measured against free memory rather than capacity, so it was not wrong about the number, but the note never said which memory it meant and reads as false next to a 64 GB machine. Each pressure note now names its pool. Kept the wording off "does not fit what is free" on purpose: pressure starts at 85% of free, where the load does still fit, so the absolute claim would be wrong in that band. The existing test guarding that phrasing catches it. The bigger one: a reload was charged for its own resident copy. The reason the warning fired at all was that the model was already loaded. Its 25.61 GiB was counted as used, leaving 25.53 GiB free, so the estimate came out at ratio 1.003 against memory its own resident copy was holding. Studio unloads before it reloads, so those bytes come back before the new load allocates. The panel was warning about a state that cannot exist at load time.
Two things left open:
7,140 tests pass, 7 of them new. Type check, build, bundle budget, and translation parity all pass, and Biome is unchanged from the previous head. |
The margin was already down to 2px; the rest of the space came from the heading row's own min-height rather than from spacing between the rows. Drop the margin and take the row to 28px. It stays full-width clickable, so the disclosure target is unaffected.
|
@codex review |
|
@codex review |
|
@codex review |
|
Confirmed the free-memory verdicts in studio/frontend/src/features/model-picker/model-config/memory-fit.ts still charge a reload for the resident copy Studio unloads first, so the credit is the part I want. The spacing, tooltip and guidance rewrites ride along in the same branch though; could you split those out so the fit change can be reviewed on its own? |
|
You have reached your Codex usage limits for security reviews. Please try again later. |
|
@codex review |
|
You have reached your Codex usage limits for security reviews. Please try again later. |
# Conflicts: # studio/frontend/src/features/model-picker/components/model-config-page.tsx
|
You have reached your Codex usage limits for security reviews. Please try again later. |
1 similar comment
|
You have reached your Codex usage limits for security reviews. Please try again later. |
|
@codex review |
|
You have reached your Codex usage limits for security reviews. Please try again later. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 28d4d0fb3e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| return { | ||
| tone: "warn", | ||
| text: "More than this GPU holds. Layers will spill to system RAM, or the context will be fitted down to what fits.", | ||
| text: "Exceeds GPU memory. Try Auto context or fewer GPU layers; loading may still fail.", |
There was a problem hiding this comment.
Avoid offloading GPU overflow into pressured RAM
When the GPU footprint exceeds physical VRAM while the host share also exceeds currently usable RAM, this branch wins before the hostPressured check and recommends fewer GPU layers. For example, a 30 GiB GPU share plus 5 GiB host share on a 24 GiB GPU with only 2 GiB usable RAM reaches this text, but moving the GPU overage into RAM worsens the host shortfall and may cause the load to be refused. Condition this placement advice on spare host availability, or use guidance that reduces overall demand when both pools are pressured.
Useful? React with 👍 / 👎.
|
You have reached your Codex usage limits for security reviews. Please try again later. |
1 similar comment
|
You have reached your Codex usage limits for security reviews. Please try again later. |
|
You have reached your Codex usage limits for security reviews. Please try again later. |
1 similar comment
|
You have reached your Codex usage limits for security reviews. Please try again later. |
|
@codex review |
|
You have reached your Codex usage limits for security reviews. Please try again later. |
|
Codex Review: Didn't find any major issues. Delightful! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
a2288be
into
shimmyshimmer/resident-memory-fit
Estimated Memory Usage crowded its heading, values, and breakdown into a small area. Give the heading its own row and align the memory figures with the neighboring settings in both the model picker and sidebar run settings.
Memory accounting is reviewed separately in #10627. This PR targets its branch so the diff contains only the UI, guidance, and their tests. Merge #10627 first, then retarget this PR to
main.Validation: Nine targeted pressure and guidance regressions pass, including GPU overflow with pressured RAM and host overflow with pressured VRAM. Earlier RAM-only and lower-bound checks also pass. Application and test type checking pass. Earlier browser checks covered narrow and wide panels, enlarged text, light and dark themes, and keyboard tooltips. No CI or full suites were awaited.