def __init__(
            self,
            lexicons: Dict[str, List[List[str]]],
            definitions: Optional[Dict[str, str]] = None,
            case_sensitive: bool = False
    ):
        '''
        :param lexicons: Dict[str, List[List[str]]], maps a topic name to its list of word sequences
        :param definitions, Optional[Dict[str, str]], maps topic name to an explanation.
        :param case_sensitive: bool, are word sequences case-sensitive?
        '''
        self.definitions = definitions
        self.keyword_processor = flashtext.KeywordProcessor(case_sensitive)
        self.keyword_processor.add_keywords_from_dict({
            topic: [' '.join(term_sequence) for term_sequence in term_sequences]
            for topic, term_sequences in lexicons.items()
        })

        :param lexicons: Dict[str, List[List[str]]], maps a topic name to its list of word sequences
        :param definitions, Optional[Dict[str, str]], maps topic name to an explanation.
        :param case_sensitive: bool, are word sequences case-sensitive?
        
scattertext/features/CognitiveDistortionsOffsetGetter.py