Leveraging Sentence-level Information with Encoder LSTM for Semantic Slot Filling

Recurrent Neural Network (RNN) and one of its specific architectures, Long Short-Term Memory (LSTM), have been widely used for sequence labeling. In this paper, we first enhance LSTM-based sequence labeling to explicitly model label dependencies. Then we propose another enhancement to incorporate the global information spanning over the whole input sequence. The latter proposed method, encoder-labeler LSTM, first encodes the whole input sequence into a fixed length vector with the encoder LSTM, and then uses this encoded vector as the initial state of another LSTM for sequence labeling. Combining these methods, we can predict the label sequence with considering label dependencies and information of whole input sequence. In the experiments of a slot filling task, which is an essential component of natural language understanding, with using the standard ATIS corpus, we achieved the state-of-the-art F1-score of 95.66%.


Introduction
Natural language understanding (NLU) is an essential component of natural human computer interaction and typically consists of identifying the intent of the users (intent classification) and extracting the associated semantic slots (slot filling) (De Mori et al., 2008).We focus on the latter semantic slot filling task in this paper.
Slot filling can be framed as a sequential labeling problem in which the most probable semantic slot labels are estimated for each word of the given word sequence.Slot filling is a traditional task and tremendous efforts have been done, especially since the 1980s when the Defense Advanced Research Program Agency (DARPA) Airline Travel Information System (ATIS) projects started (Price, 1990).Following the success of deep learning (Hinton et al., 2006;Bengio, 2009), Recurrent Neural Network (RNN) (Elman, 1990;Jordan, 1997) and one of its specific architectures, Long Short-Term Memory (LSTM) (Hochreiter and Schmidhuber, 1997), have been widely used since they can capture temporal dependencies (Yao et al., 2013;Yao et al., 2014a;Mesnil et al., 2015).
The RNN/LSTM-based slot filling has been extended to be combined with explicit modeling of label dependencies (Yao et al., 2014b;Liu and Lane, 2015).
In this paper, we extend the LSTM-based slot filling to consider sentence-level information.
In the field of machine translation, an encoder-decoder LSTM has been gaining attention (Sutskever et al., 2014), where the encoder LSTM encodes the global information spanning over the whole input sentence in its last hidden state.Inspired by this idea, we propose an encoderlabeler LSTM that leverages the encoder LSTM for slot filling.First, we encode the input sentence into a fixed length vector by the encoder LSTM.Then, we predict the slot label sequence by the labeler LSTM whose hidden state is initialized with the encoded vector by the encoder LSTM.With this encoder-labeler LSTM, we can predict the label sequence while taking the sentence-level information into consideration.
The main contributions of this paper are twofolds: 1. Proposed an encoder-labeler LSTM to leverage sentence-level information for slot filling.
2. Achieved the state-of-the-art F 1 -score of 95.66% in the slot filling task of the standard ATIS corpus.

Proposed Method
We first revisit the LSTM for slot filling and enhance this to explicitly model label dependencies.Then we explain the proposed encoder-labeler LSTM.

LSTM for Slot Filling
Figure 1(a) shows a typical LSTM for slot filling and we call this as labeler LSTM(W) where words are fed to the LSTM (Yao et al., 2014a).Slot filling is a sequential labeling task to map a sequence of T words x T 1 to a sequence of T slot labels y T 1 .Each word x t is represented with a V dimensional one-hot-vector where V is the vocabulary size and is transferred to d e dimensional continuous space by the word embedding matrix E ∈ R de×V as Ex t .Instead of simply feeding Ex t into the LSTM, Context Window is a widely used technique to jointly consider k preceding and succeeding words as Ex t+k t−k ∈ R de(2k+1) .The LSTM has the architecture based on Jozefowicz et al. (2015) that does not have peephole connections and yields the hidden state sequence h T 1 .For each time step t, the posterior probabilities for each slot label are calculated by the softmax layer over the hidden state h t .The word embedding matrix E, LSTM parameters, and softmax layer parameters are estimated to minimize the negative log likelihood over the correct label sequences with Back-Propagation Through Time (BPTT) (Williams and Peng, 1990).

Explicit Modeling of Label Dependency
A shortcoming of the labeler LSTM(W) is that it does not consider label dependencies.To explicitly model label dependencies, we introduce a new architecture, labeler LSTM (W+L), as shown in Figure 1(b), where the output label of previous time step is fed to the hidden state of current time step, jointly with words, as Mesnil et al. (2015) and Liu and Lane (2015) tried with RNN.For model training, one-hot-vector of ground truth label of previous time step is fed to the hidden state of current time step and for evaluation, left-to-right beam search is used.

Encoder-labeler LSTM for Slot Filling
We propose two types of the encoder-labeler LSTM that uses the labeler LSTM(W) and the labeler LSTM(W+L).Figure 1(d) shows the encoderlabeler LSTM(W).The encoder LSTM, to the left of the dotted line, reads through the input sentence backward.Its last hidden state contains the encoded information of the input sentence.The labeler LSTM(W), to the right of the dotted line, is the same with the labeler LSTM(W) explained in Section 2.1, except that its hidden state is initialized with the last hidden state of the encoder LSTM.The labeler LSTM(W) predicts the slot label conditioned on the encoded information by the encoder LSTM, which means that slot filling is conducted with taking sentence-level information into consideration.Figure 1(e) shows the encoder-labeler LSTM(W+L), which uses the labeler LSTM(W+L) and predicts the slot label considering sentence-level information and label dependencies jointly.
Model training is basically the same as with the baseline labeler LSTM(W), as shown in Section 2.1, except that the error in the labeler LSTM is propagated to the encoder LSTM with BPTT.
This encoder-labeler LSTM is motivated by the encoder-decoder LSTM that has been applied to machine translation (Sutskever et al., 2014), graphemeto-phoneme conversion (Yao and Zweig, 2015), text summarization (Nallapati et al., 2016) and so on.The difference is that the proposed encoder-labeler LSTM accepts the same input sequence twice while the usual encoder-decoder LSTM accepts the input sequence once in the encoder.Note that the LSTMs for encoding and labeling are different in the encoder-labeler LSTM, but the same word embedding matrix is used both for the encoder and labeler since the same input sequence is fed twice.
While the bi-directional RNN/LSTM model the preceding and succeeding contexts at a specific word and don't explicitly encode the whole sentence, our proposed encoderlabeler LSTM explicitly encodes whole sentence and predicts slots conditioned on the encoded information.
Another method to consider the sentence-level information for slot filling is the attention-based approach (Simonnet et al., 2015).The attention-based approach is novel in aligning two sequences of different length.However, in the slot filling task where the input and output sequences have the same length and the input word and the output label has strong relations, the effect of introducing "soft" attention might become smaller.Instead, we directly fed the input word into the labeler part with using context window method as explained in Section 2.3.

Experiments
We report two sets of experiments.First we use the standard ATIS corpus to confirm the improvement by the proposed encoder-labeler LSTM and compare our results with the published results while discussing the related works.Then we use a large-scale data set to confirm the effect of the proposed method in a realistic use-case.

Experimental Setup
We used the ATIS corpus, which has been widely used as the benchmark for NLU (Price, 1990;Dahl et al., 1994;Wang et al., 2006;Tur et al., 2010).shows an example sentence and its semantic slot labels in In-Out-Begin (IOB) representation.The slot filling task was to predict the slot label sequences from input word sequences.
The performance was measured by the F 1 -score: , where precision is the ratio of the correct labels in the system's output and recall is the ratio of the correct labels in the ground truth of the evaluation data (van Rijsbergen, 1979).
The ATIS corpus contains the training data of 4,978 sentences and evaluation data of 893 sentences.The unique number of slot labels is 127 and the vocabulary size is 572.In the following experiments, we randomly selected 80% of the original training data to train the model and used the remaining 20% as the heldout data (Mesnil et al., 2015).We reported the F 1 -score on the evaluation data with hyper-parameters that achieved the best F 1 -score on the heldout data.
For training, we randomly initialized parameters in accordance with the normalized initialization (Glorot and Bengio, 2010).We used ADAM for learning rate control (Kingma and Ba, 2014) and dropout for generalization with a dropout rate of 0.5 (Srivastava et al., 2014;Zaremba et al., 2014).
For all architectures, we set the initial learning rate to 0.001 (Kingma and Ba, 2014) and the dimension of word embeddings to d e = 30.We changed the number of hidden units in the LSTM, d h ∈ {100, 200, 300}2 , and the size of the context window, k ∈ {0, 1, 2}3 .We used backward encoding for the encoder-decoder LSTM and the encoder-labeler LSTM as suggested in Sutskever et al. (2014).For the encoder-decoder LSTM, labeler LSTM(W+L), and encoder-labeler LSTM(W+L), we used the left-to-right beam search decoder (Sutskever et al., 2014) with beam sizes of 1, 2, 4, and 8 for evaluation where the best F 1 -score was reported.During 100 training epochs, we reported the F 1 -score on the evaluation data with the epoch when the F 1 -score for the heldout data was maximized.Table 1 shows the results.
The proposed encoder-labeler LSTM(W) and encoder-labeler LSTM(W+L) both outperformed the labeler LSTM(W) and labeler LSTM(W+L), which confirms the novelty of considering sentencelevel information with the encoder LSTM by our proposed method.
Contrary to expectations, F 1 -score by the encoder-labeler LSTM(W+L) was not improved from that by the encoder-labeler LSTM(W).A possible reason for this is the propagation of label prediction errors.We compared the label prediction accuracy for the words after the first label prediction error in the evaluation sentences and confirmed that the accuracy deteriorated from 84.0% to 82.6% by using pthe label dependencies.
For the encoder-labeler LSTM(W) which was better than the encoder-labeler LSTM(W+L), we tried the deep architecture of 2 LSTM layers (Encoderlabeler deep LSTM(W)).We also trained the corresponding labeler deep LSTM(W).As in which was statistically significant at the 90% level.Lastly, F 1 -score by the encoder-decoder LSTM was worse than other methods as shown in the first row of Table 1.Since the slot label is closely related with the input word, the encoder-decoder LSTM was not an appropriate approach for the slot filling task.

Comparison with Published Results
Table 2 summarizes the recently published results on the ATIS slot filling task and compares them with the results from the proposed methods.
Recent research has been focusing on RNN and its extensions.Yao et al. (2013) used RNN and outperformed methods that did not use neural networks, such as SVM (Raymond and Riccardi, 2007) and CRF (Deng et al., 2012).Mesnil et al. (2015) tried bi-directional RNN, but reported degradation comparing with their single-directional RNN (94.98%).Yao et al. (2014a) introduced LSTM and deep LSTM and obtained improvement over RNN.Peng and Yao (2015) proposed RNN-EM that used an external memory architecture to improve the memory capability of RNN.
Many studies have been also conducted to explicitly model label dependencies.Xu and Sarikaya (2013) proposed CNN-CRF that explicitly models the dependencies of the output from CNN. Mesnil et al. (2015) used hybrid RNN that combined Elman-type and Jordan-type RNNs.Liu and Lane (2015) used the output label for the previous word to model label dependencies (RNN-SOP).Vu et al. (2016) recently proposed to use ranking loss function over bi-directional RNNs with achieving 95.47% (R-biRNN) and reported 95.56% by en-semble (5×R-biRNN).
By comparing with these methods, the main difference of our proposed encoder-labeler LSTM is the use of encoder LSTM to leverage sentence-level information 4 .
Note some of the previous results used whole training data for model training while others used randomly selected 80% of data for model training and the remaining 20% for hyper-parameter tuning.Our results are based on the latter setup.

Large-scale Experiment
We prepared a large-scale data set by merging the MIT Restaurant Corpus and MIT Movie Corpus (Liu et al., 2013a;Liu et al., 2013b;Spoken Laungage Systems Group, 2013) with the ATIS corpus.Since users of the NLU system may provide queries without explicitly specifying their domain, building one NLU model for multiple domains is necessary.The merged data set contains 30,229 training and 6,810 evaluation sentences.The unique number of slot labels is 191 and the vocabulary size is 16,049.With this merged data 4 Since Simonnet et al. (2015) did not report the experimental results on ATIS, we could not experimentally compare our result with their attention-based approach.Theoretical comparison is available in Section 2.4.
5 There are other published results that achieved better F1scores by using other information on top of word features.Vukotic et al. (2015) achieved 96.16% F1-score by using the named entity (NE) database when estimating word embeddings.Yao et al. (2013) and Yao et al. (2014a) used NE features in addition to word features and obtained improvement with both the RNN and LSTM upto 96.60% F1-score.Mesnil et al. (2015) also used NE features and reported F1-score of 96.29% with RNN and 96.46% with Recurrent CRF.

Conclusion
We proposed an encoder-labeler LSTM that can conduct slot filling conditioned on the encoded sentence-level information.We applied this method to the standard ATIS corpus and obtained the stateof-the-art F 1 -score in a slot filling task.We also tried to explicitly model label dependencies, but it was not beneficial in our experiments, which should be further investigated in our future work.
In this paper, we focused on the slot labeling in this paper.
Previous papers reported that jointly training the models for slot filling and intent classification boosted the accuracy of both tasks (Xu and Sarikaya, 2013;Shi et al., 2015;Liu et al., 2015).Leveraging our encoder-labeler LSTM approach in joint training should be worth Encoder-labeler LSTM(W).

Figure 1 :
Figure1: Neural network architectures for slot filling.Input sentence is "I need a ticket to Seattle"."B-ToCity" is slot label for specific meaning and "O"is slot label without specific meaning."<B>" is beginning symbol for slot sequence.

Figure 2 :
Figure 2: Example of ATIS sentence and annotated slots.

Table 1 :
Experimental results on ATIS slot filling task.Leftmost column corresponds to Figure 1.Lines with bold fonts use proposed encoder-labeler LSTM.[%]

Table 2 :
Comparison with published results on ATIS slot filling task.F1-scores by proposed method are improved from Table1due to sophisticated hyper-parameters.[%]