<commit_before>package com.sksamuel.elastic4s

/** @author <NAME> */
case class IndexesTypes(indexes: Seq[String], types: Seq[String]) {
  def index = indexes.headOption.getOrElse(throw new RuntimeException("Specify at least one index"))
  def typ = types.headOption
}
object IndexesTypes {
  def apply(indexes: Iterable[String]): IndexesTypes = indexes.size match {
    case 0 => throw new RuntimeException("Could not parse into index/type")
    case 1 => apply(index)
    case _ => apply(more.toSeq, Nil)
  }
  def apply(tuple: (String, String)): IndexesTypes = apply(tuple._1, tuple._2)
  def apply(index: String, `type`: String): IndexesTypes = IndexesTypes(List(index), List(`type`))
  def apply(string: String): IndexesTypes = {
    string.split("/") match {
      case Array(index) => IndexesTypes(Array(index), Nil)
      case Array(index, t) => IndexesTypes(List(index), List(t))
      case _ => throw new RuntimeException("Could not parse into index/type")
    }
  }
}
trait IndexesTypesDsl {
  implicit def string2indexestypes(string: String): IndexesTypes = IndexesTypes(string)
  implicit def tuple2indexestypes(tuple: (String, String)): IndexesTypes = IndexesTypes(tuple)
}<commit_msg>Release 1.3.2<commit_after>package com.sksamuel.elastic4s

/** @author <NAME> */
case class IndexesTypes(indexes: Seq[String], types: Seq[String]) {
  def index = indexes.headOption.getOrElse(throw new RuntimeException("Specify at least one index"))
  def typ = types.headOption
}
object IndexesTypes {
  def apply(indexes: Iterable[String]): IndexesTypes = indexes.size match {
    case 0 => throw new RuntimeException("Could not parse into index/type")
    case 1 => apply(indexes.head)
    case _ => apply(indexes.toSeq, Nil)
  }
  def apply(tuple: (String, String)): IndexesTypes = apply(tuple._1, tuple._2)
  def apply(index: String, `type`: String): IndexesTypes = IndexesTypes(List(index), List(`type`))
  def apply(string: String): IndexesTypes = {
    string.split("/") match {
      case Array(index) => IndexesTypes(Array(index), Nil)
      case Array(index, t) => IndexesTypes(List(index), List(t))
      case _ => throw new RuntimeException("Could not parse into index/type")
    }
  }
}
trait IndexesTypesDsl {
  implicit def string2indexestypes(string: String): IndexesTypes = IndexesTypes(string)
  implicit def tuple2indexestypes(tuple: (String, String)): IndexesTypes = IndexesTypes(tuple)
}
{'fraction_non_alphanumeric': 0.13164451827242524, 'fraction_numerical': 0.0070598006644518275, 'mean_word_length': 4.918918918918919, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 17, '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': '3134673', 'n_tokens_mistral': 763, 'n_tokens_neox': 752, 'n_words': 197}