plexus.cli.shared.experiment_runner module
- plexus.cli.shared.experiment_runner.create_tracker_and_experiment_task(*, client: PlexusDashboardClient, account_id: str, procedure_id: str, scorecard_name: str | None = None, score_name: str | None = None, total_items: int = 0) → Tuple[TaskProgressTracker | None, Procedure | None, Task | None]
Create a TaskProgressTracker for an experiment run.
Mirrors the evaluation behavior for experiment operations. Returns the tracker (with its Task created/claimed) and optionally updates the Experiment record.
- Args:
client: Dashboard API client account_id: Account ID procedure_id: Procedure ID to associate with the task scorecard_name: Optional scorecard name for metadata score_name: Optional score name for metadata total_items: Total number of items to process (for Evaluation stage)
- Returns:
Tuple of (TaskProgressTracker or None, Procedure record or None, Task)
- async plexus.cli.shared.experiment_runner.run_experiment_with_task_tracking(*, procedure_id: str, client: PlexusDashboardClient | None = None, account_id: str | None = None, scorecard_name: str | None = None, score_name: str | None = None, total_items: int = 0, **experiment_options) → Dict[str, Any]
Run a procedure with task tracking.
This function creates Task and TaskStage records for progress tracking, then runs the actual procedure using the ProcedureService.
- Args:
procedure_id: ID of the procedure to run client: Dashboard API client account_id: Account ID scorecard_name: Optional scorecard name for metadata score_name: Optional score name for metadata total_items: Total number of items to process **experiment_options: Additional options to pass to the experiment runner
- Returns:
Dictionary containing experiment run results and task information