def reformat()

in modules/python/src/datapreprocessing/datacleaner.py [0:0]


    def reformat(self, text: str) -> str:
        """
        Reformats a string by removing square brackets and double quotes.

        Args:
            text (str): The string to reformat.

        Returns:
            str: The reformatted string, or an empty string if the input is NaN.
        """
        if pd.isnull(text):
            return ""
        return text.replace("[", "").replace("]", "").replace('"', "")