Skip to content

Comments

feat: model dropdown now uses server-side filtering#213

Merged
IonesioJunior merged 1 commit intomainfrom
fix-model-dropdown-server-side-filter
Feb 18, 2026
Merged

feat: model dropdown now uses server-side filtering#213
IonesioJunior merged 1 commit intomainfrom
fix-model-dropdown-server-side-filter

Conversation

@IonesioJunior
Copy link
Member

Summary

  • Model dropdown (and data source selection) now correctly shows endpoints even when one type dominates the list
  • Previously, getChatModels() and getChatDataSources() used client-side filtering after fetching mixed endpoint lists, causing empty results when 100+ data sources filled the page limit
  • SDK's browse() and trending() methods now support endpointType parameter for server-side filtering
  • Frontend functions updated to pass endpoint_type to the SDK, which forwards it to the backend API

Modified Files

  • sdk/typescript/src/resources/hub.ts — Added endpointType to BrowseOptions and TrendingOptions interfaces; updated browse() and trending() methods to pass endpoint_type query parameter to backend
  • components/frontend/src/lib/endpoint-utils.ts — Updated getPublicEndpoints() and getTrendingEndpoints() to use server-side filtering via SDK instead of client-side filtering

Test plan

  • Build TypeScript SDK successfully
  • Verify model dropdown shows models even when data sources dominate the endpoint list
  • Verify data source dropdown shows data sources correctly
  • Check that filtering works correctly for both browse() and trending() SDK methods

🤖 Generated with Claude Code

…ts and getTrendingEndpoints, and extend HubResource to support endpointType filter
@IonesioJunior IonesioJunior merged commit 62467bf into main Feb 18, 2026
21 checks passed
@IonesioJunior IonesioJunior deleted the fix-model-dropdown-server-side-filter branch February 18, 2026 20:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant