Skip to content

The agent that grows with you

Merge branch 'simp/cli-models' into simp/integration

Teknium24b9d184489b
diff --cc hermes_cli/model_setup_flows.py
index c039df656bf,a65ae4c5ee9..997d89186af
--- a/hermes_cli/model_setup_flows.py
+++ b/hermes_cli/model_setup_flows.py
@@@ -1829,20 -1710,30 +1710,31 @@@ def _model_flow_named_custom(config, pr
print(f"\n✅ Model set to: {model_name}")
print(f" Provider: {name} ({base_url})")
+
+ def _copilot_model_list(live_ids) -> list:
+ """Live GitHub Copilot ids, or the curated fallback with a warning."""
+ from hermes_cli.models import _PROVIDER_MODELS
+
+ if live_ids:
+ model_list = [model_id for model_id in live_ids if model_id]
+ print(f" Found {len(model_list)} model(s) from GitHub Copilot")
+ return model_list
+ model_list = _PROVIDER_MODELS.get("copilot", [])
+ if model_list:
+ print(
+ " ⚠ Could not auto-detect models from GitHub Copilot — showing defaults."
+ )
+ print(' Use "Enter custom model name" if you do not see your model.')
+ return model_list
+
+
def _model_flow_copilot(config, current_model=""):
"""GitHub Copilot flow using env vars, gh CLI, or OAuth device code."""
- from hermes_cli.main import _current_reasoning_effort, _prompt_reasoning_effort_selection, _set_reasoning_effort
+ from hermes_cli.main import _prompt_reasoning_effort_selection
+ from hermes_cli.setup import _current_reasoning_effort, _set_reasoning_effort
- from hermes_cli.auth import (
- PROVIDER_REGISTRY,
- _prompt_model_selection,
- _save_model_choice,
- deactivate_provider,
- resolve_api_key_provider_credentials,
- )
- from hermes_cli.config import save_env_value, load_config, save_config
+ from hermes_cli.auth import PROVIDER_REGISTRY, resolve_api_key_provider_credentials
+ from hermes_cli.config import save_env_value, load_config
from hermes_cli.models import (
- _PROVIDER_MODELS,
fetch_api_models,
fetch_github_model_catalog,
github_model_reasoning_efforts,
diff --cc hermes_cli/setup.py
index 1213eb11582,7408faa5de4..bce62d2d70d
--- a/hermes_cli/setup.py
+++ b/hermes_cli/setup.py
@@@ -173,6 -121,6 +121,21 @@@ from hermes_cli.cli_output import ( #
from hermes_cli.secret_prompt import masked_secret_prompt # noqa: E402
++def _current_reasoning_effort(config: dict) -> str:
++ agent_cfg = config.get("agent")
++ if isinstance(agent_cfg, dict):
++ return str(agent_cfg.get("reasoning_effort") or "").strip().lower()
++ return ""
++
++
++def _set_reasoning_effort(config: dict, effort: str) -> None:
++ agent_cfg = config.get("agent")
++ if not isinstance(agent_cfg, dict):
++ agent_cfg = {}
++ config["agent"] = agent_cfg
++ agent_cfg["reasoning_effort"] = effort
++
++
def is_interactive_stdin() -> bool:
"""Return True when stdin looks like a usable interactive TTY."""
stdin = getattr(sys, "stdin", None)