class_docstr: A class that represent a notebook cell as text
class_docstr_tok: ["A","class","that","represent","a","notebook","cell","as","text"]
code: def __init__(
      self, cell, default_language, fmt=None, unsupported_keys=None
  ):
      self.fmt = fmt or {}
      self.ext = self.fmt.get("extension")
      self.cell_type = cell.cell_type
      self.source = cell_source(cell)
      self.unfiltered_metadata = cell.metadata
      self.metadata = filter_metadata(
          cell.metadata,
          self.fmt.get("cell_metadata_filter"),
          _IGNORE_CELL_METADATA,
          unsupported_keys=unsupported_keys,
      )
      if self.parse_cell_language:
          custom_cell_magics = self.fmt.get(
              "custom_cell_magics", ""
          ).split(",")
          self.language, magic_args = cell_language(
              self.source, default_language, custom_cell_magics
          )
  
          if magic_args:
              self.metadata["magic_args"] = magic_args
      else:
          self.language = None
  
      if self.language and not self.ext.endswith(".Rmd"):
          self.metadata["language"] = self.language
  
      self.language = self.language or cell.metadata.get(
          "language", default_language
      )
      self.default_language = default_language
      self.comment = _SCRIPT_EXTENSIONS.get(self.ext, {}).get(
          "comment", "#"
      )
      self.comment_suffix = _SCRIPT_EXTENSIONS.get(self.ext, {}).get(
          "comment_suffix", ""
      )
      self.comment_magics = self.fmt.get(
          "comment_magics", self.default_comment_magics
      )
      self.cell_metadata_json = self.fmt.get(
          "cell_metadata_json", False
      )
      self.use_runtools = self.fmt.get("use_runtools", False)
      self.doxygen_equation_markers = self.fmt.get(
          "doxygen_equation_markers", False
      )
  
      # how many blank lines before next cell
      self.lines_to_next_cell = cell.metadata.get("lines_to_next_cell")
      self.lines_to_end_of_cell_marker = cell.metadata.get(
          "lines_to_end_of_cell_marker"
      )
  
      if (
          cell.cell_type == "raw"
          and "active" not in self.metadata
          and not any(
              tag.startswith("active-")
              for tag in self.metadata.get("tags", [])
          )
      ):
          self.metadata["active"] = ""
  
imports: import re
  import warnings
  from copy import copy
  from .cell_metadata import _IGNORE_CELL_METADATA, is_active, metadata_to_double_percent_options, metadata_to_rmd_options, metadata_to_text
  from .cell_reader import LightScriptCellReader, MarkdownCellReader, RMarkdownCellReader
  from .doxygen import markdown_to_doxygen
  from .languages import _SCRIPT_EXTENSIONS, cell_language, comment_lines, same_language
  from .magics import comment_magic, escape_code_start, need_explicit_marker
  from .metadata_filter import filter_metadata
  from .pep8 import pep8_lines_between_cells
label_desc: Use image node_id 1 to create a new BaseCellExporter object  with example: obj = BaseCellExporter(cell, default_language, fmt, unsupported_keys)