Description
Pretrained T5ForConditionalGeneration model, adapted from Hugging Face and curated to provide scalability and production-readiness using Spark NLP. ke-t5-base-ko
is a Korean model originally trained by KETI-AIR
.
How to use
documentAssembler = DocumentAssembler() \
.setInputCols("text") \
.setOutputCols("document")
t5 = T5Transformer.pretrained("t5_ke_base","ko") \
.setInputCols("document") \
.setOutputCol("answers")
pipeline = Pipeline(stages=[documentAssembler, t5])
data = spark.createDataFrame([["PUT YOUR STRING HERE"]]).toDF("text")
result = pipeline.fit(data).transform(data)
val documentAssembler = new DocumentAssembler()
.setInputCols("text")
.setOutputCols("document")
val t5 = T5Transformer.pretrained("t5_ke_base","ko")
.setInputCols("document")
.setOutputCol("answers")
val pipeline = new Pipeline().setStages(Array(documentAssembler, t5))
val data = Seq("PUT YOUR STRING HERE").toDS.toDF("text")
val result = pipeline.fit(data).transform(data)
Model Information
Model Name: | t5_ke_base |
Compatibility: | Spark NLP 4.3.0+ |
License: | Open Source |
Edition: | Official |
Input Labels: | [documents] |
Output Labels: | [t5] |
Language: | ko |
Size: | 569.1 MB |
References
- https://huggingface.co/KETI-AIR/ke-t5-base-ko
- https://github.com/google-research/text-to-text-transfer-transformer#released-model-checkpoints
- https://github.com/AIRC-KETI/ke-t5
- https://aclanthology.org/2021.findings-emnlp.33/
- https://jmlr.org/papers/volume21/20-074/20-074.pdf
- https://ai.googleblog.com/2020/02/exploring-transfer-learning-with-t5.html
- https://aclanthology.org/2021.acl-long.330.pdf
- https://dl.acm.org/doi/pdf/10.1145/3442188.3445922
- https://www.tensorflow.org/datasets/catalog/c4
- https://jmlr.org/papers/volume21/20-074/20-074.pdf
- https://mlco2.github.io/impact#compute
- https://arxiv.org/abs/1910.09700