def build_repr(self, *args, _to_repr: bool = True, **kwargs) -> str:
    """
    Builds a clear repr string that can be used when overriding
    '__repr__' in classes.

    NOTE: all args and kwargs are by default converted
    to a string using 'str()' or if '_to_repr' is True are
    converted using 'repr()'. If the args or kwargs are already
    a string then no conversion is done.

    :param self: the instance of the class
    :param args: the args that can be used to recreate the instance
    :param _to_repr: if True uses 'repr()' on all args, otherwise
        uses 'str()' on all args
    :param kwargs: the keyword args that can be used to recreate
        the instance
    :return: a clear repr string
    """
    final_args_str = ""

    if len(args) == 1:
        if isinstance(args[0], str):
            final_args_str = args[0]
        else:
            if _to_repr:
                final_args_str = repr(args[0])
            else:
                final_args_str = str(args[0])

    elif len(args) > 1:
        for item in args:
            if isinstance(item, str):
                final_args_str += item + ", "
            else:
                if _to_repr:
                    final_args_str += repr(item) + ", "
                else:
                    final_args_str += str(item) + ", "

    if len(kwargs) >= 1:
        for key, item in kwargs.items():
            if isinstance(item, str):
                final_args_str += f"{key}={item}, "
            else:
                if _to_repr:
                    final_args_str += f"{key}={repr(item)}, "
                else:
                    final_args_str += f"{key}={str(item)}, "

    final_args_str = final_args_str.rstrip(", ")

    return f"{type(self).__name__}({final_args_str})"