条件随机场
Only focus on tagging problem and linear chain
Probabilistic Undirected Graphical Model
Pairwise Markov Property
Node $u$, $v$, and all nodes $O$. Their corresponding random variable are $Y_u$, $Y_v$, $Y_O$($Y$ means random variable). They have following probabilistic relationship.
Local Markov Property
Node $v$, $W$ is all nodes adjacent to $v$, and $O$ is remaining nodes. They have following probabilistic relationship.
Global Markov Property
Nodes set $A$, $B$, $C$. $A$ and $B$ are divided by $C$. They have following probabilistic relationship.
Definition: Probabilistic Undirected Graphical Model
Satisfying three Markov properties.
Definition: Clique and Maximum Clique
clique: A subnet with all nodes adjacent to other nodes.
maximum clique: The biggest subnet with all nodes adjacent to other nodes.
Factorization
CRF
Definition: Linear Chain conditional Random Field
We suppose that $X$ and $Y$ are random variable. If random $Y$ is a Markov random field, that is
$w \sim v$ means $v$ is adjacent to $w$.
Normally, we consider $X$ has the same structure as $Y$.
Linear Chain CRF

We have following probabilistic relationship.
Parametric form of linear-chain Conditional Random Fields
Of which
Among them, $t_k$ and $s_l$ are feature function, $\lambda_k$ and $\mu_l$ are corresponding weights.
Simplification
So
That is
Matrix Form
For each label sequence, we introduce special start point and end point labels, $y_0 = \text{start}$ and $y_{n+1} = \text{stop}$. For each position in observation sequence $x$ $i =1,2,\dots,n+1$, we can define a matrix $m \in \mathbb{R}^m$
So
Specially
Calculation
Forward-Backward Algorithm
For each index $i = 0, 1, \dots, n + 1$, we define forward vector $\alpha_i(x)$;
recursive formula is
also, we define backward vector;
Probabilistic Calculation
of which