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
feat(machinery): allow base_url of OpenAI to be customized #11467
base: main
Are you sure you want to change the base?
feat(machinery): allow base_url of OpenAI to be customized #11467
Conversation
Allows usage of local LLMs or other providers
Can you please add documentation which other providers or local LLM work with the OpenAI API and how to configure these? |
Co-authored-by: Michal Čihař <michal@cihar.com>
for more information, see https://pre-commit.ci
widget=forms.Textarea, | ||
help_text=gettext_lazy("Base URL of the OpenAI API"), | ||
required=False, | ||
default=None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TypeError: Field.init() got an unexpected keyword argument 'default'
See https://github.com/WeblateOrg/weblate/actions/runs/8800026958/job/24150336022?pr=11467
Seriously, has this been tested?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nijel No, I just pushed it to see the pipeline! Not ready for review! I should have marked it as a draft!
Thanks for the fast review though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I recommend testing locally first against real custom API endpoint. The model selection will need to be changed for custom LLMs as well.
Allows usage of local LLMs or other providers
Proposed changes
Adds a new field when setting up the OpenAI integration to allow the user to add a custom base_url
Checklist
Other information