AI engineering glossary · NLP embeddings
What is CRF (conditional random field)?
Conditional random field (also called CRF, Linear-chain CRF): A probabilistic model for labelling sequences that scores whole label sequences using features of the input and of neighbouring labels, then normalises over all sequences. It avoids impossible label combinations and is often placed on top of a neural encoder.
Conditional random field: an example
A CRF layer learns that an I-PER tag cannot directly follow an O tag, and so prevents that invalid output.
Related terms
More NLP embeddings terms
- CoNLL-2003
- Constituency parsing
- Contextual embedding
- Continuous bag of words
- Coreference resolution
- Corpus
- Cross-encoder
- Cross-lingual transfer
Where you learn it
Conditional random field is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.