From 3f29b1467e944af4356f4b5ecd566b65b7533114 Mon Sep 17 00:00:00 2001 From: TheDude Date: Tue, 13 Aug 2024 14:47:10 +0530 Subject: [PATCH] Add component cache property --- superduper/components/component.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/superduper/components/component.py b/superduper/components/component.py index 4391a3895..28b219040 100644 --- a/superduper/components/component.py +++ b/superduper/components/component.py @@ -85,6 +85,10 @@ class Component(Leaf): :param artifacts: A dictionary of artifacts paths and `DataType` objects :param upstream: A list of upstream components :param plugins: A list of plugins to be used in the component. + :param cache: (Optional) If set `true` the component will not be cached + during primary job of the component i.e on a distributed + cluster this component will be reloaded on every component + task e.g model prediction. """ type_id: t.ClassVar[str] = 'component' @@ -95,6 +99,7 @@ class Component(Leaf): upstream: t.Optional[t.List["Component"]] = None plugins: t.Optional[t.List["Plugin"]] = None artifacts: dc.InitVar[t.Optional[t.Dict]] = None + cache: t.Optional[bool] = False @property def children(self):