code: def create_frame(text, intent_label, slot_names_str, byte_len):
      frame = Node(
          label=intent_label,
          span=Span(0, byte_len),
          children={
              Node(label=slot.label, span=Span(slot.start, slot.end))
              for slot in parse_slot_string(slot_names_str)
          },
          text=text,
      )
      return frame
  
imports: from typing import Dict, List, Optional
  from pytext.common.constants import DatasetFieldName, Stage
  from pytext.data.data_structures.annotation import CLOSE, escape_brackets, OPEN
  from pytext.metrics.intent_slot_metrics import compute_all_metrics, FramePredictionPair, Node, Span
  from pytext.utils.data import byte_length, get_substring_from_offsets, merge_token_labels_to_slot, parse_slot_string
  from .channel import Channel, ConsoleChannel, FileChannel
  from .metric_reporter import MetricReporter
label_desc: Use image node_id 1 for calling a global function with example usage: create_frame(text, intent_label, slot_names_str, byte_len) and returns: frame