nemo_curator.stages.interleaved.io.writers.base
nemo_curator.stages.interleaved.io.writers.base
Module Contents
Classes
API
Bases: ProcessingStage[InterleavedBatch, FileGroupTask]
Base class for interleaved writers.
Handles filesystem setup, deterministic file naming, optional binary
materialization, schema alignment, and process() orchestration.
Subclasses implement _write_dataframe for format-specific output.
If schema is set, every output table is aligned to it (missing columns
become typed nulls, extra columns are dropped, types are reconciled).
By default (schema=None) extra user columns are preserved and only
reserved-column types are reconciled via reconcile_schema.
Use schema or schema_overrides only when strict column control is needed (e.g. to prevent heterogeneous-schema crashes).
Reconcile or align df to the declared schema.
Format-specific DataFrame writer. Subclasses must implement this.
Subclasses that override write_data() or process() directly
(e.g. writers that do not follow the one-file-per-task pattern) may
override this method as a no-op instead.