Automate your W&B workflows.
This is the multi-page printable view of this section. Click here to print.
Automations
- 1: ActionType
- 2: ArtifactEvent
- 3: Automation
- 4: DoNothing
- 5: EventType
- 6: MetricChangeFilter
- 7: MetricThresholdFilter
- 8: NewAutomation
- 9: OnAddArtifactAlias
- 10: OnCreateArtifact
- 11: OnLinkArtifact
- 12: OnRunMetric
- 13: ProjectScope
- 14: RunEvent
- 15: ScopeType
- 16: SendNotification
- 17: SendWebhook
- 18: SlackIntegration
- 19: WebhookIntegration
3 - Automation
class Automation
A local instance of a saved W&B automation.
property Automation.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property Automation.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
4 - DoNothing
class DoNothing
Defines an automation action that intentionally does nothing.
property DoNothing.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property DoNothing.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
6 - MetricChangeFilter
class MetricChangeFilter
Defines a filter that compares a change in a run metric against a user-defined threshold.
The change is calculated over “tumbling” windows, i.e. the difference between the current window and the non-overlapping prior window.
property MetricChangeFilter.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property MetricChangeFilter.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
7 - MetricThresholdFilter
class MetricThresholdFilter
Defines a filter that compares a run metric against a user-defined threshold value.
property MetricThresholdFilter.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property MetricThresholdFilter.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
8 - NewAutomation
class NewAutomation
A new automation to be created.
property NewAutomation.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property NewAutomation.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
property NewAutomation.scope
The scope in which the triggering event must occur.
9 - OnAddArtifactAlias
class OnAddArtifactAlias
A new alias is assigned to an artifact.
property OnAddArtifactAlias.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property OnAddArtifactAlias.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
method OnAddArtifactAlias.then
then(action: 'InputAction') → NewAutomation
Define a new Automation in which this event triggers the given action.
10 - OnCreateArtifact
class OnCreateArtifact
A new artifact is created.
property OnCreateArtifact.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property OnCreateArtifact.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
method OnCreateArtifact.then
then(action: 'InputAction') → NewAutomation
Define a new Automation in which this event triggers the given action.
11 - OnLinkArtifact
class OnLinkArtifact
A new artifact is linked to a collection.
property OnLinkArtifact.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property OnLinkArtifact.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
method OnLinkArtifact.then
then(action: 'InputAction') → NewAutomation
Define a new Automation in which this event triggers the given action.
12 - OnRunMetric
class OnRunMetric
A run metric satisfies a user-defined condition.
property OnRunMetric.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property OnRunMetric.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
method OnRunMetric.then
then(action: 'InputAction') → NewAutomation
Define a new Automation in which this event triggers the given action.
13 - ProjectScope
class ProjectScope
An automation scope defined by a specific Project
.
property ProjectScope.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property ProjectScope.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
14 - RunEvent
class RunEvent
method RunEvent.metric
metric(name: 'str') → MetricVal
Define a metric filter condition.
16 - SendNotification
class SendNotification
Defines an automation action that sends a (Slack) notification.
property SendNotification.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property SendNotification.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
classmethod SendNotification.from_integration
from_integration(
integration: 'SlackIntegration',
title: 'str' = '',
text: 'str' = '',
level: 'AlertSeverity' = <AlertSeverity.INFO: 'INFO'>
) → Self
Define a notification action that sends to the given (Slack) integration.
17 - SendWebhook
class SendWebhook
Defines an automation action that sends a webhook request.
property SendWebhook.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property SendWebhook.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
classmethod SendWebhook.from_integration
from_integration(
integration: 'WebhookIntegration',
payload: 'Optional[SerializedToJson[dict[str, Any]]]' = None
) → Self
Define a webhook action that sends to the given (webhook) integration.
18 - SlackIntegration
class SlackIntegration
property SlackIntegration.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property SlackIntegration.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.
19 - WebhookIntegration
class WebhookIntegration
property WebhookIntegration.model_extra
Get extra fields set during validation.
Returns:
A dictionary of extra fields, or None
if config.extra
is not set to "allow"
.
property WebhookIntegration.model_fields_set
Returns the set of fields that have been explicitly set on this model instance.
Returns: A set of strings representing the fields that have been set, i.e. that were not filled from defaults.