Update chat-plugin to support model-proxy #101
Merged
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.
This pull request refactors the chat plugin to simplify model selection and API interactions by removing job-based model fetching and related state. The code now fetches all available models directly from a unified model proxy endpoint, eliminating the need for job management logic. This streamlines the user interface and backend logic, making the codebase easier to maintain and understand.
Major refactoring and simplification:
Jobtype, job selection UI, and associated API calls. The application no longer fetches or manages jobs, focusing solely on model selection. [1] [2] [3] [4] [5] [6] [7]API and state management changes:
fetchModelsInCurrentJob) with a newfetchAllModelsfunction that retrieves all models from a single model proxy endpoint, updating related API calls and state accordingly. [1] [2]Component and prop updates:
Appcomponent and plugin initialization to remove job server and token props, reflecting the new simplified model. [1] [2] [3]These changes collectively result in a cleaner, more maintainable codebase focused on direct model selection without the complexity of job management.