feat: Integrate Helicone into Aider
This pull request adds comprehensive support for the Helicone AI gateway and public model registry to the codebase. Helicone is now treated as a first-class provider: models can be addressed via the helicone/<model-id> syntax, model metadata is fetched and cached locally, API key requirements are handled, and requests are routed through the Helicone gateway automatically. Documentation has been updated to explain Helicone usage, and new tests ensure correct error handling and integration.
Helicone gateway and registry support:
- Added
aider/helicone.py, which implements a local cache and lookup for the Helicone public model registry via the newHeliconeModelManagerclass. This provides model metadata for anyhelicone/<model-id>and exposes a list of available models. - Integrated Helicone support throughout
aider/models.py: model info lookup, environment validation forHELICONE_API_KEY, request routing via Helicone gateway, normalization for rule matching, and fuzzy model matching now all support Helicone models. [1] [2] [3] [4] [5] [6] [7]
Error handling and testing:
- Improved error handling for Helicone gateway outages in
aider/exceptions.py, mirroring OpenRouter handling. Added tests for Helicone error detection and live registry fetching, as well as environment validation for API key presence. [1] [2] [3] [4]
Documentation updates:
- Added a new Helicone documentation page and updated existing docs to describe Helicone usage, API key setup, and model addressing. Tips for using Helicone with OpenAI, xAI, DeepSeek, and Anthropic have been added. [1] [2] [3] [4] [5] [6] [7]
Dependency updates:
- Updated the
blackcode formatter in.pre-commit-config.yamlto version 24.10.0.
@paul-gauthier
any chance we can get this merged?
or any changes i should make?
thanks!!