The C lassical L anguage T oolkit: A n NLP Framework for Pre-Modern Languages (2021)

Abstract: This paper announces version 1.0 of the Classical Language Toolkit (CLTK), an NLP framework for pre-modern languages. The vast majority of NLP, its algorithms and software, is created with assumptions particular to living languages, thus neglecting certain important characteristics of largely non-spoken historical languages. Further, scholars of pre-modern languages often have different goals than those of living-language researchers. To fill this void, the CLTK adapts ideas from several leading NLP frameworks to create a novel software architecture that satisfies the unique needs of pre-modern languages and their researchers. Its centerpiece is a modular processing pipeline that balances the competing demands of algorithmic diversity with pre-configured defaults. The CLTK currently provides pipelines, including models, for almost 20 languages.

## introduction pre-modern (or historical) languages are linguistically no different than those with speakers living today. differences, however, manifest in how premodern languages are preserved, to what extent they are preserved, how they may be analyzed, and the ends to which they are studied. nlp is comprised of "computational techniques for the purpose of learning, understanding, and producing human language content" (hirschberg and manning, 2015, 261). in principle, such techniques may be applied to pre-modern languages. but because nlp, its algorithms and software, presumes living languages, there remains a significant void for nlp for pre-modern languages. the classical language toolkit (cltk) is a python library that borrows ideas from state-of-theart nlp software, in order to cater to the particular needs of pre-modern languages and their re-searchers. @xcite its centerpiece is a modular processing pipeline that balances the competing demands of algorithmic diversity with pre-configured defaults. the cltk currently provides pipelines, including models, for almost 20 languages. this architecture allows for relatively easy customization of currently available pipelines to new languages. ## system design an nlp pipeline within a framework architecture standardizes i/o while preserving algorithmic diversity. the cltk should provide: a user should be able to modify, replace, and add processes to a pipeline. pipelines may be adjusted for new languages. pipeline for language 'latin' (iso: 'lat'): `latinnormalizeprocess`, `latinstanzaprocess`, `latinembeddingsprocess`, `stopsprocess`, `latinnerprocess`, `latinlexiconprocess`. ## architecture and usage the cltk has one primary interface, nlp(), and five custom data types: when a user calls nlp. ⌋ analyze(), it outputs a doc, which contains all processed information. at doc.words is a list of word objects, each of which contains tokenlevel information added by each process. a pipeline contains a list of process objects for a given language. ## conclusion and future work the architecture of the cltk v. 1.0 has an engineering rigor necessary to model the world's several hundred pre-modern languages. currently, it serves the basic, and several more advanced, needs of researchers for 19 languages. software alone, however, is not sufficient. the cltk lacks formal evaluations of its models' accuracies. at time of publication, most process definitions wrap models trained by upstream projects (e.g., stanza). while these projects report accuracies respective to their training sets (i.e., with crossvalidation), they do not provide evaluations against outside benchmarks. unfortunately, such benchmarks do not yet exist for pre-modern languages, with the exception of the recent sprugnoli et al. these efforts will improve scientific procedure for pre-modern nlp. another initiative involves experimentation with transfer learning, along the lines of multilingual bert (pires et al., 2019), training on all surviving pre-modern texts. because languages are related and because texts, even in different languages, often share entities, information sharing may prove felicitous. @xcite the pre-modern world, its languages and peoples, was deeply networked. @xcite the cltk is a comprehensive collection of nlp technologies to support the study of this history.