You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CLAUDE.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ Guidance for AI models (like Claude) working with this codebase.
4
4
5
5
## Project Overview
6
6
7
-
**GOModel** is a high-performance AI gateway in Go that routes requests to multiple AI model providers (OpenAI, Anthropic, Gemini, Groq, xAI, Ollama). LiteLLM killer.
7
+
**GOModel** is a high-performance AI gateway in Go that routes requests to multiple AI model providers (OpenAI, Anthropic, Gemini, Groq, xAI, Oracle, Ollama). LiteLLM killer.
8
8
9
9
**Go:** 1.26.1
10
10
**Repo:**https://github.com/ENTERPILOT/GOModel
@@ -111,4 +111,4 @@ Full reference: `.env.template` and `config/config.yaml`
111
111
-**Resilience:** Configured via `config/config.yaml` — global `resilience.retry.*` and `resilience.circuit_breaker.*` defaults with optional per-provider overrides under `providers.<name>.resilience.retry.*` and `providers.<name>.resilience.circuit_breaker.*`. Retry defaults: `max_retries` (3), `initial_backoff` (1s), `max_backoff` (30s), `backoff_factor` (2.0), `jitter_factor` (0.1). Circuit breaker defaults: `failure_threshold` (5), `success_threshold` (2), `timeout` (30s)
@@ -221,7 +223,11 @@ Setting `CIRCUIT_BREAKER_TIMEOUT=60s` in the environment overrides whatever `tim
221
223
Ollama requires no API key. Even with no YAML and no `OLLAMA_BASE_URL` set, an Ollama provider is registered pointing at `http://localhost:11434/v1`. If you do not want Ollama, make sure no Ollama instance is reachable at that address (the gateway's availability check will remove it from routing if it cannot be reached).
222
224
223
225
**Azure requires both key and base URL.**
224
-
`AZURE_API_KEY`alone is not enough for auto-discovery. Set `AZURE_API_BASE` to the Azure deployment endpoint as well, otherwise the provider is ignored.
226
+
`AZURE_API_KEY`alone is not enough for auto-discovery. Set `AZURE_BASE_URL` to the Azure deployment endpoint as well, otherwise the provider is ignored.
227
+
228
+
**Oracle requires both key and base URL.**
229
+
`ORACLE_API_KEY`alone is not enough for auto-discovery. Set `ORACLE_BASE_URL` to the Oracle OpenAI-compatible endpoint, otherwise the provider is ignored.
230
+
If your Oracle endpoint does not return a usable model list, configure `providers.<name>.models` in YAML to seed the router with explicit model IDs.
225
231
226
232
**Azure ships with a pinned API version by default.**
227
233
If you do not set `AZURE_API_VERSION`, the gateway sends `api-version=2024-10-21`. Override it only when you need a different Azure API version.
A high-performance AI gateway written in Go, providing a unified OpenAI-compatible API for multiple AI model providers, full-observability and more.
9
+
A high-performance AI gateway written in Go, providing a unified OpenAI-compatible API for OpenAI, Anthropic, Gemini, xAI, Groq, OpenRouter, Azure OpenAI, Oracle, Ollama, and more.
10
10
11
11
<ahref="docs/dashboard.gif">
12
12
<imgsrc="docs/dashboard.gif"alt="Animated GOModel AI gateway dashboard showing usage analytics, token tracking, and estimated cost monitoring"width="100%">
Copy file name to clipboardExpand all lines: docs/adr/0001-explicit-provider-registration.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
## Context
4
4
5
-
GOModel supports multiple LLM providers (OpenAI, Anthropic, Gemini, Groq, Ollama, xAI). Each provider must be registered with the factory before use.
5
+
GOModel supports multiple LLM providers, including OpenAI, Anthropic, Gemini, xAI, Groq, OpenRouter, Azure OpenAI, Oracle, Ollama, and custom OpenAI-compatible endpoints. Each provider must be registered with the factory before use.
6
6
7
7
## Decision
8
8
@@ -25,4 +25,4 @@ Use explicit registration in main.go:
25
25
26
26
### Negative
27
27
28
-
- Slightly more boilerplate in main.go (6 explicit Register calls)
28
+
- Slightly more boilerplate in main.go (9 explicit registration calls)
Copy file name to clipboardExpand all lines: docs/advanced/configuration.mdx
+35-2Lines changed: 35 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -131,10 +131,12 @@ Set these to automatically register providers. No YAML configuration required.
131
131
|`OPENROUTER_API_KEY`| OpenRouter |
132
132
|`XAI_API_KEY`| xAI (Grok) |
133
133
|`GROQ_API_KEY`| Groq |
134
-
|`AZURE_API_KEY`| Azure OpenAI (`AZURE_API_BASE` also required) |
134
+
|`AZURE_API_KEY`| Azure OpenAI (`AZURE_BASE_URL` also required) |
135
+
|`ORACLE_API_KEY`| Oracle (`ORACLE_BASE_URL` also required) |
135
136
|`OLLAMA_BASE_URL`| Ollama (no API key needed) |
136
137
137
-
Most providers can use a custom base URL via `<PROVIDER>_BASE_URL` (for example `OPENAI_BASE_URL`). OpenRouter defaults to `https://openrouter.ai/api/v1` and can be overridden with `OPENROUTER_BASE_URL`. Azure uses `AZURE_API_BASE` for its deployment base URL and accepts an optional `AZURE_API_VERSION` override; otherwise it defaults to `2024-10-21`.
138
+
Most providers can use a custom base URL via `<PROVIDER>_BASE_URL` (for example `OPENAI_BASE_URL`). OpenRouter defaults to `https://openrouter.ai/api/v1` and can be overridden with `OPENROUTER_BASE_URL`. Azure uses `AZURE_BASE_URL` for its deployment base URL and accepts an optional `AZURE_API_VERSION` override; otherwise it defaults to `2024-10-21`. Oracle requires `ORACLE_BASE_URL` because its OpenAI-compatible endpoint is region-specific.
139
+
When using Oracle, `models:` also acts as a fallback inventory if the upstream endpoint does not expose a usable `/models` response.
138
140
139
141
For OpenRouter, GOModel also sends default attribution headers unless the request already sets them. Override those defaults with `OPENROUTER_SITE_URL` and `OPENROUTER_APP_NAME`.
140
142
@@ -229,8 +231,19 @@ The simplest way to add providers. GOModel checks for well-known API key environ
0 commit comments