code: def main(cfg):
      cfg.cwd = utils.get_original_cwd()
  
      text = cfg.text_input
  
      if not cfg.api_key:
          raise ValueError("Need an API Key.")
      if cfg.engine not in [
          "text-davinci-003",
          "text-davinci-002",
          "text-curie-001",
          "text-babbage-001",
          "text-ada-001",
          "gpt-3.5-turbo",
      ]:
          raise ValueError("The OpenAI model is not supported now.")
  
      os.environ["OPENAI_API_KEY"] = cfg.api_key
  
      ie_prompter = IEPrompt(cfg.task)
  
      examples = None
      if not cfg.zero_shot:
          examples = prepare_examples(
              cfg.data_path, cfg.task, cfg.language
          )
  
      if cfg.task == "re":
          ie_prompter.build_prompt(
              prompt=text,
              head_entity=cfg.head_entity,
              head_type=cfg.head_type,
              tail_entity=cfg.tail_entity,
              tail_type=cfg.tail_type,
              language=cfg.language,
              instruction=cfg.instruction,
              in_context=not cfg.zero_shot,
              domain=cfg.domain,
              labels=cfg.labels,
              examples=examples,
          )
      else:
          ie_prompter.build_prompt(
              prompt=text,
              language=cfg.language,
              instruction=cfg.instruction,
              in_context=not cfg.zero_shot,
              domain=cfg.domain,
              labels=cfg.labels,
              examples=examples,
          )
  
      result = ie_prompter.get_openai_result()
      logger.info(result)
  
file_path: DeepKE/example/llm/LLMICL/run.py
imports: import os
  import json
  import hydra
  from hydra import utils
  import logging
  from easyinstruct.prompts import IEPrompt
  from .preprocess import prepare_examples
label_desc: Use image node_id 1 for calling a global function with example usage: main(cfg) without return types