> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/nemo/curator/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/nemo/curator/_mcp/server.

# nemo_curator.tasks.tasks

## Module Contents

### Classes

| Name                                                 | Description                                    |
| ---------------------------------------------------- | ---------------------------------------------- |
| [`Task`](#nemo_curator-tasks-tasks-Task)             | Abstract base class for tasks in the pipeline. |
| [`_EmptyTask`](#nemo_curator-tasks-tasks-_EmptyTask) | Dummy task for testing.                        |

### Data

[`EmptyTask`](#nemo_curator-tasks-tasks-EmptyTask)

[`T`](#nemo_curator-tasks-tasks-T)

### API

```python
class nemo_curator.tasks.tasks.Task(
    task_id: str,
    dataset_name: str,
    data: nemo_curator.tasks.tasks.T,
    _stage_perf: list[nemo_curator.utils.performance_utils.StagePerfStats] = list(),
    _metadata: dict[str, typing.Any] = dict()
)
```

Dataclass

Abstract

**Bases:** `Generic[T]`

Abstract base class for tasks in the pipeline.
A task represents a batch of data to be processed. Different modalities
(text, audio, video) can implement their own task types.
Attributes:
task\_id: Unique identifier for this task
dataset\_name: Name of the dataset this task belongs to
dataframe\_attribute: Name of the attribute that contains the dataframe data. We use this for input/output validations.
\_stage\_perf: List of stages perfs this task has passed through

Get the number of items in this task.

```python
nemo_curator.tasks.tasks.Task.__post_init__() -> None
```

Post-initialization hook.

```python
nemo_curator.tasks.tasks.Task.__repr__() -> str
```

```python
nemo_curator.tasks.tasks.Task.add_stage_perf(
    perf_stats: nemo_curator.utils.performance_utils.StagePerfStats
) -> None
```

Add performance stats for a stage.

```python
nemo_curator.tasks.tasks.Task.validate() -> bool
```

abstract

Validate the task data.

```python
class nemo_curator.tasks.tasks._EmptyTask(
    task_id: str,
    dataset_name: str,
    data: nemo_curator.tasks.tasks.T,
    _stage_perf: list[nemo_curator.utils.performance_utils.StagePerfStats] = list(),
    _metadata: dict[str, typing.Any] = dict()
)
```

Dataclass

**Bases:** [Task\[None\]](#nemo_curator-tasks-tasks-Task)

Dummy task for testing.

```python
nemo_curator.tasks.tasks._EmptyTask.validate() -> bool
```

Validate the task data.

```python
nemo_curator.tasks.tasks.EmptyTask = _EmptyTask(task_id='empty', dataset_name='empty', data=None)
```

```python
nemo_curator.tasks.tasks.T = TypeVar('T')
```