Package ai.djl.basicdataset.nlp
Class WikiText2.Builder
java.lang.Object
ai.djl.basicdataset.nlp.WikiText2.Builder
- Enclosing class:
- WikiText2
A builder to construct a
WikiText2 .-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a newWikiText2object.optArtifactId(String artifactId) Sets the optional artifactId.optGroupId(String groupId) Sets optional groupId.optRepository(ai.djl.repository.Repository repository) Sets the optional repository for the dataset.optUsage(ai.djl.training.dataset.Dataset.Usage usage) Sets the optional usage for the dataset.
-
Method Details
-
optRepository
Sets the optional repository for the dataset.- Parameters:
repository- the new repository- Returns:
- this builder
-
optGroupId
Sets optional groupId.- Parameters:
groupId- the groupId- Returns:
- this builder
-
optArtifactId
Sets the optional artifactId.- Parameters:
artifactId- the artifactId- Returns:
- this builder
-
optUsage
Sets the optional usage for the dataset.- Parameters:
usage- the usage- Returns:
- this builder
-
build
Builds a newWikiText2object.- Returns:
- the new
WikiText2object
-