plugins/_model_config/README.md
Manage which models Agent Zero uses for chat, utility, and embeddings, with support for scoped overrides and reusable presets.
This plugin centralizes model selection and model-related settings for the application. It provides helpers and APIs for:
ModelConfig objects and the runtime chat, utility, and embedding wrappers used elsewhere in the app.helpers/model_config.py resolves config, presets, overrides, and runtime model objects.api/model_config_get.pyapi/model_config_set.pyapi/model_override.pyapi/model_presets.pyapi/model_search.pyapi/api_keys.pyhooks.py exposes plugin-level integration hooks.agenttruetruetrueProjects store copied model settings in the standard scoped plugin path:
/a0/usr/projects/<project>/.a0proj/plugins/_model_config/config.json
Project-only presets live beside that config:
/a0/usr/projects/<project>/.a0proj/plugins/_model_config/presets.yaml
The project preset file uses the same plain YAML list schema as global presets. It does not contain scope metadata:
- name: Research
chat:
provider: openrouter
name: anthropic/claude-sonnet-4.6
api_base: ""
ctx_length: 200000
ctx_history: 0.7
vision: true
utility:
provider: openrouter
name: openai/gpt-5.4-mini
Preset slots are partial overlays. Missing fields inherit from the current effective config, so a preset can switch only the model identity while preserving tuned context windows, rate limits, and nested kwargs. The utility and embedding slots are optional and only apply when they declare a provider or model name; otherwise those configured models are inherited. Selecting a preset for a project writes the merged result into the project's config.json.
_model_configModel Configuration