code: def alpaca_pt(messages):
      prompt = custom_prompt(
          role_dict={
              "system": {
                  "pre_message": "### Instruction:\n",
                  "post_message": "\n\n",
              },
              "user": {
                  "pre_message": "### Instruction:\n",
                  "post_message": "\n\n",
              },
              "assistant": {
                  "pre_message": "### Response:\n",
                  "post_message": "\n\n",
              },
          },
          bos_token="<s>",
          eos_token="</s>",
          messages=messages,
      )
      return prompt
  
imports: from enum import Enum
  import requests, traceback
  import json
  from jinja2 import Template, exceptions, Environment, meta
  from typing import Optional, Any
label_desc: Use image node_id 2 for calling a global function with example usage: alpaca_pt(messages) and returns: prompt