Named Entity Recognition (NER) with BiLSTMs, CRFs, and Viterbi Decoding
One of the fundamental building blocks of NLU is Named Entity Recognition (NER). The names of people, companies, products, and quantities can be tagged in a piece of text with NER, which is very useful in chatbot applications and many other use cases in information retrieval and extraction. NER will be the main focus of this chapter. Building and training a model capable of doing NER requires several techniques, such as Conditional Random Fields (CRFs) and Bi-directional LSTMs (BiLSTMs). Advanced TensorFlow techniques like custom layers, losses, and training loops are also used. We will build on the knowledge of BiLSTMs gained from the previous chapter. Specifically, the following will be covered:
- Overview of NER
- Building an NER tagging model with BiLSTM
- CRFs and Viterbi algorithms
- Building a custom Keras layer for CRFs
- Building a custom loss function in Keras and...