code: def process_story(raw_story):
      """Extract the story and summary from a story file.
  
      Arguments:
          raw_story (str): content of the story file as an utf-8 encoded string.
  
      Raises:
          IndexError: If the story is empty or contains no highlights.
      """
      nonempty_lines = list(
          filter(
              lambda x: len(x) != 0,
              [line.strip() for line in raw_story.split("\n")],
          )
      )
  
      # for some unknown reason some lines miss a period, add it
      nonempty_lines = [
          _add_missing_period(line) for line in nonempty_lines
      ]
  
      # gather article lines
      story_lines = []
      lines = deque(nonempty_lines)
      while True:
          try:
              element = lines.popleft()
              if element.startswith("@highlight"):
                  break
              story_lines.append(element)
          except IndexError:
              # if "@highlight" is absent from the file we pop
              # all elements until there is None, raising an exception.
              return story_lines, []
  
      # gather summary lines
      summary_lines = list(
          filter(lambda t: not t.startswith("@highlight"), lines)
      )
  
      return story_lines, summary_lines
  
file_path: H2O/h2o_flexgen/benchmark/third_party/transformers/examples/research_projects/bertabs/utils_summarization.py
imports: import os
  from collections import deque
  import torch
  from torch.utils.data import Dataset
label_desc: Use image node_id 1 for calling a global function with example usage: process_story(raw_story) and returns: story_lines,  summary_lines, story_lines,  list