## 8 Conclusions  
In this paper, we presented the offline Handwritten Text Recognition (HTR) system and its linguistic restriction when using the decoding method through the Hidden Markov Model (HMM) with a language model. As a proposal, we built a Spelling Correction system that acts as post-processing to the HTR system. It enabled the experimentation of eight independent spelling correction techniques within the field of Natural Language Processing (NLP), from statistical to neural network, including the traditional approach of HMM with language model.  
A statistical analysis was performed to validate the significance of the results. We considered all the executions of the combinations and group them by spelling correction technique; thus, our proposed encoder-decoder model, using 1024 hidden units and Luong Attention, had the best averages of error rates, about 3.2% CER, 7.7% WER, and 35.3% SER, while traditional HMM with language model reached about 6.5% CER, 19.0% WER, and 76.7% SER. This means that there were significant results in the total of completely correct sentences, around 54% improvement, and a decrease of 3.3, 11.3, and 41.4 percentage points in the metrics, respectively.  
In the future, we want to expand the linguistic model independently of the optical model, optimizing its precision to apply the correction in very noisy sentences or even in sentences that are missing words, due to damaged images.  
\begin{table}
\begin{tabular}{l c c c c c} \hline \hline
**Technique** & \begin{tabular}{c} **\# of Params** \\ **(Million)** \\ \end{tabular} & \begin{tabular}{c} **GPU Memory** \\ **(GB)** \\ \end{tabular} & \begin{tabular}{c} **Convergence** \\ **Epoch** \\ \end{tabular} & \
\begin{tabular}{c} **Training Time**\({}^{1}\) \\ **(Hours)** \\ \end{tabular} &
\begin{tabular}{c} **Inference Time**\({}^{2}\) \\ **(Seconds/Sentence)** \\ \end{tabular} \\ \hline Kaldi & 0.5 & - & - & - & 0.003 \\ Similarity & - & - & - & - & 0.032 \\ Norvig & - & - & - & - & 0.321 \\ SymSpell & - & - & - & - & 0.004 \\ Bahdanau & 5.9 & 9.5 & 336 & 83 & 0.091 \\ Luong 512 & 5.9 & 2.5 & 348 & 53 & 0.090 \\ Luong 1024 & 21.4 & 4.5 & 250 & 45 & 0.111 \\ Transformer & 8.0 & 4.4 & 338 & 83 & 7.077 \\ \hline \hline \end{tabular}  
\({}^{1}\) GPU mode; \({}^{2}\) CPU mode.  
\end{table}
Table 8: Spelling corrector average execution summary.  
**Author Contributions:** Conceptualization, A.F.d.S.N., B.L.D.B., and A.H.T.; methodology, A.F.d.S.N. and B.L.D.B.; software, A.F.d.S.N. and A.H.T.; validation, A.F.d.S.N., B.L.D.B., and A.H.T.; formal analysis, A.H.T.; investigation, B.L.D.B.; resources, B.L.D.B.; writing--original draft preparation, A.F.d.S.N.; writing--review and editing, B.L.D.B. and A.H.T.; visualization, A.F.d.S.N.; supervision, B.L.D.B. and A.H.T.; project administration, B.L.D.B.; funding acquisition, B.L.D.B. All authors have read and agreed to the published version of the manuscript.  
**Funding:** This research was financed in part by the Coordenacao de Aperfeicoamento de Pessoal de Nivel Superior--Brasil (CAPES)--Finance Code 001, and CNPq Grant No. 315251/2018-2.  
**Acknowledgments:** This study was financed in part by the founding public agencies: Coordenacao de Aperfeicoamento de Pessoal de Nivel Superior--Brasil (CAPES)--Finance Code 001, and CNPq.  
**Conflicts of Interest:** The authors declare no conflict of interest.