def delete_pipeline(task: str) -> None:
    """
    Remove pipelines from current registry by task name.
    """
    if HAS_PIPELINE_REGISTRY:
        from transformers.pipelines import PIPELINE_REGISTRY

        del PIPELINE_REGISTRY.supported_tasks[task]
    else:
        # For backward compatibility
        from transformers.pipelines import SUPPORTED_TASKS

        del SUPPORTED_TASKS[task]
Remove pipelines from current registry by task name.
src/bentoml/_internal/frameworks/transformers.py