Skip to main content
The Inference Phase is where the model meets production. Two components complete the pipeline:
  1. Predictor — offline scoring engine. Applies the full trained pipeline (cleaning → encoding → prediction) to new data using the exact parameters locked during training.
  2. ProductionExporter — deployment artifact. Serializes the champion into a self-contained scoring module with an orchestration layer.
Together, they guarantee that the model that passed the Selection Phase is the exact model that scores in production. Zero drift. Zero re-derivation. Zero ambiguity.

The Objective: Trained Model → Scored Data → Deployed Artifact

The Inference Phase has no training. Everything is locked. The only question is: what data are you scoring, and where does it deploy?

Component 1: Predictor (Inference Engine)

The Predictor loads all trained models from a stored project and provides a symmetrical API to the training pipeline. Every stage is accessible — from raw data cleaning to champion prediction. Requirement: The project must have been trained with save=1.

Usage Modes

  • preprocess=True (default for agent predictions): Pass raw input columns (same schema as training). The full pipeline — cleaning → stability → encoding → prediction — is applied automatically.
  • preprocess=False: Pass pre-encoded data (e.g., WOE features). Skips preprocessing. Useful when chaining stages or when encoding is applied externally.

Accessible Stages

Chainable Access

Individual stages can be called independently to inspect intermediate results:

Component 2: ProductionExporter (Deployment Artifact)

The ProductionExporter serializes the champion agent into production-ready artifacts. The output is a closed, versioned unit — deployable to any inference infrastructure.

What’s Exported

The Exported Agent Contract

The exported pickle exposes exactly four methods: This is the complete runtime interface. No other attributes are accessed at inference time.

Export Configuration

The DAG is fully configurable via ExportConfig:

Practical Implementation

The Output

champion.pkl — load and score with no AIDflow dependency:
dag.py — drop into your Airflow dags/ folder. Configure raw_data_loader and result_sink to point to your data source and warehouse.

Deep Dive: Technical Reference

View Predictor API | View Exporter API