caikit.runtime.client.remote_model_initializer

The RemoteModelInitializer loads a RemoteModuleConfig as an empty Module that sends all requests to an external runtime server

Configuration for RemoteModelInitializer lives under the config as follows:

model_management:
initializers:
<initializer name>:

type: REMOTE

Attributes

log

error

Classes

RemoteModelInitializer

A class can be constructed by a factory if its constructor takes exactly

Module Contents

caikit.runtime.client.remote_model_initializer.log[source]
caikit.runtime.client.remote_model_initializer.error
class caikit.runtime.client.remote_model_initializer.RemoteModelInitializer(config: aconfig.Config, instance_name: str)[source]

Bases: caikit.core.model_management.model_initializer_base.ModelInitializerBase

A 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 RemoteModelInitializer loads a RemoteModuleConfig as an empty Module that
sends all requests to an external runtime server

Configuration for RemoteModelInitializer lives under the config as follows:

model_management:
    initializers:
        <initializer name>:
            type: REMOTE
"""
name = 'REMOTE'

This is the name of this constructible type that will be used by the factory to identify this class

_instance_name
_module_class_map
init(model_config: caikit.runtime.client.remote_config.RemoteModuleConfig, **kwargs) caikit.core.modules.ModuleBase | None[source]

Given a RemoteModuleConfig, initialize a RemoteModule instance

construct_module_class(model_config: caikit.runtime.client.remote_config.RemoteModuleConfig) Type[caikit.core.modules.ModuleBase][source]
Helper function to construct a ModuleClass. This is a separate function to allow

for easy overloading

Args:
model_config: RemoteModuleConfig

The model config to construct the module from

Returns:
module: Type[ModuleBase]

The constructed module