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
Makes the built-in lmstudio provider appear in the model picker when LM Studio is configured with a local base URL but no API key.
Current behavior on main: if a user sets LM_BASE_URL for local LM Studio but does not set LM_API_KEY, the built-in LM Studio provider can be omitted from the /model picker unless LM Studio is already the active provider or the auth-gated path is satisfied.
That is wrong for the common local LM Studio setup: LM Studio typically runs on localhost and does not require an API key.
Related Issue
No separate issue filed. This came from a live Hermes model-picker configuration issue on a local LM Studio setup.
Type of Change
🐛 Bug fix (non-breaking change that fixes an issue)
✅ Tests (adding or improving test coverage)
Changes Made
Update hermes_cli/model_switch.py so the built-in lmstudio provider is included in picker candidates when LM_BASE_URL is configured, even if LM_API_KEY is absent.
Preserve existing behavior when:
LM Studio is already the active provider
LM Studio auth is configured
other provider credential gates are evaluated
Add regression coverage in tests/hermes_cli/test_lmstudio_model_picker.py for the local no-auth LM Studio picker path.
Why this is the right scope
This is intentionally narrow: it does not add a new provider, change runtime routing, alter model resolution, or loosen auth requirements for remote providers.
It only fixes picker visibility for the existing built-in lmstudio provider when the existing local base URL configuration is enough to use it.
Typical affected configuration:
LM_BASE_URL=http://127.0.0.1:1234/v1# no LM_API_KEY
Expected result: LM Studio appears in the model picker as an available local provider.
How to Test
Targeted regression test used before opening the PR:
The test covers the bug directly: LM_BASE_URL is configured, LM_API_KEY is absent, and the picker still emits the built-in lmstudio provider row.
Platforms Tested
Native Windows 10
Python 3.11 Hermes environment
Local LM Studio base URL configuration
Duplicate Search
Searched open and closed issues/PRs for LM Studio picker visibility with LM_BASE_URL / missing LM_API_KEY and did not find an existing PR or issue covering this fix.
Updated the PR description to more explicitly match CONTRIBUTING.md / the PR template: current-main behavior, affected local LM Studio config, narrow bug scope, testing, platform tested, and duplicate-search note. This is still mergeable and intentionally limited to the model-picker visibility bugfix.
Thanks for the focused regression fix. Current main still has the reported gap: hermes_cli/model_switch.py:1646-1667 probes LM Studio when LM_BASE_URL is present, but the subsequent provider-row gate at hermes_cli/model_switch.py:1795-1853 only recognizes LM_API_KEY or another credential source, so the row is skipped. The proposed condition addresses that exact divergence, and the added test exercises the interactive-picker wrapper.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
comp/cliCLI entry point, hermes_cli/, setup wizardP3Low — cosmetic, nice to havesweeper:blast-moderateSweeper blast radius: moderate — a subsystem or single platformsweeper:risk-compatibilitySweeper risk: may break existing users, config, migrations, defaults, or upgradestype/bugSomething isn't working
3 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Makes the built-in
lmstudioprovider appear in the model picker when LM Studio is configured with a local base URL but no API key.Current behavior on
main: if a user setsLM_BASE_URLfor local LM Studio but does not setLM_API_KEY, the built-in LM Studio provider can be omitted from the/modelpicker unless LM Studio is already the active provider or the auth-gated path is satisfied.That is wrong for the common local LM Studio setup: LM Studio typically runs on localhost and does not require an API key.
Related Issue
No separate issue filed. This came from a live Hermes model-picker configuration issue on a local LM Studio setup.
Type of Change
Changes Made
hermes_cli/model_switch.pyso the built-inlmstudioprovider is included in picker candidates whenLM_BASE_URLis configured, even ifLM_API_KEYis absent.tests/hermes_cli/test_lmstudio_model_picker.pyfor the local no-auth LM Studio picker path.Why this is the right scope
This is intentionally narrow: it does not add a new provider, change runtime routing, alter model resolution, or loosen auth requirements for remote providers.
It only fixes picker visibility for the existing built-in
lmstudioprovider when the existing local base URL configuration is enough to use it.Typical affected configuration:
Expected result: LM Studio appears in the model picker as an available local provider.
How to Test
Targeted regression test used before opening the PR:
/c/Users/daveotero/.hermes/hermes-agent/venv/Scripts/python.exe -m pytest tests/hermes_cli/test_lmstudio_model_picker.py -q -o 'addopts='The test covers the bug directly:
LM_BASE_URLis configured,LM_API_KEYis absent, and the picker still emits the built-inlmstudioprovider row.Platforms Tested
Duplicate Search
Searched open and closed issues/PRs for LM Studio picker visibility with
LM_BASE_URL/ missingLM_API_KEYand did not find an existing PR or issue covering this fix.Checklist
Code
fix(scope):,feat(scope):, etc.)Documentation & Housekeeping
cli-config.yaml.exampleupdate: N/A, no config keys added or changedCONTRIBUTING.md/AGENTS.mdupdate: N/A, no architecture/workflow change