code: def phrases(
      s: TokenSeries,
      min_count: int = 5,
      threshold: int = 10,
      symbol: str = "_",
  ) -> TokenSeries:
      r"""Group up collocations words
  
      Given a pandas Series of tokenized strings, group together bigrams where
      each tokens has at least `min_count` term frequency and where the
      `threshold` is larger than the underline formula.
  
      :math:`\frac{(bigram\_a\_b\_count - min\_count)* len\_vocab }
      { (word\_a\_count * word\_b\_count)}`.
  
      Parameters
      ----------
      s : :class:`texthero._types.TokenSeries`
  
      min_count : int, optional, default=5
          Ignore tokens with frequency less than this.
  
      threshold : int, optional, default=10
          Ignore tokens with a score under that threshold.
  
      symbol : str, optional, default="_"
          Character used to join collocation words.
  
      Examples
      --------
      >>> import texthero as hero
      >>> s = pd.Series([['New', 'York', 'is', 'a', 'beautiful', 'city'],
      ...               ['Look', ':', 'New', 'York', '!']])
      >>> hero.phrases(s, min_count=1, threshold=1)
      0    [New_York, is, a, beautiful, city]
      1                [Look, :, New_York, !]
      dtype: object
  
      Reference
      --------
      `Mikolov, et. al: "Distributed Representations of Words and Phrases and
      their Compositionality"
          <https://arxiv.org/abs/1310.4546>`_
  
      """
  
      if not isinstance(s.iloc[0], list):
          warnings.warn(
              _not_tokenized_warning_message, DeprecationWarning
          )
          s = tokenize(s)
  
      delimiter = symbol.encode("utf-8")
      phrases_model = Phrases(
          sentences,
          min_count=1,
          threshold=1,
          connector_words=ENGLISH_CONNECTOR_WORDS,
      )
      output = pd.Series(phrases_model[s.values], index=s.index)
      print(output)
      return output
  
imports: from gensim.models.phrases import Phrases
  import re
  import string
  from typing import Optional, Set
  import unicodedata
  import numpy
  import pandas
  from texthero._types import TokenSeries, TextSeries, InputSeries
  from typing import List, Callable, Union
  import warnings
label_desc: Use image node_id 24 for calling a global function with example usage: phrases(s, min_count, threshold, symbol) and returns: output