code: def get_model_from_words(
      words: Iterable[str],
  ) -> ahocorasick.Automaton:
      model = ahocorasick.Automaton()
      for word in words:
          model.add_word(word, word)
      model.make_automaton()
      return model
  
file_path: camphr/packages/camphr_pattern_search/camphr_pattern_search/__init__.py
imports: import itertools
  from typing import Callable, Iterable, Iterator, List, Optional, Tuple
  import ahocorasick
  from spacy.tokens.token import Token
  import textspan
  from spacy.tokens import Doc, Span
label_desc: Use image node_id 2 for calling the PatternSearcher obj's underlying member method code with example usage: obj.get_model_from_words(words) and returns: model