feat(models): add Azure OpenAI provider + GOOGLE_API_KEY alias for Gemini

Resolves the only two open issues that still apply to the Rust build:
- #21 Azure OpenAI: new `azure` provider (OpenAI-compatible). Endpoint comes
  from AZURE_OPENAI_ENDPOINT, api-version from AZURE_OPENAI_API_VERSION
  (default 2024-10-21); the model name is the Azure deployment; auth uses the
  `api-key` header instead of Bearer. Use `--model azure:<deployment>`.
- #25 Gemini key confusion: GEMINI_API_KEY now also accepts GOOGLE_API_KEY
  (Google's standard env var) as an alias; local providers (ollama/litellm)
  require no key. .env.example documents both.

Kept under the v3.5.2 line (additive provider support).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
CyberSecurityUP
2026-06-26 14:17:25 -03:00
parent 761d3df444
commit d957429c09
3 changed files with 58 additions and 9 deletions
+8
View File
@@ -17,7 +17,15 @@ ANTHROPIC_API_KEY=
OPENAI_API_KEY=
# gemini: https://aistudio.google.com/app/apikey
# (GOOGLE_API_KEY is also accepted as an alias if GEMINI_API_KEY is unset)
GEMINI_API_KEY=
#GOOGLE_API_KEY=
# azure: Azure OpenAI (OpenAI-compatible). Use `--model azure:<deployment>`
# (the model name is your Azure *deployment* name).
#AZURE_OPENAI_API_KEY=
#AZURE_OPENAI_ENDPOINT=https://your-resource.openai.azure.com
#AZURE_OPENAI_API_VERSION=2024-10-21
# xai: https://console.x.ai/
XAI_API_KEY=