In this paper , we aim to understand whether current language and vision ( LaVi ) models truly grasp the interaction between the two modalities . To this end , we propose an extension of the MS-COCO dataset , FOIL-COCO , which associates images with both correct and ' foil ' captions , that is , descriptions of the image that are highly similar to the original ones , but contain one single mistake ( ' foil word ' ) . We show that current LaVi models fall into the traps of this data and perform badly on three tasks : a ) caption classification ( correct vs. foil ) ; b ) foil word detection ; c ) foil word correction . Humans , in contrast , have near-perfect performance on those tasks . We demonstrate that merely utilising language cues is not enough to model FOIL-COCO and that it challenges the state-of-the-art by requiring a fine-grained understanding of the relation between text and image . Most human language understanding is grounded in perception . There is thus growing interest in combining information from language and vision in the NLP and AI communities . So far , the primary testbeds of Language and Vision ( LaVi ) models have been ' Visual Question Answering ' ( VQA ) ( e.g. Antol et al . ( 2015 ) ; Malinowski and Fritz ( 2014 ) ; Malinowski et al . ( 2015 ) ; Gao et al . ( 2015 ) ; Ren et al . ( 2015 ) ) and ' Image Captioning ' ( IC ) ( e.g. Hodosh et al . ( 2013 ) ; Fang et al . ( 2015 ) ; Chen and Lawrence Zitnick ( 2015 ) ; Donahue et al . ( 2015 ) ; Karpathy and Fei-Fei ( 2015 ) ; Vinyals et al . ( 2015 ) ) . Whilst some models have seemed extremely successful on those tasks , it remains unclear how the reported results should be interpreted and what those Figure 1 : Is the caption correct or foil ( T1 ) ? If it is foil , where is the mistake ( T2 ) and which is the word to correct the foil one ( T3 ) ? models are actually learning . There is an emerging feeling in the community that the VQA task should be revisited , especially as many current dataset can be handled by ' blind ' models which use language input only , or by simple concatenation of language and vision features ( Agrawal et al . , 2016 ; Jabri et al . , 2016 ; Zhang et al . , 2016 ; Goyal et al . , 2016a ) . In IC too , Hodosh and Hockenmaier ( 2016 ) showed that , contrarily to what prior research had suggested , the task is far from been solved , since IC models are not able to distinguish between a correct and incorrect caption . Such results indicate that in current datasets , language provides priors that make LaVi models successful without truly understanding and integrating language and vision . But problems do not stop at biases . Johnson et al . ( 2016 ) also point out that current data ' conflate multiple sources of error , making it hard to pinpoint model weaknesses ' , thus highlighting the need for diagnostic datasets . Thirdly , existing IC evaluation metrics are sensitive to n-gram overlap and there is a need for measures that better simulate human judgments ( Hodosh et al . , 2013 ; Elliott and Keller , 2014 ; Anderson et al . , 2016 ) . Our paper tackles the identified issues by proposing an automatic method for creating a large dataset of real images with minimal language bias and some diagnostic abilities . Our dataset , FOIL ( Find One mismatch between Image and Language caption),1 consists of images associated with incorrect captions . The captions are produced by introducing one single error ( or ' foil ' ) per caption in existing , human-annotated data ( Figure 1 ) . This process results in a challenging error-detection / correction setting ( because the caption is ' nearly ' correct ) . It also provides us with a ground truth ( we know where the error is ) that can be used to objectively measure the performance of current models . We propose three tasks based on widely accepted evaluation measures : we test the ability of the system to a ) compute whether a caption is compatible with the image ( T1 ) ; b ) when it is incompatible , highlight the mismatch in the caption ( T2 ) ; c ) correct the mistake by replacing the foil word ( T3 ) . The dataset presented in this paper ( Section 3 ) is built on top of MS-COCO ( Lin et al . , 2014 ) , and contains 297,268 datapoints and 97,847 images . We will refer to it as FOIL-COCO . We evaluate two state-of-the-art VQA models : the popular one by Antol et al . ( 2015 ) , and the attention-based model by Lu et al . ( 2016 ) , and one popular IC model by ( Wang et al . , 2016 ) . We show that those models perform close to chance level , while humans can perform the tasks accurately ( Section 4 ) . Section 5 provides an analysis of our results , allowing us to diagnose three failures of LaVi models . First , their coarse representations of language and visual input do not encode suitably structured information to spot mismatches between an utterance and the corresponding scene ( tested by T1 ) . Second , their language representation is not finegrained enough to identify the part of an utterance that causes a mismatch with the image as it is ( T2 ) . Third , their visual representation is also too poor to spot and name the visual area that corresponds to a captioning error ( T3 ) . We have introduced FOIL-COCO , a large dataset of images associated with both correct and foil captions . The error production is automatically generated , but carefully thought out , making the task of spotting foils particularly challenging . By associating the dataset with a series of tasks , we allow for diagnosing various failures of current LaVi systems , from their coarse understanding of the correspondence between text and vision to their grasp of language and image structure . Our hypothesis is that systems which , like humans , deeply integrate the language and vision modalities , should spot foil captions quite easily . The SoA LaVi models we have tested fall through that test , implying that they fail to integrate the two modalities . To complete the analysis of these results , we plan to carry out a further task , namely ask the system to detect in the image the area that produces the mismatch with the foil word ( the red box around the bird in Figure 1 . ) This extra step would allow us to fully diagnose the failure of the tested systems and confirm what is implicit in our results from task 3 : that the algorithms are unable to map particular elements of the text to their visual counterparts . We note that the addition of this extra step will move this work closer to the textual / visual explanation research ( e.g. , ( Park et al . , 2016 ; Selvaraju et al . , 2016 ) ) . We will then have a pipeline able to not only test whether a mistake can be detected , but also whether the system can explain its decision : ' the wrong word is dog because the cyclists are in fact approaching a bird , there , in the image ' . LaVi models are a great success of recent research , and we are impressed by the amount of ideas , data and models produced in this stimulating area . With our work , we would like to push the community to think of ways that models can better merge language and vision modalites , instead of merely using one to supplement the other .

Despite the success of language and vision models on visual question answering tasks, what these models are learning remains unknown because of coarse-grained datasets.

They propose to automatically inject one mistake to captions in the MS-COCO dataset as a foil word and three diagnostic tasks to study models' behaviors.

Using the introduced dataset, they find that best performing models fail on the proposed tasks indicating their abilities to integrate two modalities.


Language is increasingly being used to define rich visual recognition problems with supporting image collections sourced from the web . Structured prediction models are used in these tasks to take advantage of correlations between co-occurring labels and visual input but risk inadvertently encoding social biases found in web corpora . In this work , we study data and models associated with multilabel object classification and visual semantic role labeling . We find that ( a ) datasets for these tasks contain significant gender bias and ( b ) models trained on these datasets further amplify existing bias . For example , the activity cooking is over 33 % more likely to involve females than males in a training set , and a trained model further amplifies the disparity to 68 % at test time . We propose to inject corpus-level constraints for calibrating existing structured prediction models and design an algorithm based on Lagrangian relaxation for collective inference . Our method results in almost no performance loss for the underlying recognition task but decreases the magnitude of bias amplification by 47.5 % and 40.5 % for multilabel classification and visual semantic role labeling , respectively . Visual recognition tasks involving language , such as captioning ( Vinyals et al . , 2015 ) , visual question answering ( Antol et al . , 2015 ) , and visual semantic role labeling ( Yatskar et al . , 2016 ) , have emerged as avenues for expanding the diversity of information that can be recovered from images . These tasks aim at extracting rich seman-tics from images and require large quantities of labeled data , predominantly retrieved from the web . Methods often combine structured prediction and deep learning to model correlations between labels and images to make judgments that otherwise would have weak visual support . For example , in the first image of Figure 1 , it is possible to predict a spatula by considering that it is a common tool used for the activity cooking . Yet such methods run the risk of discovering and exploiting societal biases present in the underlying web corpora . Without properly quantifying and reducing the reliance on such correlations , broad adoption of these models can have the inadvertent effect of magnifying stereotypes . In this paper , we develop a general framework for quantifying bias and study two concrete tasks , visual semantic role labeling ( vSRL ) and multilabel object classification ( MLC ) . In vSRL , we use the imSitu formalism ( Yatskar et al . , 2016 ( Yatskar et al . , , 2017 ) ) , where the goal is to predict activities , objects and the roles those objects play within an activity . For MLC , we use MS-COCO ( Lin et al . , 2014 ; Chen et al . , 2015 ) , a recognition task covering 80 object classes . We use gender bias as a running example and show that both supporting datasets for these tasks are biased with respect to a gender binary1 . Our analysis reveals that over 45 % and 37 % of verbs and objects , respectively , exhibit bias toward a gender greater than 2:1 . For example , as seen in Figure 1 , the cooking activity in imSitu is a heavily biased verb . Furthermore , we show that after training state-of-the-art structured predictors , models amplify the existing bias , by 5.0 % for vSRL , and 3.6 % in MLC . Each image is paired with a table describing a situation : the verb , cooking , its semantic roles , i.e agent , and noun values filling that role , i.e. woman . In the imSitu training set , 33 % of cooking images have man in the agent role while the rest have woman . After training a Conditional Random Field ( CRF ) , bias is amplified : man fills 16 % of agent roles in cooking images . To reduce this bias amplification our calibration method adjusts weights of CRF potentials associated with biased predictions . After applying our methods , man appears in the agent role of 20 % of cooking images , reducing the bias amplification by 25 % , while keeping the CRF vSRL performance unchanged . To mitigate the role of bias amplification when training models on biased corpora , we propose a novel constrained inference framework , called RBA , for Reducing Bias Amplification in predictions . Our method introduces corpus-level constraints so that gender indicators co-occur no more often together with elements of the prediction task than in the original training distribution . For example , as seen in Figure 1 , we would like noun man to occur in the agent role of the cooking as often as it occurs in the imSitu training set when evaluating on a development set . We combine our calibration constraint with the original structured predictor and use Lagrangian relaxation ( Korte and Vygen , 2008 ; Rush and Collins , 2012 ) to reweigh bias creating factors in the original model . We evaluate our calibration method on imSitu vSRL and COCO MLC and find that in both instances , our models substantially reduce bias amplification . For vSRL , we reduce the average magnitude of bias amplification by 40.5 % . For MLC , we are able to reduce the average magnitude of bias amplification by 47.5 % . Overall , our calibration methods do not affect the performance of the underlying visual system , while substantially reducing the reliance of the system on socially biased correlations 2 . 2 Code and data are available at https://github . com / uclanlp / reducingbias Structured prediction models can leverage correlations that allow them to make correct predictions even with very little underlying evidence . Yet such models risk potentially leveraging social bias in their training data . In this paper , we presented a general framework for visualizing and quantifying biases in such models and proposed RBA to calibrate their predictions under two different settings . Taking gender bias as an example , our analysis demonstrates that conditional random fields can amplify social bias from data while our approach RBA can help to reduce the bias . Our work is the first to demonstrate structured prediction models amplify bias and the first to propose methods for reducing this effect but significant avenues for future work remain . While RBA can be applied to any structured predictor , it is unclear whether different predictors amplify bias more or less . Furthermore , we presented only one method for measuring bias . More extensive analysis could explore the interaction among predictor , bias measurement , and bias deamplification method . Future work also includes applying bias reducing methods in other structured domains , such as pronoun reference resolution ( Mitkov , 2014 ) .

Language is used for visual recognition problems such as captioning to improve performance however it can also encode social biases found in web corpora.

They propose a framework to quantify bias for visual semantic role labelling and multilabel object classification and a constraint inference framework to calibrate existing models.

They find that existing datasets contain gender bias the use of text can amplify it, and the proposed framework can reduce bias without performance loss.


We present a pairwise context-sensitive Autoencoder for computing text pair similarity . Our model encodes input text into context-sensitive representations and uses them to compute similarity between text pairs . Our model outperforms the state-of-the-art models in two semantic retrieval tasks and a contextual word similarity task . For retrieval , our unsupervised approach that merely ranks inputs with respect to the cosine similarity between their hidden representations shows comparable performance with the state-of-the-art supervised models and in some cases outperforms them . Representation learning algorithms learn representations that reveal intrinsic low-dimensional structure in data ( Bengio et al . , 2013 ) . Such representations can be used to induce similarity between textual contents by computing similarity between their respective vectors ( Huang et al . , 2012 ; Silberer and Lapata , 2014 ) . Recent research has made substantial progress on semantic similarity using neural networks ( Rothe and Schütze , 2015 ; Dos Santos et al . , 2015 ; Severyn and Moschitti , 2015 ) . In this work , we focus our attention on deep autoencoders and extend these models to integrate sentential or document context information about their inputs . We represent context information as low dimensional vectors that will be injected to deep autoencoders . To the best of our knowledge , this is the first work that enables integrating context into autoencoders . In representation learning , context may appear in various forms . For example , the context of a current sentence in a document could be either its neighboring sentences ( Lin et al . , 2015 ; Wang and Cho , 2015 ) , topics associated with the sentence ( Mikolov and Zweig , 2012 ; Le and Mikolov , 2014 ) , the document that contains the sentence ( Huang et al . , 2012 ) , as well as their combinations ( Ji et al . , 2016 ) . It is important to integrate context into neural networks because these models are often trained with only local information about their individual inputs . For example , recurrent and recursive neural networks only use local information about previously seen words in a sentence to predict the next word or composition . 1On the other hand , context information ( such as topical information ) often capture global information that can guide neural networks to generate more accurate representations . We investigate the utility of context information in three semantic similarity tasks : contextual word sense similarity in which we aim to predict semantic similarity between given word pairs in their sentential context ( Huang et al . , 2012 ; Rothe and Schütze , 2015 ) , question ranking in which we aim to retrieve semantically equivalent questions with respect to a given test question ( Dos Santos et al . , 2015 ) , and answer ranking in which we aim to rank single-sentence answers with respect to a given question ( Severyn and Moschitti , 2015 ) . The contributions of this paper are as follows : ( 1 ) integrating context information into deep autoencoders and ( 2 ) showing that such integration improves the representation performance of deep autoencoders across several different semantic similarity tasks . Our model outperforms the state-of-the-art su-pervised baselines in three semantic similarity tasks . Furthermore , the unsupervised version of our autoencoder show comparable performance with the supervised baseline models and in some cases outperforms them . 2 Context-sensitive Autoencoders We introduce an effective approach to integrate sentential or document context into deep autoencoders and show that such integration is important in semantic similarity tasks . In the future , we aim to investigate other types of linguistic context ( such as POS tag and word dependency information , word sense , and discourse relations ) and develop a unified representation learning framework that integrates such linguistic context with representation learning models .

Existing approaches for textual representation learning only use local information without contexts which capture global information that can guide neural networks in generating accurate representations.

They propose a pairwise context-sensitive Autoencoder which integrates sentential or document context for computing text pair similarity.

The proposed model outperforms the state-of-the-art models in two retrieval and word similarity tasks and an unsupervised version performs comparable with several supervised baselines.


Distance-based ( windowless ) word assocation measures have only very recently appeared in the NLP literature and their performance compared to existing windowed or frequency-based measures is largely unknown . We conduct a largescale empirical comparison of a variety of distance-based and frequency-based measures for the reproduction of syntagmatic human assocation norms . Overall , our results show an improvement in the predictive power of windowless over windowed measures . This provides support to some of the previously published theoretical advantages and makes windowless approaches a promising avenue to explore further . This study also serves as a first comparison of windowed methods across numerous human association datasets . During this comparison we also introduce some novel variations of window-based measures which perform as well as or better in the human association norm task than established measures . Automatic discovery of semantically associated words has attracted a large amount of attention in the last decades and a host of computational association measures have been proposed to deal with this task ( see Section 2 ) . These measures traditionally rely on the co-ocurrence frequency of two words in a corpus to estimate a relatedness score . There has been a recent emergence of distancebased language modelling techiques in NLP ( Savicki and Hlavacova , 2002 ; Terra and Clarke , 2004 ) in which the number of tokens separating words is the essential quantity . While some of this work has considered distance-based alternatives to conventional association measures ( Hardcastle , 2005 ; Washtell , 2009 ) , there has been no principled empirical evaluation of these measures as predictors of human association . We remedy this by conducting a thorough comparison of a wide variety of frequency-based and distance-based measures as predictors of human association scores as elicited in several different free word association tasks . In this work we focus on first-order association measures as predictors of syntagmatic associations . This is in contrast to second and higher-order measures which are better predictors of paradigmatic associations , or word similarity . The distinction between syntagmatic and paradigmatic relationship types is neither exact nor mutually exclusive , and many paradigmatic relationships can be observed syntagmatically in the text . Roughly in keeping with ( Rapp , 2002 ) , we hereby regard paradigmatic assocations as those based largely on word similarity ( i.e. including those typically classed as synonyms , antonyms , hypernyms , hyponyms etc ) , whereas syntagmatic associations are all those words which strongly invoke one another yet which can not readily be said to be similar . Typically these will have an identifiable semantic or grammatical relationship ( meronym / holonym : stem -flower , verb / object : eat -food etc ) , or may have harder-to-classify topical or idiomatic relationships ( family -Christmas , rock -roll ) . We will show in Section 3.2 that syntagmatic relations by themselves constitute a substantial 25 - 40 % of the strongest human responses to cue words . Although the automatic detection of these assocations in text has received less attention than that of paradigmatic associations , they are nonetheless important in applications such as the resolution of bridging anaphora ( Vieira and Poesio , 2000 ) . 1 Furthermore , first-order associations are often the basis of higher-order vector wordspace models used for predicting paradigmatic relationships : i.e. through the observation of words which share similar sets of syntagmatic associations . Therefore improvements made at the level we are concerned with may reasonably be expected to carry through to applications which hinge on the identification of paradigmatic relationships . After a discussion of previous work in Section 2 , we formulate the exact association measures and parameter settings which we compare in Section 3 , where we also introduce the corpora and human association sets used . Then , by using evaluations similar to those described in ( Baroni et al . , 2008 ) and by Rapp ( 2002 ) , we show that the best distance-based measures correlate better overall with human association scores than do the best window based configurations ( see Section 4 ) , and that they also serve as better predictors of the strongest human associations ( see Section 5 ) . This paper presented the first empirical comparison of window-based and the relatively recently introduced windowless association measures , using their ability to reproduce human association scores as a testbed . We show that the best windowless measures are always at least as good as the best window-based measures , both when it comes to overall correlation with human association scores and predicting the strongest human response . In addition , for several human association sets , they perform significantly better . Although not all parameter settings and corpus sizes could be explored , we conclude that it is worthwhile investigating windowless association measures further . As a side-benefit , we have also introduced new variants of existing frequency-based association measures and shown them to perform as well as or better than their existing counterparts . Although these measures were semi-principled in their construction , a deeper understanding of why they work so well is needed . This may in turn lead to the construction of superior windowless measures . In our own future work , we are especially interested in using higher-order windowless association measures for retrieving paradigmatic relations as well as exploring their use in various NLP applications .

The performance of new windowless word association measures which take the number of tokens separating words into account remains unknown.

They conduct large-scale empirical comparisons of window-based and windowless association measures for the reproduction of syntagmatic human association norms.

The best windowless measures perform on part with best window-based measures on correlation with human association scores.


This paper presents an effective method for generating natural language sentences from their underlying meaning representations . The method is built on top of a hybrid tree representation that jointly encodes both the meaning representation as well as the natural language in a tree structure . By using a tree conditional random field on top of the hybrid tree representation , we are able to explicitly model phrase-level dependencies amongst neighboring natural language phrases and meaning representation components in a simple and natural way . We show that the additional dependencies captured by the tree conditional random field allows it to perform better than directly inverting a previously developed hybrid tree semantic parser . Furthermore , we demonstrate that the model performs better than a previous state-of-the-art natural language generation model . Experiments are performed on two benchmark corpora with standard automatic evaluation metrics . One of the ultimate goals in the field of natural language processing ( NLP ) is to enable computers to converse with humans through human languages . To achieve this goal , two important issues need to be studied . First , it is important for computers to capture the meaning of a natural language sentence in a meaning representation . Second , computers should be able to produce a humanunderstandable natural language sentence from its meaning representation . These two tasks are referred to as semantic parsing and natural language generation ( NLG ) , respectively . In this paper , we use corpus-based statistical methods for constructing a natural language generation system . Given a set of pairs , where each pair consists of a natural language ( NL ) sentence and its formal meaning representation ( MR ) , a learning method induces an algorithm that can be used for performing language generation from other previously unseen meaning representations . A crucial question in any natural language processing system is the representation used . Meaning representations can be in the form of a tree structure . In Lu et al . ( 2008 ) , we introduced a hybrid tree framework together with a probabilistic generative model to tackle semantic parsing , where tree structured meaning representations are used . The hybrid tree gives a natural joint tree representation of a natural language sentence and its meaning representation . A joint generative model for natural language and its meaning representation , such as that used in Lu et al . ( 2008 ) has several advantages over various previous approaches designed for semantic parsing . First , unlike most previous approaches , the generative approach models a simultaneous generation process for both NL and MR . One elegant property of such a joint generative model is that it allows the modeling of both semantic parsing and natural language generation within the same process . Second , the generative process proceeds as a recursive top-down Markov process in a way that takes advantage of the tree structure of the MR . The hybrid tree generative model proposed in Lu et al . ( 2008 ) was shown to give stateof-the-art accuracy in semantic parsing on benchmark corpora . While semantic parsing with hybrid trees has been studied in Lu et al . ( 2008 ) , its inverse task -NLG with hybrid trees -has not yet been explored . We believe that the properties that make the hybrid trees effective for semantic parsing also make them effective for NLG . In this paper , we develop systems for the generation task by building on top of the generative model introduced in Lu et al . ( 2008 ) ( referred to as the LNLZ08 system ) . We first present a baseline model by directly " inverting " the LNLZ08 system , where an NL sentence is generated word by word . We call this model the direct inversion model . This model is unable to model some long range global dependencies over the entire NL sentence to be generated . To tackle several weaknesses exhibited by the baseline model , we next introduce an alternative , novel model that performs generation at the phrase level . Motivated by conditional random fields ( CRF ) ( Lafferty et al . , 2001 ) , a different parameterization of the conditional probability of the hybrid tree that enables the model to encode some longer range dependencies amongst phrases and MRs is used . This novel model is referred to as the tree CRF-based model . Evaluation results for both models are presented , through which we demonstrate that the tree CRF-based model performs better than the direct inversion model . We also compare the tree CRFbased model against the previous state-of-the-art model of Wong and Mooney ( 2007 ) . Furthermore , we evaluate our model on a dataset annotated with several natural languages other than English ( Japanese , Spanish , and Turkish ) . Evaluation results show that our proposed tree CRF-based model outperforms the previous model . In this paper , we presented two novel models for the task of generating natural language sentences from given meaning representations , under a hybrid tree framework . We first built a simple direct inversion model as a baseline . Next , to address the limitations associated with the direct inversion model , a tree CRF-based model was introduced . We evaluated both models on standard benchmark corpora . Evaluation results show that the tree CRF-based model performs better than the direct inversion model , and that the tree CRF-based model also outperforms WASP -1 + + , which was a previous state-of-the-art system reported in the literature .

While hybrid trees are shown to be effective for semantic parsing, their application for text generation is under explored.

They propose a phrase-level tree conditional random field that uses a hybrid tree of a meaning representation for the text generation model.

Experiments in four languages with automatic evaluation metrics show that the proposed conditional random field-based model outperforms the previous state-of-the-art system.


In this paper we examine how the differences in modelling between different data driven systems performing the same NLP task can be exploited to yield a higher accuracy than the best individual system . We do this by means of an experiment involving the task of morpho-syntactic wordclass tagging . Four well-known tagger generators ( Hidden Markov Model , Memory-Based , Transformation Rules and Maximum Entropy ) are trained on the same corpus data . After comparison , their outputs are combined using several voting strategies and second stage classifiers . All combination taggers outperform their best component , with the best combination showing a 19.1 % lower error rate than the best individual tagger . In all Natural Language Processing ( NLP ) systems , we find one or more language models which are used to predict , classify and/or interpret language related observations . Traditionally , these models were categorized as either rule-based / symbolic or corpusbased / probabilistic . Recent work ( e.g. Brill 1992 ) has demonstrated clearly that this categorization is in fact a mix-up of two distinct Categorization systems : on the one hand there is the representation used for the language model ( rules , Markov model , neural net , case base , etc . ) and on the other hand the manner in which the model is constructed ( hand crafted vs. data driven ) . Data driven methods appear to be the more popular . This can be explained by the fact that , in general , hand crafting an explicit model is rather difficult , especially since what is being modelled , natural language , is not ( yet ) wellunderstood . When a data driven method is used , a model is automatically learned from the implicit structure of an annotated training corpus . This is much easier and can quickly lead to a model which produces results with a ' reasonably ' good quality . Obviously , ' reasonably good quality ' is not the ultimate goal . Unfortunately , the quality that can be reached for a given task is limited , and not merely by the potential of the learning method used . Other limiting factors are the power of the hard-and software used to implement the learning method and the availability of training material . Because of these limitations , we find that for most tasks we are ( at any point in time ) faced with a ceiling to the quality that can be reached with any ( then ) available machine learning system . However , the fact that any given system can not go beyond this ceiling does not mean that machine learning as a whole is similarly limited . A potential loophole is that each type of learning method brings its own ' inductive bias ' to the task and therefore different methods will tend to produce different errors . In this paper , we are concerned with the question whether these differences between models can indeed be exploited to yield a data driven model with superior performance . In the machine learning literature this approach is known as ensemble , stacked , or combined classifiers . It has been shown that , when the errors are uncorrelated to a sufficient degree , the resulting combined classifier will often perform better than all the individual systems ( Ali and Pazzani 1996 ; Chan and Stolfo 1995 ; Tumer and Gosh 1996 ) . The underlying assumption is twofold . First , the combined votes will make the system more robust to the quirks of each learner 's particular bias . Also , the use of information about each individual method 's behaviour in principle even admits the possibility to fix collective errors . We will execute our investigation by means of an experiment . The NLP task used in the experiment is morpho-syntactic wordclass tagging . The reasons for this choice are several . First of all , tagging is a widely researched and well-understood task ( cf . van Halteren ( ed . ) 1998 ) . Second , current performance levels on this task still leave room for improvement : ' state of the art ' performance for data driven automatic wordclass taggers ( tagging English text with single tags from a low detail tagset ) is 96 - 97 % correctly tagged words . Finally , a number of rather different methods are available that generate a fully functional tagging system from annotated text . Our experiment shows that , at least for the task at hand , combination of several different systems allows us to raise the performance ceiling for data driven systems . Obviously there is still room for a closer examination of the differences between the combination methods , e.g. the question whether Memory-Based combination would have performed better if we had provided more training data than just Tune , and of the remaining errors , e.g. the effects of inconsistency in the data ( cf . Ratnaparkhi 1996 on such effects in the Penn Treebank corpus ) . Regardless of such closer investigation , we feel that our results are encouraging enough to extend our investigation of combination , starting with additional component taggers and selection strategies , and going on to shifts to other tagsets and/or languages . But the investigation need not be limited to wordclass tagging , for we expect that there are many other NLP tasks where combination could lead to worthwhile improvements .

Different data driven approaches tend to produce different errors and their qualities are limited due to the learning method and available training material.

They propose to combine four different modelling methods for the task of morpho-syntactic wordclass tagging by using several voting strategies and second stage classifiers.

All combinations outperform the best component, with the best one showing a 19.1% lower error rate and raising the performance ceiling.


Adversarial attacks for discrete data ( such as texts ) have been proved significantly more challenging than continuous data ( such as images ) since it is difficult to generate adversarial samples with gradient-based methods . Current successful attack methods for texts usually adopt heuristic replacement strategies on the character or word level , which remains challenging to find the optimal solution in the massive space of possible combinations of replacements while preserving semantic consistency and language fluency . In this paper , we propose BERT-Attack , a high-quality and effective method to generate adversarial samples using pre-trained masked language models exemplified by BERT . We turn BERT against its fine-tuned models and other deep neural models in downstream tasks so that we can successfully mislead the target models to predict incorrectly . Our method outperforms state-of-theart attack strategies in both success rate and perturb percentage , while the generated adversarial samples are fluent and semantically preserved . Also , the cost of calculation is low , thus possible for large-scale generations . The code is available at https://github.com/ LinyangLee / BERT-Attack . Despite the success of deep learning , recent works have found that these neural networks are vulnerable to adversarial samples , which are crafted with small perturbations to the original inputs ( Goodfellow et al . , 2014 ; Kurakin et al . , 2016 ; Chakraborty et al . , 2018 ) . That is , these adversarial samples are imperceptible to human judges while they can mislead the neural networks to incorrect predictions . Therefore , it is essential to explore these adversarial attack methods since the ultimate goal is to make sure the neural networks are highly reliable and robust . While in computer vision fields , both attack strategies and their defense countermeasures are well-explored ( Chakraborty et al . , 2018 ) , the adversarial attack for text is still challenging due to the discrete nature of languages . Generating of adversarial samples for texts needs to possess such qualities : ( 1 ) imperceptible to human judges yet misleading to neural models ; ( 2 ) fluent in grammar and semantically consistent with original inputs . Previous methods craft adversarial samples mainly based on specific rules ( Li et al . , 2018 ; Gao et al . , 2018 ; Yang et al . , 2018 ; Alzantot et al . , 2018 ; Ren et al . , 2019 ; Jin et al . , 2019 ; Zang et al . , 2020 ) . Therefore , these methods are difficult to guarantee the fluency and semantically preservation in the generated adversarial samples at the same time . Plus , these manual craft methods are rather complicated . They use multiple linguistic constraints like NER tagging or POS tagging . Introducing contextualized language models to serve as an automatic perturbation generator could make these rules designing much easier . The recent rise of pre-trained language models , such as BERT ( Devlin et al . , 2018 ) , push the performances of NLP tasks to a new level . On the one hand , the powerful ability of a fine-tuned BERT on downstream tasks makes it more challenging to be adversarial attacked ( Jin et al . , 2019 ) . On the other hand , BERT is a pre-trained masked language model on extremely large-scale unsupervised data and has learned general-purpose language knowledge . Therefore , BERT has the potential to generate more fluent and semantic-consistent substitutions for an input text . Naturally , both the properties of BERT motivate us to explore the possibility of attacking a fine-tuned BERT with another BERT as the attacker . In this paper , we propose an effective and high-quality adversarial sample generation method : BERT-Attack , using BERT as a language model to generate adversarial samples . The core algorithm of BERT-Attack is straightforward and consists of two stages : finding the vulnerable words in one given input sequence for the target model ; then applying BERT in a semantic-preserving way to generate substitutes for the vulnerable words . With the ability of BERT , the perturbations are generated considering the context around . Therefore , the perturbations are fluent and reasonable . We use the masked language model as a perturbation generator and find perturbations that maximize the risk of making wrong predictions ( Goodfellow et al . , 2014 ) . Differently from previous attacking strategies that require traditional single-direction language models as a constraint , we only need to inference the language model once as a perturbation generator rather than repeatedly using language models to score the generated adversarial samples in a trial and error process . Experimental results show that the proposed BERT-Attack method successfully fooled its finetuned downstream model with the highest attack success rate compared with previous methods . Meanwhile , the perturb percentage and the query number are considerably lower , while the semantic preservation is high . To summarize our main contributions : • We propose a simple and effective method , named BERT-Attack , to effectively generate fluent and semantically-preserved adversarial samples that can successfully mislead stateof-the-art models in NLP , such as fine-tuned BERT for various downstream tasks . • BERT-Attack has a higher attacking success rate and a lower perturb percentage with fewer access numbers to the target model compared with previous attacking algorithms , while does not require extra scoring models therefore extremely effective . In this work , we propose a high-quality and effective method BERT-Attack to generate adversarial samples using BERT masked language model . Experiment results show that the proposed method achieves a high success rate while maintaining a minimum perturbation . Nevertheless , candidates generated from the masked language model can sometimes be antonyms or irrelevant to the original words , causing a semantic loss . Thus , enhancing language models to generate more semantically related perturbations can be one possible solution to perfect BERT-Attack in the future .

Generating adversarial samples with gradient-based methods for text data is because of its discrete nature and existing complicated heuristic-based methods suffer from finding optimal solutions.

They propose to use BERT to generate adversarial samples by first finding the valuable words and generating substitutes for these words in a semantic-preserving way.

The proposed method outperforms state-of-the-art methods in success rate and perturb percentage while preserving fluency and sematic of generated samples with low cost.


We investigate the generation of onesentence Wikipedia biographies from facts derived from Wikidata slot-value pairs . We train a recurrent neural network sequence-to-sequence model with attention to select facts and generate textual summaries . Our model incorporates a novel secondary objective that helps ensure it generates sentences that contain the input facts . The model achieves a BLEU score of 41 , improving significantly upon the vanilla sequence-to-sequence model and scoring roughly twice that of a simple template baseline . Human preference evaluation suggests the model is nearly as good as the Wikipedia reference . Manual analysis explores content selection , suggesting the model can trade the ability to infer knowledge against the risk of hallucinating incorrect information . Despite massive effort , Wikipedia and other collaborative knowledge bases ( KBs ) have coverage and quality problems . Popular topics are covered in great detail , but there is a long tail of specialist topics with little or no text . Other text can be incorrect , whether by accident or vandalism . We report on the task of generating textual summaries for people , mapping slot-value facts to onesentence encyclopaedic biographies . In addition to initialising stub articles with only structured data , the resulting model could be used to improve consistency and accuracy of existing articles . Figure 1 shows a Wikidata entry for Mathias Tuomi , with fact keys and values flattened into a sequence , and the first sentence from his Wikipedia article . Some values are in the text , others are missing TITLE mathias tuomi SEX OR GENDER male DATE OF BIRTH 1985 - 09 - 03 OCCUPATION squash player CITIZENSHIP finland ( e.g. male ) or expressed differently ( e.g. dates ) . We treat this knowlege-to-text task like translation , using a recurrent neural network ( RNN ) sequence-to-sequence model ( Sutskever et al . , 2014 ) that learns to select and realise the most salient facts as text . This includes an attention mechanism to focus generation on specific facts , a shared vocabulary over input and output , and a multi-task autoencoding objective for the complementary extraction task . We create a reference dataset comprising more than 400,000 knowledgetext pairs , handling the 15 most frequent slots . We also describe a simple template baseline for comparison on BLEU and crowd-sourced human preference judgements over a heldout TEST set . Our model obtains a BLEU score of 41.0 , compared to 33.1 without the autoencoder and 21.1 for the template baseline . In a crowdsourced preference evaluation , the model outperforms the baseline and is preferred 40 % of the time to the Wikipedia reference . Manual analysis of content selection suggests that the model can infer knowledge but also makes mistakes , and that the autoencoding objective encourages the model to select more facts without increasing sentence length . The task formulation and models are a foundation for text completion and consistency in KBs . We present a neural model for mapping between structured and unstructured data , focusing on creating Wikipedia biographic summary sentences from Wikidata slot-value pairs . We introduce a sequence-to-sequence autoencoding RNN which improves upon base models by jointly learning to generate text and reconstruct facts . Our analysis of the task suggests evaluation in this domain is challenging . In place of a single score , we analyse statistical measures , human preference judgements and manual annotation to help characterise the task and understand system performance . In the human preference evaluation , our best model outperforms template baselines and is preferred 40 % of the time to the gold standard Wikipedia reference . Code and data is available at https:// github.com / andychisholm / mimo .

Wikipedia and other collaborative knowledge bases have coverage and quality issues especially on a long tail of specialist topics.

They propose a recurrent neural network sequence-to-sequence model with an attention mechanism trained on a multi-task autoencoding objective to generate one-sentence Wikipedia biographies from Wikidata.

The proposed model achieves 41 BLEU score outperforming the baseline model and human annotators prefer the 40% of outputs as good as Wikipedia gold references.


Most state-of-the-art wide-coverage parsers are trained on newspaper text and suffer a loss of accuracy in other domains , making parser adaptation a pressing issue . In this paper we demonstrate that a CCG parser can be adapted to two new domains , biomedical text and questions for a QA system , by using manually-annotated training data at the POS and lexical category levels only . This approach achieves parser accuracy comparable to that on newspaper data without the need for annotated parse trees in the new domain . We find that retraining at the lexical category level yields a larger performance increase for questions than for biomedical text and analyze the two datasets to investigate why different domains might behave differently for parser adaptation . Most state-of-the-art wide-coverage parsers are based on the Penn Treebank ( Marcus et al . , 1993 ) , making such parsers highly tuned to newspaper text . A pressing question facing the parsing community is how to adapt these parsers to other domains , such as biomedical research papers and web pages . A related question is how to improve the performance of these parsers on constructions that are rare in the Penn Treebank , such as questions . Questions are particularly important since a question parser is a component in most Question Answering ( QA ) systems ( Harabagiu et al . , 2001 ) . In this paper we investigate parser adaptation in the context of lexicalized grammars , by using a parser based on Combinatory Categorial Grammar ( CCG ) ( Steedman , 2000 ) . A key property of CCG is that it is lexicalized , meaning that each word in a sentence is associated with an elementary syntactic structure . In the case of CCG this is a lexical category expressing subcategorization information . We exploit this property of CCG by performing manual annotation in the new domain , but only up to this level of representation , where the annotation can be carried out relatively quickly . Since CCG lexical categories are so expressive , many of the syntactic characteristics of a domain are captured at this level . The two domains we consider are the biomedical domain and questions for a QA system . We use the term " domain " somewhat loosely here , since questions are best described as a particular set of syntactic constructions , rather than a set of documents about a particular topic . However , we consider question data to be interesting in the context of domain adaptation for the following reasons : 1 ) there are few examples in the Penn Treebank ( PTB ) and so PTB parsers typically perform poorly on them ; 2 ) questions form a fairly homogeneous set with respect to the syntactic constructions employed , and it is an interesting question how easy it is to adapt a parser to such data ; and 3 ) QA is becoming an important example of NLP technology , and question parsing is an important task for QA systems . The CCG parser we use ( Clark and Curran , 2007b ) makes use of three levels of representation : one , a POS tag level based on the fairly coarse-grained POS tags in the Penn Treebank ; two , a lexical category level based on the more fine-grained CCG lexical categories , which are assigned to words by a CCG su-pertagger ; and three , a hierarchical level consisting of CCG derivations . A key idea in this paper , following a pilot study in Clark et al . ( 2004 ) , is to perform manual annotation only at the first two levels . Since the lexical category level consists of sequences of tags , rather than hierarchical derivations , the annotation can be performed relatively quickly . For the biomedical and question domains we manually annotated approximately 1,000 and 2,000 sentences , respectively , with CCG lexical categories . We also created a gold standard set of grammatical relations ( GR ) in the Stanford format ( de Marneffe et al . , 2006 ) , using 500 of the questions . For the biomedical domain we used the BioInfer corpus ( Pyysalo et al . , 2007a ) , an existing gold-standard GR resource also in the Stanford format . We evaluated the parser on both lexical category assignment and recovery of GRs . The results show that the domain adaptation approach used here is successful in two very different domains , achieving parsing accuracy comparable to state-of-the-art accuracy for newspaper text . The results also show , however , that the two domains have different profiles with regard to the levels of representation used by the parser . We find that simply retraining the POS tagger used by the parser leads to a large improvement in performance for the biomedical domain , and that retraining the CCG supertagger on the annotated biomedical data improves the performance further . For the question data , retraining just the POS tagger also improves parser performance , but retraining the supertagger has a much greater effect . We perform some analysis of the two datasets in order to explain the different behaviours with regard to porting the CCG parser . We have targeted lower levels of representation in order to adapt a lexicalized-grammar parser to two new domains , biomedical text and questions . Although each of the lower levels has been targeted independently in previous work , this is the first study that examines both levels together to determine how they affect parsing accuracy . We achieved an accuracy on grammatical relations in the same range as that of the original parser for newspaper text , without requiring costly annotation of full parse trees . Both biomedical and question data are domains in which there is an immediate need for accurate parsing . The question dataset is in some ways an extreme example for domain adaptation , since the sentences are syntactically uniform ; on the other hand , it is of interest as a set of constructions where the parser initially performed poorly , and is a realistic parsing challenge in the context of QA systems . Interestingly , although an increase in accuracy at each stage of the pipeline did yield an increase at the following stage , these increases were not uniform across the two domains . The new POS tagger model was responsible for most of the improvement in parsing for the biomedical domain , while the new supertagger model was necessary to see a large improvement in the question domain . We attribute this to the fact that question syntax is significantly different from newspaper syntax . We expect these considerations to apply to any lexicalized-grammar parser . Of course , it would be useful to have a way of predicting which level of annotation would be most effective for adapting to a new domain before the annotation begins . The utility of measures such as unknown word rate ( which can be performed with unlabelled data ) and unknown POS n-gram rate ( which can be performed with only POS tags ) is not yet sufficiently clear to rely on them as predictive measures , but it seems a fruitful avenue for future work to investigate the importance of such measures for parser domain adaptation .

Most existing parsers are tuned for newspaper texts making them limited in applicable domains.

They propose a method to adapt a CCG parser to new domains using manually-annotated data only at POS and lexical category levels.

The proposed method achieves comparable results to in-domain parsers without expensive full annotations on biomedical texts and questions that are rare in existing benchmark datasets.