hermes - ✅(Solved) Fix hermes doctor: false-positive "model.provider 'bedrock' is not a recognised provider" [1 pull requests, 1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
NousResearch/hermes-agent#15358Fetched 2026-04-25 06:22:51
View on GitHub
Comments
0
Participants
1
Timeline
5
Reactions
0
Author
Participants
Timeline (top)
labeled ×4cross-referenced ×1

hermes doctor reports a false-positive error for a valid AWS Bedrock configuration:

✗ model.provider 'bedrock' is not a recognised provider (known: ai-gateway, alibaba, ..., bedrock, ...)
...
1. model.provider 'bedrock' is unknown. Valid providers: ..., bedrock, ...
Fix: run 'hermes config set model.provider <valid_provider>'

The error message itself lists bedrock as a known provider. The API Connectivity section in the same doctor run also succeeds against Bedrock. My session uses provider: bedrock and works fine — only the doctor validator is wrong.

Error Message

hermes doctor reports a false-positive error for a valid AWS Bedrock configuration: The error message itself lists bedrock as a known provider. The API Connectivity section in the same doctor run also succeeds against Bedrock. My session uses provider: bedrock and works fine — only the doctor validator is wrong.

Root Cause

hermes_cli/doctor.py (~line 322) calls resolve_provider_full('bedrock', ...) and falls back to flagging the provider as unknown if the result is None:

canonical_provider = provider
if provider and _resolve_provider_full is not None and provider != "auto":
    provider_def = _resolve_provider_full(provider, user_providers, custom_providers)
    canonical_provider = provider_def.id if provider_def is not None else None

if provider and provider != "auto":
    if canonical_provider is None or (known_providers and canonical_provider not in known_providers):
        check_fail(f"model.provider '{provider_raw}' is not a recognised provider", ...)

For bedrock specifically, resolve_provider_full returns None because:

  1. HERMES_OVERLAYS in hermes_cli/providers.py has no bedrock entry.
  2. agent.models_dev.get_provider_info('bedrock') also returns None — models.dev's id is amazon-bedrock, not bedrock.
  3. get_provider('bedrock') therefore returns None, and so does resolve_provider_full.

Meanwhile hermes_cli/auth.py::PROVIDER_REGISTRY DOES register bedrock (auth_type aws_sdk, transport bedrock_converse), which is why the rest of the agent works. Only provider resolution in providers.py is missing it.

Reproduction (demonstrates the contradiction inside resolve_provider_full):

from hermes_cli.auth import PROVIDER_REGISTRY
from hermes_cli.providers import resolve_provider_full

print('bedrock' in PROVIDER_REGISTRY)                # True
print(resolve_provider_full('bedrock', None, []))    # None  ← bug

Fix Action

Fixed

PR fix notes

PR #15361: fix(providers): register bedrock in HERMES_OVERLAYS so resolve_provider_full succeeds

Description (problem / solution / changelog)

What & Why

Fixes #15358.

hermes doctor emits a false-positive error on valid provider: bedrock configs:

✗ model.provider 'bedrock' is not a recognised provider (known: ..., bedrock, ...)

Root cause: hermes_cli/auth.py::PROVIDER_REGISTRY registers bedrock, but hermes_cli/providers.py::HERMES_OVERLAYS had no entry for it. models.dev publishes this provider under the id amazon-bedrock, not bedrock, so get_provider('bedrock') and therefore resolve_provider_full('bedrock', ...) both returned None. Doctor then flagged the provider as unknown, contradicting its own "known providers" list.

The rest of the agent (runtime resolution, bedrock_converse transport, AWS SDK auth) already works — only provider resolution in providers.py was missing.

Change

hermes_cli/providers.py: add a minimal HermesOverlay entry for bedrock, mirroring the PROVIDER_REGISTRY metadata:

"bedrock": HermesOverlay(
    transport="bedrock_converse",
    auth_type="aws_sdk",
    extra_env_vars=("AWS_BEARER_TOKEN_BEDROCK", "AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_REGION"),
    base_url_env_var="BEDROCK_BASE_URL",
),

The existing ALIASES already map aws, aws-bedrock, amazon-bedrock, and amazon to bedrock, so this single entry also makes all aliases resolve correctly.

Tests

Added TestBedrockResolution in tests/hermes_cli/test_api_key_providers.py with three regression tests:

  • bedrock is present in PROVIDER_REGISTRY
  • resolve_provider_full('bedrock', None, []) returns a ProviderDef with transport='bedrock_converse' and auth_type='aws_sdk'
  • All four aliases (aws, aws-bedrock, amazon-bedrock, amazon) resolve to bedrock

How to test

pytest tests/hermes_cli/test_api_key_providers.py::TestBedrockResolution -v
pytest tests/hermes_cli/test_doctor.py -v
pytest tests/agent/test_bedrock_integration.py -v

All pass locally (77 tests across doctor + bedrock integration + new regression tests).

Before the fix, hermes doctor on a provider: bedrock config prints:

✗ model.provider 'bedrock' is not a recognised provider

After the fix, it prints no such error and correctly moves on to API connectivity checks.

Platforms tested

  • macOS 14 (Apple Silicon), Python 3.11.14

Scope

One logical change. No behavior change for other providers — the new overlay entry is only consulted when provider == 'bedrock' (or one of its existing aliases) is passed in.

Changed files

  • hermes_cli/providers.py (modified, +6/-0)
  • tests/hermes_cli/test_api_key_providers.py (modified, +31/-0)

Code Example

✗ model.provider 'bedrock' is not a recognised provider (known: ai-gateway, alibaba, ..., bedrock, ...)
...
1. model.provider 'bedrock' is unknown. Valid providers: ..., bedrock, ...
Fix: run 'hermes config set model.provider <valid_provider>'

---

model:
  default: us.anthropic.claude-opus-4-7
  provider: bedrock

---

canonical_provider = provider
if provider and _resolve_provider_full is not None and provider != "auto":
    provider_def = _resolve_provider_full(provider, user_providers, custom_providers)
    canonical_provider = provider_def.id if provider_def is not None else None

if provider and provider != "auto":
    if canonical_provider is None or (known_providers and canonical_provider not in known_providers):
        check_fail(f"model.provider '{provider_raw}' is not a recognised provider", ...)

---

from hermes_cli.auth import PROVIDER_REGISTRY
from hermes_cli.providers import resolve_provider_full

print('bedrock' in PROVIDER_REGISTRY)                # True
print(resolve_provider_full('bedrock', None, []))    # None  ← bug
RAW_BUFFERClick to expand / collapse

Summary

hermes doctor reports a false-positive error for a valid AWS Bedrock configuration:

✗ model.provider 'bedrock' is not a recognised provider (known: ai-gateway, alibaba, ..., bedrock, ...)
...
1. model.provider 'bedrock' is unknown. Valid providers: ..., bedrock, ...
Fix: run 'hermes config set model.provider <valid_provider>'

The error message itself lists bedrock as a known provider. The API Connectivity section in the same doctor run also succeeds against Bedrock. My session uses provider: bedrock and works fine — only the doctor validator is wrong.

Config

model:
  default: us.anthropic.claude-opus-4-7
  provider: bedrock

Root Cause

hermes_cli/doctor.py (~line 322) calls resolve_provider_full('bedrock', ...) and falls back to flagging the provider as unknown if the result is None:

canonical_provider = provider
if provider and _resolve_provider_full is not None and provider != "auto":
    provider_def = _resolve_provider_full(provider, user_providers, custom_providers)
    canonical_provider = provider_def.id if provider_def is not None else None

if provider and provider != "auto":
    if canonical_provider is None or (known_providers and canonical_provider not in known_providers):
        check_fail(f"model.provider '{provider_raw}' is not a recognised provider", ...)

For bedrock specifically, resolve_provider_full returns None because:

  1. HERMES_OVERLAYS in hermes_cli/providers.py has no bedrock entry.
  2. agent.models_dev.get_provider_info('bedrock') also returns None — models.dev's id is amazon-bedrock, not bedrock.
  3. get_provider('bedrock') therefore returns None, and so does resolve_provider_full.

Meanwhile hermes_cli/auth.py::PROVIDER_REGISTRY DOES register bedrock (auth_type aws_sdk, transport bedrock_converse), which is why the rest of the agent works. Only provider resolution in providers.py is missing it.

Reproduction (demonstrates the contradiction inside resolve_provider_full):

from hermes_cli.auth import PROVIDER_REGISTRY
from hermes_cli.providers import resolve_provider_full

print('bedrock' in PROVIDER_REGISTRY)                # True
print(resolve_provider_full('bedrock', None, []))    # None  ← bug

Expected

resolve_provider_full('bedrock', ...) should return a ProviderDef with transport='bedrock_converse' and auth_type='aws_sdk', and hermes doctor should not flag a valid bedrock config.

Proposed Fix

Add a bedrock overlay entry to HERMES_OVERLAYS in hermes_cli/providers.py. PR incoming.

Environment

  • macOS
  • Hermes config v22
  • Python 3.11.14
  • hermes doctor run on latest main as of April 2026

extent analysis

TL;DR

The most likely fix is to add a bedrock entry to HERMES_OVERLAYS in hermes_cli/providers.py to correctly resolve the bedrock provider.

Guidance

  • Verify that HERMES_OVERLAYS in hermes_cli/providers.py does not contain a bedrock entry, which is causing resolve_provider_full to return None.
  • Check the PROVIDER_REGISTRY in hermes_cli/auth.py to confirm that bedrock is registered with auth_type='aws_sdk' and transport='bedrock_converse'.
  • To mitigate the issue, consider adding a temporary workaround to resolve_provider_full to handle the bedrock provider until the proposed fix is implemented.
  • Review the agent.models_dev.get_provider_info('bedrock') call to understand why it returns None when the expected id is amazon-bedrock.

Example

# Example of proposed fix
HERMES_OVERLAYS = {
    # ... existing entries ...
    'bedrock': {'auth_type': 'aws_sdk', 'transport': 'bedrock_converse'}
}

Notes

The issue seems to be specific to the hermes_cli/providers.py file and the resolve_provider_full function. The proposed fix should resolve the issue, but it's essential to test and verify the changes.

Recommendation

Apply the proposed fix by adding a bedrock entry to HERMES_OVERLAYS in hermes_cli/providers.py, as this should correctly resolve the bedrock provider and fix the hermes doctor error.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

hermes - ✅(Solved) Fix hermes doctor: false-positive "model.provider 'bedrock' is not a recognised provider" [1 pull requests, 1 participants]