U
    -eH                     @   s8   d Z ddlZddlmZ ddlmZ eedddZdS )zCContains utilities to flag a feature as "experimental" in datasets.    Nwraps)Callable)fnreturnc                    s   t   fdd}|S )al  Decorator to flag a feature as experimental.

    An experimental feature trigger a warning when used as it might be subject to breaking changes in the future.

    Args:
        fn (`Callable`):
            The function to flag as experimental.

    Returns:
        `Callable`: The decorated function.

    Example:

    ```python
    >>> from datasets.utils import experimental

    >>> @experimental
    ... def my_function():
    ...     print("Hello world!")

    >>> my_function()
    UserWarning: 'my_function' is experimental and might be subject to breaking changes in the future.
    Hello world!
    ```
    c                     s    t d j dt  | |S )N'zI' is experimental and might be subject to breaking changes in the future.)warningswarn__name__UserWarning)argskwargsr    \/var/www/html/Darija-Ai-Train/env/lib/python3.8/site-packages/datasets/utils/experimental.py	_inner_fn"   s
    zexperimental.<locals>._inner_fnr   )r   r   r   r   r   experimental   s    r   )__doc__r   	functoolsr   typingr   r   r   r   r   r   <module>   s   