whylogs_container.whylabs.container.config¶
Classes
|
|
|
|
|
|
|
|
|
|
|
|
- class whylogs_container.whylabs.container.config.ConfigActor(config_instance: ConfigInstance)¶
Bases:
ProcessActor
[RefreshMessage
,None
],SynchronousConfig
- close_process() None ¶
- handle_refresh_message(messages: List[RefreshMessage]) None ¶
- is_process_alive() bool ¶
- process_batch(batch, batch_type) None ¶
- process_close_message(_messages: List[CloseMessage]) None ¶
- run() None ¶
Method to be run in sub-process; can be overridden in sub-class
- start_process(pre_warm: bool = False) None ¶
- class whylogs_container.whylabs.container.config.ConfigInstance(config: whylogs_container.whylabs.container.config.ConfigState)¶
Bases:
object
- config: ConfigState¶
The current configuration state. This can only be updated by the ConfigActor in order to handle concurrency properly with multiple processes.
- class whylogs_container.whylabs.container.config.ConfigManager(address=None, authkey=None, serializer='pickle', ctx=None)¶
Bases:
BaseManager
- ConfigInstance(*args, **kwds)¶
- class whylogs_container.whylabs.container.config.ConfigProxy(token, serializer, manager=None, authkey=None, exposed=None, incref=True, manager_owned=False)¶
Bases:
NamespaceProxy
- class whylogs_container.whylabs.container.config.ConfigState(local_policies: Tuple[Union[whylogs_container.whylabs.container.policy.policy_0_0_1.Policy, whylogs_container.whylabs.container.policy.policy_0_1_0.Policy], ...] = <factory>, s3_policies: Tuple[Union[whylogs_container.whylabs.container.policy.policy_0_0_1.Policy, whylogs_container.whylabs.container.policy.policy_0_1_0.Policy], ...] = <factory>, whylabs_policies: Tuple[Union[whylogs_container.whylabs.container.policy.policy_0_0_1.Policy, whylogs_container.whylabs.container.policy.policy_0_1_0.Policy], ...] = <factory>, last_update_time_ms: Optional[int] = None, create_time: datetime.datetime = <factory>)¶
Bases:
object
- create_time: datetime¶
- get_container_config() ContainerConfiguration | None ¶
- get_dataset_options(dataset_id: str, org_id: str) DatasetOptions ¶
- get_default_langkit_workflow() Workflow ¶
- get_default_whylogs_schema() DatasetOptions ¶
- get_langkit_metric_workflows() Mapping[DatasetKey, Workflow] ¶
Geta map of dataset id to a workflow that represents the combined langkit options between the container configuration and the yaml policy files from local, s3, and whylabs platform.
- get_langkit_score_workflow(dataset_id: str, org_id: str) Workflow | None ¶
Get the langkit workflow for calculating scores based on policy rulesets. This workflow doesn’t compute the metrics, it consumes the output of another workflow that computes metrics and geneates normalized scores.
- get_langkit_workflow(dataset_id: str, org_id: str) Workflow ¶
- get_merged_metric_options() Mapping[DatasetKey, StrictLangkitOptions] ¶
Get a map from dataset id to the merged langkit options from the container configuration and all sources of the policy files: local, s3, whylabs, etc.
- get_policies() Mapping[DatasetKey, Policy | Policy] ¶
- get_policy_langkit_metric_options() Mapping[DatasetKey, StrictLangkitOptions] ¶
Returns the langkit options derived from all of the known policy files, as though they were originally defined in the custom configuration.
- last_update_time_ms: int | None = None¶