Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 fix: Ensure Default ModelSpecs Are Set Correctly #5218

Merged
merged 8 commits into from
Jan 9, 2025

Conversation

danny-avila
Copy link
Owner

@danny-avila danny-avila commented Jan 8, 2025

Summary

Relevant documentation updates: LibreChat-AI/librechat.ai#197

I fixed an issue where default model specifications (modelSpecs) were not being set correctly when there was no default preset, which caused problems during app startup for users without a preset spec. Additionally, I updated type definitions related to user plugins and incremented the data-provider package version.

  • Updated the logic in useAppStartup.ts to set default modelSpecs when defaultPreset is not available.
  • Removed the unused import of fakeData from useAppStartup.ts.
  • Updated the TUser type in data-provider to make the plugins field optional.
  • Bumped the librechat-data-provider package version from 0.7.691 to 0.7.692 in package.json.
  • Fixed the "Save & Submit" functionality for the Google endpoint when editing messages by adjusting the disabled condition in EditMessage.tsx.
  • Modified tConversationSchema to make endpointType nullable and optional for improved flexibility.
  • Added endpointType to getSaveOptions in GoogleClient.js and enhanced endpoint handling in the Settings component.
  • Added the append_current_datetime parameter to tQueryParamsSchema to improve endpoint functionality.
  • Refactored configuration schemas and types for improved structure and clarity, affecting several files in the data provider.
  • Implemented the processModelSpecs function to enhance model specs processing from configuration.
  • Added imageDetail parameter for OpenAI endpoints in tQueryParamsSchema for better image processing options.
  • Fixed a bug where default modelSpecs were not being set during application startup.

Change Type

  • Bug fix (non-breaking change which fixes an issue)

Testing

I tested these changes by running the application locally and verifying that default modelSpecs are correctly set for users without a preset spec. I also tested the app startup process to ensure that the app title and available plugins are configured as expected, and that there are no regressions for existing users.

Checklist

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • I have commented in any complex areas of my code
  • I have made pertinent documentation changes
  • My changes do not introduce new warnings
  • Local unit tests pass with my changes

@danny-avila danny-avila linked an issue Jan 8, 2025 that may be closed by this pull request
1 task
@xhejtman
Copy link

xhejtman commented Jan 8, 2025

Followed from the closed #5213 if I set endpoint Ollama instead of the custom, I got error, that Ollama is unknown and that only custom, openai etc can be set as an endpoint. Thanks

@danny-avila
Copy link
Owner Author

danny-avila commented Jan 8, 2025

Followed from the closed #5213 if I set endpoint Ollama instead of the custom, I got error, that Ollama is unknown and that only custom, openai etc can be set as an endpoint. Thanks

thanks I'm aware and resolving this here

@danny-avila danny-avila merged commit 69a9b8b into main Jan 9, 2025
4 checks passed
@danny-avila danny-avila deleted the fix/default-modelspecs branch January 9, 2025 02:57
owengo pushed a commit to openwengo/LibreChat that referenced this pull request Jan 21, 2025
* 🐛 fix: default modelSpecs not being set

* feat: Add imageDetail parameter for OpenAI endpoints in tQueryParamsSchema

* feat: Implement processModelSpecs function to enhance model specs processing from configuration

* feat: Refactor configuration schemas and types for improved structure and clarity

* feat: Add append_current_datetime parameter to tQueryParamsSchema for enhanced endpoint functionality

* fix: Add endpointType to getSaveOptions and enhance endpoint handling in Settings component

* fix: Change endpointType to be nullable and optional in tConversationSchema for improved flexibility

* fix: allow save & submit for google endpoint
lpirola pushed a commit to lpirola/LibreChat that referenced this pull request Jan 22, 2025
* 🐛 fix: default modelSpecs not being set

* feat: Add imageDetail parameter for OpenAI endpoints in tQueryParamsSchema

* feat: Implement processModelSpecs function to enhance model specs processing from configuration

* feat: Refactor configuration schemas and types for improved structure and clarity

* feat: Add append_current_datetime parameter to tQueryParamsSchema for enhanced endpoint functionality

* fix: Add endpointType to getSaveOptions and enhance endpoint handling in Settings component

* fix: Change endpointType to be nullable and optional in tConversationSchema for improved flexibility

* fix: allow save & submit for google endpoint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants