public static void copyBreaksByTime(List<Word> words, List<Region> breaks) {
    int break_idx = 0;
    int word_idx = 0;
    String previous_break = null;

    while (break_idx < breaks.size() && word_idx < words.size()) {

      Region b = breaks.get(break_idx);
      Word word = words.get(word_idx);

      if (b.getEnd() < word.getStart()) {        
        break_idx++;
      } else if (word.getEnd() < b.getStart()) {
        if (word.getBreakAfter() == null) {
          word.setBreakBefore(previous_break);
          word.setBreakAfter("1");
          previous_break = "1";
          
        }
        word_idx++;
      } else {
        // Assign break to word
        word.setBreakBefore(previous_break);
        String current_break = breaks.get(break_idx).getLabel();
        word.setBreakAfter(current_break);
        previous_break = current_break;

        break_idx++;
      }
    }
  }