code: def extract_keyterms(doc: Doc, method: str, **kwargs):
      """
      Extract keyterms from a document using one of several different methods.
      For full detail, see the underlying functions listed below.
  
      See Also:
          - :func:`textacy.extract.keyterms.scake()`
          - :func:`textacy.extract.keyterms.sgrank()`
          - :func:`textacy.extract.keyterms.textrank()`
          - :func:`textacy.extract.keyterms.yake()`
      """
      if method == "scake":
          return keyterms.scake(doc, **kwargs)
      elif method == "sgrank":
          return keyterms.sgrank(doc, **kwargs)
      elif method == "textrank":
          return keyterms.textrank(doc, **kwargs)
      elif method == "yake":
          return keyterms.yake(doc, **kwargs)
      else:
          raise ValueError(
              errors.value_invalid_msg(
                  "method",
                  method,
                  {"scake", "sgrank", "textrank", "yake"},
              )
          )
  
file_path: textacy/src/textacy/extract/_exts.py
imports: from __future__ import annotations
  from spacy.tokens import Doc
  from ..None import errors, types
  from ..spacier.extensions import doc_extensions_registry
  from .None import acros, bags, basics, keyterms, kwic, matches, triples
label_desc: Use image node_id 1 for calling a global function with example usage: extract_keyterms(doc, method) and returns: keyterms, keyterms, keyterms, keyterms