Skip to main content
The models block (available inside defaults blocks only in v0.1) controls how ONR queries and parses the GET /v1/models endpoint of an upstream provider to populate its internal registry or Admin Page proxy. Global reusable presets can now be declared in config/modes/models_modes.conf and included from config/onr.conf:

Built-In Handlers

You can rely on built-in parser presets for standard providers. In this repository’s default config, the same names are declared in config/modes/models_modes.conf as global models_mode presets:
The vertex preset lists Google publisher base models. It requires credential metadata from the selected upstream key. Configure credential_file and location in keys.yaml; use base_url_override for regional Vertex hosts.

Custom Model Parsers

For providers exposing bizarre schemas or prefixed namespaces, build a custom parser to extract and clean the model lists explicitly.

Directives specific to models_mode custom

  • id_path (repeatable): Extracts variables into a deduplicated union list.
  • id_regex: If it includes a Capture Group, group 1 becomes the final ID. Otherwise, the full Regex Match is used. Non-matching values are dropped.