code: def generate_text_documentation(
      pydantic_models: List[Type[BaseModel]],
      model_prefix="Model",
      fields_prefix="Fields",
      documentation_with_field_description=True,
  ) -> str:
      """
      Generate text documentation for a list of Pydantic models.
  
      Args:
          pydantic_models (List[Type[BaseModel]]): List of Pydantic model classes.
          model_prefix (str): Prefix for the model section.
          fields_prefix (str): Prefix for the fields section.
          documentation_with_field_description (bool): Include field descriptions in the documentation.
  
      Returns:
          str: Generated text documentation.
      """
      documentation = ""
      pyd_models = [(model, True) for model in pydantic_models]
      for model, add_prefix in pyd_models:
          if add_prefix:
              documentation += f"{model_prefix}: {model.__name__}\n"
          else:
              documentation += f"Model: {model.__name__}\n"
  
          # Handling multi-line model description with proper indentation
  
          class_doc = getdoc(model)
          base_class_doc = getdoc(BaseModel)
          class_description = (
              class_doc
              if class_doc and class_doc != base_class_doc
              else ""
          )
          if class_description != "":
              documentation += "  Description: "
              documentation += (
                  "\n"
                  + format_multiline_description(class_description, 2)
                  + "\n"
              )
  
          if isclass(model) and issubclass(model, BaseModel):
              documentation_fields = ""
              for name, field_type in model.__annotations__.items():
                  # if name == "markdown_code_block":
                  #    continue
                  if get_origin(field_type) == list:
                      element_type = get_args(field_type)[0]
                      if isclass(element_type) and issubclass(
                          element_type, BaseModel
                      ):
                          pyd_models.append((element_type, False))
                  if get_origin(field_type) == Union:
                      element_types = get_args(field_type)
                      for element_type in element_types:
                          if isclass(element_type) and issubclass(
                              element_type, BaseModel
                          ):
                              pyd_models.append((element_type, False))
                  documentation_fields += generate_field_text(
                      name,
                      field_type,
                      model,
                      documentation_with_field_description=documentation_with_field_description,
                  )
              if documentation_fields != "":
                  if add_prefix:
                      documentation += (
                          f"  {fields_prefix}:\n{documentation_fields}"
                      )
                  else:
                      documentation += (
                          f"  Fields:\n{documentation_fields}"
                      )
              documentation += "\n"
  
          if (
              hasattr(model, "Config")
              and hasattr(model.Config, "json_schema_extra")
              and "example" in model.Config.json_schema_extra
          ):
              documentation += f"  Expected Example Output for {format_model_and_field_name(model.__name__)}:\n"
              json_example = json.dumps(
                  model.Config.json_schema_extra["example"]
              )
              documentation += (
                  format_multiline_description(json_example, 2) + "\n"
              )
  
      return documentation
  
imports: import inspect
  import json
  from copy import copy
  from inspect import isclass, getdoc
  from types import NoneType
  from docstring_parser import parse
  from pydantic import BaseModel, create_model, Field
  from typing import Any, Type, List, get_args, get_origin, Tuple, Union, Optional, _GenericAlias
  from enum import Enum
  from typing import get_type_hints, Callable
  import re
  from enum import Enum
label_desc: Use image node_id 15 for calling a global function with example usage: generate_text_documentation(pydantic_models, model_prefix, fields_prefix, documentation_with_field_description) and returns: documentation