caikit.core.model_management.multi_model_finder
The MultiModelFinder configures a set of other model finders that will be used in sequence to try loading models.
Configuration for MultiModelFinder lives under the config as follows:
- model_management:
- finders:
- <finder name>:
type: MULTI config:
# Sequence of other finder names to use in priority order finder_sequence:
other_finder1
other_finder2
Attributes
Classes
A class can be constructed by a factory if its constructor takes exactly |
Module Contents
- caikit.core.model_management.multi_model_finder.error
- class caikit.core.model_management.multi_model_finder.MultiModelFinder(config: aconfig.Config, instance_name: str)[source]
Bases:
caikit.core.model_management.model_finder_base.ModelFinderBaseA class can be constructed by a factory if its constructor takes exactly one argument that is an aconfig.Config object and it has a name to identify itself with the factory.
- __doc__ = Multiline-String
Show Value
""" The MultiModelFinder configures a set of other model finders that will be used in sequence to try loading models. Configuration for MultiModelFinder lives under the config as follows: model_management: finders: <finder name>: type: MULTI config: # Sequence of other finder names to use in priority order finder_sequence: - other_finder1 - other_finder2 """
- name = 'MULTI'
This is the name of this constructible type that will be used by the factory to identify this class
- _instance_name
- _finders
- find_model(model_path: str, **kwargs) caikit.core.modules.ModuleConfig | None[source]
Iterate through the sequence of finders and return the first one that succeeds