Repository navigation
PR3 of #136: cross-route model search - #222
Merged
Merged
Conversation
Final PR of the phased #136 sequence. The compact model control (footer [model] segment / Alt+C picker) now genuinely searches across every connected route instead of silently narrowing to whichever route happens to be active — the full-screen /connect and /model picker keeps its existing guided-browse scoping unchanged. - Split connect_model_open_impl's single current_profile_id parameter into "what marks a row current" vs "what seeds the initial search scope" — the compact control now starts unscoped by default. - Model search matches the vendor/route label text as well as the model id, case-insensitively (ModelItem gains a pre-resolved route_label, filled in once by TuiApp::model_picker_items via the existing vendor_route_labels helper). - A model offered by more than one connected route no longer gets silently auto-resolved (previously: prefer Live source, else first). Each route now renders as its own explicitly selectable row named by its route label, removing the "catalog quirk" auto-pick entirely. - The Models column's empty state distinguishes "no provider connected", "catalog still loading" (new catalog_loading flag, set/cleared around the existing background catalog-refresh machinery), "nothing cached yet", and "no matches for this filter" instead of two generic messages. - Added a regression test confirming a picker selection with an explicit route never crosses wires between openai (generic API key) and openai_codex (subscription/OAuth) even when both are connected.
This was referenced Aug 4, 2026
mohitranka
added a commit
that referenced
this pull request
Aug 21, 2026
Final PR of the phased #136 sequence. The compact model control (footer [model] segment / Alt+C picker) now genuinely searches across every connected route instead of silently narrowing to whichever route happens to be active — the full-screen /connect and /model picker keeps its existing guided-browse scoping unchanged. - Split connect_model_open_impl's single current_profile_id parameter into "what marks a row current" vs "what seeds the initial search scope" — the compact control now starts unscoped by default. - Model search matches the vendor/route label text as well as the model id, case-insensitively (ModelItem gains a pre-resolved route_label, filled in once by TuiApp::model_picker_items via the existing vendor_route_labels helper). - A model offered by more than one connected route no longer gets silently auto-resolved (previously: prefer Live source, else first). Each route now renders as its own explicitly selectable row named by its route label, removing the "catalog quirk" auto-pick entirely. - The Models column's empty state distinguishes "no provider connected", "catalog still loading" (new catalog_loading flag, set/cleared around the existing background catalog-refresh machinery), "nothing cached yet", and "no matches for this filter" instead of two generic messages. - Added a regression test confirming a picker selection with an explicit route never crosses wires between openai (generic API key) and openai_codex (subscription/OAuth) even when both are connected.
mohitranka
added a commit
that referenced
this pull request
Sep 11, 2026
Final PR of the phased #136 sequence. The compact model control (footer [model] segment / Alt+C picker) now genuinely searches across every connected route instead of silently narrowing to whichever route happens to be active — the full-screen /connect and /model picker keeps its existing guided-browse scoping unchanged. - Split connect_model_open_impl's single current_profile_id parameter into "what marks a row current" vs "what seeds the initial search scope" — the compact control now starts unscoped by default. - Model search matches the vendor/route label text as well as the model id, case-insensitively (ModelItem gains a pre-resolved route_label, filled in once by TuiApp::model_picker_items via the existing vendor_route_labels helper). - A model offered by more than one connected route no longer gets silently auto-resolved (previously: prefer Live source, else first). Each route now renders as its own explicitly selectable row named by its route label, removing the "catalog quirk" auto-pick entirely. - The Models column's empty state distinguishes "no provider connected", "catalog still loading" (new catalog_loading flag, set/cleared around the existing background catalog-refresh machinery), "nothing cached yet", and "no matches for this filter" instead of two generic messages. - Added a regression test confirming a picker selection with an explicit route never crosses wires between openai (generic API key) and openai_codex (subscription/OAuth) even when both are connected.
mohitranka
added a commit
that referenced
this pull request
Sep 11, 2026
Final PR of the phased #136 sequence. The compact model control (footer [model] segment / Alt+C picker) now genuinely searches across every connected route instead of silently narrowing to whichever route happens to be active — the full-screen /connect and /model picker keeps its existing guided-browse scoping unchanged. - Split connect_model_open_impl's single current_profile_id parameter into "what marks a row current" vs "what seeds the initial search scope" — the compact control now starts unscoped by default. - Model search matches the vendor/route label text as well as the model id, case-insensitively (ModelItem gains a pre-resolved route_label, filled in once by TuiApp::model_picker_items via the existing vendor_route_labels helper). - A model offered by more than one connected route no longer gets silently auto-resolved (previously: prefer Live source, else first). Each route now renders as its own explicitly selectable row named by its route label, removing the "catalog quirk" auto-pick entirely. - The Models column's empty state distinguishes "no provider connected", "catalog still loading" (new catalog_loading flag, set/cleared around the existing background catalog-refresh machinery), "nothing cached yet", and "no matches for this filter" instead of two generic messages. - Added a regression test confirming a picker selection with an explicit route never crosses wires between openai (generic API key) and openai_codex (subscription/OAuth) even when both are connected.
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.
Summary
Final PR of the phased #136 sequence (provider/model/effort picker redesign). PR1 (#215) added the persistent footer control; PR2 (#221) fixed zero-state onboarding correctness. PR3 covers issue #136's "Cross-route model search" section — specifically the compact model control (footer
[model]segment /Alt+C), which today does not actually search across routes despite the issue's explicit requirement.Three concrete gaps found and fixed:
selected_routeseeded from whatever profile was currently active, and a connected user almost always has one — so the "cross-route" control opened already narrowed to a single route. Split the constructor's overloadedcurrent_profile_idparameter (which conflated "what marks a row current" with "what seeds the search scope") so the compact control now starts unscoped by default. The full-screen/connect//modelpicker is unchanged — that's a deliberate guided browse, not "the model control."ModelItemgains a pre-resolvedroute_label("OpenAI" / "OpenAI · ChatGPT sign-in"), computed once via the existingvendor_route_labelshelper, and the matcher checks it alongside the model id, case-insensitively.CatalogSource::Liveelse the first route, with the code's own comment calling it a "catalog quirk." Replaced with explicit, individually-selectable rows: each route now renders as its own row named by its route label, so the choice is always unambiguous — no auto-pick logic left at all.Also: the Models column's empty state now distinguishes "no provider connected" / "catalog still loading" (new
catalog_loadingflag wired through the existing background-refresh machinery from PR1) / "nothing cached yet" / "no matches for this filter", instead of two generic messages. And a new regression test confirms a picker selection with an explicit route never crosses wires betweenopenai(generic API key) andopenai_codex(subscription/OAuth) even when both are connected simultaneously — atomicity was already correct structurally, this just locks it in.Test plan
cargo fmt --all -- --checkcargo clippy --workspace --all-targets --locked -- -D warningscargo test -p forge-tui --lib(739 passed)cargo test -p forge-connect --lib(184 passed)cargo test --workspace --all-targets --locked— all green except the same pre-existing, unrelatedforge-config::permissionsfailure documented in PR1/PR2 (this dev machine's real local config leaking into unisolated tests; zero diff to that crate).