Skip to content

Results

Results container: the shared state passed between pipeline steps.

Dict-like container for pipeline step outputs.

Every step reads from and writes to this object. The core contract: step(results) -> results.

def __init__(self):
def keys(self):

Return a view of the stored result keys.

def get(self, key: str, default: Any = None) -> Any:

Safe key access with a default value.

Args:

  • key: Result key to look up.
  • default: Value returned when key is not present.

Returns:

  • The stored value, or default if no value is stored under key.
def copy(self) -> Results:

Return a shallow copy for fan-out pipelines.

Returns:

  • A new Results object whose internal mapping is a shallow copy of
  • the original; values themselves are not duplicated.
def save(self, output_dir: str = DEFAULT_OUTPUT_DIR, run_name: str | None = None, model_id: str = ''):

Save all results to disk.

Args:

  • output_dir: Base directory for outputs.
  • run_name: Optional subdirectory name inside output_dir.
  • model_id: Model identifier for metadata.

Returns:

  • Path to the run directory.