Add a built-in NVIDIA NIM OpenAI-compatible workflow that reads NVIDIA_API_KEY, document the backend, and cover auth/profile materialization. Also make Windows shell resolution skip discovered bash executables that cannot run commands, and update the macOS Terminal backspace troubleshooting note to reflect the current fix.
ANTHROPIC_BASE_URL and ANTHROPIC_MODEL were applied unconditionally after
profile materialization, replacing explicit profile settings like Ollama's
base_url with unrelated endpoints. Now OPENHARNESS_* env vars always
override, while ANTHROPIC_*/OPENAI_* vars only apply when the active
profile doesn't explicitly configure the corresponding field.
Also adds Ollama setup instructions to README.
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Wire Gemini as a first-class provider so `oh setup` offers it alongside
Anthropic, OpenAI, Moonshot, and others. The ProviderSpec for Gemini
already existed in the API registry; this commit adds the missing
profile, auth-source mappings, and CLI integration so users can
configure Gemini through the standard setup flow instead of manually
creating a custom profile.
Changes:
- Add "gemini" entry to `default_provider_profiles()` with
`gemini-2.5-flash` as default model and the AI Studio OpenAI-compat
base URL
- Register `gemini_api_key` auth source in `auth_source_provider_name()`
and `default_auth_source_for_provider()`
- Add gemini to `_KNOWN_PROVIDERS`, `_AUTH_SOURCES`, and
`_PROFILE_BY_PROVIDER` in `auth/manager.py`
- Add gemini to `_PROVIDER_LABELS`, `_AUTH_SOURCE_LABELS`, and the
`oh auth login` API-key flow in `cli.py`
- Add Gemini row to the OpenAI-Compatible provider table in both
README.md and README.zh-CN.md
Closes#90
Add OpenAICompatibleClient that implements SupportsStreamingMessages,
enabling any provider using the OpenAI /v1/chat/completions format:
DashScope, DeepSeek, GitHub Models, Groq, Ollama, etc.
- New openai_client.py with streaming, tool calling, retry logic
- --api-format openai CLI flag and OPENHARNESS_API_FORMAT env var
- OPENAI_API_KEY fallback in resolve_api_key()
- Provider detection for dashscope/qwen and github models
- Wired through cli → app → runtime → client selection
- 11 unit tests for format conversion functions
- Updated README provider compatibility section
- CHANGELOG entries