feat(tui): set up cloud while the model downloads, and see the pull anywhere - #227
Open
plombeer31 wants to merge 3 commits into
Open
feat(tui): set up cloud while the model downloads, and see the pull anywhere#227plombeer31 wants to merge 3 commits into
plombeer31 wants to merge 3 commits into
Conversation
…nywhere A local first run parks the operator in front of a 2.7–22 GB progress bar with nothing to do. The download is owned by a session-scoped orchestrator, so nothing about it needs that screen — but it was only ever drawn inside the LLM panel, so leaving meant losing sight of it. Three things: - The download screen carries an accent-marked offer: press `c` to set up a cloud model in the meantime. The pull is not paused or restarted; it keeps running while the wizard is up. - Finishing that wizard while the pull is still going asks the operator the only question left — start using the agent now, or wait here. Jumping is the default row; the download does not need the screen. Backing out of the wizard returns to the download rather than to a backend choice that has already been made. - `DownloadChip` puts the pull in the status bar — the one row that is always on screen — so a transfer started during setup stays visible from the agent, with model, bar, percent and ETA. The embedding-offer suppression now covers the whole local branch, including the cloud detour, rather than just the download step.
The chip took ~50 columns unconditionally. On a 100-column terminal, with the brand lockup, the breadcrumb, the session tag and a session title already on that row, it did not fit — and Ink wraps rather than clips, so the one-row header would have become two and pushed the rail, the chat and the composer down the screen. Exactly the failure #221 fixes for the title. The chip now takes a column budget and sheds by rank, the same discipline `hotkey-hint` uses: ETA first, then the bar and the model name, then the chip itself below twelve columns. `StatusBar` computes what is left of the row after everything with a stronger claim to it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #226 → #225 → #224 → #223 → #222 → #220.
Why
A local first run leaves the operator in front of a 2.7–22 GB progress bar with nothing to do, and a cloud model takes about a minute to configure. The pull is owned by a session-scoped orchestrator — it does not need the screen that started it — but it was only ever drawn inside the LLM panel, so walking away from that tab meant a multi-gigabyte transfer running with nothing anywhere saying so.
Three changes
The offer. The download screen carries an accent-marked block:
Hidden when a cloud provider is already configured — nothing left to offer.
Wait or jump. Finishing that wizard while the pull is still running asks the only question left:
Jumping is the default row — waiting is a preference, not a requirement. If the pull already landed by the time the wizard closes, the flow finishes instead of asking a question with one answer. Backing out of the wizard returns to the download, not to a backend choice that has already been made.
The chip.
DownloadChiprenders the pull in the status bar — model, bar, percent, ETA — for as long as one is running, from any screen:Notes for review
resumeAfterCloudon the flow state is what distinguishes "cloud wizard from the choice screen" (finish) from "cloud wizard from a running download" (ask). It is cleared on both exits.localModelsPanel.pull !== null— state, not config, so it stays pure.use-typewriter.test.tsxgot a longer poll deadline: it waits on Ink frame commits, which slow down considerably under a full parallel run.Tests
Five reducer cases (open-with-memory, wait-or-jump on a live pull, finish when it already landed, back-out to the download, pull landing while wait-or-jump is up), plus
download-chip.test.tsx— one-row chip, runtime naming, both rows of wait-or-jump and its default cursor.Full suite: 5205 passed; the two long-standing failures are unchanged on
main.