Skip to main content

run_interactive_task

Run an interactive DAG task from a FlowSpec YAML file.

This script is the CLI counterpart of the JOB_REQUEST gRPC trigger for the interactive phase. It loads a v9 FlowSpec YAML, builds the interactive DAG, and executes it locally against the background cache.

The interactive phase is post-processing (GA calculation, criteria matching, report generation) that reads the background phase's model-inference results from the cache. The background phase must therefore have already run for the same pod + datasource (e.g. via bitfount run_background_task); otherwise the interactive steps' cross-phase references fail fast.

Prerequisites

  • The pod must have been started at least once via bitfount run_pod so the background cache (~/.bitfount/cache/pods/<pod_name>/background_cache.db) is populated with file metadata.
  • The background DAG must have already run so the model-inference rows the interactive steps reference exist in that cache.

Usage

bitfount run_interactive_task path/to/flow_spec.yaml \\
--pod-config path/to/pod_config.yaml \\
--datasource-name my-dataset \\
[--project-id my-project-001]

--pod-config is the same YAML passed to bitfount run_pod; it is used to materialise the datasource and schema the interactive steps need.

If --project-id is omitted a local run ID is generated. You must provide a project ID when the DAG includes steps that require model access gated by project.

Module

Functions

run

def run(    path_to_task_yaml: str | PathLike[str],    pod_config: str | PathLike[str],    datasource_name: str,    project_id: str | None = None,)> None:

Run an interactive DAG from a FlowSpec YAML file.

Arguments

  • path_to_task_yaml: Path to the v9 FlowSpec YAML file.
  • pod_config: Path to the pod config YAML (the same file passed to bitfount run_pod). Used to materialise the datasource and its schema exactly as the live pod would.
  • datasource_name: Name of the datasource to run against (must exist in the pod config). Selects the background cache partition the interactive steps read from.
  • project_id: Optional project ID for Hub completion reporting and model access gating. Defaults to a generated local run ID.