code: def infotext_pasted(infotext, params):
      if "AddNet Module 1" in [
          x[1] for x in scripts.scripts_txt2img.infotext_fields
      ]:
          return  # if the other extension is active, it will handle those fields, no need to do anything
  
      added = []
  
      for k in params:
          if not k.startswith("AddNet Model "):
              continue
  
          num = k[13:]
  
          if params.get("AddNet Module " + num) != "LoRA":
              continue
  
          name = params.get("AddNet Model " + num)
          if name is None:
              continue
  
          m = re_network_name.match(name)
          if m:
              name = m.group(1)
  
          multiplier = params.get("AddNet Weight A " + num, "1.0")
  
          added.append(f"<lora:{name}:{multiplier}>")
  
      if added:
          params["Prompt"] += "\n" + "".join(added)
  
imports: import logging
  import os
  import re
  import lora_patches
  import network
  import network_lora
  import network_glora
  import network_hada
  import network_ia3
  import network_lokr
  import network_full
  import network_norm
  import network_oft
  import torch
  from typing import Union
  from modules import shared, devices, sd_models, errors, scripts, sd_hijack
  import modules.textual_inversion.textual_inversion
  from lora_logger import logger
label_desc: Use image node_id 21 for calling a global function with example usage: infotext_pasted(infotext, params) without return types