danny-avila / LibreChat

Enhanced ChatGPT Clone: Features Anthropic, AWS, OpenAI, Assistants API, Azure, Groq, o1, GPT-4o, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, langchain, DALL-E-3, ChatGPT Plugins, OpenAI Functions, Secure Multi-User System, Presets, completely open-source for self-hosting. Actively in public development.
https://librechat.ai/
MIT License
19.34k stars 3.23k forks source link

[Bug]: maxContextTokens in Agents is not correctly set when the model != deploymentName #4700

Open peeeteeer opened 1 week ago

peeeteeer commented 1 week ago

What happened?

in our case the model configuration in the librechat.yaml file is using the the deploymentName parameter. The model name (e.g. gpt-4o) is not equal the deploymentName. With this when commuicating with an Agent the maxContextTokens is not defined and results in an error.

Steps to Reproduce

  1. name a deployment of a model different than the model name
  2. set the deploymentName in the librechat.yaml
  3. use it in an Agent

What browsers are you seeing the problem on?

No response

Relevant log output

No response

Screenshots

I'm new to js - but this change e.g. fixes the issue - but I'm actually not sure if it is the right thing to do...

image

Code of Conduct