Class WikiText2.Builder

java.lang.Object
ai.djl.basicdataset.nlp.WikiText2.Builder
Enclosing class:
WikiText2

public static final class WikiText2.Builder extends Object
A builder to construct a WikiText2 .
  • Method Details

    • optRepository

      public WikiText2.Builder optRepository(ai.djl.repository.Repository repository)
      Sets the optional repository for the dataset.
      Parameters:
      repository - the new repository
      Returns:
      this builder
    • optGroupId

      public WikiText2.Builder optGroupId(String groupId)
      Sets optional groupId.
      Parameters:
      groupId - the groupId
      Returns:
      this builder
    • optArtifactId

      public WikiText2.Builder optArtifactId(String artifactId)
      Sets the optional artifactId.
      Parameters:
      artifactId - the artifactId
      Returns:
      this builder
    • optUsage

      public WikiText2.Builder optUsage(ai.djl.training.dataset.Dataset.Usage usage)
      Sets the optional usage for the dataset.
      Parameters:
      usage - the usage
      Returns:
      this builder
    • build

      public WikiText2 build()
      Builds a new WikiText2 object.
      Returns:
      the new WikiText2 object