import re


def preprocess_decomp_rule(in_str):
    """Preprocess a decomposition rule before converting to regex.

    Parameters
    ----------
    in_str : str
        String representing a decomposition rule.

    Returns
    -------
    in_str: str[]
        List of components in decomposition rule.
    """
    # The input is of the form: e.g. (0 YOU 0)
    # Strip parenthesis
    in_str = re.sub('[()]', '', in_str)

    # Split string into space separated list
    return in_str.split()