-
Notifications
You must be signed in to change notification settings - Fork 184
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
Instructions for adding to the list of Gemini models #529
base: master
Are you sure you want to change the base?
Conversation
Thanks for the PR! The model metadata specification method you've used is incorrect, as you need to provide (setf (gptel-backend-models gptel-backend)
(append
(gptel--process-models '((gemini-2.0-flash-thinking-exp
:context-window 32
...)))
(gptel-backend-models gptel-backend))) where the active As you can see, this method is also quite complicated, and requires the use of an internal function The simplest way to do this is to just push a model onto the model list. i.e. you can do this: (push 'gemini-2.0-flash-thinking-exp (gptel-backend-models gptel-backend)) where the active This works for all backends, so can we turn this PR into a generic section of the README that doesn't pertain to any backend? Here's what I'm picturing:
In addition to this section, we can add an FAQ entry that links to it. |
Good catch! So dumb of me to miss that. In trying to remove my API key, I overlooked passing I got an error when I initially tried these instructions. I added this to my
This however, worked.
So maybe we change the part about "Obtain a reference to the backend..."? I updated the PR with your suggestions and this modification:
LMK what you think |
Thanks for the update. I think gptel needs a better way to update backend attributes (like the model). The process of obtaining a reference to the backend is going to confuse users. Let me think about this some more. If you have any ideas for how this can be made more user-friendly, let me know. |
@jlcheng I've added a helper, (gptel-get-backend "Gemini") ;Returns the Gemini backend So you can add to its models like this: (push 'gemini-2.0-flash-thinking-exp
(gptel-backend-models (gptel-get-backend "Gemini"))) or modify other attributes: (setf (gptel-backend-host (gptel-get-backend "Gemini")) ...) I think the instructions in this PR can be made simpler now? |
No description provided.