code: def naive_get_text(doc):
      full_text = ""
      for page in doc:
          full_text += page.get_text(
              "text", sort=True, flags=settings.TEXT_FLAGS
          )
          full_text += "\n"
      return full_text
  
file_path: pdf-to-markdown/marker/extract_text.py
imports: import os
  from typing import Tuple, List, Optional
  from spellchecker import SpellChecker
  from marker.bbox import correct_rotation
  from marker.ocr.page import ocr_entire_page
  from marker.ocr.utils import detect_bad_ocr, font_flags_decomposer
  from marker.settings import settings
  from marker.schema import Span, Line, Block, Page
  from concurrent.futures import ThreadPoolExecutor
label_desc: Use image node_id 5 for calling a global function with example usage: naive_get_text(doc) and returns: full_text