code: def _get_prompt_and_tools(
      df: Any,
      prefix: Optional[str] = None,
      suffix: Optional[str] = None,
      input_variables: Optional[List[str]] = None,
      include_df_in_prompt: Optional[bool] = True,
      number_of_head_rows: int = 5,
      format_instructions=FORMAT_INSTRUCTIONS,
  ) -> Tuple[BasePromptTemplate, List[PythonAstREPLTool]]:
      try:
          import pandas as pd
  
          pd.set_option("display.max_columns", None)
      except ImportError:
          raise ImportError(
              "pandas package not found, please install with `pip install pandas`"
          )
  
      if include_df_in_prompt is not None and suffix is not None:
          raise ValueError(
              "If suffix is specified, include_df_in_prompt should not be."
          )
  
      if isinstance(df, list):
          for item in df:
              if not isinstance(item, pd.DataFrame):
                  raise ValueError(
                      f"Expected pandas object, got {type(df)}"
                  )
          return _get_multi_prompt(
              df,
              prefix=prefix,
              suffix=suffix,
              input_variables=input_variables,
              include_df_in_prompt=include_df_in_prompt,
              number_of_head_rows=number_of_head_rows,
          )
      else:
          if not isinstance(df, pd.DataFrame):
              raise ValueError(
                  f"Expected pandas object, got {type(df)}"
              )
          return _get_single_prompt(
              df,
              prefix=prefix,
              suffix=suffix,
              input_variables=input_variables,
              include_df_in_prompt=include_df_in_prompt,
              number_of_head_rows=number_of_head_rows,
              format_instructions=format_instructions,
          )
  
imports: from io import IOBase
  from typing import Any, Dict, List, Optional, Sequence, Tuple, Union
  from langchain._api import warn_deprecated
  from langchain.agents import AgentExecutor, BaseSingleActionAgent
  from langchain_experimental.agents.agent_toolkits.pandas.prompt import FUNCTIONS_WITH_DF, FUNCTIONS_WITH_MULTI_DF, MULTI_DF_PREFIX, MULTI_DF_PREFIX_FUNCTIONS, PREFIX, PREFIX_FUNCTIONS, SUFFIX_NO_DF, SUFFIX_WITH_DF, SUFFIX_WITH_MULTI_DF
  from langchain.agents.mrkl.base import ZeroShotAgent
  from langchain.agents.mrkl.prompt import FORMAT_INSTRUCTIONS
  from langchain.agents.openai_functions_agent.base import OpenAIFunctionsAgent
  from langchain.agents.types import AgentType
  from langchain.callbacks.base import BaseCallbackManager
  from langchain.chains.llm import LLMChain
  from langchain.schema import BasePromptTemplate
  from langchain.schema.language_model import BaseLanguageModel
  from langchain.schema.messages import SystemMessage
  from langchain.tools import BaseTool
  from langchain_experimental.tools.python.tool import PythonAstREPLTool
label_desc: Use image node_id 3 for calling a global function with example usage: _get_prompt_and_tools(df, prefix, suffix, input_variables, include_df_in_prompt, number_of_head_rows, format_instructions) and returns: _get_multi_prompt, _get_single_prompt