Commit Graph

2 Commits

Author SHA1 Message Date
Teknium 72490fa6cd refactor(model_setup_flows): extract custom-endpoint, Azure Foundry and Bedrock wizards into concern modules
hermes_cli/model_setup_flows_custom.py (_model_flow_custom, _model_flow_named_custom + helpers),
model_setup_flows_azure.py (_model_flow_azure_foundry + Entra preflight / picker),
model_setup_flows_bedrock.py (BEDROCK_GEO_PREFIXES, routability predicates, both Bedrock flows).
Bodies moved verbatim (AST slices); every name re-exported from model_setup_flows (noqa: F401)
so hermes_cli.main and test imports keep resolving. Origin: 1975 -> 1159 lines.
Flow corpus (396 cases): 0 diffs; 34 test files / 364 tests green.
2026-09-02 16:39:35 -07:00
Teknium 57f828a3da refactor(model_setup_flows): shared wizard skeleton in model_setup_flows_common, flows rebuilt on it (2849 -> 1975 lines)
- new hermes_cli/model_setup_flows_common.py: _say/_ask prompt primitives, _persist_model/
  _finish_model (save model choice -> provider/base_url/api_mode -> scrub creds -> save),
  _activate_provider_model (OAuth providers), _oauth_gate (login / use / reauth / cancel),
  _curses_choice + _print_numbered (radio picker with numbered fallback); every existing
  helper moved there and re-exported from the origin (noqa: F401).
- god flows split: azure_foundry -> _azure_entra_preflight/_azure_pick_model, custom ->
  _probe_custom_endpoint/_pick_detected_model/_parse_context_length, named_custom ->
  _configured_model_ids/_discover_named_custom_models/_pick_named_custom_model, nous ->
  _nous_model_catalog, copilot -> _copilot_obtain_token, bedrock -> _bedrock_text_model_ids.
- 396-case scripted flow corpus (transcript/config.yaml/.env/auth.json): 0 diffs vs base.
2026-09-02 16:33:41 -07:00