Skip to content

[AI-3] List the cached models on the connection page - #24883

Open
tangopium wants to merge 1 commit into
feature/66020-pr04-model-records-sync-capabilitiesfrom
feature/66020-pr05-model-list-ui
Open

[AI-3] List the cached models on the connection page#24883
tangopium wants to merge 1 commit into
feature/66020-pr04-model-records-sync-capabilitiesfrom
feature/66020-pr05-model-list-ui

Conversation

@tangopium

@tangopium tangopium commented Aug 22, 2026

Copy link
Copy Markdown
Collaborator

Ticket

AI-3

What are you trying to accomplish?

PR 5 of 11 in the AI-3 stack. Renders the cached model catalogue on the connection page as a filterable, paginated table (a gateway can report hundreds of models). Rendering never contacts the server; the sub-header offers the explicit Refresh models action instead. Filtering matches identifier and friendly name, answers with a turbo stream so only the table is replaced, and works on a shared full-page link too.

Merge checklist

  • Added/updated tests
  • Behind the llm_connection feature flag

Stacked on #24882.

@github-actions

Copy link
Copy Markdown

Caution

The provided work package version does not match the core version

Details:

Please make sure that:

  • The work package version OR your pull request target branch is correct

@github-actions

Copy link
Copy Markdown

Caution

The Enterprise plan field is not set on the work package

Details:

Please make sure that:

  • The work package Enterprise plan field is set

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9a73a3ff1d

ℹ️ 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".

Comment thread app/components/llm_connections/models_table_component.rb
Comment thread app/controllers/admin/llm_connections_controller.rb Outdated
Comment thread app/views/admin/llm_connections/show.html.erb Outdated
@tangopium
tangopium force-pushed the feature/66020-pr05-model-list-ui branch from 9a73a3f to a511dde Compare August 22, 2026 15:05
@tangopium tangopium changed the title [#66020] List the cached models on the connection page [AI-3] List the cached models on the connection page Aug 22, 2026
@tangopium
tangopium force-pushed the feature/66020-pr05-model-list-ui branch from a511dde to 2ca5caa Compare August 22, 2026 15:26
@tangopium
tangopium force-pushed the feature/66020-pr05-model-list-ui branch from 2ca5caa to 9cf1036 Compare August 22, 2026 15:51
Renders the model catalogue as a filterable, paginated table below the connection form. Rendering never contacts the server: the list is read from the cached catalogue, and the sub-header offers the explicit Refresh models action instead. Filtering matches the identifier and the friendly name, answers with a turbo stream so only the table is replaced, and works on a shared full-page link too.

Part 5 of the AI-3 stack.

https://community.openproject.org/work_packages/66020
@github-actions

Copy link
Copy Markdown

Warning

Flaky specs

  • rspec ./spec/features/roles/report_spec.rb[1:3]
  • rspec ./spec/features/work_packages/table/switch_types_spec.rb[1:1:1]
  • rspec ./spec/features/work_packages/table/switch_types_spec.rb[1:1:2]
🤖 Ask Copilot to investigate

Copy the prompt below into a new comment on this PR to delegate the investigation to GitHub Copilot. It will look into the flakiness and open a separate pull request with you as reviewer.

@copilot The following spec(s) are flaky in CI (first seen on PR #24883, linked for reference only):

- `rspec ./spec/features/roles/report_spec.rb[1:3]`
- `rspec ./spec/features/work_packages/table/switch_types_spec.rb[1:1:1]`
- `rspec ./spec/features/work_packages/table/switch_types_spec.rb[1:1:2]`

Treat this as a standalone task, unrelated to PR #24883. Create a new branch from origin/dev and open a new pull request targeting dev — do not stack it on PR #24883 or reuse that branch.

Follow the playbook in docs/development/testing/handling-flaky-tests/README.md to find the root cause and fix the underlying race — do not skip, delete, or weaken the spec to make it pass; disabling is a last resort per the playbook, and only with a bug ticket. Verify the fix by running the spec(s) repeatedly (e.g. `script/bulk_run_rspec --run-count 10`).

If you cannot reproduce the flake or are not confident in a fix after reasonable investigation, do not fabricate a change or skip the spec to force CI green. Instead, leave the pull request in draft and document what you tried, the suspected cause, and any leads in its description, then assign @tangopium to take over.

Once the fix is verified, title the PR after the spec(s) it fixes, and use the PR description to explain the root cause, how the change resolves it, and the before/after results. Label the PR `flaky-spec`, assign @tangopium, and request a review from @tangopium.
On every commit, set @tangopium as the sole co-author with a `Co-authored-by:` trailer (use their GitHub no-reply email so it links to their account), so it is traceable who dispatched the fix.

@tangopium
tangopium force-pushed the feature/66020-pr05-model-list-ui branch from 9cf1036 to 5b4d9bf Compare August 22, 2026 16:16
@github-actions

Copy link
Copy Markdown

Warning

Flaky specs

  • rspec ./spec/features/work_packages/table/queries/parent_field_ranking_spec.rb[1:1]
  • rspec ./spec/features/work_packages/table/switch_types_spec.rb[1:1:2]
🤖 Ask Copilot to investigate

Copy the prompt below into a new comment on this PR to delegate the investigation to GitHub Copilot. It will look into the flakiness and open a separate pull request with you as reviewer.

@copilot The following spec(s) are flaky in CI (first seen on PR #24883, linked for reference only):

- `rspec ./spec/features/work_packages/table/queries/parent_field_ranking_spec.rb[1:1]`
- `rspec ./spec/features/work_packages/table/switch_types_spec.rb[1:1:2]`

Treat this as a standalone task, unrelated to PR #24883. Create a new branch from origin/dev and open a new pull request targeting dev — do not stack it on PR #24883 or reuse that branch.

Follow the playbook in docs/development/testing/handling-flaky-tests/README.md to find the root cause and fix the underlying race — do not skip, delete, or weaken the spec to make it pass; disabling is a last resort per the playbook, and only with a bug ticket. Verify the fix by running the spec(s) repeatedly (e.g. `script/bulk_run_rspec --run-count 10`).

If you cannot reproduce the flake or are not confident in a fix after reasonable investigation, do not fabricate a change or skip the spec to force CI green. Instead, leave the pull request in draft and document what you tried, the suspected cause, and any leads in its description, then assign @tangopium to take over.

Once the fix is verified, title the PR after the spec(s) it fixes, and use the PR description to explain the root cause, how the change resolves it, and the before/after results. Label the PR `flaky-spec`, assign @tangopium, and request a review from @tangopium.
On every commit, set @tangopium as the sole co-author with a `Co-authored-by:` trailer (use their GitHub no-reply email so it links to their account), so it is traceable who dispatched the fix.

@thykel thykel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👋 This one was heavily discussed in the UX feedback round -- I'd like to revisit it once the actual code changes are done, as they are likely to cut deep.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants