Skip to content

fix(runtime_provider): use custom provider name instead of hardcoded string#2853

Open
teyrebaz33 wants to merge 1 commit into
NousResearch:mainfrom
teyrebaz33:fix/custom-provider-label
Open

fix(runtime_provider): use custom provider name instead of hardcoded string#2853
teyrebaz33 wants to merge 1 commit into
NousResearch:mainfrom
teyrebaz33:fix/custom-provider-label

Conversation

@teyrebaz33

Copy link
Copy Markdown
Contributor

Fixes #2736 (item 7)

Problem

_resolve_named_custom_runtime() returned "openrouter" as the provider label for all named custom providers. When a user asked "what provider are you using?" with Ollama configured as a custom provider, Hermes reported "OpenRouter" even though requests were going to a local Ollama endpoint.

Change

One-line fix in hermes_cli/runtime_provider.py: return custom_provider.get("name", requested_provider) instead of the hardcoded "openrouter" string, so the label reflects the actual configured provider name.

Tests

  • Updated test_named_custom_provider_uses_saved_credentials which was asserting the wrong label
  • Added test_named_custom_provider_label covering a named Ollama provider returning its own name

…string

_resolve_named_custom_runtime() was returning 'openrouter' as the
provider label for all named custom providers (e.g. Ollama at a local
endpoint). This caused 'hermes what provider are you using?' to report
'OpenRouter' even when requests were going to a local Ollama instance.

Fix: return custom_provider.get('name', requested_provider) so the
label reflects the actual configured provider name.

Also update the existing test that expected the wrong label, and add
test_named_custom_provider_label to cover this case explicitly.
@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/cli CLI entry point, hermes_cli/, setup wizard labels May 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/cli CLI entry point, hermes_cli/, setup wizard P2 Medium — degraded but workaround exists type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Obsidian Vault as Persistent Shared Memory Layer

2 participants