aider

aider is a terminal-based AI pair-programming tool that can edit files in your local git repo. It connects to any OpenAI-compatible endpoint via environment variables.

Installation

Install

python -m pip install aider-install
aider-install

Quick start

Set your environment variables and run aider:

Quick start

export OPENAI_API_BASE=https://api.modelbridge.dev/v1
export OPENAI_API_KEY=mb_live_your_key_here

cd /your/project
aider --model openai/claude-sonnet-4-6

Persistent configuration

Shell profile

Add to ~/.zshrc or ~/.bashrc:

Shell profile

export OPENAI_API_BASE=https://api.modelbridge.dev/v1
export OPENAI_API_KEY=mb_live_your_key_here

YAML config file

Create ~/.aider.conf.yml (global) or .aider.conf.yml (per-project):

.aider.conf.yml

openai-api-base: https://api.modelbridge.dev/v1
openai-api-key: mb_live_your_key_here
model: openai/claude-sonnet-4-6

CLI flags

You can also pass credentials directly:

CLI flags

aider \
  --openai-api-base https://api.modelbridge.dev/v1 \
  --openai-api-key mb_live_your_key_here \
  --model openai/claude-sonnet-4-6

Tips

  • aider may show warnings for models it doesn't recognize by name -- these are safe to ignore
  • If aider doesn't recognize your model's capabilities, you may need to specify the edit format manually with --edit-format
  • aider supports both streaming and non-streaming modes. ModelBridge handles both.
  • For large codebases, consider using a faster model like claude-sonnet-4-6 for the initial repo mapping

Was this page helpful?