configs/ directory and builds ModelSpec instances. This is the single source of truth for all model specifications.
EndpointPaths
endpoints:.
HuggingFaceConfig
timm for the in-process huggingface backend. Present only on configs of models that can be served this way.
Attributes:
repo_id- Hugging Face Hub repository ID (without thehf-hub:prefix), e.g."bioptimus/H-optimus-0".timm_kwargs- Raw keyword arguments forwarded totimm.create_model. String values are treated as dotted import paths (e.g."timm.layers.SwiGLUPacked") and resolved to the referenced object at build time viaresolve_dotted_path; other values are passed through unchanged.
resolve_dotted_path
"timm.layers.SwiGLUPacked" imports timm.layers and returns SwiGLUPacked. Kept lazy (imports happen only when called) so that backends other than huggingface never import timm.
A dotted path of the form
"module.submodule.attribute".path.
Raises:
ValueError- Ifpathdoes not contain a module component.ImportError- If the module cannot be imported.AttributeError- If the attribute does not exist on the module.
ModelConfig
ModelSpec with routing metadata that is not part of the spec itself.
endpoint_path
genes_endpoint_path
load_model_config
Path to the YAML file.
ModelConfig with the parsed spec and routing.
load_all_model_configs
*.yaml files and returns a dict keyed by model_name.
Directory to scan. Defaults to the package-bundled
configs/ directory.ModelConfig.
