code: def generate(query):
      return generate_text(query, max_new_tokens=150)[0][
          "generated_text"
      ]
  
imports: import gradio
  import torch
  import os
  from transformers import AutoTokenizer, AutoModelForCausalLM
  from h2oai_pipeline import H2OTextGenerationPipeline
label_desc: Use image node_id 1 for calling a global function with example usage: generate(query) and returns: generate_text