<commit_before>package ru.circumflex
package diff

class Chunk[T](val original: Seq[T], val revised: Seq[T])

class InsertChunk[T](original: Seq[T], revised: Seq[T])
    extends Chunk(original, revised) {

  override def toString = "[InsertChunk, elements: " +
      revised.mkString(", ") + "]";
}

class DeleteChunk[T](original: Seq[T], revised: Seq[T])
    extends Chunk(original, revised) {

  override def toString = "[DeleteChunk, elements: " +
      original.mkString(", ") + "]";
}

class ChangeChunk[T](original: Seq[T], revised: Seq[T])
    extends Chunk(original, revised) {

  override def toString = "[ChangeChunk, elements: " +
      original.mkString(", ") + " to " + revised.mkString(", ") + "]";
}

class EqualChunk[T](original: Seq[T], revised: Seq[T])
    extends Chunk(original, revised) {
  override def toString = "[EqualChunk, elements: " +
      original.mkString(", ") + "]";
}

class Difference[T](val chunks: Seq[Chunk[T]]) extends Seq[Chunk[T]] {
  def length = chunks.size
  def apply(idx: Int) = chunks(idx)
  def iterator = chunks.iterator
}<commit_msg>Chagned Chuck from class to sealed trait<commit_after>package ru.circumflex
package diff

sealed trait Chunk[T]{
  def original: Seq[T]
  def revised: Seq[T]
}

class InsertChunk[T](val original: Seq[T], val revised: Seq[T])
    extends Chunk[T] {

  override def toString = "[InsertChunk, elements: " +
      revised.mkString(", ") + "]";
}

class DeleteChunk[T](val original: Seq[T], val revised: Seq[T])
    extends Chunk[T] {

  override def toString = "[DeleteChunk, elements: " +
      original.mkString(", ") + "]";
}

class ChangeChunk[T](val original: Seq[T], val revised: Seq[T])
    extends Chunk[T] {

  override def toString = "[ChangeChunk, elements: " +
      original.mkString(", ") + " to " + revised.mkString(", ") + "]";
}

class EqualChunk[T](val original: Seq[T], val revised: Seq[T])
    extends Chunk[T] {
  override def toString = "[EqualChunk, elements: " +
      original.mkString(", ") + "]";
}

class Difference[T](val chunks: Seq[Chunk[T]]) extends Seq[Chunk[T]] {
  def length = chunks.size
  def apply(idx: Int) = chunks(idx)
  def iterator = chunks.iterator
}
{'fraction_non_alphanumeric': 0.16873563218390805, 'fraction_numerical': 0.0, 'mean_word_length': 4.281553398058253, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2223057', 'n_tokens_mistral': 753, 'n_tokens_neox': 753, 'n_words': 182}