Skip to content

refactor(auxiliary): config.yaml takes priority over env vars#7889

Merged
teknium1 merged 1 commit into
mainfrom
hermes/hermes-ec496c80
Apr 11, 2026
Merged

refactor(auxiliary): config.yaml takes priority over env vars#7889
teknium1 merged 1 commit into
mainfrom
hermes/hermes-ec496c80

Conversation

@teknium1

Copy link
Copy Markdown
Contributor

Summary

The auxiliary client checked env vars (AUXILIARY_{TASK}_PROVIDER, AUXILIARY_{TASK}_MODEL, AUXILIARY_{TASK}_BASE_URL, etc.) before config.yaml's auxiliary.{task}.* section. These are behavioral settings, not secrets — they shouldn't live in .env at all.

Flipped the resolution order in _resolve_task_provider_model():

Priority Before After
1 Explicit args Explicit args
2 Env vars (AUXILIARY_, CONTEXT_) config.yaml (auxiliary.{task}.*)
3 config.yaml (auxiliary.{task}.*) Env vars (backward-compat fallback)
4 auto auto

Env var reading code is kept for backward compatibility but config.yaml now takes precedence.

Changes

  • agent/auxiliary_client.py: Flipped provider/model/base_url resolution order, updated module + function docstrings
  • hermes_cli/config.py: Removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS

Tests

181 passed, 3 pre-existing failures (Anthropic OAuth + missing import — unrelated, fail on clean main too).

… task settings

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
@teknium1 teknium1 merged commit 976bad5 into main Apr 11, 2026
5 of 6 checks passed
forsonny pushed a commit to forsonny/hermes-agent that referenced this pull request Apr 11, 2026
…i provider, community bug fixes)

- fix(vision): auto-resize oversized images + preserve aspect ratio
- feat: warn when compression model context is too small (NousResearch#7894)
- refactor(auxiliary): config.yaml priority over env vars (NousResearch#7889)
- fix: three high-impact community bugs (NousResearch#5819, NousResearch#6893, NousResearch#3388)
- fix(streaming): adaptive backoff + cursor strip (NousResearch#7683)
- fix(weixin): keep multi-line messages in single bubble
- fix(matrix): pass required args for mautrix >=0.21
- feat(xiaomi): add Xiaomi MiMo as first-class provider
- feat(migration): preview-then-confirm UX + docs
- fix: unify openai-codex model list
- docs: MiMo docs + compression context warning docs

Self-improve: automated improvement
Tommyeds pushed a commit to Tommyeds/hermes-agent that referenced this pull request Apr 12, 2026
… task settings (NousResearch#7889)

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
ulasbilgen pushed a commit to ulasbilgen/hermes-adhd-agent that referenced this pull request May 1, 2026
… task settings (NousResearch#7889)

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
aj-nt pushed a commit to aj-nt/hermes-agent that referenced this pull request May 1, 2026
… task settings (NousResearch#7889)

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
02356abc pushed a commit to 02356abc/hermes-agent that referenced this pull request May 14, 2026
… task settings (NousResearch#7889)

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
olympus-terminal pushed a commit to olympus-terminal/hermes-agent that referenced this pull request May 16, 2026
… task settings (NousResearch#7889)

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
gweeteve pushed a commit to gweeteve/hermes-agent that referenced this pull request Jun 2, 2026
… task settings (NousResearch#7889)

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
Egavasyug pushed a commit to Egavasyug/hermes-agent that referenced this pull request Jun 10, 2026
… task settings (NousResearch#7889)

The auxiliary client previously checked env vars (AUXILIARY_{TASK}_PROVIDER,
AUXILIARY_{TASK}_MODEL, etc.) before config.yaml's auxiliary.{task}.* section.
This violated the project's '.env is for secrets only' policy — these are
behavioral settings, not API keys.

Flipped the resolution order in _resolve_task_provider_model():
  1. Explicit args (always win)
  2. config.yaml auxiliary.{task}.* (PRIMARY)
  3. Env var overrides (backward-compat fallback only)
  4. 'auto' (full auto-detection chain)

Env var reading code is kept for backward compatibility but config.yaml
now takes precedence. Updated module docstring and function docstring.

Also removed AUXILIARY_VISION_MODEL from _EXTRA_ENV_KEYS in config.py.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant