aider icon indicating copy to clipboard operation
aider copied to clipboard

Adding keys in config files for other LLM providers.

Open PrashamTrivedi opened this issue 2 years ago • 2 comments

Issue

First of all, Thanks a lot for aider. And specially for the latest version which enables us to talk with multiple models.

Based on updated description and checking main.py. I have found out that the tool only supports OpenAI and Anthropic keys to be set in ~/.aider.conf.yml. I was checking if we can add keys for other providers, mainly Gemini and Command+R in Config file and check it from there.

I am planning to create a PR, but before I do that, I want to know is there any specific reason why it shouldn't be done? Thanks again...

Version and model info

Aider v0.30.1
Models: gpt-4-1106-preview with udiff edit format, weak model gpt-3.5-turbo
Git repo: .git with 156 files
Repo-map: using 1024 tokens

PrashamTrivedi avatar Apr 29 '24 06:04 PrashamTrivedi

Thanks for trying aider and filing this issue. Aider supports a .env file to pick up environment variables with model keys and other settings. Hopefully that should meet your needs?

paul-gauthier avatar Apr 29 '24 14:04 paul-gauthier

Here are some brief docs about the .env file:

https://aider.chat/docs/llms.html#using-a-env-file

paul-gauthier avatar Apr 29 '24 20:04 paul-gauthier

That satisfies all the requirements. Hence Closing the comment. Thanks

PrashamTrivedi avatar Apr 30 '24 07:04 PrashamTrivedi