class_docstr: Base class to implement a new LLM.
docstr: Extract the code from the response.
  
  Args:
      response (str): Response
      separator (str, optional): Separator. Defaults to "```".
  
  Raises:
      NoCodeFoundError: No code found in the response
  
  Returns:
      str: Extracted code from the response
docstr_tok: ["Extract","the","code","from","the","response",".","Args",":","response","(","str",")",":","Response","separator","(","str",",","optional",")",":","Separator",".","Defaults","to","``","``","`","``",".","Raises",":","NoCodeFoundError",":","No","code","found","in","the","response","Returns",":","str",":","Extracted","code","from","the","response"]
code: def _extract_code(self, response: str, separator: str = "```") -> str:
      """
      Extract the code from the response.
  
      Args:
          response (str): Response
          separator (str, optional): Separator. Defaults to "```".
  
      Raises:
          NoCodeFoundError: No code found in the response
  
      Returns:
          str: Extracted code from the response
  
      """
      code = response
      if len(code.split(separator)) > 1:
          code = code.split(separator)[1]
      code = self._polish_code(code)
      if not self._is_python_code(code):
          raise NoCodeFoundError("No code found in the response")
  
      return code
  
imports: import os
  import ast
  import re
  from abc import abstractmethod
  from typing import Any, Dict, Optional, Union, Mapping, Tuple
  import requests
  from ..exceptions import APIKeyNotFoundError, MethodNotImplementedError, NoCodeFoundError, LLMResponseHTTPError
  from ..helpers.openai import is_openai_v1
  from ..helpers.openai_info import openai_callback_var
  from ..prompts.base import AbstractPrompt
label_desc: Use image node_id 5 for calling the LLM obj's underlying member method code with example usage: obj._extract_code(response, separator) and returns: code