Configure and optimize Aider, an AI pair programming tool that edits your code through terminal chat. Supports multiple LLM providers, auto-commits, linting, testing, and repository mapping.
This skill has safety concerns that you should review before use. Some patterns were detected that may pose a risk.Safety score: 60/100.
KillerSkills scans all public content for safety. Use caution before installing or executing flagged content.
Configure and use Aider, a terminal-based AI pair programming tool that directly edits your code files through natural language chat. Supports multiple LLM providers, automatic git commits, linting, testing, and intelligent repository mapping.
This skill helps you set up and optimize Aider configuration files (`.aider.conf.yml`) for AI-assisted coding. Aider works with various AI models (OpenAI, Anthropic, Google, etc.) to edit code, generate commit messages, run tests, and maintain git repositories through conversational commands.
When a user requests Aider configuration or assistance:
1. **Assess Requirements**
- Ask what AI model/provider they prefer (Claude, GPT-4, DeepSeek, etc.)
- Determine if they need specific features: auto-commits, linting, testing, repo mapping
- Check if they want voice input, GUI mode, or terminal-only usage
- Identify their git workflow preferences
2. **Generate Configuration File**
- Create `.aider.conf.yml` in the project root or user's home directory
- Configure the main model and optional weak/editor models
- Set up API keys via environment variables (never hardcode keys)
- Enable/disable features based on requirements:
- `auto-commits`: Automatic git commits (default: true)
- `auto-lint`: Automatic linting after changes (default: true)
- `auto-test`: Automatic testing after changes (default: false)
- `map-tokens`: Repository map for context (suggest 2048-4096 for medium projects)
- `dark-mode` or `light-mode`: Terminal color scheme
3. **API Key Management**
- Store API keys in `.env` file, never in `.aider.conf.yml`
- Use `--set-env` or `--api-key` options for non-OpenAI/Anthropic providers
- Example `.env` entries:
```
OPENAI_API_KEY=sk-...
ANTHROPIC_API_KEY=sk-ant-...
DEEPSEEK_API_KEY=...
```
4. **Optimize Model Selection**
- **Main model**: Primary coding assistant (Claude 3.7 Sonnet, GPT-4o, DeepSeek Chat)
- **Weak model**: Commit messages & summarization (Claude Haiku, GPT-4o-mini)
- **Editor model**: Quick edits (can use same as main or lighter model)
- Consider cost vs. capability tradeoffs
5. **Git Integration Setup**
- Enable `gitignore: true` to auto-add `.aider*` files
- Set `attribute-author: true` to track Aider changes in git
- Configure `dirty-commits` behavior for uncommitted changes
- Set up `.aiderignore` for files to exclude from context
6. **Linting and Testing**
- Configure `lint-cmd` for each language:
```yaml
lint-cmd:
- "python: ruff check --fix"
- "javascript: eslint --fix"
- "typescript: eslint --fix"
```
- Set `test-cmd` for running tests: `pytest`, `npm test`, etc.
- Enable `auto-test: true` for continuous testing (high token usage warning)
7. **Repository Mapping**
- Set `map-tokens` based on project size:
- Small projects (<50 files): 1024-2048
- Medium projects: 2048-4096
- Large projects: 4096-8192
- Disable with `map-tokens: 0` if not needed
- Use `map-refresh: auto` (default) for optimal performance
8. **Advanced Features**
- **Architect mode**: Multi-file refactoring with `architect: true`
- **Voice input**: Set `voice-format`, `voice-language`, `voice-input-device`
- **GUI mode**: Enable `gui: true` for browser-based interface
- **Prompt caching**: Enable `cache-prompts: true` for supported models
- **Watch mode**: Enable `watch-files: true` for automatic change detection
9. **Common Workflows**
- **Initial setup**: `aider --model claude-3-7-sonnet --yes-always`
- **Lint and fix**: `aider --lint`
- **Run tests**: `aider --test`
- **Commit changes**: `aider --commit`
- **Specific files**: `aider --file src/main.py --read docs/spec.md`
10. **Provide Usage Examples**
```yaml
# Minimal configuration
model: anthropic/claude-3-7-sonnet-20250219
auto-commits: true
map-tokens: 2048
dark-mode: true
# Advanced configuration
model: anthropic/claude-3-7-sonnet-20250219
weak-model: claude-3-5-haiku-20241022
editor-model: claude-3-5-haiku-20241022
architect: true
auto-lint: true
lint-cmd:
- "python: ruff check --fix"
test-cmd: pytest
map-tokens: 4096
cache-prompts: true
dark-mode: true
```
1. **Python Project with Linting**
```yaml
model: anthropic/claude-3-7-sonnet-20250219
auto-commits: true
auto-lint: true
lint-cmd: "python: ruff check --fix"
map-tokens: 2048
```
2. **TypeScript Project with Testing**
```yaml
model: gpt-4o
weak-model: gpt-4o-mini
auto-commits: true
lint-cmd: "typescript: eslint --fix"
test-cmd: npm test
map-tokens: 4096
```
3. **Multi-Language Refactoring**
```yaml
model: anthropic/claude-3-7-sonnet-20250219
architect: true
auto-accept-architect: false
map-tokens: 8192
cache-prompts: true
```
When generating configurations, always explain the choices made and provide guidance on adjusting settings based on project needs and budget constraints.
Leave a review
No reviews yet. Be the first to review this skill!
# Download SKILL.md from killerskills.ai/api/skills/aider-ai-coding-assistant-i6gcqe/raw