BERT Base Cased


This model contains a deep bidirectional transformer trained on Wikipedia and the BookCorpus. The details are described in the paper “BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding”.


How to use

embeddings = BertEmbeddings.pretrained("bert_base_cased", "en") \
      .setInputCols("sentence", "token") \

val embeddings = BertEmbeddings.pretrained("bert_base_cased", "en")
      .setInputCols("sentence", "token")

Model Information

Model Name: bert_base_cased
Type: embeddings
Compatibility: Spark NLP 2.4.0+
License: Open Source
Edition: Official
Input Labels: [sentence, token]
Output Labels: [word_embeddings]
Language: [en]
Dimension: 768
Case sensitive: true

Data Source

The model is imported from