Comments (7)
There are some docs which might be helpful:
https://aider.chat/docs/llms.html#azure
https://aider.chat/docs/llms.html#model-warnings
https://aider.chat/docs/llms.html#using-a-env-file
from aider.
Thanks Paul. Yes, I've reviewed those items, and did manage to get the alternative deployment name working in conjunction with the environmental variables. It does display a warning but proceeds regardless.
However, it doesnt address why we were previously able to execute against Azure without the environmental variables. If OPENAI_API_TYPE is set to "azure" then why do we still have to set those variables separately?
Just pointing out that it was working without them before.
from aider.
Aider recently added support for directly connecting to many LLM providers via the litellm package. This change required a shift to environment variables. I would recommend following the new docs about how to connect with Azure, but you're welcome to try and make it work a different way if you prefer.
from aider.
Thanks for confirming the change.
The .ENV method doesn't appear to work for multiple users; does the file require a specific name? I've tried simply ".env" myself as well as other file names, and another person reported the same.
Aider continues to complain that the environmental variables aren't set.
from aider.
You should create a .env
file in the directory where you run aider. I've tested this on my local and it works fine.
I just pushed a change to add a --env-file
param to aider, so you can explicitly tell it which file to load. By default it will look in the root of your git repo, in the same dir where you find the .git
directory. But you can override and have it load a specific file with --env-file <filename>
.
The change is available in the main branch. You can get it by installing the latest version from github:
python -m pip install --upgrade git+https://github.com/paul-gauthier/aider.git
If you have a chance to try it, let me know if it works better for you.
from aider.
I appreciate the feedback. I can only test on a Windows computer at the moment, but it's definitely not picking up my .env. See below. I'll test on the updated version when I can.
05/02/2024 12:56 PM
.05/01/2024 10:12 AM ..
05/02/2024 08:52 AM 34,417 .aider.chat.history.md
05/02/2024 08:49 AM 24 .aider.conf.yml
05/01/2024 01:30 PM 275 .aider.input.history
05/02/2024 08:49 AM 141 .env
05/01/2024 10:13 AM 108,459 aider.exe
more .env
AZURE_API_KEY=xxxx
AZURE_API_VERSION=2024-02-01
AZURE_API_BASE=xxx.openai.azure.com
aider
Aider v0.30.1
Newer version v0.31.1 is available. To upgrade, run:
C:\installdir\python.exe -m pip
install --upgrade aider-chat
Add .aider* to .gitignore (recommended)? n
**Model azure/test-model: Missing these environment variables:
- AZURE_API_BASE
- AZURE_API_VERSION
- AZURE_API_KEY**
from aider.
I'm going to close this issue for now, but feel free to add a comment here and I will re-open or file a new issue any time.
from aider.
Related Issues (20)
- completion always adds backticks HOT 1
- azure/gpt-4-turbo-vision-preview only returns a few tokens before returning 'The chat session is larger than the context window!' HOT 5
- Aider support for hosted LLM (LLM gateway endpoint) HOT 4
- Let aider grok and configure the environment and run commands autonomously HOT 2
- Add option to force the AI to ask the user to confirm each change before doing it HOT 1
- Add support for WebStorm
- Renaming/moving files HOT 1
- aider: error: unrecognized arguments HOT 2
- tests folder is imported as separate package HOT 1
- .NET: Add a support of auto-installing new NuGet package into the project or solution HOT 2
- Aider benchmark results on quantized Codeqwen-8B, Codestral-22B, Qwen2-72B HOT 1
- .NET: Linter runner doesn't work HOT 2
- Question / contributing test cases. HOT 1
- Feature request: giving aider an example PR or commit HOT 2
- Configure aider to always add specific files to the chat (eg, conventions file) HOT 2
- Ugly crash during startup when `~/.gitconfig` is missing [user] HOT 3
- Running --commit --dry-run should not actually make the commit HOT 1
- Add an option to skip SSL verification for users behind firewalls
- Suggestion: Multi Agent (Supervisor/Reviewer agent)
- Sublime Text (or rather Sublime Merge Support)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aider.