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: GoogleClient Context Handling & GenAI Parameters #5503

Merged
merged 12 commits into from
Jan 27, 2025

Conversation

danny-avila
Copy link
Owner

Summary

  • Enhanced token usage tracking logic and recorded usage metadata for VertexAI and GenAI models.
  • Consolidated initialization logic and removed legacy or unused methods.
  • Improved context handling by adjusting the prompt prefix and refining the token counting method.
  • Streamlined the DynamicInput component to correctly handle numeric input values.
  • Fixed model parameter handling for GenAI and removed extraneous code references.

Change Type

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

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
  • I have written tests demonstrating that my changes are effective or that my feature works
  • Local unit tests pass with my changes
  • Any changes dependent on mine have been merged and published in downstream modules.

@danny-avila danny-avila linked an issue Jan 27, 2025 that may be closed by this pull request
1 task
@danny-avila danny-avila merged commit 528ee62 into main Jan 27, 2025
4 checks passed
@danny-avila danny-avila deleted the fix/google-params branch January 27, 2025 17:21
justinmdickey pushed a commit to e-gineering/LibreChat that referenced this pull request Jan 30, 2025
…5503)

* fix: remove legacy code for GoogleClient and fix model parameters for GenAI

* refactor: streamline client init logic

* refactor: remove legacy vertex clients, WIP remote vertex token count

* refactor: enhance GoogleClient with improved type definitions and streamline token count method

* refactor: remove unused methods and consolidate methods

* refactor: remove examples

* refactor: improve input handling logic in DynamicInput component

* refactor: enhance GoogleClient with token usage tracking and context handling improvements

* refactor: update GoogleClient to support 'learnlm' model and streamline model checks

* refactor: remove unused text model handling in GoogleClient

* refactor: record token usage for GoogleClient titles and handle edge cases

* chore: remove unused undici, addresses verbose version warning
justinmdickey pushed a commit to e-gineering/LibreChat that referenced this pull request Feb 7, 2025
…5503)

* fix: remove legacy code for GoogleClient and fix model parameters for GenAI

* refactor: streamline client init logic

* refactor: remove legacy vertex clients, WIP remote vertex token count

* refactor: enhance GoogleClient with improved type definitions and streamline token count method

* refactor: remove unused methods and consolidate methods

* refactor: remove examples

* refactor: improve input handling logic in DynamicInput component

* refactor: enhance GoogleClient with token usage tracking and context handling improvements

* refactor: update GoogleClient to support 'learnlm' model and streamline model checks

* refactor: remove unused text model handling in GoogleClient

* refactor: record token usage for GoogleClient titles and handle edge cases

* chore: remove unused undici, addresses verbose version warning
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.

[Bug]: Max Output Tokens doesn't work for Gemini
1 participant