메인 콘텐츠로 건너뛰기

class OnLinkArtifact

새 artifact가 collection에 연결됩니다. 예시: alias “prod”와 함께 artifact가 collection “my-collection”에 연결될 때 트리거되는 이벤트를 정의합니다:
from wandb import Api
from wandb.automations import OnLinkArtifact, ArtifactEvent

api = Api()
collection = api.artifact_collection(name="my-collection", type_name="model")

event = OnLinkArtifact(
    scope=collection,
    filter=ArtifactEvent.alias.eq("prod"),
)

메서드 OnLinkArtifact.__init__

__init__(
    event_type: 'Literal[LINK_ARTIFACT]' = LINK_ARTIFACT,
    scope: '_ArtifactSequenceScope | _ArtifactPortfolioScope | ProjectScope',
    filter: 'And | Or | Nor | Not | Lt | Gt | Lte | Gte | Eq | Ne | In | NotIn | Exists | Regex | Contains | FilterExpr | dict[str, Any]' = And(())
) → None
매개변수:
  • event_type (Literal[LINK_ARTIFACT]):
  • scope (Union[_ArtifactSequenceScope, _ArtifactPortfolioScope, ProjectScope]): 이벤트의 범위입니다.
  • filter (Union[And, Or, Nor, Not, Lt, Gt, Lte, Gte, Eq, Ne, In, NotIn, Exists, Regex, Contains, FilterExpr, Dict[str, Any]]): 이 이벤트를 트리거하기 위해 필요한 추가 조건(있는 경우)입니다.
반환값: OnLinkArtifact 객체입니다.