scieee AI-readable full text Open interactive document viewer

Introducing linguistic knowledge into statistical machine translation.

Gispert Ramis, Adrià

Abstract

Aquesta tesi està dedicada a l'estudi de la utilització de informació morfosintàctica en el marc dels sistemes de traducció estocàstica, amb l'objectiu de millorar-ne la qualitat a través de la incorporació de informació lingüística més enllà del nivell simbòlic superficial de les paraules.<br/><br/><br/><br/>El sistema de traducció estocàstica utilitzat en aquest treball segueix un enfocament basat en tuples, unitats bilingües que permeten estimar un model de traducció de probabilitat conjunta per mitjà de la combinació, dins un entorn log-linial, de cadenes d'n-grames i funcions característiques addicionals. Es presenta un estudi detallat d'aquesta aproximació, que inclou la seva transformació des d'una implementació d'X-grames en autòmats d'estats finits, més orientada a la traducció de veu, cap a l'actual solució d'n-grames orientada a la traducció de text de gran vocabulari. La tesi estudia també les fases d'entrenament i decodificació, així com el rendiment per a diferents tasques (variant el tamany dels corpora o el parell d'idiomes) i els principals problemes reflectits en les anàlisis d'error.<br/><br/><br/><br/>La tesis també investiga la incorporació de informació lingüística específicament en aliniament per paraules. Es proposa l'extensió mitjançant classificació de formes verbals d'un algorisme d'aliniament paraula a paraula basat en co-ocurrències, amb resultats positius. Així mateix, s'avalua de forma empírica l'impacte en qualitat d'aliniament i de traducció que s'obté mitjançant l'etiquetatge morfològic, la lematització, la classificació de formes verbals i el truncament o stemming del text paral·lel.<br/><br/><br/><br/>Pel que fa al model de traducció, es proposa un model de tractament de les formes verbals per mitjà d'un model de instanciació addicional, i es realitzen experiments en la direcció d'anglès a castellà. La tesi també introdueix un model de llenguatge d'etiquetes morfològiques del destí per tal d'abordar problemes de concordança. Finalment, s'estudia l'impacte de la derivació morfològica en la formulació de la traducció estocàstica mitjançant n-grames, avaluant empíricament el possible guany derivat d'estratègies de reducció morfològica.

Full text

Ph.D. Thesis Dissertation Introducing Linguistic Knowledge into Statistical Machine Translation Author: Adri`a de Gispert Ramis Advisor: Prof. Jos´e B. Mari˜no Acebal TALP Research Center, Speech Processing Group Department of Signal Theory and Communications Universitat Polit`ecnica de Catalunya Barcelona, October 2006 Time flies like an arrow. Fruit flies like a banana. Groucho Marx. iv Abstract This Ph.D. thesis dissertation addresses the use of morphosyntactic information in order to improve the performance of Statistical Machine Translation (SMT) systems, providing them with additional linguistic information beyond the surface level of words from parallel corpora. The statistical machine translation system in this work here follows a tuple-based approach, modelling joint-probability translation models via log-linear combination of bilingual n-grams with additional feature functions. A detailed study of the approach is conducted. This includes its initial development from a speech-oriented Finite-State Transducer architecture implementing X-grams towards a large-vocabulary text-oriented n-grams implementation, training and decoding particularities, portability across language pairs and tasks, and main difficulties as revealed in error analyses. The use of linguistic knowledge to improve word alignment quality is also studied. A cooccurrence-based one-to-one word alignment algorithm is extended with verb form classification with successful results. Additionally, we evaluate the impact in word alignment and translation quality of Part-Of-Speech, base form, verb form classification and stemming on state-of-art word alignment tools. Furthermore, the thesis proposes a translation model tackling verb form generation through an additional verb instance model, reporting experiments in English→Spanish tasks. Disagreement is addressed via incorporating a target Part-Of-Speech language model. Finally, we study the impact of morphology derivation on Ngram-based SMT formulation, empirically evaluating the quality gain that is to be gained via morphology reduction. v vi Resum Aquesta tesi est`a dedicada a l’estudi de la utilitzaci´o de informaci´o morfosint`actica en el marc dels sistemes de traducci´o estoc`astica, amb l’objectiu de millorar-ne la qualitat a trav´es de la incorporaci´o de informaci´o ling¨u´ıstica m´es enll`a del nivell simb`olic superficial de les paraules. El sistema de traducci´o estoc`astica utilitzat en aquest treball segueix un enfocament basat en tuples, unitats biling¨ues que permeten estimar un model de traducci´o de probabilitat conjunta per mitj`a de la combinaci´o, dins un entorn log-linial, de cadenes d’n-grames i funcions caracter´ıstiques addicionals. Es presenta un estudi detallat d’aquesta aproximaci´o, que inclou la seva transformaci´o des d’una implementaci´o d’X-grames en aut`omats d’estats finits, m´es orientada a la traducci´o de veu, cap a l’actual soluci´o d’n-grames orientada a la traducci´o de text de gran vocabulari. La tesi estudia tamb´e les fases d’entrenament i decodificaci´o, aix´ı com el rendiment per a diferents tasques (variant el tamany dels corpora o el parell d’idiomes) i els principals problemes reflectits en les an`alisis d’error. La tesis tamb´e investiga la incorporaci´o de informaci´o ling¨u´ıstica espec´ıficament en aliniament per paraules. Es proposa l’extensi´o mitjan¸cant classificaci´o de formes verbals d’un algorisme d’aliniament paraula a paraula basat en co-ocurr`encies, amb resultats positius. Aix´ı mateix, s’avalua de forma emp´ırica l’impacte en qualitat d’aliniament i de traducci´o que s’obt´e mitjan¸cant l’etiquetatge morfol`ogic, la lematitzaci´o, la classificaci´o de formes verbals i el truncament o stemming del text paral·lel. Pel que fa al model de traducci´o, es proposa un model de tractament de les formes verbals per mitj`a d’un model de instanciaci´o addicional, i es realitzen experiments en la direcci´o angl`es→castell`a. La tesi tamb´e introdueix un model de llenguatge d’etiquetes morfol`ogiques del dest´ı per tal d’abordar problemes de concordan¸ca. Finalment, s’estudia l’impacte de la derivaci´o morfol`ogica en la formulaci´o de la traducci´o estoc`astica mitjan¸cant n-grames, avaluant emp´ıricament el possible guany derivat d’estrat`egies de reducci´o morfol`ogica. vii viii Agra¨ıments Vull donar les gr`acies de tot cor al Pepe, no nom´es per haver-me ajudat a tirar endavant aquesta tesi, sin´o per mostrar-se sempre com una persona exemplar dins i fora de l’entorn professional, i de la qual he apr`es molts valors, i moltes actituds i maneres de treballar admirables. Sempre li estar´e molt agra¨ıt per tot el que ha fet per mi. Gr`acies tamb´e als companys i companyes del grup de traducci´o estad´ıstica, i en especial al Josep Maria Crego, sense l’aportaci´o del qual aquesta tesi no hauria anat tan lluny, i amb qui he apr`es a fer recerca de manera seriosa. Tamb´e vull donar les gr`acies a aquells i aquelles que, amb el seu treball i potser sense adonarse’n, han estat i sempre seran un referent de comprom´ıs i motivaci´o per a mi, com ara el Climent Nadeu, el Jaume Padrell, el Xavi P´erez (el company de feina que tothom desitjaria tenir), el Llu´ıs Padr´o i el Llu´ıs M`arquez. Gr`acies tamb´e als molts companys de tesi amb qui he compartit molt bones estones com l’Alberto, el Ramon, el Pere, l’Ignasi, la Marta, el Javi o el Joel, entre molts d’altres. Moltes gr`acies tamb´e als grans amics i amigues que m’han acompanyat en aquest trajecte, no nom´es pel que m’han aguantat quan ha fet falta, sin´o per fer-me veure clarament que sempre hi tornarien a ser si calgu´es (Jordi, Mari, Oriol, N´uria, Paqui, Ferran, Pablo, Ana, Llu´ıs, David, etc.). Per ´ultim, vull dedicar aquesta tesi als meus pares i a l’Aleyda, que amb el seu amor constant em donen la for¸ca necess`aria per treballar i viure amb il·lusi´o. Aquesta tesi ´es, en bona part, tamb´e vostra. Adri`a Barcelona, octubre del 2006 ix 6.1 Introduction ....................................... 151 6.2 Verb classification for SMT .............................. 152 6.2.1 Introduction .................................. 152 6.2.2 Verb classification model ............................ 152 6.2.2.1 Instance model ............................ 154 6.2.2.2 Generalisation of unseen verb forms ................ 154 6.2.2.3 Extended generalisation ....................... 155 6.2.3 Advantages and difficulties .......................... 155 6.2.4 LC-Star experiment .............................. 157 6.2.4.1 Verb Phrase Detection/Classification ............... 158 6.2.4.2 Translation results .......................... 158 6.2.4.3 Discussion .............................. 159 6.2.5 European Parliament experiment ....................... 160 6.3 Target Part-Of-Speech Language Model ....................... 163 6.4 Morpho-reduced Translation Models and Morphology Post-processing . . . . . . 165 6.4.1 Introduction .................................. 165 6.4.2 Morpho-reduced Translation Models ..................... 167 6.4.2.1 Training architectures ........................ 167 6.4.2.2 Decoding architectures ....................... 169 6.4.3 Morphology Post-processing .......................... 170 6.4.4 Experimental study .............................. 170 6.4.4.1 Post-processing oracles ....................... 171 6.4.4.2 Study of post-processing oracles .................. 172 6.4.4.3 Morpho-reduced model oracles ................... 173 6.4.5 Conclusions ................................... 175 6.5 Chapter Summary and Conclusions .......................... 176 xvi xvii 7 Conclusions and Future Work 177 7.1 Conclusions ....................................... 177 7.2 Future Work ...................................... 179 Bibliography 181 xviii Chapter 1 Introduction The information society we live in is undoubtedly a globalised and multilingual one. Every day, hundreds of thousands of documents are being generated, and in many cases one or several translations for them are needed in order to cover the linguistic variety of the target population. The majority of work carried out by professional translators is related to non-literary documents (technical reports, legal and financial documents, user manuals, political debates, meeting minutes, and so on), where translation tends to be mechanical and domain-specific. However, the high translation cost in terms of money and time is a bottleneck that prevents all information from being easily spread across languages. Apart from that, the growth and popularity rise of internet has given users access to practically any written, visual and audio material from anywhere in the world. Still, the language barrier is the only obstacle for this vast information to be fully shared by all users. In this context, automatic or machine translation (MT) services are becoming more and more attractive. Several companies are already using and offering automatic translation software, and thousands of users are automatically translating web content on a daily basis, even though translation performance is still far from perfection. Additionally, many research efforts are being focused on speech-to-speech machine translation, and the seemingly unreachable goal of automatically translating spoken language is nearer than ever before. To a large extent, much of the optimism being shared in the MT research community nowadays has been caused by the revival of statistical approaches to machine translation, or in other words, the birth of purely Statistical Machine Translation (SMT). In contrast to previous approaches based on linguistic knowledge representation, SMT is based on large amounts of human-translated example sentences (parallel corpora) in order to estimate a set of statistical models describing the translation process. 1 Chapter 1. Introduction 2 1.1 Machine Translation and the Statistical Approach 1.1.1 A brief history of MT The beginnings of statistical machine translation (SMT) can be traced back to the early fifties, closely related to the ideas from which information theory arose [Sha49b] and inspired by works on cryptography [Sha49a,Sha51] during World War II. According to this view, machine translation was conceived as the problem of finding a sentence by decoding a given “encrypted” version of it [Wea55]. At that time, machine translation was seen as a quite simple and feasible task, basically consisting of automatically reading dictionary entries in order to translate the input sentence into a hypothetical universal language, from which the target sentence could be generated. A first public Russian–English system was presented at the University of Georgetown in 1954, and despite its very restricted domain (with a vocabulary size of around 250 words), the promising prospects of rapid improvement, and undoubtedly the cold war political context, led the United States government to make strong investments in emergent machine translation technologies. Since then, many research projects were devoted to MT during the late 1950s. However, as the complexity of the linguistic phenomena involved in the translation process together with the computational limitations of the time were made apparent, enthusiasm faded out quickly. Despite much research effort, by the turn of the decade results had fallen short of all expectations. To crown it all, two negative reports had a dramatic impact on MT research. On the one hand, the Bar-Hillel report [BH60] concluded that Fully Automatic High-Quality Translation was an unreachable goal and that research efforts should be focused on less-ambitious tasks, such as Computer-assisted Machine Translations tools. On the other hand, the controversial 1966 ALPAC report concluded that machine translation was of poor quality and twice as expensive as human translation, effectually causing all MT research to vanish. During the 1970s, the focus of MT activity switched from the United States to Canada and to Europe, especially due to the growing demands for translations within their multicultural societies. M´et´eo, a fully-automatic system translating weather forecasts had a great success in Canada, and meanwhile, the European Commission installed a French–English MT system called Systran. Other reseach projects, such as Eurotra, Ariane and Susy, broadened the scope of MT objectives and techniques, and rule-based approaches emerged as the right way towards successful MT quality. Throughout the 1980s many different types of MT systems appeared [Hut86], the most prevalent being those using an intermediate semantic language such as the Interlingua approach (more detailed in §1.1.2). In the early 1990s, the progress made by the application of statistical methods to speech Chapter 1. Introduction 3 recognition inspired the introduction by IBM reseachers of purely-statistical machine translation models. The drastic increment in computational power and the increasing availability of written translated texts allowed the development of statistical and other corpus-based MT approaches. Many academic tools turned into useful commercial translation products [Arn95], and several translation engines were quickly offered in the world wide web. Today, while commercial MT systems are not error-free, their use is widespread and there is a growing demand for high-quality automatic translation. Regarding research, basically all the research community has moved towards corpus-based techniques, which have systematically outperformed traditional knowledge-based techniques in most performance comparisons. Every year more research groups embark on SMT experimentation, and a regained optimism as regards to future progress seems to be shared among the community. 1.1.2 Approaches to MT Several criteria can be used to classify machine translation approaches [GV03], yet the most popular classification is done attending to the level of linguistic analysis (and generation) required by the system to produce translations. Usually, this can be graphically expressed by the machine translation pyramid in Figure 1.1. Figure 1.1: Machine Translation pyramid Generally speaking, the bottom of the pyramid represents those systems which do not perform any kind of linguistic analysis of the source sentence in order to produce a target sentence. Moving upwards, the systems which carry out some analysis (usually by means of morphosyntaxbased rules) are to be found. Finally, on top of the pyramid a semantic analysis of the source sentence turns the translation task into generating a target sentence according to the obtained semantic representation. Chapter 1. Introduction 4 Aiming at a bird’s-eye survey rather than a complete review, next each of these approaches is briefly discussed, before delving into the statistical approach to machine translation. Direct translation This approach solves translation on a word-by-word basis, and it was followed by the early MT systems, which included a very shallow morphosyntactic analysis. Today, this preliminary approach has been abandoned, even in the framework of corpus-based approaches (see below). Transfer-based translation The rationale behind the transfer-based approach is that, once we grammatically analyse a given sentence, we can pass this grammar on to the grammatical representation of this sentence in another language. In order to do so, rules to convert source text into some structure, rules to transfer the source structure into a target structure, and rules to generate target text from it are needed. Lexical rules need to be introduced as well. Usually, rules are collected manually, thus involving a great deal of expert human labour and knwoledge of comparative grammar of the language pair. Apart from that, when several competing rules can be applied, it is difficult for the systems to prioritise them, as there is no natural way of weighing them. This approach was massively followed in the 1980s, and despite much research effort, highquality MT was only achieved for limited domains [Hut92]. Interlingua-based translation This approach advocates for the deepest analysis of the source sentence, reaching a language of semantic representation named Interlingua. This conceptual language, which needs to be developed, has the advantage that, once the source meaning is captured by it, in theory we can express it in any number of target languages, so long as a generation engine for each of them exists. Though conceptually appealing, several drawbacks make this approach unpractical. On the one hand, the difficulty of creating a conceptual language capable of bearing the particular semantics of all languages is an enormous task, which in fact has only been achieved in very limited domains. Apart from that, the requirement that the whole input sentence needs to be understood before proceeding onto translating it, has proved to make these engines less robust to the grammatical incorrectness of informal language, or which can be produced by an automatic speech recognition system. Chapter 1. Introduction 5 Corpus-based approaches In contrast to the previous approaches, these systems extract the information needed to generate translations from parallel corpora that include many sentences which have already been translated by human translators. The advantage is that, once the required techniques have been developed for a given language pair, in theory it should be relatively simple to transpose them to another language pair, so long as sufficient parallel training data is available. Among the many corpus-based approaches that sprung at the beginning of the 1990s, the most relevant ones are example-based (EBMT) and statistical (SMT), although the differences between them are constantly under debate. Example-based MT makes use of parallel corpora to extract a database of translation examples, which are compared to the input sentence in order to translate. By choosing and combining these examples in an appropriate way, a translation of the input sentence can be provided. In SMT, this process is accomplished by focusing on purely statistical parameters and a set of translation and language models, among other data-driven features. Although this approach initially worked on a word-to-word basis and could therefore be classified as a direct method, nowadays several engines attempt to include a certain degree of linguistic analysis into the SMT approach, slightly climbing up the aforementioned MT pyramid. The following section further introduces the statistical approach to machine translation. 1.1.3 Statistical Machine Translation Since its revival more than a decade ago when IBM researchers presented the Candide SMT system [Bro90,Bro93], the statistical approach to machine translation has seen an increasing interest among both natural language and speech processing research communities. Mainly, three factors account for this increasing interest: •There is a growing availability of parallel texts (though this applies, in general, only to major languages in terms of presence in internet), coupled with increasing computational power. This enables research on statistical models which, in spite of their huge number of parameters (or probabilities) to estimate, are sufficiently represented in the data. •The statistical methods are more robust to speech disfluencies or grammatical faults. As no deep analysis of the source sentence is done, these systems seek the most probable translation hypothesis given a source sentence, assuming the input sentence is correct. •And last but not least, shortly after their introduction, these methods proved at least as good or even better as rule-based approaches in various evaluation campaigns1. A clear 1See NIST annual evaluation results at http://www.nist.gov/speech/tests/mt Chapter 1. Introduction 6 example is the German project VerbMobil, which concluded that preliminary statistical approaches outperformed other approaches, on which research had been focused for many years [Wah00]. At the turn of the 21st century, apart from VerbMobil2, other projects and consortiums (C-STAR3, LC-STAR, FAME, among others) involving many research centers have focused on SMT and its applications to text and speech translation tasks. Recently, the European project TC-STAR (Technology and Corpora for Speech to Speech Translation),4has among its main objectives to achieve significant performance improvements in the statistical machine translation approach. 1.2 Motivation In the face of the promising horizon for Spoken Language Translation (SLT) and having a longstanding experience on Automatic Speech Recognition (ASR), the Speech Processing Group of the Universitat Polit`ecnica de Catalunya (UPC) set among its objectives to undertake reseach on SMT in 2001. Having to initiate this work from scratch, a first and necessary step was to develop a set of tools implementing a statistical translation model with state-of-the-art performance. The implemention with a Finite-State Transducer of the joint probability model by adapting speech recognition tools, set the foundations of this Ph.D. research work, obtaining preliminary text and speech translation results with small hand-crafted parallel training data. Since 2003, the work of mantaining the system up-to-date with the rapid changes in the field has been shared by the author with a growing team of outstanding Ph.D. researchers and professors. Today, the initial translation engine has turned into an Ngram-based SMT system capable of dealing with large amounts of material, steadily participating in worldwide evaluation campaigns and successfully achieving state-of-the-art results. Internationally, in this five-year period statistical machine translation has evolved from a newborn speech recognition task being looked at as unrealistic, into a prominent task bringing together the natural language processing community and the speech recognition community towards spoken language translation. Nowadays, the number of publications on SMT-related issues, as well as the number of conference sessions, workshops and shared task evaluations, is progressively augmenting. Although Statistical Machine Translation has seen a big progress over the last years, mainly 2http://verbmobil.dfki.de/overview-us.html 3http://www.c-star.org 4http://www.tc-star.org Chapter 1. Introduction 7 thanks to the development of new statistical models, to the ever-growing availability of parallel corpora, to the steady increase in computational power and to the widespread use of automatic evaluation measures, it still suffers from basic morphology- and syntax-related translation errors as of today. On the other hand, every year more linguistic resources are made available to the research community. Natural Language Processing (NLP) tools such as Part-of-Speech taggers, word segmentors, lemmatisers, named-entity detectors and recognisers, chunkers, shallow and full parsers and semantic onthologies (among other tools and resources) are being made available for a growing list of languages. Despite internally taking statistical decisions in most of the cases, these tools provide a wider and deeper linguistic knowledge of a language than the one SMT is currently capturing from parallel corpora. Therefore, having as ultimate goal the challenging balance between parallel corpora and additional linguistic tools that will lead to flawless machine translation performance, this Ph.D. thesis also investigates models and techniques which incorporate this additional morphosyntactic information into the statistical framework of SMT. The underlying assumption is that going beyond the surface level of words can help improve the translation system performance whenever empirical evidence from parallel corpora is insufficient. This undesired situation is a highly task-dependent one. The pair of languages involved, the parallel corpus size, the domain of the task and other factors strongly affect the incorporation of morphosyntactic information, and might even condition its need at all. Due to corpora and linguistic tools availability reasons, most of this Ph.D. research work was carried out with the English and Spanish languages, and less significanty, with the Catalan and Arabic languages. 1.3 Objectives of this Ph.D. The objectives of this Ph.D. thesis are the following: •To define a statistical translation model and to implement a tool estimating it, in order to use it as baseline system for text and speech translation purposes. As very few tools related with SMT training or decoding were available at the time when this research work began, the goal was to adapt UPC speech recognition tools in order to implement a joint-probability model for text and speech translation. Eventually, this fundamental goal shifted towards the next objective. •To achieve and mantain state-of-the-art performance with this system through the many changes in the research field. Chapter 2. State of the art 14 A detailed description of IBM models and their estimation from a parallel corpus can be found in [Bro93]. In [Kni99] an informal yet clarifying tutorial on IBM models can be found. Word Alignment As explicitly introduced by IBM formulation as a model parameter, word alignment becomes a function from source positions jto target positions i, so that a(j) = i. This definition implies that resultant alignment solutions will never contain many-to-many links, but only many-to- one2, as only one function result is possible for a given source position j. Although this limitation does not account for many real-life alignment relationships, in principle IBM models can solve this by estimating the probability of generating the source empty word, which can translate into non-empty target words. However, as we will see in the following section, many current SMT systems do not use IBM model parameters in their training schemes, but only the most probable alignment (using a Viterbi search) given the estimated IBM models. Therefore, in order to obtain many-to-many word alignments, usually alignments from source-to-target and target-to-source are performed, and symmetrisation strategies have to be applied, as will be further discussed in §2.5. 2.1.2 Training and decoding tools A stack decoder for IBM model 2 was presented in [Wan97], based on the A*-search algorithm. In 1999, the John Hopkins University summer workshop research team on SMT released GIZA (as part of the EGYPT toolkit), a tool implementing IBM models training from parallel corpora and best-alignment Viterbi search, as reported in [AO99], where a decoder for model 3 is also described. This was a breakthrough in that it enabled many other teams to join SMT research easily. In 2001 and 2003 improved versions of this tool were released, and named GIZA++[Och03c]. DP-based decoders both for model 2 and model 4 can be found in [Til00] and [Til03]. In [Ger01] the speed and quality of a stack-based, a greedy and an integer-programming decoder for IBM model 4 is compared. In [GV03] several decoders for IBM models are presented, ranging from greedy approaches to dynamic programming and stack solutions. 2By many-to-many links those relationships between more than one word in each language are refered, whereas many-to-one links associate more than one source word with a single target word. One-to-one links are defined analogously. Chapter 2. State of the art 15 2.2 Phrase-based translation models By the turn of the century it became clear that in many cases specifying translation models at the level of words turned out to be inappropriate, as much local context seemed to be lost during translation. Novel approaches needed to describe their models according to longer units, typically sequences of consecutive words (or phrases). 2.2.1 Alignment templates The first approach using longer translation units was presented in [Och99b] and named Alignment Templates, which are pairs of generalised phrases that allow word classes and include an internal word alignment. This idea is expressed by Equation 2.4. Pr(fJ 1|eI 1) = X zK 1,˜aK 1 K Y k=1 p(˜ak|˜ak−1)·p(zk|˜ek)·p(˜ fk|zk,˜ek) (2.4) where zkis the k-th template used, the sequence of alignment templates zK 1and the alignments whithin the templates ˜aK 1are hidden variables, and there are three probability distributions: •the phrase alignment probability p(˜ak|˜ak−1), in the fashion of the word-based HMM model in[Vog96] •the probability of applying an alignment template p(zk|˜ek) •the phrase translation probability p(˜ fk|zk,˜ek) Therefore, in this powerful approach the translation unit becomes a triple composed of: a source sequence of word classes, a target sequence of word classes, and a set of internal alignment links between word classes inside the borders of the template. Word classes from source and target language can be automatically estimated from monolingual or bilingual data as in [Och99a]. The generative process underlying the Alignment Template approach is drawn in Figure 2.2. As it can be seen, source words (each of them belonging to a word class) are grouped into phrases ˜ fk, and for each phrase an alignment template is applied, originating a set of target phrases. Then, these phrases are ordered according to the phrase alignment model, and finally target words are produced. More details on this approach can be found in [Och04b], where significant improvements over word-based approaches are reported. Chapter 2. State of the art 16 Figure 2.2: Illustration of the translation process of the Alignment Template approach 2.2.2 Phrase-based SMT A simplified version of the previous approach is the so-called phrase-based statistical machine translation presented in [Zen02]. Under this framework, word classes are not used (but the actual words from the text instead), and the translation unit looses internal alignment information, turning into so-called bilingual phrases. Mathematically, former equation 2.4 gets simplified to: Pr(fJ 1|eI 1) = α(eI 1)·X B Pr(˜ fk|˜ek) (2.5) where the hidden variable Bis the segmentation of the sentence pair in Kbilingual phrases (˜ fK 1,˜eK 1), and α(eI 1) is assuming the same probability for all segmentations. The phrase translation probabilities are usually estimated, over all bilingual phrases in the corpus, by relative frequency of the target sequence given the source sequence, as in: Pr(˜ fk|˜ek) = N(˜ fk,˜ek) N(˜ek)(2.6) where bilingual phrases are defined as any pair of source and target phrases that have consecutive words and are consistent with the word alignment matrix. According to this criterion, any sequence of consecutive source words and consecutive target words which are aligned to each other and not aligned to any other token in the sentence, become a phrase. This is exemplified in Figure 2.3, where eight different phrases are extracted and it is worth noting that AB→WY is not extracted, given the definition constraint. For more details on this criterion, see [Och99b] Chapter 2. State of the art 17 or [Zen02]. Figure 2.3: Phrase extraction from a certain word aligned pair of sentences. In [Mar02] a joint-probability phrase-based model is introduced, which learns both word and phrase translation and alignment probabilities from a set of parallel sentences. However, this model is only tractable up to an equivalent of IBM model 3, due to severe computational limitations. Furthermore, when comparing this approach to the simple above-mentioned phrase generation from word alignments and a syntax-based phrase generation [Yam01], the approach from word alignment achieves best results as shown in [Koe03]. An alternative way to compute phrase translation probabilities is to use IBM model 1 lexical probabilities of the words inside the phrase pair, as presented in [Vog03]. A smoothed relative frequency is used in [Zen04]. Nowadays, many SMT systems follow a phrase-based approach, in that their translation unit is the bilingual phrase, such as [Lee06,Ber06,Mat06,Aru06,Kuh06,Kir06,Hew05], among many others. Most of these systems introduce a log-linear combination of models, as will be discussed in §2.4. Relevantly, this phrase-based relative frequency model ignores IBM model parameters, being automatically estimated from a word-aligned parallel corpus, thus turning word alignment into a stand-alone training stage which can be done independently, as will be discussed in §2.5. 2.2.3 Training and decoding tools Lately many tools are being implemented and released, so that every year it becomes easier for a beginner to get quickly introduced into phrase-based SMT, and even run preliminary experiments in one day. Without aiming at completeness, some of them are mentioned here. Regarding phrase extraction and estimation, an open-source tool has been released in [Ort05]. As for decoding tools, in [Koe04] a freely-available beam search decoder for phrase-based translation models is described. A freely-available phrase-based and ngram-based decoder is described in [Cre05b]. A decoder based on confusion networks is presented in [Ber05], and two open-source decoders have been released in [Pat06,Olt06], programmed in C++ and Java respectively. Chapter 2. State of the art 18 2.3 Tuple-based translation model Without loss of generality, an alternative approach to SMT is to view translation as a stochastic process maximising the joint probability p(f, e) instead of the conditional probability p(f|e), leading to the following decomposition: ˆeI 1= arg max eI 1{p(fJ 1, eI 1)}=··· = (2.7) arg max eI 1{ N Y n=1 p((f, e)n|(f, e)1, ..., (f, e)n−1)}(2.8) where (f, e)nis the n-th bilingual unit, or tuple, of a given tuple sequence which generates monotonically both the training source and target sentences. Under this approach, the translation of a given source unit (f, e)nis conditioned by a previous bilingual context (f, e)1, ..., (f, e)n−1, which in practice must be limited in length. 2.3.1 Finite-State Transducer implementation In [Vid97,Cas01] this joint-probability model is implemented by means of a Finite-State Transducer (FST), which can be automatically inferred from parallel data as in [Cas00]. Typically, this approach is followed in literature for speech translation. This is because, in contrast to initial word-based models and phrase-based approaches 3, the use of such a transducer allows for an elegant integration of the acoustic model p(x|f) (xbeing the input acoustic signal) into a global search, thus performing speech translation in one fell swoop [Vid97]. Mathematically, this is expressed in equation 2.9: ˆeI 1≃arg max eI 1 max fJ 1 p(fJ 1, eI 1)·p(x|fJ 1) (2.9) where p(f, e) plays here the same role of the language model in speech recognition and p(x|f) is the acoustic model. A graphical representation of such a translation FST is shown in Figure 2.4, where each arc contains a bilingual unit comprised of one or more source words and zero, one or more target words, together with the associated probability estimated during training. 3Recently there is a growing and interesting research line towards integrating speech recognition and phrasebased text translation, mainly directed at outputting a word graph in recognition, and feeding it into the translation engine, which can combine its scores with some acoustic-related scores. However, falling out of the scope of this Ph.D. thesis, no further details on this issue will be given. Chapter 2. State of the art 19 Figure 2.4: A translation FST from Spanish to English Similarly to phrase-based approaches, these units are extracted in training from the Viterbi word alignment, therefore ignoring IBM model parameters. However, now the bilingual units are constrained by the sequentiality which is inherent to the N-gram decomposition of equation 2.8. By adapting X-grams (which had been successfully used for language modelling in [Bon96] and speech recognition in [Bon98]) to this transducer architecture, this approach was followed in order to address the first main objective of this Ph.D. work, namely the implementation of a preliminary speech translation system. For this reason, all further details are addressed in detail in the following chapter. 2.3.2 Other implementations Another implementation with cascaded finite-state transducers combining both statistically learnt transducers and hand-crafted rules can be found in [Vog00]. The FST-based approach is monotonous in that its model is based on the sequential order of tuples during training. Therefore, in principle it is more appropriate for pairs of languages with relatively similar word order schemes. However, an approach with reordered transducers can be found in [Ban01]. As we will see in chapter 3, due to structual inefficiency, the FST approach needs to be recast into an Ngram approach in order to deal with large quantities of data, as will be seen in detail in chapter 4. However, an efficient implementation of Weighted Finite-State Transducers for SMT is presented in [Kan04], which can incorporate word ordering capabilities as introduced in [Mat05]. Chapter 2. State of the art 20 2.4 Feature-based models combination Another alternative to the noisy-channel approach is to directly model the posterior probability Pr(eI 1|fJ 1), a well-founded approach in the framework of maximum entropy, as shown in [Ber96]. By treating many different knowledge sources as feature functions, a log-linear combination of models can be performed, allowing an extension of a baseline translation system with the addition of new feature functions. In this case, the decision rule responds to the following expression: ˆeI 1= arg max eI 1(M X m=1 λmhm(eI 1, fJ 1))(2.10) so that the noisy-channel approach can be obtained as a special case if we consider only two feature functions, namely the target language model h1(eI 1, fJ 1) = log p(eI 1) and the translation model of the source sentence given the target h2(eI 1, fJ 1) = log p(fJ 1|eI 1). 2.4.1 Minimum-error training This approach, which was introduced in [Pap98] for a natural language understanding task, suggests that the training optimisation task becomes finding out the λmwhich weight each model according to a certain criterion. In [Och02] minimum error training is introduced for statistical machine translation, stating that these weights need to be settled by directly minimising the translation error on a development set, as measured by a certain automatic measure (see §2.7). Typically, this log-linear combination includes, apart from a translation model, other feature functions, such as: •additional language models (word-based or class-based high-order Ngrams) •sentence length models, also called word bonuses •lexical models (such as IBM model 1 from source to target and from target to source) •phrase penalties •others (regarding information on manual lexicon entries or other grammatical features) In order to optimise the λmweights, the usual criterion is to use the maximum posterior probability p(e|f) on a training corpus. Adequate algorithms for such a task are the GIS (Generalised Iterative Scaling) or the downhill simplex method [Nel65]. On the other hand, given a loss function based on automatic translation evaluation measures, a minimum bayes-risk Chapter 2. State of the art 21 decoding scheme can also be used to tune a SMT system, as in [Kum04]. Nowadays, all SMT systems use a log-linear combination of feature models, optimised according to a certain automatic measure on the development data. 2.4.2 Re-ranking In [She04] a discriminative reranking strategy is introduced for improving SMT performance (and also used in many systems, such as [Qua05]). This technique works as follows: •First, a baseline system generates n-best candidate hypotheses •Then, a set of features which can potentially discriminate between good and bad hypotheses are computed for each candidate •Finally, these features are weighted in order to produce a new candidate ranking The advantage is that, given the candidate sentence, features can be computed globally, enabling rapid experimentation with complex feature functions. This approach is followed in [Och03b] and [Och04a] to evaluate the benefits of a huge number of morphological and shallowsyntax feature functions to re-rank candidates from a standard phrase-based system, with little success. The introduction of linguistic information into SMT systems is later addressed in §2.6. 2.5 Statistical Word Alignment Even though IBM word-based translation models include the alignment model as part of a whole translation scheme, this can also be defined as an independent Natural Language Processing task. In fact, most of current new generation translation models treat word alignment as an independent result from the translation model, as it was mentioned in §2.2.2 and §2.3. The task of automatic word alignment focuses on detecting, given a parallel corpus, which tokens or sets of tokens from each language are connected together in a given translation context, revealing thus the relationship between these bilingual units. Among the many applications in natural language processing, such as bilingual dictionaries extraction or transfer rules learning, word alignment becomes particularly crucial in the context of statistical machine translation, where it represents an essential block in the learning process of current statistical translation models. In fact, it is reasonable to expect that a correct generation of word alignment will show a positive correlation with translation quality. Chapter 2. State of the art 22 Actually, the relevance of word alignment has been corresponded by several previous works on the matter, including shared tasks in the frame of HLT-NAACL 2003 and ACL 2005 Workshops on Building and Using Parallel Texts [Mih03,Mar05]. Several competing systems were presented and evaluated against a manual reference. 2.5.1 Evaluating Word Alignment In order to evaluate the quality of the word alignment task, so far Alignment Error Rate (AER) as proposed in [Och00b] is commonly used. This measure requires a manual alignment reference (also called gold standard), indicating which source words should be linked to which target words for each reference sentence. Due to the ambiguity brought up by the alignment task, two link types are allowed during manual tagging, namely Sure links (which must be present for the alignment to be correct) and Possible links (which may be present for the alignment to be correct, but are not compulsory). With these definitions, one can define Recall, Precision and AER measures thus: recall =|A∩S| |S|, precision =|A∩P| |A| AER = 1 −|A∩S|+|A∩P| |A|+|S| where Ais the hypothesis alignment and Sis the set of Sure links in the gold standard reference, and P includes the set of Possible and Sure links in the gold standard reference. It has been shown that the percentage of Sure and Possible links in the gold standard reference has a strong influence in the final AER result, favouring high-precision alignments when Possible links outnumber Sure links, and favouring high-recall alignments otherwise [Lam04]. A well-founded criterion is to produce Possible links only when they allow combinations which are considered equally correct, as a reference with too many Possible links suffers from a resolution loss, causing several different alignments to be equally rated. In [Lam05] guidelines for building a word alignment evaluation scheme are presented. Taking into account that the notion of word alignment quality depends on the application, the authors review standard scoring metrics for full text alignment and give explanations on how to use them better, and suggest a strategy to build a reference corpus particularly adapted to applications Chapter 2. State of the art 23 where recall plays a significant role, like in machine translation. Specific examples for the Spanish- English European Parliament corpus are also described. Nowadays, due to a lack of perfect correlation between Alignment Error Rate and translation evaluation scores observed in many experiments, alternative word alignment evaluation metrics are being pursued. Very recent works on the subject can be found in [Fra06a,Aya06]. 2.5.2 Word Alignment approaches Currently statistical word alignment based on IBM and HMM models are considered to be state- of-the-art. A systematic performance comparison in terms of AER of these models can be found in [Och03c], where the authors also advocate a positive correlation between AER improvement and translation quality, as stated in [Och00a]. Typically, the implementation by[Och03a], which is freely-available in the GIZA++ package, is used. A great majority of current approaches to statistical translation depend on the results of this alignment tool to estimate their translation models. However, due to the model definition of alignment as a function from positions in the target sentence to positions in the source sentence, the result is strictly asymmetric, generating one- to-many word alignments. Usually, this is tackled by performing the alignment from source to target and from target to source, and symmetrising via the union of links, the intersection or other refined methods as in [Och00b]. In [GV02] contextual information is added to the IBM models in the framework of maximum entropy, with small but consistent improvements in AER. Other alignment models have been presented based on word cooccurrences, such as the Competitive Linking Algorithm (CLA) in [Mel00], or on link probabilities, as introduced in [Che03a] with promising results (as shown in [Mih03]). However, they generally assume a one-to-one constraint that, despite generating high-precision links, does not account for many translation phenomena. A similar idea is followed in [Che05] where one-to-one CLA alignments are combined with IBM-based symmetrised aligmment to extend the phrase extraction procedure. In 2005, following an idea already hinted in [CB04], several independent works demonstrated that discriminatively trained models can equal or surpass the alignment accuracy of the standard models, if the usual unlabeled bilingual training corpus is supplemented with human-annotated word alignments for only a small subset of the training data [Liu05,Itt05,Fra05]. Therefore, current research efforts seem to be shifting towards a log-linear combination of feature models, estimated on a small word-aligned development set [Che06,Fra06b,Moo06,Blu06]. Chapter 2. State of the art 30 nist penalty(ratio) = exp log(0.5) log(1.5)2·log (ratio)2(2.19) Finally, Nmatch weightiis also a cumulative count (updated sentence by sentence), defined as: Nmatch weighti= N X n=1 X ngr∈Smin nN(testn, ngr),max r{N(refn,r, ngr)}o·weight(ngr)(2.20) where weight(ngr) is used to weight every n-gram according to the identity of the words it contains, expressed as follows: weight(ngr) =    −log2N(ngr) N(mgr)if mgr exists; −log2N(ngr) Nwords otherwise; (2.21) where mgr is the same N-gram of words contained in ngr except for the last word. N(ngram) is the number of occurrences of the Ngram ngram in the reference sets. Nwords is the total number of words of the reference sets. The NIST score is a quality score ranging from 0 to (worst translation) to an unlimited positive value. In practice, this score ranges between 5 or 12, depending on the difficulty of the task (languages involved and test set length). From its definition, we can conclude that NIST favours those translations that have the same length as the average reference translation. If the provided translation is perfect but ’short’ (for example, it is the result of choosing the shortest reference for each sentence), the resultant NIST score is much lower than another translation with a length more similar to that of the average reference. 2.7.1.3 mWER Word Error Rate (WER) is a standard speech recognition evaluation metric, where the problem of multiple references does not exist. For translation, its multiple-reference version (mWER) is computed on a sentence-by-sentece basis, so that the final measure for a given corpus is based Chapter 2. State of the art 31 on the cumulative WER for each sentence. This is expressed in 2.22: mWER = N X n=1 WERn N X n=1 Avrg Ref Lengthn ·100 (2.22) where Nis the number of sentences to be evaluated. Assuming we have Rdifferent references for each sentence, the average reference length for a given sentence nis defined as: Avrg Ref Lengthn= R X r=1 Length(Refn,r) R(2.23) Finally, the WER cost for a given sentence nis defined as: WERn= min rLevDist(Testn, Refn,r) (2.24) where LevDist is the Levenshtein Distance between the test sentence and the reference being evaluated, assigning an equal cost of 1 for deletions, insertions and substitutions. All lengths are computed in number of words. mWER is an percentual error metric, thus defined in the range of 0 to 100, 0 meaning the perfect translation (matching at least one reference for each test sentence). From mWER description, we can conclude that the score tends to slightly favour shorter translations to longer translations. This ca be explained by considering that the absolute number of errors (found as the Levenshtein distance) is being divided by the average sentence length of the references, so that a mistake of one word with respect to a long reference is being overweighted in contrast to one mistake of one word with respect to a short reference. Suppose we have three references of length 9, 11 and 13 (avglen = 11). If we have a translation which is equal to the shortest reference, except by one mistake, we have a score of 1/11 (where, in fact, the error could be considered higher, as it is one mistake over 9 words, that is 1/9). 2.7.1.4 mPER Similar to WER, the so-called Position-Independent Error Rate (mPER) is computed on a sentence-by-sentece basis, so that the final measure for a given corpus is based on the cumulative PER for each sentence. This is expressed thus: Chapter 2. State of the art 32 mPER = N X n=1 PERn N X n=1 Avrg Ref Lengthn ·100 (2.25) where Nis the number of sentences to be evaluated. Assuming we have Rdifferent references for each sentence, the average reference length for a given sentence nis defined as in eqnarray 2.23. Finally, the PER cost for a given sentence nis defined as: PERn= min r(Pmax(Testn, Refn,r)) (2.26) where Pmax is the maximum between: •POS = num. of words in the REF that are not found in the TST sent. (recall) •NEG = num. of words in the TST that are not found in the REF sent. (precision) in this case, the number of words includes repetitions. This means that if a certain word appears twice in the reference but only once in the test, then POS=1. 2.7.1.5 Other evaluation metrics Apart from these, several other automatic evaluation measures comparing hypothesis translations against supplied references have been introduced, claiming good correlation with human intuition. Although not used in this Ph.D. dissertation, here we refer to some of them. •Geometric Translation Mean, orGTM, measures the similarity between texts by using a unigram-based F-measure, as presented in [Tur03] •Weighted N-gram Model, or WNM, introduced in [Bab04], is a variation of BLEU which assigns different value for different n-gram matches •METEOR includes a word stemming process of the hypothesis and references to extend unigram matches (see [Ban05b]) •ORANGE ([Lin04b]) uses unigram co-occurrences and adapts techniques from automatic evaluation of text summarisation, as presented in the ROUGE score ([Lin04a]) Chapter 2. State of the art 33 •mCER is a simple multiple-reference character error rate, and is supplied by ELDA •As a result from a 2003 John Hopkins University workshop on Confidence Estimation for Statistical MT, [Bla04] introduce evaluation metrics such as Classification Error Rate (CER) or the Receiving Operating Characteristic (ROC) •From a more intuitive point of view, in [Sno05] Translation Error Rate, or TER, is presented. This measures the amount of editing that a human would have to perform to change a system output so it exactly matches a reference translation. Its application in real-life situation is reported in [Prz06]. Finally, rather than aiming at defining a supermetric ’XXX’, in [Gim06] the IQMT framework is presented. This tool follows a ’divide and conquer’ strategy, so that one can define a set of metrics and then combine them into a single measure of MT quality in a robust and elegant manner, avoiding scaling problems and metric weightings. 2.7.2 Human evaluation metrics Human evaluation metrics require a certain degree of human intervention in order to obtain the quality score. This is a very costly evaluation strategy that seldom can be conducted. However, thanks to international evaluation campaigns, these measures are also used in order to compare different systems. Usually, the tendency has been to evaluate adequacy and fluency (or other relevant aspects of translation) according to a 1 to 5 quality scale. Fluency indicates how natural the hypothesis sounds to a native speaker of the target language, usually with these possible scores: 5 for Flawless, 4 for Good, 3 for Non-native, 2 for Disfluent and 1 for Incomprehensible. On the other hand, Adequacy is assessed after the fluency judgement is done, and the evaluator is presented with a certain reference translation and has to judge how much of the information from the original translation is expressed in the translation by selecting one of the following grades: 5 for all of the information, 4 for most of the information, 3 for much of the information, 2 for little information, and 1 for none of it5. However, another trend is to manually post-edit the references with information from the test hypothesis translations, so that differences between translation and reference account only for errors and the final score is not influenced by the effects of synonymia. The human targeted reference is obtained by editing the output with two main constraints, namely that the resultant references preserves the meaning and is fluent. 5These grades are just orientative, and may vary depending on the task. Chapter 2. State of the art 34 In this case, we refer to the measures as their human-targeted variants, such as HBLEU, HMETEOR or HTER as in [Sno05]. Unfortunately, this evaluation technique is also costly and cannot be used constantly to evaluate minor system improvements. Yet we are of the opinion that, in the near future, these methods will gain popularity do to the fact that, apart from providing a well-founded absolute quality score, they produce new reference translations that can serve to automatically detect and classify translation errors. Regarding automatic error classification or analysis, some recent works on the subject suggest that it is possible to use linguistic information to automatically extract further knowledge from translation output than just a single quality score (we note the work of [Pop06a,Pop06b]). 2.7.3 International evaluation campaigns Another very relevant factor contributing to the growth in SMT research are international evaluation campaigns. Organised by different institutions, consortiums, conferences or workshops, these campaigns are the perfect tool to assess the translation quality of state-of-the-art SMT systems. Furthermore, systems can be compared and knowledge is shared among researchers from several different sites. With a large experience in automatic speech recognition benchmark tests, the National Institute of Standards and Technology (NIST), belonging to the Government of the United States, organises yearly machine translation tests since the early 2000s. Aiming at a breakthrough in translation quality, these tests are usually unlimited in terms of data for training. The target language is English, and sources include Arabic and Chinese. Further information can be accessed through http://www.nist.gov/speech/tests/mt/index.htm. Since October 2004, the C-STAR6consortium organises the International Workshop on Spoken Language Translation (IWSLT) on a yearly basis. This workshop includes an evaluation campaign oriented towards speech translation and small data availability. Therefore, training material tends to be limited. Language pairs include Chinese, Japanese, Korean, Arabic, Italian and English (usually English being the target language). Reports of the 2004 and 2005 editions7 are published in [Aki04] and [Eck05], respectively. In 2005, a Workshop on Building and Using Parallel Texts: data-driven MT and beyond, organised at the 43rd Annual Meeting of the Association for Computational Linguistics (ACL), also included a machine translation shared task reported in [Koe05b]. In this case, translation between European languages (Spanish, Finnish, French, German and English) was the main task. Training included the European Parliament proceedings corpus ([Koe05a]). 6Consortium for Speech Translation Advanced Research, http://www.c-star.org 7Further information at http://www.slt.atr.jp/IWSLT2004 and http://www.is.cs.cmu.edu/iwslt2005 . Chapter 2. State of the art 35 In 2006, a new edition of this evaluation campaign was conducted in the HLT/NAACL’06 Workshop on Statistical Machine Translation, as reported in [Koe06]. Additionally, the the European project TC-STAR (Technology and Corpora for Speech to Speech Translation) organised a first internal evaluation in 2005 (for members of the project, including UPC) and an open evaluation in 2006. Further details can be obtained from http://www.elda.org/tcstar-workshop/2006eval.htm. Chapter 2. State of the art 36 Chapter 3 The Bilingual N-gram Translation Model 3.1 Introduction This chapter is devoted to the study of the bilingual translation model implemented, which is the core model of UPC SMT system. This chapter is organised as follows: •Firstly, the initial implementation using X-grams for speech translation (on a Finite-State Transducer architecture) is discussed in §3.2. The training of such a model, along with experiments and results with small corpora are reported. Main achievements, limitations and related publications are also commented. •Then, in §3.3 we report on the evolution of this model towards an N-gram implementation, which is able to work on large-vocabulary tasks. Modelling issues such as tuple pruning and smoothing are also addressed, and experiments are reported on larger data sets. •Finally, §3.4 presents a thorough study of the translation unit used in the model, ie. the tuple. Its main properties and alternative tuple definitions are evaluated and compared. These topics include a discussion on tuple structural definition in §3.2.3, the problem of embedded words in §3.4.1 and details on tuple segmentation in §3.4.2. To conclude, in §3.5 a summary of the chapter can be found, highlighting the main conclusions extracted from it. 37 Chapter 3. The Bilingual N-gram Translation Model 38 3.2 X-grams FST implementation 3.2.1 Reviewing X-grams for Language Modelling A language model can be defined as the probability of a certain sequence of tokens (usually words), and it is a broadly-used model which plays a very important role in several statistical pattern matching tasks, ranging from speech recognition to machine translation or other language-related tasks defined on posterior probability frameworks. In order to estimate the probability of a certain sequence of Mwords w1, w2...wMas defined in equation 3.1, the most extended method are n-grams, which reduce the exponentiallyincreasing history space to the n−1 previous words, as shown in equation 3.2. p(w1w2...wM) = M X i=1 p(wi|w1...wi−1) (3.1) p(w1w2...wM)≈ M X i=1 p(wi|wi−n+1...wi−1) (3.2) Still, even for a moderate vocabulary size of K= 1000 words, the number of model parameters to estimate for trigrams (n= 3) is very large (more than 109) and usually unobserved in training material. In this case, the maximum likelihood estimator is not appropriated, and smoothing techniques are required. In [Bon96] an alternative approach to language modelling, named X-grams, is presented. Three main conclusions can be drawn from this work, namely: •n-grams can be implemented efficiently by means of a Finite-State Automaton. Each state is represents a conditioning history (wi−n+1...wi−1) which has been seen in training material, and each arc contains the words wiwhich have followed them, together with the associated language model probability p(wi|wi−n+1...wi−1). This way, the language model of a certain sentence can be computed by traversing the full sentence through the FSA and multiplying probabilities. •State merging techniques can be used to smooth probabilities and achieve a language model with low perplexity. Two criteria to merge the state defined by history (wi−n+1...wi−1) into the smaller-history state defined by (wi−n+2...wi−1) are introduced, resulting in language models with low perplexity values. These criteria are: Chapter 3. The Bilingual N-gram Translation Model 39 –the states are merged if the longest-history state has occurred less than kmin number of times in the training material –the states are merged if the divergence between their output probability distributions p=p(w|wi−n+1...wi−1) and q=q(wi|wi−n+2...wi−1) is smaller than a certain threshold f, where divergence is defined as in equation 3.3, a well-known information theory function D(pkq) = J X j=1 p(i)·log p(j) q(j)(3.3) •History size can vary depending on the words involved. When n-gram models increase their history size n, probabilities estimated for long histories may not be always reliable. On the other hand, even when reliable, perhaps these give no additional information with respect to probabilities conditioned on smaller histories. As the X-gram term denotes, the presented state merging techniques produce a model conditioned on variable-size histories, capturing long histories only whenever these bear some relevant information. This language modelling technique was successfully incorporated into an speech recognition engine in [Bon98]. For this purpose, a very compact representation of X-grams using null transitions is introduced. However, this representation is not a formal automaton, as the valid transitions now depend on the way a certain state was accessed, causing a less efficient decoding search (as the valid transitions need to be marked at decoding time). 3.2.2 Bilingual X-grams for Speech Translation Regarding machine translation, we can follow the same approach by estimating X-grams for a new bilingual language, whose words are not regular words anymore, but a composition of words from a source and a target language having a translational relationship (ie. in principle carrying the same meaning). This unit is to be called tuple, and can be defined as: Tk= (sik+1−1 ik, tjk+1−1 jk)≡(s, t)k(3.4) where sik+1−1 ikindicates the sequence of source words from position ik(where tuple Tkstarts) to position ik+1 −1, and tjk+1−1 jkthe associated sequence of target words. As we can see, a source sentence and its translation can be decomposed into a sequence of such tuples T1, T2, ..., Tk. Under this framework, given an input sentence, standard search algorithms (such as Viterbi) can still be used to find the best-probability path through the automaton. Only minor changes need to be done in order to quickly implement such a translator; since the vocabulary is now Chapter 3. The Bilingual N-gram Translation Model 46 Closely related to tuple structure is the word alignment used to extract tuples from. If tuples are extracted from source-to-target word alignment, many one-to-NULL tuples are generated, and the model is prone to omit translations (resembling tuple type I). On the contrary, if a symmetrised word alignment is used (the ’union’ of source-to-target and target-to-source alignments), then less tuples have empty translation, and more many-to-many tuples make the model more sparse. This issue will be addressed again in §3.2.5.2. 3.2.4 Monotonicity vs. word reordering Given the need for a sequence of tokens related to the X-grams formulation, the very basic treat of tuples is their monotonicity. In other words, when following them in monotone order, tuples must produce both the source and target sentence in the correct word order. However, each language expresses concepts in different order, and depending on the pair of languages involved, translation will not be a monotone process. In fact, this is also captured in the definition of IBM translation and alignment models of §2.1.1, where crossed dependencies are expected to occur. Therefore, if two languages are close in word order, alignment will tend to be monotone, and the extracted tuples from training data will be shorter (include less words) and easier to re-use during decoding. On the contrary, if these languages differ strongly in word order, alignments will have so-called long-distance links, forcing the extraction of long tuples (including many words), leading to a sparser bilingual model with a bigger tuple vocabulary. This is exemplified in Tables 3.6 and 3.7. buscaba . . . . . . . . . . . . . + que . . . . . . . . . . . . +. lugar . . . . . . . . . . . +. . al . . . . . . . . . + + . . . llev´o . . . . . . . + + ..... le . . . . . . +....... objeto . . . . . +........ el . . . . +......... Encontrar . + + ........... NULL . . . +.......... NULL La troballa de l’ objecte el va dur a l’ indret que cercava Extracted tuples: Encontrar # La troballa NULL # de el # l’ objeto # objecte le # el llev´o # va dur al # a l’ lugar # indret que # que buscaba # cercava Table 3.6: Monotone alignments and tuple extraction. Spanish-Catalan example. Thus, we can conclude that, in principle, the bilingual model approach implemented by X- grams is more appropriate for addressing translation with closely-related languages, in terms Chapter 3. The Bilingual N-gram Translation Model 47 ayer . . . . . . . . . + aqu´ı . . . . . . . . +. inadmisible . . . . . +. . . . e . . . . +..... triste . . . +...... muy . . +....... incidente . . . . . . +. . . un . +........ produjo . . . . . . . +. . Se . . . . . . . +. . NULL . . . . . . . . . . NULL A rather sad and unacceptable incident happened here yesterday Extracted tuples: Se produjo un incidente muy triste e inadm. # A rather sad and unacc. incident happened aqu´ı # here ayer # yesterday Table 3.7: Non-monotone alignments and tuple extraction. Spanish-English example. of word order. For instance, translating between Romance languages (Catalan, French, Italian, Portuguese, Spanish, etc.). Note that, on the other hand, tuple extraction will be more influenced from erroneous word alignments which include false long-distance links, than the phrase extraction strategy from §2.2.2, which is able to extract smaller units independently apart from the largest units. 3.2.4.1 Studying English–Spanish cross patterns Notwithstanding this monotonicity restriction, the bilingual approach was applied to two limiteddomain English↔Spanish tasks in 2003, as reported in [Gis03]. These tasks were the complete VerbMobil database4, containing around 30k sentences and featuring a Catalan parallel translation, and an extract of the European Parliament 1996-2001 proceedings, containing 30k carefullyselected sentences5. These corpora statistics are shown in Tables 3.8 and 3.9, respectively. Statistics include number of sentences, words, vocabulary size, maximum sentence length, average sentence length, and number of human reference translations available. Note that, for test sets, vocabulary size is not shown but the number of Out-Of-Vocabulary (OOVs) words (ie. words appearing in the test which are not present in the training data) instead. 4Similar to the corpus used in §3.2.3, but now repeated training pairs are included, as well as punctuation marks. 5Due to computational problems at that time, all sentences were scored according to a geometric mean, computed by assigning each of its words a value, equivalent to its position within a frequency-of-occurrence ranking (extracted from the whole corpus). This way, the most ’vocabulary-consistent’ sentences were selected. Chapter 3. The Bilingual N-gram Translation Model 48 VerbMobil sent. words vcb/OOVs max.len. avg.len. refs. Catalan 253,241 4,909 75 9.1 train English 27,995 262,681 3,174 74 9.4 1 Spanish 253,394 5,620 74 9.1 Catalan 25,425 234 71 11.8 test English 2,059 25,454 137 68 12.3 1 Spanish 25,421 296 69 11.8 Table 3.8: VerbMobil parallel corpus statistics. EuParl-30k sent. words vcb/OOVs max.len. avg.len. refs. English 444,224 25,244 181 14.8 train Spanish 30,000 417,435 39,998 177 14.0 1 English 5,830 217 79 11.7 test Spanish 500 5,639 390 78 11.3 1 Table 3.9: EuParl-30k parallel corpus statistics. In order to tackle the non-monotonicity problem of the English↔Spanish pair, first a study of the most common non-monotonic alignments patterns (or cross patterns) was performed. For this, we defined each cross as a set of links (x1, y1),(x2, y2), ...(xN, yN) where each (xi, yi) describes a link between position xiand yiin the source and target sub-sequences composed of the words appearing in the cross. By extracting all word-aligned training examples with an alignment cross, we obtain the statistics from Table 3.10, which present the ten most frequent cross patterns when aligning from Spanish to English and from English to Spanish with the VerbMobil data. These patterns account for more than 60 % of all cases with a non-monotonic alignment, and reflect linguistic relationships between both languages, whereas the patterns appearing only once generally link many words and either are produced by infrequent long links or by a poor automatic word alignment. The columns entitled ’EuParl’ show how representative are these patterns in the EuParl corpus. As it can be seen, although there are some slight differences in the distributions, the trend tends to be the same. It is worth noting the much higher percentage of patterns appearing only once, which might be outlining a bad performance in the automatic alignment due to data sparseness. Spanish→English patterns The most frequent pattern (1,2)(2,1) usually takes the form of ’Noun + Adjective # Adjective + Noun’, as in ’semana siguiente # next week’. Less frequently, we found the form Chapter 3. The Bilingual N-gram Translation Model 49 Spa→Eng pattern Vmobil EuParl Eng→Spa pattern Vmobil EuParl (1,2) (2,1) 24.6 % 32.1 % (1,2) (2,1) 36.7 % 36.4 % (1,2) (2,0) (3,1) 15.0 % 3.6 % (1,3) (2,1) 8.7 % 2.1 % (1,3) (2,1) (2,2) 5.4 % 1.2 % (1,2) (2,3) (3,1) 4.8 % 4.7 % (1,3) (2,0) (3,1) (4,2) 3.9 % 0.2 % (1,3) (2,4) (3,1) 3.4 % 0.1 % (1,3) (2,1) (3,2) 3.4 % 1.5 % (1,2) (2,0) (3,1) 2.5 % 0.6 % (1,2) (2,0) (3,0) (4,1) 2.9 % 0.4 % (1,3) (2,1) (3,2) 2.3 % 0.2 % (1,2) (2,3) (3,1) 1.8 % 0.2 % (1,2) (1,3) (2,1) 1.9 % 0.5 % (1,3) (2,0) (3,0) (4,1) 1.4 % 0.3 % (1,2) (2,0) (3,3) (4,1) 1.8 % 0 % (1,3) (2,0) (3,0) (4,1) (5,0) (6,2) 1.3 % 0.1 % (1,4) (2,0) (3,1) 1.3 % 0.2 % (1,4) (2,0) (3,1) (4,2) (4,3) 0.9 % 0.1 % (1,3) (2,1) (2,2) 1.2 % 0.1 % 10 Vmobil most freq. patterns 60.5 % 39.7 % 64.6 % 44.9 % Patterns occurring only once 19.1 % 59.1 % 15.3 % 54.5 % Table 3.10: Most-frequent cross patterns for Spa→Eng and Eng→Spa alignments ’Adverb1+ Adverb2 # Adverb2 + Adverb1’, as in ’bastante bien # good enough. Interestingly, some cases are clear omissions, as in ’hecho es # is actually’, where the preceding Spanish word ’de’ was omitted due to the asymmetry of the alignment models (discussed in §2.1.1). This can be addressed with information of the crosses when aligning in the other direction. The second most frequent pattern (1,2)(2,0)(3,1) nearly always takes the form of a Noun followed by a Spanish prepositional clause (Noun + Preposition + Noun), and Adjective + Noun in English, as in ’viaje de negocios # business trip, or comparative adjectives as in ’hotel m´as barato # cheaper hotel. The third pattern (1,3)(2,1)(2,2) reveals the relationship ’Adverb + Verb = Pronoun + Verb + Adverb’ existing in cases such as ’siempre podemos # we can always, a relationship impossible to detect when aligning from English to Spanish. However, even in this case some crosses are wrongly detected, as in ’teor´ıa puedo # I can conceivably, where Spanish preceding word ’en’ is left out of the cross. English→Spanish patterns Interestingly, in this direction the great majority of patterns are concentrated into the most frequent one (1,2)(2,1), because it includes many cases from the first and third most-frequent patterns from the opposite alignment direction. It is clear that the Spa→Eng alignment is better than the Eng→Spa for these cases. However, in other situations, we found the conclusion to be the contrary. For example, whenever Spa→Eng alignment detects the (1,2)(2,1) pattern (such as ’vez entonces # then again) and the Eng→Spa detects the (1,3)(2,1)(2,2) pattern (’otra vez entonces # then again), the latter is more reliable. This suggests the existence of some complementary information between both views and Chapter 3. The Bilingual N-gram Translation Model 50 thus a combination strategy to better detect non-monotonic alignments might be possible. 3.2.4.2 An initial reordering strategy In order to improve the generation of bilingual tuples during the FST training, the introduction, for the most frequent patterns, of indexes referring to the relative positions of the target-language words given a cross was presented. For example, for pattern (1,2)(2,1), we swapped the order of the target words, introducing an index to the last target word to preserve the original link. This is expressed by: si→tj+1 si+1 →tj =⇒si→tj si+1 →tj+1(−1) where siis the source word in position iand tjis the target word in position j. The same applies for the second most frequent pattern (1,2)(2,0)(3,1), as the middle source word is aligned to no target word. For the third pattern (1,3)(2,1)(2,2), the same can be done after joining the two last words of the target sentence into a single token.    si→tj+2 si+1 →tj si+1 →tj+1 =⇒si→tj si+1 →tj+1tj+2(−1) Equivalently, the same procedure was carried out for the five most frequent VMobil cross patterns. Results are shown in the upper rows of Table 3.11, where cross5 results compare favourably to the baseline for all tasks reported. As complementary information regarding non-monotonic alignments was found when aligning from one direction to the other, another translation experiment was performed by adding as valid all those crosses which were detected in the opposite direction and belonged to the three most frequent patterns, but were not found in the straight direction. For instance, in Spa→Eng, we found 582 Eng→Spa crosses (489 for (1,2)(2,1), 39 for (1,3)(2,1) and 54 for (1,2)(2,3)(3,1)) which did not map into any cross in Spa→Eng alignment, and were thus added and subsequently coded. Results, shown in row crossX show a very slight further improvement. All in all, results showed a weak tendency to improvement, but definitely not a marked one. In fact, the best result was achieved through a much simpler categorisation strategy (described in the following section). The main reason to account for this seems to be that basically, the effect of introducing a relative-position index in some words when coding tuples seems to generalise but only in very few test cases. On the other hand, making the crossed relationship only dependent on relative positions and words might not help in some cases. For example, when dealing with the typical Spa→Eng pattern NounS+AdjS=AdjE+NounE, the new coding will be: NounS/NounEAdjS/AdjE-1 Chapter 3. The Bilingual N-gram Translation Model 51 VerbMobil EuParl-30k Spa →Eng Cat →Eng Spa →Eng WER BLEU WER BLEU WER BLEU baseline 31.15 0.564 33.18 0.541 48.25 0.463 +categ 29.67 0.583 31.40 0.564 +cross5 30.80 0.568 47.70 0.466 +crossX 30.70 0.569 32.68 0.542 47.29 0.470 +baseV 30.80 0.570 32.75 0.542 +baseA 30.90 0.566 +baseVA 30.91 0.569 +categ +crossX 29.37 0.584 +categ +baseV 29.57 0.583 +categ +crossX +baseV 29.30 0.584 31.16 0.565 Table 3.11: Translation results when reordering by indexing cross information (’cross’ rows) and classifying words to base form for alignment (’base’ words), for VerbMobil and EuParl-30k tasks. where the noun is generalised (whenever the same noun appears in a different context, it will be correctly translated, because its probability is boosted thanks to the coding), but the adjective is not. When this adjective appears in a different unseen context, the transducer will have to choose between a monotone (without index) and non-monotone (with index) translation, deciding for the most frequent in the training. In addition to that, the upper bound of this reordering strategy was not measured (ie. by means of an oracle score), being hard to conclude whether the new FST morphology (including relative-position indexes) was insufficient to achieve correct order, or whether simple the new estimated probabilities were not good enough (or both). 3.2.4.3 Morphology-reduced word alignment In addition, some preliminary results were presented on introducing POS-tagging and lemmatisation, as well as some preprocessing such as categorisation, to help improving the training of the system. In row categ from Table 3.11, date and time expressions were automatically categorised (substituted by a unified tag), achieving a more generalised translation FST6. Several experiments have been conducted substituting the original forms of Spanish verbs, adjectives, nouns and determiners, by their base form before aligning. The objective was to reduce variability and enforce links between, for example, a Spanish adjective, which might be declined in gender or number, and its English counterpart, which is invariant. For this, Spanish and Catalan data were tagged using maco+ and relax, the tagger and morphological disambiguator for unrestricted text developed at TALP Research Centre [Ats98]. 62746 instances of time expressions and 897 of date expressions were substituted in the training corpus Chapter 3. The Bilingual N-gram Translation Model 52 As seen in the lower part of Table 3.11, the most relevant results were found by classifying Verbs or Adjectives (see rows baseV and baseA), but improvements were again very meager. By far the major impact on evaluation metrics was achieved by categorising date and time expressions, or combinations of this with the previous presented strategies. Finally, given the structural similarity between Spanish and Catalan, the results for Catalan→English show the same trend. 3.2.5 The TALP X-grams translation system The bilingual X-grams translation system implemented with an FST architecture and presented above served as UPC–TALP Research Centre Statistical Machine Translation system until the end of 2004, before undergoing severe changes (which will be discussed in detail in chapter 4). The presentation of the system, as well as the preliminary morphology and reordering experiments, were published in the following contributions: •[Gis02b] A. de Gispert and J.B. Mari˜no, “Using X-grams for Speech-to-Speech Translation,” in Proceedings of the 7th International Conference on Spoken Language Processing, ICSLP’02, pps. 1885–1888, September 2002. •[Gis02a] A. de Gispert and J.B. Mari˜no, “An´alisis de las relaciones cruzadas en el alineado estad´ıstico para la traducci´on autom´atica,” in II Jornadas en Tecnolog´ıa del Habla, December 2002. •[Gis03] A. de Gispert and J.B. Mari˜no, “Experiments in word-ordering and morphological preprocessing for transducer-based statistical machine translation,” in IEEE Automatic Speech and Understanding Workshop, ASRU’03, pps.634–639, November 2003. In July 2004, the system was showcased in a public demonstration for the FAME project closure, and by August the same year it participated in the 1st IWSLT Workshop, competing against other systems in a Chinese→English task. 3.2.5.1 FAME project public demonstration Funded by European Union, the FAME7project (acronym of Facilitating Agents for Multicultural Exchange) joined efforts from Interactive Systems Labs at Universit¨at Karlsruhe, IRST (Trento), Univ. Polit`ecnica de Catalunya (Barcelona), Laboratoire GRAVIR (Grenoble), Laboratoire CLIPS (Grenoble), SONY Germany and ATLAS (Barcelona), in order to advance technologies towards a more human-like communication and information access environment. Among other research fields such as robust speech recognition or visual recognition and 7EU contract IST-2000-28323. http://islold.ira.uka.de/fame/ Chapter 3. The Bilingual N-gram Translation Model 53 tracking of human action, improving limited-domain Catalan↔English and Spanish↔English speech translation was one of the main goals. Two research lines were conducted, namely an interlingua-based approach ([Arr04]) and an statistical approach (X-gram-based SMT as presented above), whose quality was compared in [Arr05]. The city council of the city of Barcelona pledged support for the FAME project by providing financial and organisational support for a demonstration of the system at the ”Forum of Cultures”, which was held in Barcelona in July 2004 (during the celebration of the 42nd Annual Meeting of the Association for Computational Linguistics, ACL’2004). The demo, followed by the Mayor of Barcelona and all the major media, featured both speech translation systems working on-line by showing their speech recognition and translation outputs on a panel screen. Even though the domain was restricted to travel-related topics (as users were asked to pretend they were in need of travel agency services), it was seen as a success. From a technical point of view, the statistical translation component was of the same quality as that of the system just discussed in §3.2.4.2. 3.2.5.2 IWSLT’04 participation In October 2004, the C-STAR8consortium organised the 1st International Workshop on Spoken Language Translation (IWSLT), with the objective of providing a framework for the applicability validation of existing machine translation evaluation methodologies to evaluate speech translation technologies. It included an evaluation campaign whose details can be found in [Aki04]. The task was to translate from Japanese and Chinese to English, and 14 institutions took part in it. Not only statistical MT systems but also example-based MT systems, one rule-based system and other hybrid approaches were presented. UPC-TALP participated with the X-grams FST translation system in the Chinese→English task. IWSLT04 sent. words vcb/OOVs max.len. avg.len. refs. Chinese 182,904 7,643 69 9.1 train English 20,000 188,935 8,191 75 9.4 1 develop. Chinese 506 3,515 160 24 6.9 16 test Chinese 500 3,794 104 62 7.5 16 Table 3.12: IWSLT’04 Chinese→English parallel corpus statistics. Table 3.12 shows the details of the parallel corpus used for this task. During the system development work, the effect of state merging techniques on bilingual modelling (see §3.2.1), yielding a slight improvement by merging states whose divergence was smaller than 0.2 (even 8Consortium for Speech Translation Advanced Research, http://www.c-star.org Chapter 3. The Bilingual N-gram Translation Model 54 for such a reduced corpus size). Two runs were submitted, basically comparing the effect of choosing a symmetrised word alignment to extract tuples from (by performing the union of Chi→Eng and Eng→Chi links) or the straight Chi→Eng word alignment (s2t, meaning source-to-target). Table 3.13 presents the main results achieved by the system for the development and test sets (the latter including a manual evaluation of fluency and adequacy). set run align BLEU NIST WER PER fluency adequacy A union 0.255 5.210 60.3 51.8 dev B s2t 0.314 3.678 60.7 54.8 Aunion 0.279 6.778 55.6 46.5 2.792 3.022 test B s2t 0.331 5.391 55.0 49.0 Table 3.13: Evaluation results for IWSLT’04 Chinese→English task Despite contradictory evaluation metrics, a qualitative inspection of the results suggested the use of the union instead of the source-to-target alignment to be more adequate (even though it produced a lower BLEU score). The main reason was output length. Given the difficulty of the task in terms of word ordering, many long-distance links are found in automatic word alignment and, as explained in §3.2.4, this enlarges extracted tuples and makes the bilingual model more sparse. Theoretically, this situation seems to be aggravated when extracting tuples from the union alignment, since more links are present and it is more likely that long links occur. However, when extracting from the source-to-target alignment (which is a one-to-many alignment), many more tuples are linked to NULL, ie. they do not have any token in their target side. For this hard task, in which due to sparseness the bilingual model is often forced to go without context, this has a very negative effect on output. In fact, whereas the union translation generated around 3k words, the s2t had only 2,5k. Other research efforts were directed towards automatically extracting a translation dictionary for those words which were present within tuples along with other words and never seen as a single tuple (embedded words, which will be discussed in detail in §3.4.1), but with little impact on scores. All in all, when compared to other participants, results were not positive. The TALP SMT system landed on the 8th position of a 9-row ranking (see [Aki04] for the complete table), confirming the inadequacy of its monotonicity for a task in need of reordering strategies. It goes without saying that the lessons learned from this experience were crucial to further develop the system, as will be clearly seen in chapter 4. Chapter 3. The Bilingual N-gram Translation Model 55 Further details on these experiments are reported in the following publication: •[Gis04a] A. de Gispert and J.B. Mari˜no, “TALP: Xgram-based Spoken Language Translation System,” in Proceedings of the 1st International Workshop on Spoken Language Translation, IWSLT’04, pps. 85–90, October 2004. Chapter 3. The Bilingual N-gram Translation Model 62 Spa→Eng Eng→Spa smoothing technique BLEU mWER BLEU mWER Good-Turing 0.4629 39.05 0.4164 44.27 Modif. Kneser-Ney 0.4645 39.11 0.4171 44.39 Modif. Kneser-Ney +interpolation 0.4698 38.73 0.4221 43.60 Natural Discounting 0.4494 40.31 0.4026 45.66 Kneser-Ney 0.4633 39.26 0.4147 44.71 Witten-Bell 0.4544 39.93 0.4055 45.33 Witten-Bell +interpolation 0.4556 39.89 0.4109 44.85 Table 3.18: Obtained scores estimating the bilingual model with different smoothing techniques (EuParl ver 2 task Eng→Spa). leading to the conclusion that the bilingual model behaves similarly to a standard (monolingual) language model when it comes to smoothing techniques. Given that modified Kneser-Ney smoothing consistently performs better, it was assumed in previous experiments on history length and pruning issues, reported in §3.3.1.1 and §3.3.1.2 respectively. 3.3.2 Case study: the Catalan-Spanish task To conclude this section devoted to the N-gram implementation of the tuple bilingual model, here we review a case study of its application to a Catalan↔Spanish large-vocabulary task ([Abe06]). Belonging to the same family of languages, being very much influenced and sharing in many cases the same speakers, Spanish and Catalan languages exhibit a morphological and grammatical similarity (including strong monotonicity in word order) favouring the deployment of the presented bilingual N-gram model, thus serving as test bank to assess the validity of the approach when initial conditions are quasi-optimal. Cat News sent. words vcb/OOVs max.len. avg.len. refs. Catalan 43.28 M 390.2 k 100 19.9 train Spanish 2.18 M 41.51 M 397.4 k 100 19.1 1 Catalan 48,3 k 217 98 24.2 1 test Spanish 2 k 46,4 k 200 98 23.2 1 Table 3.19: Catalan–Spanish newspaper parallel corpus statistics. The corpus used for this experimentation, named CatNews, is a collection of web-mined news from a general bilingual newspaper published in Catalonia in the period of 1998 to 2003. Data collection and preprocessing is reported in [Fri03,FM05,Abe06]. Table 3.19 shows the main statistics of the corpus. As observed from the high vocabulary figures, this is largely an Chapter 3. The Bilingual N-gram Translation Model 63 open-domain task. Results obtained by the SMT system are shown in Table 3.20. As it can be seen from the obtained evaluation scores, the translation quality improvement with respect to all other translation tasks is noteworthy. Even with a single manual reference, error is much smaller. BLEU mWER NIST PER Spa→Cat 0.8421 9.88 13.93 8.74 Cat→Spa 0.8334 10.08 13.73 8.86 Table 3.20: Translation results for Catalan–Spanish newspaper task. Besides, and interestingly, whereas the N-gram translation model takes advantage of additional feature models in most translation tasks (as will be studied in chapter 4), this behaviour is not observed in the Catalan-Spanish tasks, where simply the ngram translation model suffices to generate high-quality translations. These facts reflect the grammatical similarity between Spanish and Catalan, which allows for a well-estimated model (nearly free from sparseness problems) even with large vocabulary sizes. A thorough human error analysis of this translation task was carried out in [Abe06], concluding that around 80% of the test sentences were entirely correct, ie. had no translation error at all. In most cases, synonyms accounted for differences between translated test and reference translations. Among errors, unseen words, agreement issues and omitted words were the most frequent types. A web demonstrator With the purpose of disseminating research activity results to a broader public, and given the positive results achieved by the system in this task, a Catalan↔Spanish web demonstrator of this system was implemented at UPC10. The result was N-II, which is accessible at http://www.n-ii.org , and allows users to obtain high-quality translations online at any time. A screenshot of this demo with a translation example is shown in Figure 3.4. Bridging to Catalan–English Another application of this high-quality Catalan↔Spanish system is related to language portability, by building a Catalan↔English SMT system without parallel corpus. Regarding the parallel corpora necessary to build statistical machine translation systems, it 10By Antonio Abell´an, Patrik Lambert, Josep Maria Crego, Jos´e B. Mari˜no and Adri`a de Gispert Chapter 3. The Bilingual N-gram Translation Model 64 Figure 3.4: Screenshot of www.n-ii.org, the Catalan↔Spanish online demostrator. becomes nearly impossible to find freely-available large-vocabulary data in Catalan and other languages (except for Spanish). Since many more parallel corpora in Spanish are available, one can reasonably think of using Spanish as a bridge towards statistical machine translation from Catalan to other languages, and vice versa. Further details on these experiments are reported in the following publication: •[Gis06b] A. de Gispert and J.B. Mari˜no, “Catalan-English Statistical Machine Translation without Parallel Corpus: Bridging through Spanish,” in Proceedings of LREC 5th Workshop on Strategies for developing Machine Translation for Minority Languages, SALTMIL’06, pps. 65–68, May 2006. To conclude, [Gis06b] also presents a result when translating from Spanish to Catalan in the European Parliament task (version 2), as shown in Table 3.21. In this case, the manual reference available is adapted to the translated output (ie. it is human-targeted, a concept introduced in §2.7.2) and does not suffer from synonymy, rendering a quality score of the system which is not pessimistic. Chapter 3. The Bilingual N-gram Translation Model 65 BLEU mWER NIST PER Spa→Cat 0.9345 3.79 13.73 3.49 Table 3.21: Translation results for Spanish→Catalan EuParl ver2 task. 3.4 The Tuple as Translation Unit Apart from this structural definition, two additional issues regarding the N-gram translation model must be considered (embedded words and NULL-to-one tuples), which are discussed next. 3.4.1 Embedded words A first issue is connected with the fact that an (possibly) important amount of single-word translation probabilities are often left out of the model. This happens for all those words that appear always embedded into tuples containing two or more source words. For example, consider source word ’D’ from Figure 3.3, which is extracted together with ’E’ and ’F’ into the tuple ’DEF→XY’ (tuple type III). When examining the word-aligned training material, if all occurrences of word ’D’ present a similar pattern, ie. the word is forced to share a tuple with other source words, no translation probability for this single word will ever be estimated by the model. In this case, we say that the word is embedded. Clearly, this problem is aggravated if the pair of languages involved has a non-monotone alignment, leading to very long tuples (and a higher number of embedded words). To address this problem, we build up a dictionary of translations for embedded words from the most accurate word alignment available (usually, the intersection of source-to-target and target-to-source alignments). For a certain embedded word fjand a given word alignment, we look for the target words ei...ei+Kthat are most frequently aligned to fjwith these two conditions: 1. Target words ei...ei+Kare consecutive in the target sentence. 2. Target words are aligned only to fjor to null. This way, we build up a statistical dictionary independently of the non-monotonicity of the word alignment. The entries of the dictionary are included as unigrams in the bilingual model. Under a Spanish↔English framework, the embedded words problem is practically irrelevant (affecting a list of singleton words11), due to the relative monotonicity of the pair, basically turning into a question of completeness, so that the system is able to produce atranslation at 11Words occurring only once in the training parallel corpus. Chapter 3. The Bilingual N-gram Translation Model 66 all. However, this dictionary solution, which was presented in [Gis04a], forces the model to fall back to an incontextual word-based translation for embedded words, which can be negative for language pairs with strong reordering needs (such as Chinese and English). 3.4.2 Tuple segmentation As we saw in §3.2.2.1, tuple extraction is the process by which tuples are generated from word alignment. From a conceptual point of view, the final goal is to obtain a set of tuples which have the highest ’re-usability’ capacity, ie. that they can be recycled in order to produce valid translations in certain unseen situations, the more the better. For example, if we segment the bilingual sentence ’through the vote on Thursday # mediante la votaci´on del jueves’ into the following tuples: through the vote on Thursday mediante la votaci´on del jueves it is intuitive that these tuples will only be useful to translate exactly the same sentence (no reuse), as we can expect that in very few situations votaci´on del jueves will be a valid translation of on Thursday. The intuition tells us that a more ’usable’ segmentation (ie. leading to a less entropic model) would be something like: through the vote on Thursday mediante la votaci´on del jueves On the other hand, the tuple definition (according to the constraints laid down in §3.2.2.1) defines a unique set of tuples except in one situation, which is whenever the resulting tuple contains no source word (NULL-source tuple). In order to re-use these units in decoding new sentences, the search should allow for no input word to generate units, and this is not the case. Therefore, these units cannot be allowed, and a certain hard decision must be taken as for tuple segmentation in these cases, as in the following example: 3.4.2.1 Segmentation strategies According to the aforementioned conceptual framework of N-gram translation model, it seems clear that the ideal tuple segmentation strategy should take a global decision based on the segmentation for all other NULL-source cases, attempting to obtain that set of tuples and N- grams which better represented the unseen universe of events, meaning the one with less entropy. However, no feasible algorithm can perform that calculation in a reasonable time given current Chapter 3. The Bilingual N-gram Translation Model 67 computational power, as this would involve a whole model re-estimation for each particular segmentation alternative. Deterministic always NEXT A very pragmatic and simple approach to take this decision is to always join the target words involved in NULL links (NULL-linked words) to the following tuple, if there is any (otherwise, to the previous one). This approach, first introduced in [Gis04a], was used in all X-gram experiments reported in §3.2. Apart from simplicity and extreme efficiency, we do not observe any other advantage of this approach, which on the other hand does not follow any linguistic or statistical criterion. IBM model 1 weight Being independent of word position, IBM model 1 probabilities provide a probabilistic lexicon between pairs of word of each language (see §2.1.1 for details on these models). This information can be used to weight and compare the resulting tuples from two competing segmentations, as introduced in [Cre05a]. The weight for each tuple is defined as: 1 I J Y j=1 I X i=0 pIBM1(ti|sj)pIBM10(sj|ti) (3.10) where sand trepresent source and target sides of a tuple, Iand Jtheir respective number of words and IBM10stands for the IBM model 1 estimated in the opposite direction. While this approach is appealing in that it takes bilingual information into account, observation of these situations leads to a different conclusion. Many NULL-linked words represent articles, prepositions, conjunctions and other particles whose main function is to ensure the grammatical correctness of a sentence, complementing other more informative words. Therefore, their probabilities to translate to another word are not very meaningful. Entropy of the POS distribution Alternatively, from a linguistic point of view, one can regard the tuple segmentation problem around source NULLs as a monolingual decision related to whether a given target word is more connected to its preceding or following word. Intuitively, we can expect that a good criterion to perform tuple segmentation lays in preserving grammatically-connected phrases (such as, for instance, articles together with the noun they precede) in the same tuple, as this may probably lead to a simplification of the translation Chapter 3. The Bilingual N-gram Translation Model 68 task. On the contrary, splitting linguistic units into separate tuples will probably lead to a tuple vocabulary increase and a higher sparseness, producing a worse (and more entropic) N-gram translation model. In this direction, we proposed to take the segmentation decision according to the entropy of the forward and backward Part-Of-Speech (POS) distributions, which was defined conditioned to context. In detail, given the following 3-tuple sequence: < ...sj>NULL < sj+1... > | | | < ...ti−1> ti< ti+1... > where sjmeans word in position jin source sentence, and equivalently timeans word in position iin target sentence, one can define a ’forward’ entropy of the POS distribution in position i+ 1 given (ti−1, ti) as in equation 3.11: Hf P OS =−X P OS pf P OS log pf P OS (3.11) where pf P OS =N(ti−1, ti, P OSi+1) PP OS0N(ti−1, ti, POS0 i+1)(3.12) is the probability of observing a certain Part-Of-Speech following the sequence of words defined by tiand ti+1, estimated by relative frequency. Equivalently, one can define a ’backward’ entropy of the POS distribution in position i−1 given (ti, ti+1) as in equation 3.13: Hb P OS =−X P OS pb P OS log pb P OS (3.13) where pb P OS =N(P OSi−1, ti, ti+1) PP OS0N(POS0 i−1, ti, ti+1)(3.14) is the probability of observing a certain Part-Of-Speech preceding the sequence of words defined by ti−1and ti. Then, we can take a tuple segmentation decision favouring the most POS-entropic case. The rationale behind this is that, if Hf P OS > Hb P OS, we have observed the first sequence of Chapter 3. The Bilingual N-gram Translation Model 69 words comprised of (ti−1, ti) in more grammatically different situations than the latter sequence comprised of (ti, ti+1). Therefore, we can induce that ti−1and titend to be more often connected than tiand ti+1, and should belong to the same translation tuple. Analogously, one can conclude the contrary if Hf P OS < Hb P OS. hay NULL ninguna | | | there are no Hf P OS(there, are, ∗∗∗) = 0.83 Hb P OS(∗∗∗, are, no) = 0.62 Table 3.22: Example of Hf P OS and Hb P OS entropies. To illustrate this idea, consider the example in Table 3.22, where ’there are’ proves to be more connected than ’are no’, thus being linked in the same translation unit. Source Target alwaysNEXT IBM1weight POSEntropy We Nos We — Nos are pleased alegramos are pleased — alegramos at NULL at—NULL NULL de at—de at—de this esta this—de esta this—esta this—esta visit visita visit — visita which que which—que which—que NULL se which—que se reflects enmarca reflects—se enmarca reflects—enmarca reflects—se enmarca en NULL en the la the—en la the—en la the—la cooperation cooperaci´on cooperation — cooperaci´on between entre between — entre parliaments parlamentos parliaments — parlamentos in NULL in—NULL in—NULL NULL de in—de the la the—de la the—de la the—la Union Uni´on Union — Uni´on Table 3.23: Example of segmentation decisions around NULL-linked words taken by each criterion in a real-life English-to-Spanish sentence. While this is a monolingual decision on the target language morphology, it proves very consistent with human intuition. To sum up, Table 3.23 shows an English–Spanish sentence example, where original links (from word alignment) are shown in the first two columns, and the segmentation decisions taken by each strategy are shown in the right-most three columns. As it can be seen, being linguistically-guided, the POS entropy approach is much more correlated Chapter 3. The Bilingual N-gram Translation Model 70 with human intuition. 3.4.2.2 Comparative results In order to compare each segmentation strategy and evaluate its impact on translation quality, experiments were carried out using two parallel corpora, differing in language pair and corpus size. On the one hand, we used a Spanish–English large-vocabulary corpus (European Parliament Proceedings Corpus version 212), and on the other hand, an Arabic-to-English small-vocabulary corpus, containing a small part of the Basic Travel Expressions Corpus. EuParl ver2 sent. words vcb OOVs avg.len. refs. English 33.37 M 104.8 k - 27.3 train Spanish 1.22 M 34.96 M 151.4 k - 28.6 1 English 15.3 k 2.30 k 20 30.4 3 develop Spanish 504 15.4 k 2.74 k 22 30.6 3 English 1094 26.88 k 4.0 k 113 24.6 2 test Spanish 840 22.75 k 4.1 k 44 27.1 2 Table 3.24: European Parliament English-Spanish corpus version 2 statistics. The main statistics of each corpus, including number of sentences, running words, vocabulary size, out-of-vocabulary words (for development and test sets), average sentence length and number of human references, are shown in Tables 3.24 and 3.25, respectively. BTEC-20k sent. words vcb OOVs avg.len. refs. Arabic 180.5 k 16.0 k - 9.0 train English 20 k 189.2 k 7.2 k - 9.5 1 develop Arabic 506 3.63 k 1.18 k 196 7.2 16 test Arabic 1006 7.22 k 1.9 k 356 7.2 16 Table 3.25: Travel Expressions Arabic-English 20k-corpus statistics. In both bases, English was tagged using TnT13 tagger ([Bra00]), and Spanish using FreeLing14 analysis toolkit ([Car04]). For the train set, Table 3.26 also shows the number of running tuples extracted from the word alignment used15, together with the percentage of tuples with NULL in one of its sides. As expected, this percentage is higher in English side (14.5%), given that Spanish contains more running words that have no direct correspondence in English. 12Version 2 is nearly identical to version 1, whose statistics are shown in Table 3.14, except for Spanish preprocessing, which includes an improved tokenisation tool 13Available at www.coli.uni-saarland.de/∼thorsten/tnt 14Available at http://garraf.epsevg.upc.es/freeling 15Union of src→trg and trg→src alignments, obtained with GIZA++ tool. Chapter 3. The Bilingual N-gram Translation Model 71 EuParl ver2 BTEC-20k Spanish English Arabic English running tuples 20,032 k 122,176 train one-to-NULL tuples 11.7% 14.5% 7.0% 7.2% Table 3.26: Tuple statistics for each two parallel corpora used. As the N-gram model does not allow for tuples with empty source language, in Eng→Spa a segmentation decision on these 14.5% tuples must be taken, whereas in the opposite direction, only 11.7% of the tuples must be re-segmented. Therefore, we can expect a bigger impact of segmentation strategies in the Eng→Spa direction. BLEU mWER NIST alwaysNEXT 0.4215 43.98 9.22 IBM1weight 0.4221 43.60 9.19 Eng→Spa POSentropy 0.4325 43.48 9.30 trgNULL 0.4249 44.47 9.21 trgNULLpos 0.4313 43.75 9.29 alwaysNEXT 0.4661 39.37 9.86 IBM1weight 0.4698 38.73 9.91 Spa→Eng POSentropy 0.4756 38.64 9.95 trgNULL 0.4728 39.23 9.91 trgNULLpos 0.4733 38.78 9.93 alwaysNEXT 0.3684 41.80 7.16 Ara→Eng IBM1weight 0.3656 41.94 7.14 POSentropy 0.3691 41.91 7.17 Table 3.27: Translation model performance for each segmentation strategy. A comparison of the translation model performance for each task is shown in rows named ’alwaysNEXT’, ’IBM1weight’ and ’POSentropy’ in Table 3.27, referring to each segmentation strategy discussed in §3.4.2.1. Regarding the large-vocabulary tasks, the proposed linguistically-guided segmentation outperforms all other strategies significantly, especially in the Eng→Spa direction. This result is consistent with the fact that Spanish is a more word-generative language than English, and therefore, more NULLs are found in the English side of extracted tuples. Even though the impact of changing the segmentation criterion when translating into English is smaller, the improvement of the POSentropy approach is significant. In the small-vocabulary Ara→Eng task differences are less significant, in correlation with the fact that only 7% of tuples contain NULLs in Arabic side, compared to the 14% of Eng→Spa task, as shown in Table 3.26. Remarkably, whereas IBM1weight provides better results in large-vocabulary tasks than the Chapter 4. Ngram-based SMT 78 4.2 Feature-based log-linear combination As already mentioned in §2.4, recent translation systems have replaced the original noisy channel approach by a more general approach, which is founded on the principles of maximum entropy applied to Natural Language Processing tasks ([Ber96]). Under this framework, given a source sentence s, the translation task is defined as finding that target sentence twhich maximises a loglinear combination of multiple feature functions hi(s, t), as described by the following equation (equivalent to equation 2.10): ˆ t=argmax tX m λmhm(s, t) (4.1) where λmrepresents the coefficient of the mth feature function hm(s, t), which corresponds to a log-scaled version of mth-model probabilities. Optimal values for the coefficients λms are estimated via an optimisation procedure on a certain development data set. Next the feature functions used in the N-gram SMT system are presented. Then, we discuss on the global training process of the system and Ngram-based decoding. This section concludes with a discussion on the optimisation procedure. 4.2.1 Feature functions In addition to the tuple N-gram translation model, the N-gram based SMT system implements four feature functions which provide complementary views of the translation process, namely a target-language model, a word-bonus model and two lexicon models. These features are described next. 4.2.1.1 Target-language model This feature provides information about the target language structure and fluency, by favouring those partial-translation hypotheses which are more likely to constitute correctly structured target sentences over those which are not. The model implements a standard word n-gram model of the target language, which is computed according to the following expression: hLM (s, t) = hT L(t) = log K Y k=1 p(wk|wk−1, wk−2, . . . , wk−n+1) (4.2) where wkrefers to kth word in the considered partial-translation hypothesis. Notice that this model only depends on the target side of the data, and can actually be trained by including additional information from other available monolingual corpora. Chapter 4. Ngram-based SMT 79 From a theoretical point of view, the translation bilingual model already constitutes a source and target language model. Therefore, one could be led into believing this target language model to be redundant and unnecessary. On the other hand, the bilingual model is more liable to suffer from sparseness than any monolingual model, which can turn this model helpful whenever tuple n-grams are not well estimated. Indeed, as will be seen in §4.3.2, this model does provide useful information to improve translation quality. 4.2.1.2 Word-bonus model The use of any language model probabilities for decoding a new test sentence is associated with a length comparison problem. In other words, when two hypotheses compete in the search for the most probable path, the one using less number of elements (be it words or tuples) will be favoured against the one using more. This is just because a smaller amount of probabilities will be multiplied to obtain the accumulated partial score. This problem results from the fact that the number of target words used for translating a test set is not fixed. In order to compensate this preference for short translations over large ones, we introduce a word bonus which depends on the partial-translation hypothesis length. This simple model is implemented through a bonus factor which directly depends on the total number of words contained in the partial-translation hypothesis, and it is computed as follows: hW B(s, t) = hW B(t) = K(4.3) where Kis the number of words contained in the partial-translation hypothesis. An alternative approach could be to compute a certain mean of the language model (arithmetic or geometric), so that scores for partial hypotheses with a different number of target words can be comparable. 4.2.1.3 Source-to-target lexicon model We can defined as a lexicon model any model assigning each translation unit a fixed score. This score is supposed to account for the translational equivalence between the source and target words within the translation unit. For example, we expect such a model to provide tuple ’por favor # please’ with a much better score than tuple ’por favor # will you.’ Several statistical approaches can be followed to automatically obtain these scores from parallel corpora, mainly focused on cooccurrence or associative measures. However, the most widely-used approach is based on IBM model 1 probabilities (already discussed in §2.1.1). In Ngram-based SMT, for each tuple (s, t)ncontaining Isource words and Jtarget words, Chapter 4. Ngram-based SMT 80 we implement a source-to-target lexicon feature computed for each tuple (t, s)naccording to equation 4.4: hLEX (s, t) = log 1 (I+ 1)J J Y j=1 I X i=0 pIBM1(tn j|sn i) (4.4) where sn iand tn jare the ith and jth words in the source and target sides of tuple and pIBM1(.) refers to IBM-1 lexical parameters estimated from alignments computed in the source-to-target direction. Note that this lexicon feature favours tuples with a smaller number of target words against longer tuples (for a fixed number of source words), as the formulation from equation 4.4 lacks a square J √to compensate for the product over the number of target words (so it becomes a geometric mean). Alternative implementations of this model can be defined if, for example, IBM model 1 probabilities are substituted by IBM model 2 or HMM model parameters (with a corresponding tuple internal alignment function), or even by a link relative frequency on the word-aligned training data. 4.2.1.4 Target-to-source lexicon model Given the asymmetry of IBM models discussed in §2.1.1, a complementary model can be computed by making use of the target-to-source lexicon probabilities, estimated from alignments computed in the target-to-source direction. This results in an equivalent yet additional lexicon model. Therefore, for the same tuple (s, t)ncontaining Isource words and Jtarget words, this model computes the following score: hLEXinv(s, t) = log 1 (J+ 1)I I Y i=1 J X j=0 pIBM1(sn i|tn j) (4.5) where pIBM1(.) now refers to the inverse IBM-1 lexical parameters, ie. estimated from alignments computed in the source-to-target direction. Note that this lexicon feature favours tuples with a smaller number of source words against longer tuples (for a fixed number of target words), as the formulation from equation 4.4 lacks a square I √to compensate for the product over the number of source words (so it becomes a geometric mean). Chapter 4. Ngram-based SMT 81 4.2.2 Global training scheme Training an Ngram-based SMT system as described above can be graphically represented as in Figure 4.1. When it comes to the bilingual N-gram translation model, its training scheme is analogous to that of the X-gram translation model from §3.2.2.1, save for the final estimation stage. In fact, the same issues regarding which original alignment to use, which tuple segmentation strategy to follow or which pruning and smoothing techniques to apply are to be found here. Therefore, they will be skipped. Figure 4.1: Training of the models included in an Ngram-based SMT system. Flow diagram. The additional training blocks include estimating a monolingual language model with the target language material only (which could be extended with monolingual data, if available) and computing the two aforementioned lexicon models from IBM model 1 probabilities. 4.2.3 Decoding As decoding when an Ngram-based translation model is present is slightly different from phrasebased decoding, in all our experiments we use MARIE, an n-gram based searching engine developed at UPC1, which was presented in [Cre05b]. 1By Josep Maria Crego. Chapter 4. Ngram-based SMT 82 MARIE implements a beam-search strategy based on dynamic programming. The decoding is performed monotonically and is guided by the source. During decoding, partial-translation hypothesis are arranged into different stacks according to the total amount of source words they cover. In this way, a given hypothesis only competes with those hypotheses that provide the same source-word coverage. At every translation step, stacks are pruned in order to keep decoding tractable. MARIE allows for two different pruning methods: •Threshold pruning. All partial-translation hypotheses scoring below a predetermined threshold value are eliminated. •Histogram pruning. The maximum number of partial-translation hypotheses to be considered is limited the b-best ranked ones. Both these parameters are crucial since they balance a trade-off between translation quality and translation efficiency (decoding times). This research, however, is out of the scope of this Ph.D. thesis. Therefore, no threshold pruning is used in any result, whereas histogram pruning is always set to 50. MARIE also considers the additional feature functions during decoding. All these models are taken into account simultaneously, along with the n-gram translation model. Even though this decoding tool also allows for the generation of N-best lists or word graphs as output (necessary for passing through to re-ranking modules), we did not use it in this research work. Therefore, all models are combined in search and a single best hypothesis is output. Tackling word ordering translation problems, MARIE also includes non-monotone search strategies, as presented in [Cre05c]. 4.2.4 Optimisation procedure Minimum-error training states that we can directly train our models according the an errorminimisation function on a certain development data, as discussed in §2.4.1. In our Ngram-based SMT system, this process is related to the λmweights which have to be assigned to each feature function. In order to find out these weights for the log-linear combination, the development set is translated several times with different model weights, and each time evaluated with an automatic score. Typically, BLEU is used (sometimes also mWER, or even combinations of BLEU and NIST as in [Che05]) and computed against a limited number of references. This process in graphically illustrated in Figure 4.2. Theoretically, this combination approach is justified by the Maximum Entropy framework, which allows for adding any kind of feature model to the final decision. However, the BLEU- Chapter 4. Ngram-based SMT 83 Figure 4.2: Optimisation procedure. Flow diagram. optimisation is a simplification of what should be an entropy maximisation in the development set, which is too complex computationally. The adequacy of this optimisation is founded on the following assumptions: •There exists a set (or sets) of weights maximising the score in the development set, and it can be found •The weights maximising the score on the development set will maximise the score on the test set (which should happen unless our development strategy suffers from over-fitting to the development) •Maximising the score produces better translations (which is related to the correlation between automatic and manual evaluation metrics) In our implementation, we use an optimisation tool, which is based on the downhill simplex method presented in [Nel65]. BLEU score was used as optimisation function in all reported experiments unless explicitly stated. Chapter 4. Ngram-based SMT 84 4.3 Experiments, examples and error analysis In this section Spanish↔English large-vocabulary translation experiments with the Ngrambased SMT system are reported. First, an initial baseline is settled by making use of the bilingual n-gram model from chapter 3. Then, three extensions of this baseline are evaluated; firstly, the target language model and word bonus features are added to the log-linear combination; secondly, we complement the baseline with the two lexicon models; and lastly, all five models are log-linearly combined to obtain a full system. All experiments are carried out in the European Parliament corpus (version 1), whose data sets are described in detail in Table 3.14 from §3.3.1. 4.3.1 Translation model (alone) Results of the baseline system (only taking into account the n-gram bilingual model) are shown in Table 4.1, where three different word alignment sets are used to extract tuples from, namely the source-to-target alignment, the symmetrised union and the symmetrised refined technique presented in [Och03c]. align. BLEU mWER NIST PER unigrams bigrams trigrams src-to-trg 0.4152 44.61 8.762 36.54 1.81 6.26 2.27 Eng→Spa union 0.4276 44.46 9.175 34.71 2.02 6.09 1.75 refined 0.4193 44.39 8.952 35.81 2.08 6.92 2.32 src-to-trg 0.4424 40.94 9.366 32.86 1.92 6.43 2.35 Spa→Eng union 0.4745 39.71 9.839 30.51 2.04 6.01 1.80 refined 0.4594 40.24 9.618 31.80 2.11 6.85 2.40 Table 4.1: Effect of alignment set on n-gram translation model quality and size. As in the previous chapter, the union of source-to-target and target-to-source alignments always produces the best tuple translation model. These results are marked in bold face. Possibly this is explained by the smaller model sizes (in terms of number of bigrams and trigrams) of this option, leading to a less sparse model. 4.3.2 Target language model and word bonus For the same task, Table 4.2 shows the results of including the target language model and word bonus in the log-linear combination (rows entitled ’+trgx +WB’). The difference between ’+trg3’ and ’+trg4’ lies in the order of the target language model (trigram or fourgram, respectively). The right-most column shows the number of words of the output generated translation. Chapter 4. Ngram-based SMT 85 As it can be seen, including these models yields a small improvement in terms of BLEU and NIST scores for both translation directions. However, mWER and PER do not show improvements (except for the minor change in mWER from Spanish to English). In the Spa→Eng direction, note that the contribution of these models produces more output words, whereas in the opposite direction the effect is contrary. Increasing the order of the target language model from 3-grams to 4-grams appears to have a negative effect on evaluation scores for both translation directions (except for NIST and PER scores in Eng→Spa). However, differences are not very significant. 4.3.3 Lexicon (IBM) models Table 4.2 also shows the results of including the two lexicon models described in §4.2.1 in the log-linear combination (rows entitled ’+lexicon’). config. BLEU mWER NIST PER trg words baseline 0.4276 44.46 9.175 34.71 25,523 +trg3 +WB 0.4367 44.67 9.196 35.50 25,226 +trg4 +WB 0.4358 45.21 9.258 35.11 26,114 Eng→Spa +lexicon 0.4482 41.69 9.541 32.43 25,391 full (trg3) 0.4688 40.34 9.715 32.02 25,062 full (trg4) 0.4714 40.55 9.740 32.22 25,094 baseline 0.4745 39.71 9.839 30.51 21,313 +trg3 +WB 0.4856 39.51 9.865 30.63 21,490 +trg4 +WB 0.4826 40.53 9.774 30.99 22,447 Spa→Eng +lexicon 0.5356 35.77 10.540 26.64 22,030 full (trg3) 0.5434 34.94 10.620 26.60 21,565 full (trg4) 0.5483 34.66 10.670 26.35 21,689 Table 4.2: Contribution of feature models in translation quality (EuParl version 1 task). Average reference length is 20,409 (for English) and 24,705 (for Spanish). In this case, the impact on translation quality is much more remarkable, as all automatic evaluation scores improve significantly. To understand this important contribution, let us consider the lexicon model formulation from equation 4.4. According to it, this model has two main characteristics which seem to contribute positively to the performance boost: •Tuple ranking. While the bilingual translation models makes each current translation dependant on previous translated parts via a tuple N-gram dependency, the lexicon feature assigns an a priori fixed cost to each tuple regardless of the context it is used in. Apparently, this has a noise-filtering effect coupled with a better capacity of the system to distinguish correct translations when the bilingual model falls to low-order n-grams. Chapter 4. Ngram-based SMT 86 •Short tuple preference. As discussed in §4.2.1.3, the direct and inverse lexicon models preference for shorter tuples (in number of target words and in number of source words, respectively) seems to promote the use of high-order bilingual n-grams (by catenating short tuples) rather than using long unfrequent tuples which tend to cause a back-off fall to unigram. 4.3.3.1 Alternative lexicon features In order to study the validity of the previous explanation on the remarkable contribution of IBM-based lexicon features, we conducted the following experiment, aiming at separating these two effects (tuple ranking and short tuple preference). Let us define an alternative source-to-target lexicon model, as in the following equation: hnLEX (s, t) = log J v u u t 1 (I+ 1)J J Y j=1 I X i=0 pIBM1(tn j|sn i) (4.6) where sn iand tn jare the ith and jth words in the source and target sides of tuple and pIBM1(.) refers to IBM-1 lexical parameters estimated from alignments computed in the source-to-target direction. This definition is analogous to equation 4.4 except for the included square function, which converts the feature into a geometric mean. Therefore, this new ’normalised’ lexicon feature does not include an explicit dependency on tuple length. Let us define the target-to-source ’normalised’ lexicon feature as: hnLEXinv(s, t) = log I v u u t 1 (J+ 1)I I Y i=1 J X j=0 pIBM1(sn i|tn j) (4.7) where pIBM1(.) now refers to the inverse IBM-1 lexical parameters, ie. estimated from alignments computed in the source-to-target direction. Let us now define a very simple tuple bonus feature model depending on the partialtranslation hypothesis length in number of tuples. This can be mathematically expressed as: hT B(s, t) = hT B(t) = T(4.8) where Tis the number of tuples contained in the partial-translation hypothesis. This aim of this feature is to supply the log-linear combination with a mechanism to prioritise the use of more tuples (ie. catenating shorter tuples), somehow emulating the length preference effect from original lexicon models. Chapter 4. Ngram-based SMT 87 Having defined these new features, we can evaluate their separate and aggregated impact on translation quality, as well as compare it to the contribution from original lexicon models. Due to data availability reasons, this experiment was carried out on EuParl version 3 task2. The European Parliament Proceedings Corpus version 3 differs from version 2 in that it adds data from December 2004 to May 2005 as training material. The main statistics of this corpus are shown in Table 4.3, where similarity with version 2 in Table 3.24 is noticeable. EuParl ver3 sent. words vcb OOVs avg.len. refs. English 34.92 M 106.5 k - 27.2 train Spanish 1.28 M 36.58 M 153.1 k - 28.5 1 English 15.4 k 2.27 k 10 30.5 3 develop Spanish 504 15.4 k 2.73 k 19 30.6 3 English 1094 26.92 k 4.0 k 56 24.6 2 test Spanish 840 22.77 k 4.1 k 28 27.1 2 Table 4.3: European Parliament English-Spanish corpus version 3 statistics. Table 4.4 shows the results of the baseline system (only using bilingual translation model) and its extensions with the original lexicon model (’+lexicon’), the normalised lexicon models (’+lexNORM’), the tuple bonus model (’+TB’), and the combination of normalised lexicon and tuple bonus (’+lexNORM +TB’). Additionally, the table shows the number of output words, the number of tuples used in the translation, and the percentage of these which were used as 3grams, 2grams and 1grams by the bilingual model. config. BLEU mWER words tuples 3gram 2gram 1gram baseline 0.4270 43.60 25,533 23,217 38.0% 43.7% 18.3% +lexicon 0.4568 41.24 26,076 23,892 38.9% 43.5% 17.7% Eng→Spa +lexNORM 0.4390 42.52 25,692 22,890 37.0% 43.7% 19.3% +TB 0.4308 43.33 25,489 23,864 39.3% 43.8% 16.9% +lexNORM +TB 0.4526 41.55 25,971 23,986 39.3% 43.5% 17.3% baseline 0.4735 38.51 21,075 20,026 45.2% 40.6% 14.2% +lexicon 0.5398 34.65 22,137 20,962 46.0% 40.0% 14.0% Spa→Eng +lexNORM 0.5056 36.75 21,554 19,687 43.7% 40.7% 15.6% +TB 0.4881 37.77 21,387 20,842 47.3% 40.0% 12.7% +lexNORM +TB 0.5335 35.30 22,253 20,990 46.6% 39.8% 13.6% Table 4.4: Contrasted contribution of lexicon, normalised lexicon and tuple bonus features (European Parliament version 3 task). As it can be seen, the contribution of the normalised lexicon models (rows ’+lexNORM’) is significantly worse than the original lexicon model (up to 0.034 and 0.018 BLEU absolute points 2However, qualitative results correlation among all EuParl tasks has been observed systematically, possibly due to the slight differences between them Chapter 4. Ngram-based SMT 94 < s > < s > That is something I believe # Creo que esto That # Eso is # es una is # es demanded # exigencia something # algo ... I believe # que creo que < s > the present rapporteur can remember # recuerda el actual ponente That # Esto ... is # NULL < s > something # , en That # Eso I # mi is # es believe # opini´on something # algo would be # , ser´ıa I believe # que creo que el ... Mr # Sr. ... Table 4.13: All occurrences of ’That is something I believe’ starting a sentence in training. Tuple segmentation is shown (EuParl version 2 Eng→Spa). to be found in the corpus. One may wonder what is the correct way for the translation model to weight a rare unfrequent long tuple in front a frequent sequence of shorter tuples. Other sources of information (such as a target language model) may help providing additional info. Example 3 Another translation example is to be found in Table 4.14, where we observe a very bad translation while the system back-offs several times to unigram. In this case, there is a clear reordering and generalisation (or classification) problem, as the structure ’EUR Xmillion # X millones de euros’ is very well represented in the corpus for several numerical values of X. This situation will not be discussed here. We spend more than EUR 950 million on subsidies to tobacco farmers 2 En 1 asignan m´as fondos que 1 euros a 1 950 2 millones de 1 en 2 subvenciones 2 a los 3 cultivadores de tabaco 2.72 7.083 6.834 6.532 1.226 ... Table 4.14: EuParl version 2 Eng→Spa, development sentence num. 221. For each tuple used, BM cost is shown. Before that, a very bad translation of ’We spend more than’ is produced. Consider the 3 alternative partial translations presented in Table 4.15, all of them having a worse cost than that of the partial hypothesis above (24.395). It is worth mentioning that the more correct path through ’We spend # Gastamos’ and ’more than # m´as de’ is penalised in front of a very strange path through ’We # En’ and ’spend more than # asignan m´as fondos que’. In both cases, the number of times the model back-offs to unigram is very high to expect a nice translation. In these cases, it is probably necessary to introduce additional linguistic information to improve performance. Chapter 4. Ngram-based SMT 95 We spend more than EUR 950 million 2 Gastamos 1 m´as de 1 euros 1 950 2 millones de total 6.096 4.338 7.18 6.532 1.226 25.372 We spend more than EUR 950 million 2 Gastamos 1 m´as 1 euros 1 950 2 millones de total 6.096 4.593 7.539 6.532 1.226 25.987 We spend more than EUR 950 million 2 Gastamos 1 m´as 1 euros a 1 950 2 millones de total 6.096 4.593 7.539 6.532 1.226 25.987 Table 4.15: Alternative translations (EuParl version 2 Eng→Spa, dev. sentence num. 221). However, one last comment can be done on frequency of occurrence. Whereas source tuple ’spend more than # asignan m´as fondos que’ occurs only once in the whole corpus (as unigram), tuples ’more than # m´as de’ and ’more than # m´as’ occur 880 and 393 times, respectively (as unigrams). On the contrary, ’We spend # Gastamos’ occurs only twice in the corpus (as bigram after < s >), while ’We # En’ occurs more than 2,000 times. As these two tuples compete against each other as bigrams (regardless of the fact of their source part being different), the latter gets a better score4. Example 4 Another problematic situation can be found in Table 4.16. Basically, the problems arise when a back-off to unigram is forced by the inexistence of samples covering ’five and a half times as much’ in the corpus. Luckily, the expression ’and a half times’ seems to have a nice unigram probability leading to an adequate translation here, but the following expression ’as much as’ is badly translated, as well as the last part (’the entire environment budget’). five and a half times as much as the entire environment budget . 2cinco 1veces y media 1como 2a2todo el 1medio ambiente 1del presupuesto 2. Table 4.16: EuParl version 2 Eng→Spa, development sentence num. 221 (last part). This example is illustrative of a very challenging input test sentence. One of the reasons is the need for numeric classification in order to identify a history in the expression ’Ntimes as much as’, as this is a represented history in the training, but unfortunately not with N=’five and a half’. Additionally, ’environmental budget’ poses another challenge to translate. Only four examples of this English bigram are found in the corpus, but unfortunately always inside longer tuples (containing complex non-literal structures). Therefore, a generalisation / reordering strat- 4Apart from that, no linguistically-guided preference is given to segmenting tuples that do not breaking a verb form, as the option ’We spend’. Chapter 4. Ngram-based SMT 96 egy is needed to reuse other structures like ’Xbudget # presupuesto de X’ with other values for X. Example 5 Finally, another interesting example is shown in Table 4.17. Again translation is unacceptable but this time, in contrast with all other previous examples, there is no back-off to unigram at all. We are actually very thrifty . 2Nos 3NULL 2NULL 2muy 2pocas 1. Table 4.17: EuParl version 2 Eng→Spa, development sentence num. 215. Two general comments can be made on this sentence. Regarding tuple segmentation, the intuition that segmenting a full verb form such as ’We are’ into two separate tuples may not be appropriate seems to be confirmed here, as we end up with a very poor translation into ’Nos’. Clearly, expressions as ’We are actually X’ with X=’glad’, ’open’, ’delighted’, etc. translating into, for example, ’Nos complace’, have been badly segmented during training. On the other hand, the word ’actually’ adds a degree of complexity to the sentence, since no example of ’We are actually very’ is to be found in the training, whereas hundreds of examples of ’We are very’ are represented. The bilingual translation model lacks the capacity to realise the presence of this optional verb-modifying adverb, and sequence is broken. Finally, the unfrequent word ’thrifty’ is also very hard to translate. Not only it is an unfrequent word in the data, but also it received several translations in the corpus (see Table 4.18 for unigram tuples5), with different contexts. thrifty # restrictivo 2 6.476917 thrifty # econ´omico 2 6.476917 thrifty # pocas 1 6.778642 thrifty # econ´omicos 1 6.778642 thrifty # cuidadosa 1 6.778642 thrifty # austeridad 1 6.778642 thrifty # ahorrativo 1 6.778642 thrifty # ahorrar 1 6.778642 thrifty # ahorradores 1 6.778642 thrifty # ahorrador 1 6.778642 Table 4.18: Possible incontextual translations of the source tuple ’thrifty’ (EuParl version 2). For each case, the number of occurrences of the tuple in training data and its BM cost are shown Even more interesting is to analyse the 24 tuples where this word is found. Table 4.19 5Note that, for once, the model correctly assigns double probability to tuples occurring double the times. Chapter 4. Ngram-based SMT 97 has # ha favours # favor been # sido a # de un thrifty # ahorrativo thrifty budget # presupuesto de ahorro and # y . # . you # ustedes lo I am # soy favour # tambi´en estamos a favor incredibly # muy a # de la thrifty # cuidadosa thrifty # austeridad with # con el budget # presupuestaria taxpayers ’ money # dinero de los contribuyentes we must # debemos It is # Es be # ser thrifty # restrictivo thrifty # ahorradores and # y , # NULL rigorous # riguroso it # NULL we are # somos is # es extremely # sumamente thrifty # econ´omico thrifty # econ´omicos , # , en , # NULL contrary # contra and # y in # NULL other words # es decir que , we are very thrifty , as they say # , como se dice , somos muy ahorradores .#. Table 4.19: Some of the 24 tuples containing English word ’thrifty’ (EuParl version 2 Eng→Spa). shows some of them, together with a bit of context. Basically, the word occurs in two linguistic contexts, namely as adjective complementing a noun (in most cases the word ’budget’), or as adjective which is predicate in a to be sentence. Translation is not clear and fluctuates between ’ahorrativo’, ’ahorrador’, ’restrictivo’, ’cuidadosa’ or ’econ´omico’ (and their gender- and number-declined Spanish variants). Interestingly, three examples of ’we + TO BE + thrifty’ are found. However, the first one has the same tense but is modified by a modal verb (’we must be’); the second one (with same person and tense) has a different adverbial modifier (’extremely’); and unfortunately, the third one (with same person, tense and even including the following word ’very’) lacks the modifier ’actually’ and besides, it is hidden inside a long tuple (with a reordered expression), which could be considered an embedded N-gram. To conclude, the standard N-gram model is practically unable to build an acceptable output in this example. The reasons might be the need to generalise / classify verb forms to detect seen Ngrams which do not exactly match the same words, but do match the same verb and even same tense and person (’we + TO BE + thrifty # SER + ahorradores’). An alternative to that is to better segment the training into tuples and aim at building the output with a tuple sequence such as ’we are # somos’, ’actually # NULL’, ’very # muy’, ’thrifty # ahorradores’, but this case probably demands an agreement resolution between ’somos’ and Chapter 4. Ngram-based SMT 98 ’ahorradores’. Therefore, additional linguistic knowledge seems to be almost necessary. 4.3.5.2 Comparison to full system combination Next a few examples using all feature functions (full log-linear combination) are presented. Example 1 Table 4.20 shows the translation provided by the full system for exactly the same sentence discussed in Example 1 of section 4.3.5.1 (see Table 4.7). Approval of Minutes of previous sitting : see Minutes 2La aprobaci´on 3del 1Acta 2de la 1sesi´on anterior 1:2NULL 1Acta Table 4.20: EuParl version 2 Eng→Spa, dev. sentence num. 2 (full system). Additionally, Table 4.21 compares the selected new hypothesis (on the right) to the best hypothesis provided by only the Bilingual Model (on the left). For each tuple, the costs of all models are shown (already multiplied by their corresponding weights). tuple BM IBM IBMi TM WB tuple BM IBM IBMi TM WB Approval # La aprobaci´on 5.19 1.33 1.00 2.32 -1.12 Approval # La aprobaci´on 5.19 1.33 1.00 2.32 -1.12 of # de 0.27 0.35 0.17 0.12 -0.56 of # del 0.70 0.89 0.18 0.42 -0.56 Minutes # actas 6.06 0.95 0.11 3.78 -0.56 Minutes # Acta 6.42 0.07 0.04 0.79 -0.56 of # de 1.23 0.35 0.17 0.39 -0.56 of # de la 1.94 0.48 0.46 0.53 -1.12 previous sitting # sesi´on 7.39 2.60 0.12 2.76 -0.56 previous sitting # sesi´on anterior 7.44 1.04 0.33 2.60 -1.12 : # : 2.88 0.08 0.05 1.89 -0.56 : # : 2.88 0.08 0.05 1.49 -0.56 see # NULL 4.73 1.16 0.36 0 0 see # NULL 4.73 1.16 0.36 0 0 Minutes # Acta 5.69 0.07 0.04 3.59 -0.56 Minutes # Acta 5.69 0.07 0.04 3.66 -0.56 </s>2.77 2.09 </s>2.77 2.09 COST/model 36.22 6.90 2.04 16.95 -4.48 COST/model 37.77 5.12 2.46 13.91 -5.6 FINAL COST 57.63 FINAL COST 53.66 Table 4.21: EuParl version 2 Eng→Spa, dev. sentence num. 2 (full system). As it can be seen, the Bilingual Model alone assigns a smaller cost to the left-most hypothesis. Some comments on this can be made: •The trigram ’<s>’+’Minutes # actas’+’of # de’ has cost 0.27 in front of 0.70 for ’of # del’. This is more or less consistent with the data, the first occurring 6 times and the latter just 3 times. •Bigram cost of ’of # de’+’Minutes # actas’ (occurs just once in training) is better than a back-off fall to unigram. •As bigrams, the costs of tuple sequences ’Minutes # actas’+’of # de’ and ’Minutes # Acta’+’of # de la’ respond to the model estimations shown in Table 4.22. Chapter 4. Ngram-based SMT 99 •Finally, all tuples translating ’previous sitting’ have equal cost as unigram (remember Table 4.9). Their cost difference from 7.39 to 7.44 is only due to the back-off cost of the previous tuple. prev: Minutes # actas prev: Minutes # Acta of # del 4 2.067005 of # de 70 1.344116 of # de 2 1.230284 of # de la 21 1.938414 of # del 13 1.735061 of # NULL 1 2.521171 Table 4.22: Possible translations of the word of’ after tuples ’Minutes # actas’ and ’Minutes # Acta’ (EuParl version 2 Eng→Spa). For each case, the number of times that the given bigram was seen in training data and its BM cost are shown. However, all other models favour the right-most alternative (except for IBM inverse, which has a very low weight). Specially relevant is the very strong preference of the target language model for the new hypothesis, even though this has two more words. This is reinforced by the word bonus model. Regarding IBM model, note that for some tuples it favours one hypothesis and for some others it favours the opposite, but preference is stronger when differences in tuple length are big. In this sentence, the preference on the ’previous sitting’ tuple plays a decisive role to decide the final best hypothesis. Example 2 This example refers to development sentence number 18, which is greatly improved by the log-linear model combination. First of all, we observe a positive gender change as shown in Table 4.23. tuple BM IBM IBMi TM WB tuple BM IBM IBMi TM WB always # siempre 4.22 0.06 0.04 1.85 -0.56 always # siempre 4.22 0.06 0.04 1.85 -0.56 has # tiene 2.13 0.88 0.19 1.38 -0.56 has # tiene 2.13 0.88 0.19 1.38 -0.56 a # una 1.27 0.508 0.10 0.98 -0.56 a # un 1.21 0.48 0.09 0.81 -0.56 very # NULL 1.88 1.10 0.34 0 0 very # NULL 2.20 1.10 0.34 0 0 difficult # dif´ıcil 2.49 0.14 0.02 2.42 -0.56 difficult # dif´ıcil 2.51 0.14 0.02 1.69 -0.56 role to play # papel 6.39 2.06 0.12 2.62 -0.56 role to play # papel 6.39 2.06 0.12 2.58 -0.56 COST/model 18.38 4.75 0.77 9.24 .2.8 COST/model 18.67 4.72 0.76 8.30 -2.8 FINAL COST 30.34 FINAL COST 29.65 Table 4.23: EuParl version 2 Eng→Spa, dev. sentence num. 18 (full system). As expected, this change is basically motivated by the target language model, which prefers the right-most hypothesis for article-noun agreement reasons (the remaining models being mostly unchanged). The preference of the bilingual model for the left-most hypothesis (centred on the trigram completed by tuple ’very # NULL’) is worth studying. Chapter 4. Ngram-based SMT 100 Note the occurrences in training of these trigrams, as shown in Table 4.24. As it can be seen, neither case has an alternative translation for the word ’very’ but the empty word, according to training material. prev: has # tiene prev: has # tiene +a#una +a#un very # NULL 6 1.878118 very # NULL 3 2.202106 Table 4.24: Possible translations of the word ’very’ after two different bigrams (EuParl version 2 Eng→Spa). For each case, the number of times that the given bigram was seen in training and its BM trigram cost are shown. Later on in the same sentence, another clear translation improvement can be found, as shown in Table 4.25 (again, new hypothesis is shown on the right-hand side of the table). tuple BM IBM IBMi TM WB tuple BM IBM IBMi TM WB which # que 2.59 0.44 0.30 1.25 -0.56 which # que 2.59 0.44 0.30 1.25 -0.56 have no # no tienen 3.81 1.78 0.55 2.20 -1.12 have no # no tienen 3.81 1.78 0.55 2.20 -1.12 choice # otra elecci´on 3.04 0.41 0.58 1.89 -1.12 choice # otra elecci´on 3.04 0.41 0.58 1.89 -1.12 but # NULL 0.50 1.65 0.51 0 0 but # NULL 0.50 1.65 0.51 0 0 to # NULL 1.86 0.86 0.27 0 0 to # que 0.65 0.81 0.26 0.29 -0.56 reach # alcanzar un 5.13 0.70 0.64 2.96 -1.12 reach agreement # un acuerdo 4.59 1.60 0.59 3.20 -1.12 agreement # acuerdo 0.19 0.07 0.07 0.22 -0.56 , # , 1.89 0.31 0.11 0.82 -0.56 , # , 1.23 0.31 0.11 0.82 -0.56 although # aunque 2.57 0.21 0.12 1.11 -0.56 although # aunque 2.80 0.21 0.12 1.11 -0.56 on # en 2.83 0.86 0.35 0.91 -0.56 on # en 2.83 0.86 0.35 0.91 -0.56 occasions # ocasiones 3.36 0.11 0.09 1.63 -0.56 occasions # ocasiones 3.36 0.11 0.09 1.63 -0.56 COST/model 27.03 8.24 3.46 13.01 -6.16 COST/model 26.12 7.35 3.58 13.27 -7.28 FINAL COST 45.58 FINAL COST 43.04 Table 4.25: EuParl version 2 Eng→Spa, dev. sentence num. 18 (full system). In this case, the target language model favours the original alternative (on the left). However, as two new words are introduced, the word bonus shows a strong preference for the right-most hypothesis. Regarding IBM models, whereas IBM inverse prefers the original translation but by a small difference (3.46 against 3.58), IBM direct has a strong preference for the new hypothesis. This is due to the relatively high cost for the ’longer’ tuple ’reach agreement # un acuerdo’. It is worth mentioning that the Bilingual Model also prefers the new hypothesis. However, when decoding only with this model, the decoder chooses the first hypothesis due to a search error; in other words, the new alternative hypothesis is not explored as the sequence ending in ’to # que’+’reach # alcanzar un’ is pruned out. Finally, a third improvement is to be found in the last part of the same sentence, as shown in Table 4.26, where we see that all features contradict the bilingual model and prefer the new hypothesis (on the right), except for IBM inverse, which is irrelevant. Chapter 4. Ngram-based SMT 101 tuple BM IBM IBMi TM WB tuple BM IBM IBMi TM WB occasions # ocasiones 4.74 0.11 0.09 2.65 -0.56 occasions # ocasiones 4.74 0.11 0.09 2.65 -0.56 it # NULL 2.93 0.90 0.28 0 0 it # NULL 2.93 0.90 0.28 0 0 seems # parece 2.80 0.10 0.13 1.81 -0.56 seems # parece 2.80 0.10 0.13 1.81 -0.56 that # NULL 2.22 0.96 0.30 0 0 that # que el 2.23 0.52 0.54 1.11 -1.12 agreement # acuerdo 2.95 0.07 0.07 1.32 -0.56 agreement is a # es un acuerdo 5.27 2.14 0.59 3.83 -1.68 is # es 1.95 0.47 0.06 1.23 -0.56 a # NULL 1.87 0.96 0.30 0 0 very # muy 1.18 0.23 0.06 0.89 -0.56 very long way off # largu´ısima 6.83 6.60 0.48 4.30 -0.56 long way off # lejos 4.93 4.22 0.36 1.98 -0.56 . # . 0.73 0.41 0.13 0.70 -0.56 . # . 0.97 0.41 0.13 0.49 -0.56 </s>0.01 0.10 </s>0.01 0.01 COST/model 25.54 11.21 1.99 13.39 -3.92 COST/model 26.58 7.98 2.00 11.49 -5.04 FINAL COST 48.21 FINAL COST 43.00 Table 4.26: EuParl version 2 Eng→Spa, dev. sentence num. 18 (full system). Example 3 Finally, this final example shows how the contribution of feature functions leads to a worse translation. Particularly, for English sequence ’on the basis of which’, the correct translation ’sobre cuya base’ achieved by the bilingual model alone is turned into the incorrect expression ’sobre la base de que’. See Table 4.27 for the comparison between the old and the new hypothesis, which is selected by the log-linear model combination. tuple BM IBM IBMi TM WB tuple BM IBM IBMi TM WB the # las 2.77 0.10 0.17 1.42 -0.56 the # las 2.77 0.10 0.17 1.42 -0.56 political priorities political priorities # prioridades pol´ıticas 3.31 1.32 0.32 2.09 -1.12 # prioridades pol´ıticas 3.31 1.32 0.32 2.09 -1.12 on # sobre 3.26 0.51 0.07 1.58 -0.56 on # sobre 3.26 0.51 0.07 1.58 -0.56 the # NULL 1.70 0.98 0.30 0 0 the # la 0.74 0.57 0.14 0.37 -0.56 basis # base 0.99 0.24 0.04 0.72 -0.56 basis of which # cuya base 1.70 3.39 0.46 2.18 -1.12 of # de 0.29 0.35 0.17 0.13 -0.56 which # que 3.65 0.44 0.30 0.83 -0.56 the # los 2.90 0.89 0.17 1.18 -0.56 the # los 2.39 0.89 0.17 0.74 -0.56 parliamentary groups parliamentary groups # Grupos parlamentarios 3.94 1.96 0.35 2.78 -1.12 # grupos parlamentarios 4.72 1.60 0.35 2.51 -1.12 and # y 0.72 0.26 0.07 0.63 -0.56 and # y los 2.06 0.45 0.44 1.14 -1.12 Members # diputados 4.33 0.17 0.04 2.50 -0.56 Members # diputados 2.62 0.17 0.04 1.38 -0.56 stood # defendido 6.48 0.82 0.34 3.31 -0.56 stood # defendido 6.48 0.82 0.34 3.62 -0.56 for # NULL 1.80 0.99 0.31 0 0 for # NULL 1.80 0.99 0.31 0 0 the # de las 2.01 0.73 0.43 2.28 -1.12 the # las 2.08 1.00 0.17 1.28 -0.56 European elections European elections # elecciones europeas 2.11 1.66 0.27 1.76 -1.12 # elecciones europeas 3.37 1.66 0.27 2.03 -1.12 on # del 2.57 1.14 0.35 0.84 -0.56 on # del 2.57 1.14 0.35 0.84 -0.56 COST/model 39.60 15.82 3.63 22.55 -9.52 COST/model 43.10 13.15 3.65 20.70 -10.64 FINAL COST 72.09 FINAL COST 69.95 Table 4.27: EuParl version 2 Eng→Spa, dev. sentence num. 12 (full system). Clearly, the Bilingual Model prefers (by far) the first hypothesis, but the IBM, TM and WB models prefer the second (IBMi being once again irrelevant). Regarding IBM model, the preference is mainly due to the high cost assigned to the long tuple ’basis of which # cuya base’ which cannot compete against the low costs of short tuples like ’basis # base’, ’of # de’ and ’which # que’. Chapter 4. Ngram-based SMT 102 As for the target language model, the situation is much more complex, as many changes are found all through this sentence segment. However, the points of stronger preference for the new hypothesis are in the regions of ’parliamentary groups’ (2.5 versus 1.38) and ’European elections’ (2.28 versus 1.28). Finally, the word bonus clearly prefers the second hypothesis, as it contains two additional words. 4.3.6 Error analysis Even though automatic evaluation measures provide quality scores to assess performance improvements, there is an evident need for understanding the nature of errors that a certain system does. With this objective, in this last section we present a brief manual error analysis performed to some of the outputs provided by the full system configuration. More specifically, a detailed review of 200 translated sentences and their corresponding source sentences, in each direction, was conducted. This analysis should be helpful to spot which translation phenomena are difficult for the Ngram-based SMT system, diagnose possible causes and trace a pragmatic research line towards improvement. For this study, we classify most common translation errors into verb forms, omissions, word order, disagreement and bad lexical choice. These error types are explained next: •Bad lexical choice. This occurs whenever the translation model selected a wrong tuple, and the resultant translation is unacceptable, possibly due to a lack of context. To illustrate this, see the following two examples, where ’either’ should be translated into ’tampoco’ (instead of ’ni’) and the correct translation of ’What’ would be ’Lo que’ instead of ’> Qu´e’: This is not acceptable either . 2Esto 3no es 3aceptable 3ni 1. What is basically happening 2> Qu´e 3es 2b´asicamente 1sucediendo Table 4.28: EuParl version 2 Eng→Spa, development sentences num. 83 and 81. •Omissions. These errors occur when a relevant part of the source sentence is not present in the translation. Two distinct cases are included here, namely whenever the translation model wrongly uses a tuple with NULL target side and whenever it chooses a tuple which translates only part of the source in this context (which could also be counted as bad lexical choice, but is included here). One example follows: Chapter 4. Ngram-based SMT 103 Cuba no debe cambiar . 3Cuba 2NULL 2must 2change 3. Table 4.29: EuParl version 2 Spa→Eng, test sentence num. 35. •Word order. This type refers to translations which require a change in word order in order to be correct. In Spanish↔English translation, most of these cases refer to Adjective–Noun, or Subject–Verb swaps (especially for passive voice), but not exclusively. Two examples follow: toda la sociedad neerlandesa , 3whole 3of 3society 1Dutch 2, that financial surpluses are prevented 2que los 1excedentes financieros 1NULL 1evitarse Table 4.30: EuParl version 2 Spa→Eng test sentence num. 14 and Eng→Spa development sentence num. 108. •Verb forms. In terms of meaning, verbs are very important in a sentence, as a mistaken verb form tends to strongly affect the message and may easily lead to confusion. For this reason, we consider any translation of a verb group with erroneous tense, person, number or lemma as a verb form error. Note that this includes verb forms being translated to NULL (ie. omitted), which are not counted as omissions. Examples of this type of errors follow: when I do not rejoice that 2cuando 2NULL 2no 1alegrarnos 2de que > Cree posible tambi´en llamar 2Does 1possible 2to 2draw Table 4.31: EuParl version 2 Eng→Spa development sentence num. 365 and Spa→Eng test sentence num. 320. •Disagreement. Also called concordance, it refers to any morphology-related (gender and number) inconsistencies between elements of the sentence. This is especially relevant when translating to morphologically richer languages, as in the Eng→Spa direction. One example can be found in Table 4.32. Table 4.33 presents the relative number of occurrences for each of the four types or errors identified in both translation directions. Notice from Table 4.33 that the most common errors in both translation directions are those related to verb forms. However, it is important to mention that 29.5% of verb-form errors in the Chapter 4. Ngram-based SMT 110 •[Cre05a] J.M. Crego, A. de Gispert, and J.B. Mari˜no, “TALP: The UPC Tuplebased SMT System,” in Proceedings of the 2nd International Workshop on Spoken Language Translation, IWSLT’05, pps. 191–198, October 2005. TC-STAR 2nd evaluation In February 2005 the TC-Star EU-funded project organised its second evaluation campaign. As in the previous year, language pairs included English↔Spanish, in which UPC took part, and Chinese↔English. Parallel training data consisted of the European Parliament corpus version 3 (see Table 4.3), while test data was newly collected. Again three types of input to the translation system were studied and compared, namely ASR, verbatim and text (see §4.4.1). Spanish→English BLEU NIST ASR IBM 42.8 IBM 9.65 RWTH 39.4 RWTH 9.38 UPC 38.3 ITC-irst’ 9.21 ITC-irst’ 37.9 UPC 9.15 LIMSI 36.6 LIMSI 8.71 SystrP 33.8 SystrP 8.58 UKA 33.0 UKA 8.53 Verbatim IBM 55.2 RWTH 10.94 RWTH 55.1 IBM 10.91 ITC-irst’ 52.1 ITC-irst’ 10.55 UPC 52.0 UPC 10.45 UW 48.0 UW 9.85 UKA 46.0 UKA 9.85 LIMSI 46.0 LIMSI 9.76 SystrP 45.3 SystrP 9.68 DFKI 42.2 DFKI 9.33 Text IBM 54.1 IBM 10.77 RWTH 53.1 RWTH 10.65 UW 52.8 UPC 10.60 ITC-irst 52.4 ITC-irst 10.56 UPC 52.3 UW 10.55 EDINBG 51.9 EDINBG 10.48 UKA 47.0 UKA 9.98 SystrP 45.7 SystrP 9.72 DFKI 43.0 DFKI 9.47 Table 4.38: Results of the 2nd TC-STAR evaluation campaign. BLEU is presented as a percentage. UPC Ngram-based SMT system included two novel features. On the one hand, a preprocessing block reordering strategy capable of swapping the order of two input word according to Chapter 4. Ngram-based SMT 111 the alignment of their respective occurrences in training. This strategy, which is introduced in [Cj06], was applied to Spanish→English translation only. On the other hand, the system included an additional feature consisting of a language model of the Part-Of-Speech sequence of the produced target sentence. This feature will be discussed in detail in §6.3. English→Spanish Fluency Adequacy BLEU NIST ASR RWTH 3.06 RWTH 3.13 ITC-irst’ 36.0 ITC-irst’ 8.75 UPC 3.04 UPC 3.09 RWTH 35.9 RWTH 8.72 IBM 3.04 ITC-irst’ 3.09 IBM 35.8 IBM 8.62 ITC-irst’ 2.99 IBM 3.05 UPC 34.8 UPC 8.56 UKA 2.84 UKA 2.97 UKA 31.3 UKA 8.10 SystrP 2.09 SystrP 2.33 SystrP 23.9 SystrP 7.03 Verbatim RWTH 3.38 RWTH 3.55 ITC-irst’ 46.6 ITC-irst’ 9.91 UPC 3.38 UPC 3.54 RWTH 45.4 RWTH 9.71 ITC-irst’ 3.35 ITC-irst’ 3.54 IBM 45.4 IBM 9.66 IBM 3.35 IBM 3.51 UPC 44.1 UPC 9.50 UW 3.13 UW 3.43 UW 43.6 UW 9.36 UKA 3.07 UKA 3.37 UKA 40.1 UKA 9.08 SystrP 2.34 SystrP 2.77 SystrP 33.0 SystrP 8.10 Text EDINBG 3.62 EDINBG 3.79 ITC-irst 49.8 ITC-irst 10.23 RWTH 3.58 RWTH 3.74 EDINBG 49.5 RWTH 10.16 IBM 3.50 UPC 3.69 RWTH 49.4 EDINBG 10.11 UPC 3.48 ITC-irst 3.67 UW 48.8 UW 10.03 ITC-irst 3.46 UW 3.62 UPC 48.2 UPC 10.00 UW 3.40 IBM 3.60 IBM 47.7 IBM 9.93 DFKI 3.31 DFKI 3.53 UKA 44.0 UKA 9.56 UKA 3.17 UKA 3.49 DFKI 36.3 DFKI 8.70 SystrP 2.46 SystrP 2.93 SystrP 36.3 SystrP 8.57 Table 4.39: Results of the 2nd TC-STAR evaluation campaign. BLEU is presented as a percentage. Results are summarised in Tables 4.38 and 4.39, where ASR Word Error Rate is 6.2% for Spanish input and 6.9% for English. LIMSI stands for LIMSI-CNRS Paris (France), SystrP for Systran Product (not Systran Research) and DFKI for German Centre for Artificial Intelligence (Germany). Results obtained by UPC Ngram-based SMT system are competitive with results from other sites. In fact, nearly 6 systems perform very similarly, with slight differences depending on translation direction and input data. The novel reordering strategy applied to Spanish→English does not seem to yield a remarkable boost in terms of system ranking. On the other hand, human evaluation conducted for English→Spanish seems to give UPC system slightly better comparative results than automatic evaluation scores. Chapter 4. Ngram-based SMT 112 In addition to these tasks, a complementary Spanish→English task was included in this evaluation for portability assessment. This data consisted of transcriptions from Spanish Parliament, for which no parallel training was provided. As results and system ranking correlate strongly with EuParl data9, they are not reported here. Further details on this evaluation campaign specification and results can be found in [Ney06], whereas more details on UPC experiments are reported in the following publication: •[Mn06b] J.B. Mari˜no, R.E. Banchs, J.M. Crego, A. de Gispert, P. Lambert, J.A.R. Fonollosa, M.R. Costa-juss`a and M. Khalilov, “UPC’s Bilingual N-gram Translation System,” in Proceedings of the TC-STAR Workshop on Speech-to-Speech Translation, pps. 43–48, June 2006. HLT/NAACL 2006 Workshop In June 2006, a Workshop on Statistical Machine Translation of the HLT/NAACL conference (Human Language Technologies / North American Chapter of the Association for Computational Linguistics) organised a shared task following the guidelines of ACL 2005 workshop discussed above. Training material consisted of the same subset of the European Parliament Proceedings Corpus used in 2005. This time language pairs were French↔English, German↔English and Spanish↔English, making a total of 6 translation directions. Apart from an in-domain test set, an out-of-domain test set was also used. In this evaluation, UPC Ngram-based system introduced a novel reordering strategy described in [Cre06b]. This strategy extends the monotone search graph with a limited number of promising source-reordered hypotheses. The decision as to produce a new reordered path is taken according to reordering patterns extracted from training alignments and source Part-Of- Speech sequences. [Cre06b] reports a significant performance increase at nearly no additional computational cost. Some results are summarised in Table 4.40. Among new acronyms, LCC stands for Language Computer Corporation (USA), UTX for University of Texas (USA) and MS for Microsoft Research (USA). Again, a lowercased letter indicates a different system submitted by the same site10. The table shows that UPC results belong to the group of 5 leading sites in terms of BLEU score for this task, which perform very similarly. This is confirmed by the varying ranking order depending on translation direction and input test. Further details of this evaluation campaign, including automatic and human evaluation scores for all translation directions and test sets, can be found in [Koe06]. UPC Ngram-based SMT 9Generally, lower performance is observed for all systems, reflecting the test-train data mismatch, as well as increased ASR WER rates, from 6.2% to 9.8%. 10Regarding UPC, ’UPCm’ and ’UPCj’ stand for two phrase-based SMT systems. Chapter 4. Ngram-based SMT 113 in-domain test out-domain test Spanish→English English→Spanish Spanish→English English→Spanish Site BLEU Site BLEU Site BLEU Site BLEU LCC 31.46 UPCm 31.06 UPC 27.92 UPCm 26.62 NTT 31.29 NTT 30.93 UTX 27.41 NTT 26.52 UTX 31.10 UTX 30.73 LCC 27.18 MS 26.15 UPC 31.01 UPC 30.44 NTT 26.85 UPC 25.59 RALI 30.80 NRC 29.97 UPCm 25.62 NRC 25.58 NRC 30.04 MS 29.76 NRC 25.40 UTX 25.26 UPCm 29.43 RALI 29.38 EDINBG 25.20 RALI 24.03 EDINBG 29.01 EDINBG 28.49 RALI 25.03 EDINBG 23.18 UPCj 28.03 UPCj 27.46 UPCj 23.42 UPCj 22.04 UPV 23.91 UPV 23.17 UPV 19.17 UPV 16.83 Table 4.40: Some results of NAACL 2006 Workshop. BLEU is presented as a percentage. system participation is reported in the following publication: •[Cre06a] J.M. Crego, A. de Gispert, P. Lambert, M.R. Costa-juss`a, M. Khalilov, R. Banchs, J.B. Mari˜no and J.A.R. Fonollosa, “N-gram-based SMT System Enhanced with Reordering Patterns,” in Proceedings of the HLT/NAACL Workshop on Statistical Machine Translation, pps. 162–165, June 2006. Most recently, UPC Ngram-based system participated in NIST 2006 MT evaluation, both for Chinese→English and Arabic→English large-data tasks, and IWSLT 2006 evaluation campaign, in all translation directions. As official results are being or have not been released yet, these are not reported here. Further details on the description of these tasks, as well as UPC participation will be easily accessible in the corresponding publications. Chapter 4. Ngram-based SMT 114 4.5 Chapter Summary and Conclusions This chapter introduced in detail Ngram-based SMT, a maximum-entropy approach to provide the bilingual N-gram translation model from chapter 3with additional feature functions in order to obtain state-of-the-art MT performance. All the training stages are thoroughly explained, as well as the optimisation procedure. Following the tendency of the field towards a log-linear combination of feature functions whose respective weights need to be optimised according to automatic evaluation measures on a development data set (minimum-error training), this chapter showed that additional features do certainly improve the bilingual N-gram model performance. In particular, the contribution of lexical models based on IBM model 1 probabilities achieve the biggest quality improvement. Their impact is double: on the one hand, they represent a constant tuple ranking which is complementary to the bilingual N-gram model; and on the other, they tend to favour shorter tuples, thus producing less number of words. These effects seem to boost automatic evaluation scores significantly. Additionally, the target language model (which is combined with a word bonus model) enlarges the translation context on a monolingual scale. In other words, whenever the bilingual context is useless, the target language model can help produce a grammatically correct target sentence, since the target language model is less sparse. Finally, the combination of the translation model plus all these four models yields the best performance. In order to illustrate each model contribution, a study of examples is presented, in which some bad examples (whose translation is worse when feature combination is at play) are purposely introduced. When it comes to tuple segmentation, the contrastive impact of the different strategies from §3.4.2 appears reduced under the optimised combination framework, hinting that features may help compensate for bad segmentation decisions. Apart from that, experiments on tuple pruning show that it is more adequate to prune given the log-linear combination than only taking the bilingual N-gram model into account, as done in §3.3.1.2. When manually studying the system outputs (for the English↔Spanish pair) and when comparing the system to other MT systems (in many evaluation campaigns), the following conclusions can be drawn: •Despite the positive impact of features in translation quality, many errors still exist •The system falls short of words, systematically outputting less words than the number of input words. Omission errors therefore demand for future studies on modelling tuples Chapter 4. Ngram-based SMT 115 translating to NULL •Verb forms are sparse and hard to translate correctly, especially when target is Spanish (or any rich language in terms of morphology) •The system obtains a very good performance in monotone tasks; however, word order errors persist and are relevant even in these cases. For language pairs in need of severe word order modification, the system looses competitiveness As noted in the publications already mentioned, a big amount of work from this chapter has been co-authored with the members of UPC SMT group. Apart from the papers being referred to throughout the chapter, the Ngram-based SMT system is further reported in the following journal publication: •[Mn06a] J.B. Mari˜no, R.E. Banchs, J.M. Crego, A. de Gispert, P. Lambert, J.A.R. Fonollosa and M.R. Costa-juss`a, “N-gram Based Machine Translation,” Accepted for publication in Computational Linguistics, December 2006. Chapter 4. Ngram-based SMT 116 Chapter 5 Linguistic Knowledge into Word Alignment 5.1 Introduction This chapter presents a set of experiments conducted with the aim of improving Alignment Error Rate by introducing a certain degree of linguistic knowledge into the statistical training of SMT systems. Mainly two approaches were followed; on the one hand, a one-to-one cooccurrence-based word alignment algorithm was implemented and extended with linguistic phrases; and on the other, word alignment based on IBM models (ie. using GIZA++) was extended by several linguistically-guided classification schemes affecting input words. All experiments were carried out in Spanish↔English tasks, with large variations in corpus size and domain. In all tests, word alignment quality is assessed by measuring Alignment Error Rate (see §2.5.1) against a human gold standard reference set. For each corpus, a reference on the development of the gold standard set will be made. The chapter is organised as follows: • §5.2 reports the development of a word alignment tool based on word cooccurrences and link probabilities, and its extension to many-to-many links by including certain linguistic phrases, namely verb forms, regular time and data expressions and idiomatic expressions. •Given the positive results provided by this many-to-many extension, IBM-based alignment can also be constrained by previously classifying verb forms in an analogous way. This is studied in §5.3. •Following this classification principle, §5.4 thoroughly evaluates the impact of various word classes (including base forms, stems and morphological word derivations) on alignment 117 Chapter 5. Linguistic Knowledge into Word Alignment 118 error rate for both large- and small-data tasks. Furthermore, a discussion on correlation with translation evaluation scores is also included. Lastly, §5.5 closes this chapter with a summary of discussed topics and main conclusions. Chapter 5. Linguistic Knowledge into Word Alignment 119 5.2 Cooccurrence-based word alignment extended with linguistic phrases 5.2.1 Related work Word alignment systems based on IBM models suffer from two structural flaws that pose a severe limitation to their performance. Due to the model definition of alignment as a function from positions in the target sentence to positions in the source sentence, the result is strictly asymmetric, generating one-to-many word alignments that do not account for many translation phenomena. Several kinds of symmetrisation heuristics (all of them linguistically blind) have been proposed to deal with this effect, seeking the most accurate result to pass onto posterior phrase-based translation systems. Furthermore, the mathematical complexity of IBM models and their overload of parameters to estimate make it very hard to introduce linguistic information into this setting in a comfortable way, although some efforts have been done in [Tou02]. From a considerably different standpoint, a word alignment can be produced using information on word cooccurrences and link probabilities, as was introduced in [Che03a]. The relative simplicity of this approach, its flexibility to introduce more knowledge sources, its structural symmetry and its promising results shown in [Mih03] make it attractive despite its dependence on empirical data and tuning strategies. However, the most important disadvantage of the approach is the one-to-one constraint, producing high precision alignments with low recall, limiting thus its use in practical translation systems. In the face of this, a novel alignment strategy was proposed during the course of this Ph.D. research work. The strategy is also based on bilingual cooccurrences, but aims at finding phrase- to-phrase alignments directly from the corpus cooccurrence counts by using linguistic knowledge, thereby overcoming the one-to-one limitation. This knowledge is introduced by means of very simple rules made by non-linguists. A similar approach is followed in the framework of example-based machine translation in [Bro99], in order to improve the coverage of the examples during translation. As it will be detailed in the following sections, in our case the rules provide a classification that leads to improved statistical word alignment performance. Another approach to directly generate phrase alignments from the corpus without symmetrising IBM-based alignments was presented in [Mar02]. In contrast to their open (and computationally costly) approach, here very high-confidence links between phrases are performed before proceeding onto word alignment, based on linguistic knowledge. This search for phrase links is limited to a small adequate set of possible phrases, as discussed below. Chapter 5. Linguistic Knowledge into Word Alignment 126 train . .  the . . take . . will . . i. . coger´e el tren full . . .  day . .. all . . . todo el d´ıa lleno tomorrow . .  for . . it . . leave . . d´ejalo para ma˜nana Figure 5.3: Three linguistically-guided postprocessing strategies: completing selected phrases with only one token aligned (left), alignment of Spanish unaligned articles together with the noun they precede (centre) and alignment of English personal pronouns following verbs linked to Spanish verbs with pronoun (right) 5.2.3.4 Postprocessing As postprocessing, three basic strategies based on linguistic criteria were implemented. First of all, we automatically align together those phrases selected during the first stage that have been left unaligned except for one of their tokens. This aligned token defines the alignment that is automatically generated for the other tokens of the phrase. The rationale behind this is to recover those detected phrases that did not have a good cooccurrence measure during the phrase alignment stage and were not linked, but got one token linked during posterior word alignment. On the other hand, we also look for those Spanish articles preceding a noun which is linked to an English word, according to POS tags. For all these tokens, we automatically generate a link from the Spanish article to that English word, as these common Spanish articles are sometimes omitted in English. Finally, a similar approach is followed with English personal pronouns following a verb. If this verb is aligned to an Spanish verb form containing a pronoun, we conclude that the English pronoun must be aligned to the Spanish verb form as well. Figure 5.3 shows graphically one example of each of these postprocessing strategies (where black and white boxes represent links produced before and during postprocessing, respectively), whereas their impact is evaluated empirically in §5.2.4.6. The postprocessing stage could take other final alignment decisions using sentence-level information (ie. deciding whether unlinked words should be linked, looking for long-distance links, reconsidering the links for a word/phrase given all its links in all sentence pairs, etc.). Ideally, it could also feedback into the phrase selection/alignment blocks to reconsider previous decisions using global information of all sentences. Undoubtedly, this stage is strongly connected to the posterior translation model. Although alignment can be and must be evaluated separately, we are of the opinion that it is not completely independent from the translation model. Chapter 5. Linguistic Knowledge into Word Alignment 127 5.2.4 Experimental work 5.2.4.1 Experiment setup Experiments with the alignment strategy described above were conducted on English–Spanish VerbMobil parallel corpus, whose main statistics were already shown in Table 3.8. Data preprocessing included: •Normalisation of contracted forms for English (ie. wouldn’t = would not, we’ve = we have) and Spanish (del = de el) •English data tagging using freely-available TnT tagger [Bra00], and base forms were obtained using wnmorph, included in the WordNet package [Mil91]. •Spanish data tagging using FreeLing package already mentioned. This software also generates a lemma or base form for each input word. •Regular date and time expressions (numerous in this domain) were substituted by a unified tag using a semi-automatic technique [Gis03]. Specifically, only dates containing a month of the year in both languages were substituted, in contrast to date expressions dealt with in section 5.2.3.1. •Finally, punctuation marks were left out. In order to assess the quality of the algorithm using Recall, Precision and AER measures, we randomly selected from the corpus two sets: a validation set of 100 sentences (for tuning of parameters) and a test set of 400 sentences. These sets were manually aligned, following the criterion of producing Possible links only when they allow combinations which are considered equally correct, as a reference with too many Possible links suffers from a resolution loss, causing several different alignments to be equally rated. The result was that 80% of the links were Sure and 20% were Possible. Figure 5.4 shows an example of a manual reference alignment used in evaluation, where two alignments between verb phrases can be found (’I said -he dicho’, ’you would send -t´u enviar´ıas’). As the interest was in aligning full verb phrases (with their pronoun, if any) as single meaningbearing units during phrase alignment, the criterion used in reference was to separate verb phrases into two parts, that is, personal pronoun (if any) and remaining tokens. These parts were aligned with Sure links to their counterparts in the other language, whereas Possible links were introduced between personal pronouns in one language and remaining tokens in the other (and vice versa). Introducing these latter links as Sure would favour our alignment result, since Chapter 5. Linguistic Knowledge into Word Alignment 128 Figure 5.4: Example of manual reference alignment (S for Sure links and P for Possible links). we produce all links between all tokens inside verb phrases. Therefore, the Possible links in the reference allow the generation of all internal links without falsely improving AER results with a misleading boost in Recall. 5.2.4.2 Phrase alignment results In this section, we evaluate separately the phrase selection, classification and alignment blocks described in sections 5.2.3.1 and 5.2.3.2. First we present results of the phrase selection and alignment stage previous to word alignment. Specifically, statistics on phrase selection and alignment are provided when dealing with verb phrases, idiomatic expressions and date expressions separately. Finally, complete alignment results are reported (phrase alignment + word alignment + postprocessing), comparing performance against state-of-the-art word alignment models. 5.2.4.3 Verb phrases Verb phrase detection rules include 14 basic rules for English language and just 6 for Spanish, which usually employs inflected verb forms omitting thus personal pronouns and using thus a single token. Verb phrase rules have detected a total of: •English: 20,556 verb phrases (1,907 different), classified into 276 different verb lemmas •Spanish: 2,007 verb phrases (674 different), classified into 190 different verb lemmas In the case of English, 5% of detected phrases are ’gapped’ in that they include adverbs modifying the verb, which will not be aligned together with the verb phrase (see section 5.2.3.1). Chapter 5. Linguistic Knowledge into Word Alignment 129 Note that these figures include only phrases with more than one token (which are linked in the phrase alignment stage). For this reason, we get such a big difference between languages, given the usual omission of personal pronoun in Spanish by using inflected single-word verb forms. However, if we include also words with POS-tag of Verb that are substituted by their base form before word alignment (see section 5.2.3.1), we detect: •English: 36,556 verb forms (2,584 different), classified into 482 different verb lemmas, and representing ∼31% of all English tokens •Spanish: 37,605 verb forms (2,763 different), classified into 539 different verb lemmas, and representing ∼20% of all Spanish tokens Results of the phrase alignment with only verb phrases for the development set are shown in the upper rows of Table 5.2, changing the value of the threshold to accept phrase links from more restrictive to less restrictive. A restriction that the linked pair cooccurs at least twice has also been used. The last two columns correspond to the percentage of verb phrases linked over the total number of phrases detected in the train set for English and Spanish, respectively. The margin of confidence at the 95% for Recall and Precision measure is 1.0%. Recall Precision LkEng LkSpa Verb phrases φ2 v<5 6.00 98.94 51% 40% Verb phrases φ2 v<10 11.06 98.97 81% 77% Verb phrases φ2 v<15 12.14 98.92 87% 86% Verb phrases φ2 v<20 12.64 96.93 93% 91% Idioms φ2 v<5 2.19 98.61 19% 47% Idioms φ2 i<10 3.24 99.06 32% 77% Idioms φ2 i<15 3.68 97.54 63% 84% Idioms φ2 v<20 3.92 95.59 89% 90% Date exprs. φ2 i<5∗4.11 98.82 88% 86% Table 5.2: Separate phrase alignment results for development data set. The proposed selection strategy provides very positive results, as Precision is consistently nearly 99 % for the three most-restrictive thresholds used, whereas Recall is just over 12% and nearly 87% of all selected blocks are being linked with a high precision. We have to keep in mind that these phrase links will necessarily boost Recall with respect to the isolated word aligner, as it is a one-to-one algorithm, unable to produce these links. As about Precision, the high figures are due to the greater statistical evidence of phrase cooccurrence measures with respect to single word cooccurrences. Given the significant descent in Precision without significant improvement in Recall setting the threshold to 20, a threshold of 15 has been selected as optimal for further experiments. Chapter 5. Linguistic Knowledge into Word Alignment 130 5.2.4.4 Idiomatic expressions Regarding idiomatic expressions, the phrase selection stage detects the following cases by matching with the available lists presented in §5.2.3.1: •English: 525 idiomatic expressions (21 different), representing ∼1% of all English tokens •Spanish: 2,760 idiomatic expressions (98 different), representing ∼3% of all Spanish tokens The results when aligning only idiomatic expressions phrase-phrase and phrase-words links are shown in the middle rows of Table 5.2, again for different thresholds. In this case, although the impact in Recall is much smaller than when considering verb phrases, two points are worth raising. First, we have again a nearly error-free alignment using a relatively small set of phrases (with thresholds up to 15). And second, but not less important, that we expect this Recall to complement the previous experiment and further boost the global alignment Recall, as we find no verb phrases among the idiomatic expressions considered. Again, a threshold of 15 has been selected as optimal for further experiments. 5.2.4.5 Date expressions Finally, regarding date expressions, which are all classified into one single class, the selection stage detects: •English: 4,221 date expressions (336 different), representing ∼5% of all English tokens •Spanish: 4,303 date expressions (410 different), representing ∼5% of all Spanish tokens The result when aligning only date expressions is shown in the bottom-most row of Table 5.2. This result does not change when increasing the threshold. As we only allow links between date expressions having the same ’value’ (same day of the week and same day of the month), this result is constant once surpassed the cooccurrence measure between the tags ’date’ of each language. Note that the 12% of expressions not linked correspond to not respecting the aforementioned constraint. 5.2.4.6 Complete alignment results and discussion All in all, when aligning verb phrases, idiomatic expressions and date expressions before word alignment (using each optimal threshold), we achieve a 19.93% of Recall with an outstanding Chapter 5. Linguistic Knowledge into Word Alignment 131 99.03% Precision. This means that nearly 20% of the links are already done before proceeding to the statistical one-to-one word aligner. Now the complete alignment results are presented. For comparison purposes, we aligned our data using GIZA++ from English to Spanish and vice versa (performing 5 iterations of model IBM1 and HMM, and 3 iterations of models IBM3 and IBM4), and evaluated two symmetrisation strategies, namely the union and the intersection. Another symmetrisation technique presented in [Och00b] was also tested, without improvement over the union given this data and reference. The obtained alignment results are shown in the first four rows of Table 5.3. Note that the giza++ union rates the best among them, an expected result given the proportion of Sure and Possible links in the manual alignment, which favours high-recall alignments. The margin of confidence at the 95% for Recall and Precision measures is 1.0%, and 0.8% for AER. Recall Precision AER giza++ eng2spa 76.70 92.90 15.78 giza++ spa2eng 78.52 94.02 14.14 giza++ union 84.24 90.64 12.52 giza++ intersection 70.98 97.37 17.78 one-to-one word align 72.78 95.85 17.15 full phrase align 80.75 96.37 11.42 Table 5.3: Comparison of final alignment results for test set. Complementarily, we also used the word alignment algorithm presented in section 5.2.3.3 to align the data without any kind of previous phrase selection and alignment, thus producing the one-to-one alignment shown in the fifth row. For this result, we ran three iterations with amscore = 30, and three iterations further restricting it to 8 to achieve high precision, always using cohesion constrain (initial NULL cost being set to 15). In contrast to giza++ intersection (the only baseline alignment that is also one-to-one and thus subject to a fair comparison), we observe a reduction in Precision and an increase in Recall, leading to a non-significant AER reduction, that is, comparable performance. However, both alignments skip around 30 % of good links (far below the other alignments recall), which make them unpractical for posterior statistical translation modelling. The results of our phrase-based word aligner are shown in the ’full phrase align’ row (including phrase selection with each of the phrase optimal thresholds and postprocessing). As it can be seen, it rates the best AER with 1.1 absolute points lower than the giza++ union (a relative 8.8% reduction). Our alignment achieves a very high Precision level (just one point lower than giza++ intersection), while providing a Recall increase of over 10 absolute points with respect to intersection, Chapter 5. Linguistic Knowledge into Word Alignment 132 and of about 8 points with respect to the one-to-one aligner. The achieved Recall figure is still 3.5 points lower than that of the giza++ union (that nevertheless offers 6.3 points worse Precision results). It is interesting to note the Precision improvement when comparing the word-to-word aligner with the phrase aligner proposed, which is due to two factors. On the one hand, the previous phrase alignment introduces links with a higher precision than that of the one-to-one aligner, and on the other hand, this previous linking results in a complexity reduction (less ambiguity) that simplifies the task of the one-to-one aligner, improving its performance. Recall Precision AER phrase align, no postrocess. 78.71 97.20 12.35 postprocess. (3 strategies) 2.04 85.20 postprocess. strategy 1 0.80 83.33 postprocess. strategy 2 0.90 86.14 postprocess. strategy 3 0.40 77.78 Table 5.4: Impact of postprocessing strategies in AER results. To analyse the impact of the postprocessing in this result, Table 5.4 shows the AER without any postprocessing, which is not significantly lower than that of the giza++ union (with as high a Precision as the intersection). It is the addition of the three linguistically-guided postprocessing strategies presented in section 5.2.3.4 that provides a further boost to Recall for achieving the best AER. To sum up, the presented alignment strategy improved state-of-the-art results while still making a relatively small use of linguistic knowledge. As its architecture is open to an easy introduction of more information, many other knowledge sources could be used. Furthermore, we performed the union between our results and the highest precision alignment, namely the giza++ intersection, obtaining a significant improvement in terms of Recall (over 3.5% absolute) and AER (1.3% absolute), as shown in Table 5.5. Recall Precision AER phr. align U giza++ intsct. 84.36 95.11 10.10 Table 5.5: Results when combining two highest-precision alignments. This result leads to two conclusions. On the one hand, the links produced by the proposed algorithm are complementary to those provided by the state-of-the-art statistical approaches, as linguistic knowledge plays a generalisation role where mere statistics are limited. And on the other hand, this means that there is still room for improvement, which could be achieved by introducing more linguistic knowledge, as mentioned in the next section. Finally, an additional conclusion which can be drawn from this result points towards the Chapter 5. Linguistic Knowledge into Word Alignment 133 inclusion of verb detection rules into alignments based on IBM models. Given the existence of complementary information between alignments based on IBM models and our cooccurrencebased aligner (including full verb detection rules forcing their treatment as single alignment tokens), it is reasonable to expect that the former will possibly benefit from verb detection rules as well. This research line is documented in the following two sections. Chapter 5. Linguistic Knowledge into Word Alignment 134 5.3 Verb form classification for constraining IBM-based alignment In this section an experiment of verb form classification for constraining IBM-based word alignment is reported. Basically the approach aims at leveraging the positive effect of full verb form classification from the previous section, where it produced a big boost in recall at nearly no precision cost. For this, the same verb detection rules (implemented with a deterministic automaton) from §5.2.3.1 were used to unambiguously classify the English–Spanish parallel text before word alignment. Again, it is worth mentioning that with these rules one can detect verbs containing adverbs and negations (underlined in Figure 5.2), which are ordered before the verb to improve word alignment with Spanish, but once aligned they are reordered back to their original position inside the detected verb, representing the real instance of this verb. Experiments were carried out using the LC-Star Spanish–English parallel corpus (see detailed statistics in Table 3.4). Preprocessing included: •Normalisation of contracted forms for English (ie. wouldn’t = would not, we’ve = we have) •English POS-tagging using freely-available TnT tagger [Bra00], and lemmatisation using wnmorph, included in the WordNet package [Mil91]. •Spanish POS-tagging using FreeLing analysis tool [Car04], which also generates a lemma or base form for each input word. 5.3.1 Verb Phrase Detection/Classification Table 5.6 shows the number of detected verbs using the detection rules presented in §5.2.3.1, and the number of different lemmas they map to. verbs lemmas Train set English 56419 768 Spanish 54460 911 Table 5.6: Detected verb forms in LC-Star parallel corpus. In average, detected English verbs contain 1.81 words, whereas Spanish verbs contain 1.08 words. This is explained by the fact that we are including the personal pronouns in English and modals for future, conditionals and other verb tenses. Chapter 5. Linguistic Knowledge into Word Alignment 135 5.3.2 Word alignment results In order to assess the quality of the word alignment, we randomly selected from the training corpus 350 sentences, and a manual gold standard alignment was created with the criterion of Sure and Possible links, in order to compute Alignment Error Rate (AER) as described in §2.5.1, together with appropriately redefined Recall and Precision measures. Word alignment was performed using GIZA++ [Och03a] from English to Spanish and vice versa (performing 5 iterations of model IBM1 and HMM, and 3 iterations of models IBM3 and IBM4), and evaluated two symmetrisation strategies, namely the union and the intersection, the union always rating the best. Once again, the refined symmetrisation technique presented in [Och00b] was also tested, without improvement over the union given this data and reference. Table 5.7 compares the result when aligning words (current baseline), and when aligning classified verb phrases. In this latter case, after word alignment we substitute the class for the original verb form and each new word gets the same links the class had. Of course, adverbs and negations are kept apart from the verb and have separate links. Recall Precision AER baseline 74.14 86.31 20.07 with class. verbs 76.45 89.06 17.37 Table 5.7: Results in statistical alignment for the LC-Star corpus. Results show a significant improvement in AER, which proves that verbal inflected forms and auxiliaries do harm alignment performance in absence of the proposed classification. The following section deepens into this approach by evaluating this classification strategy in a large-vocabulary task and comparing it to other classification approaches.