TAAI2015
Tainan, Taiwan
Nov. 20-22, 2015
Deep generation of metaphors Andrew Gargett * Simon Millet and John Barnden+ *School of Computer Science University of Birmingham Birmingham United Kingdom Email: A
[email protected] tNatural Language Processing Group Pompeu Fabra University Barcelona Spain Email:
[email protected] +School of Computer Science University of Birmingham Birmingham United Kingdom Email: J.A
[email protected] ,
Abstract-We report here on progress toward a pipeline for the deep generation of metaphorical expressions in natural lan guage. Our approach uses a combination of artificial intelligence and deep natural language generation. Metaphor is ubiquitous in forms of everyday discourse [1], [2], such as ordinary conversa tion, news articles, popular novels, advertisements, etc. Metaphor is an important resource for clearly and economically conveying ideas of prime human interest, such as relationships, money, disease, states of mind, passage of time. Since most Artificial Intelligence (AI) research has been about understanding rather than generating metaphorical language, such ubiquity presents a challenge to those working toward improving the ways in which AI systems understand inter-human discourse (e.g. newspaper ar ticles, etc), or produce more natural-seeming language. Recently, there has been a renewed interest in generation, but accounts of metaphor understanding are still relatively more advanced. To redress the balance towards generation of metaphor, we directly tackle the role of AI systems in communication, uniquely combining this with corpus linguistics, deep generation and other natural language processing techniques, in order to guide output toward more natural forms of expression.
I.
INTRODUCTION
This paper reports on progress toward a computer system for automatically generating metaphor in natural language, using a unique assemblage of tools from artificial intelligence (A I), corpus linguistics, deep natural language generation (NLG), and other areas of natural language processing (NLP). The resulting pipeline provides an NLG front-end for a state of-the-art metaphor processing A I framework, ATT-Meta [3]. Further, the deep NLG system we are using has previously produced state-of-the-art results [4], and this paper reports on our recent efforts to use this system for the novel task of generating metaphorical language. While still at the prototype stage, our approach aims to coordinate in modular fashion the interaction between existing frameworks; this paper details our approach, and reports our progress in integrating these frameworks into the overall system.
978-1-4673-9606-6/15/$31.00 ©2015 IEEE
336
II.
GENERATING METAPHOR
A. Overview of Natural Language Generation (NLG)
Natural Language Generation (NLG) is the study of the use of computational techniques for adequately generating strings of natural language, and a key task of NLG is choosing not only what to say when producing a natural language utterance, but also how to say it. NLG tasks typically range from deciding the basic content of the utterance ("what"), through to determining how to resolve forms of reference, plan discourse structure, and realise appropriate words and their combinations [5]. B. Data-driven approaches to modelling metaphor
Our attempts to develop a corpus-driven approach to mod elling metaphor are heavily influenced by a range of previous data-oriented accounts, such as [6], who aims to determine taxonomies directly from the corpora concerned, as well as [2], who illuminates the role of metaphor in "tuning" linguistic contributions during reconciliation talks between and victims (within the context of acts of terrorism), for example, how a victim increases the impact of their contribution during mediated discussion with an offender, by employing metaphor in an extended description of the effect on their personal lives of the offender's actions. Such corpus-based studies have inspired our own attempts to incorporate actual patterns of use of metaphors in the expressions our system generates. Within metaphor generation, substantial work is emerging which is based on modelling patterns of actual metaphor usage from corpora, and employing data-intensive methods, for example, [7] and [8]. The example of [7] is instructive, as it also suggests how web-based data can be exploited to improve NLG systems, which is another thread within our own work. [7] formulated a system which is able to mine the world-wide web in order to process and generate "apt" metaphors, employing the grammatical markedness of
TAAI2015
Tainan, Taiwan
relatively simple similes, such as T[enor] is as P[roperty] as [a] V[ehicle], to extract information about the target and sources involved (e.g. that P is both a salient aspect of T, is shared by both T and V, etc). Their system, Sardonicus, is thereby furnished with a large set of cases from which it can generate metaphorical expressions which are deemed apt, perhaps due to their relatively high frequency of occurrence. One consequence of this approach is that finding a vehicle for a term like graceful is potentially an open-ended task (e.g. as a swan ?, as an elephant ?), exploding the search space for choosing the most apt metaphor. With the help of a user, the search procedure is directed toward a goal, whereby the user specifies a tenor as well as a property to be focused on e.g. for tenor Paris Hilton referring to a recent celebrity, the user can direct Sardonicus to generate apt metaphors focusing on the property skinny, with Sardonicus evaluating a range of possible vehicle nouns (e.g. twig, pole, rake, cadaver). [7] report possible metaphors that are returned through this method include (presented in Sardonicus format, bracketted numbers are counts): post(46), pole(42), stick(38), miser(34), stick insect(26) In turn, these can be analysed with respect to their properties: straight(387), skinny(369), thin(353), slim(204), stiff(20), scrawny(8) It is important to note that while Sardonicus has no knowl edge of Paris Hilton, since it is basically a purely data-intensive approach, lacking more sophisticated reasoning capacities, [7] point out that Sardonicus can be supplied with additional resources to make up for this limitation (e.g. hypotheses derived from collocational analysis of large corpora, and so working out the meaning of some lexical item based on the company it keeps). C.
Inferential approaches to modelling metaphor
Past approaches to metaphor generation based on rule- or constraint-based methods include [9], [lO], [11], [12] and [13]. We have chosen to compare two exemplary approaches. 1) MIDAS: The MIDAS system proposed by [lO] had the capacity to both understand and generate metaphors in the narrow domain of the operating system UNIX, e.g.:
(a) (b) (c)
How can I get into mail? How can I get out of emacs? How can I kill a file?
Each of the verbs get into, get out of and kill are deemed metaphorical, since there is no literal reading of these verbs which can render a sensible contextual meaning. For example, killing a file here cannot mean, directly, ending the life of something that is alive, but it can mean, less directly, ending a computer process, and even deleting some item of information stored on a computer. A s pointed out by [10], such forms of metaphorical expression are frequently conventional, which is in line with claims by metaphor theorists that a significant aspect of the meanings of such phenomena is that they reflect larger conceptual classes of which they are members; 337
Nov. 20-22, 2015
other well-known examples include A rgument-Is-War, Time Is-Money, and the like (see [1]). MIDAS actually models this aspect of metaphorical meaning quite directly, storing such conventional metaphors in its lexicon; as such, MIDAS is an exemplar of a long line of knowledge-rich approaches to metaphor processing, which typically approach the under standing of a particular (conventional) metaphor as largely a matter of being able to access the entry for that metaphor in a large-scale store of such knowledge. Interestingly, MIDAS is apparently over-specialised to the domain, incorporating conventional metaphors like Is-A t-Variable-Value, which may have been "added to MIDAS especially for interpreting partic ular sentences" [14]. Yet, the coverage of MIDAS is certainly impressive, and since MIDAS, there have been few knowledge rich approaches that have achieved a substantially greater coverage. Here, as elsewhere in NLG, how to model content adequately has been the chief obstacle to progress. 2) A1T-Meta: Our approach to metaphor employs Barn den's ATT-Meta system, a state-of-the-art AI system for mod elling metaphor as reasoning-by-simulation [3], whereby those aspects of a metaphorical expression, like How do I get out of emacs ?, which are clearly not about reality, on a par with How do I get out of this house ?, are dealt with in a distinct mental space, a so-called metaphorical pretence cocoon, wherein reasoning about such propositions and inferences can be kept separate from propositions and reasoning about reality.
While ATT-Meta has until now been used for metaphor understanding, it turns out to be fairly straightforward to extend it to generation, due to a novel feature of the system, namely its ability to transfer information from target-to-source, as well as in the more usual source-to-target direction. The reversed transfer is held to be crucial for the understanding of some metaphor, but can be adapted also for generation. A s we noted above, while in its day, MIDAS represented an innovation, it was somewhat specialised to the task it was built for, whereas ATT-Meta presents a number of interesting features allowing greater generalization, yet at the same time it retains a certain specificity in its operation which provides a basis for contextualised reasoning. ATT-Meta's reverse use of mappings can readily be de ployed as a part of the process of generating metaphorical utterances, yet we need some way of causing a reverse use to happen, bearing in mind that ATT-Meta works entirely by backward-chaining reasoning, or goal-directed reasoning, a form of reasoning conunonly used in rule-based systems. So we need either to add a forward-chaining capability to ATT Meta (so that, given a reality-space representation, reasoning would step forwards into the pretences space across a map ping), or to emulate such forward chaining by constructing a certain type of rule of the following intuitive form: (Rt)
IF reality situation X corresponds to pretence situation Y, and Y holds THEN can-state(Y).
where X and Y are variables. Here we are helped by a distinctive feature of ATT-Meta mappings, in that they have the form: (R2)
IF guard-condition G holds THEN real-U corresponds to pretend-V.
TAAI2015
Tainan, Taiwan
Thus, rule (R2) would only pick up those mappings whose guard conditions are satisfied. Then crucial to understanding the claim that John has a cold, is presuming a cold to be a physical, and hence possessable, object, permitting only mappings whose guards (antecedents in these conditional rule forms) are satisfied by that presumption. Consider the following examples utterances expressing the metaphorical notion of a cold as a physical thing (including representations of these in ATT-Meta terms): (1) John has a cold -+ the_episode(being_infected, john, coldvirus) (2) John gave Mary a cold -+ the_episode(transfer, john, mary, coldvirus) Regarding terminology, "the_episode" refers to an instance of some general event, labelled here as a "being_infected". For generation we focus on the right-hand side of (1) and (2), and assuming someone's cold can be regarded as a physical object, then only those mappings whose guards are satisfied by that condition will be picked up. Moreover, the satisfaction of the guard is relative to specific entities and facts, thereby causing, for example, some very specific instance of a mapping to hold, rather than having this hold of anyone's cold. So, John's having his cold is deemed to correspond to John's physically-possessing his cold (as in (1) above). Thus, rule (Rl), by the very fact of picking up on such specific mappings instances, will already at least partially instantiate Y to that specific situation. Our work on incorporating rules such as (Rl) into our system has revealed significant technical difficulties, resulting from the fact that ATT-Meta has a way of open-endedly generating variants of mappings (see discussion of so-called view neutral mappings in [15]). There is a danger, therefore, that (Rl) would cause prolific over-generation, a problem we will address in future work. III.
GEN-META: COMB INING INFERENTIAL AND
DATA-ORIENTED APPROACHES TO MODELLING METAPHOR
A. Overview
Gen-Meta attempts to explicitly combine inferential and data-oriented modelling of metaphor: chaining together mod ules which are individually validated approaches to modeling language, brings advantages to the resulting system as a whole. We have discussed ATT-Meta above, and the remaining modules are: a) Embodied Construction Grammar (ECG): ECG is an ambitious approach to language understanding, aspects of which are highly congenial to modelling metaphor, and have broad interdisciplinary significance [16]. ECG also has been recently implemented [17]. I However, crucially for our purposes, ECG currently has no model of generation. In ECG, the conceptual level is represented as interconnected schemas. Schemas consist of "roles" together with constraints on these roles. Recalling examples (1) and (2): there is a schema for the concept of somebody realising a transferer role TRANS FERRING something to somebody else realising a transferee role. ECG's schemas are strongly geared towards conceptual I https:llembodiedconstructiongrammar.wordpress.com
338
Nov. 20-22, 2015
representations, and have broadly the same orientation as ATT Meta's representations. ECG represents the linguistic level as interconnected constructions. Constructions will be familiar from work within Cognitive Linguistics [18], for example, the English verb give may employ a ditransitive construction having three constituents, subject, direct object and indirect object (see examples (1) & (2» - ECG formally specifies the ordering constraints operating over such constituents, as well as the linkage between the form and the meaning of the construction. Further, meaning is represented by an external ontology (see [16] for details). Being more flexible than tra ditional grammatical representations, constructions can better model the diversity of expression types, from single words to multi-word expressions (MWEs). Constructions also use fully represent conventional metaphorical form and meaning, with MWEs rather than individual words frequently having metaphorical meanings. b) MARQUIS: For the surface realization module of the Gen-Meta system, we adapt the MARQUIS NLG pipeline [4], which aims to generate text from raw air quality data, such as temperatures, pollutant concentrations, etc., measured by monitoring stations. During the generation process, many tasks are tackled, in particular, content selection, discourse struc turing, sentence planning, lexicalization of meaning-bearing and grammatical units, determination of the sentence structure, word ordering and inflection. MARQUIS performs all these actions step-by-step through successive mappings, using the MATE graph-transduction environment [19]: Document Plan -+ Conceptual Structure -+ Semantic Structure -+ Deep syntactic Structure -+ Surface-syntactic Structure -+ Topolog ical Structure -+ Morphological Structure -+ Surface Structure (for more details, see section IV-A ). B. System details
Schematic overviews of the Gen-Meta system are provided in Figures (1) and (2). Figure (1) is an overview of the understanding system, whereby relevant patterns of metaphor ical expressions are captured. This system essentially provides the means of mining patterns in the various corpora we are employing [20]. In this way, we are able to provide the necessary data to ensure the generation system is able to replicate patterns of usage for metaphorical expressions. In what follows, we focus on the generation side of the overall system. A high-level overview of key aspects of the actual gen eration system is shown in Figure (2). This figure sketches our approach to generation, from content planning through to surface realization (details of the latter are in Section (IV ) below). Presuming a target situation, ATT-Meta logical forms are derived to represent this situation: to get some idea of such forms, recall examples (1) and (2) above. A t this point, the process of reverse mapping, described in Section (II-C2) above, generates source from target representations, thereby deriving logical forms in source domain terms. By way of preparing to interface the AI system with the NLG surface realisation system, we translate the logical forms into representations more familiar from PropBank (PB) [21]. Presuming that the reverse mapping results in the target domain meaning transfer being mapped to the source domain meaning
TAAI2015
Tainan, Taiwan
Nov. 20-22, 2015
logical forms in
larget domain lenns
:" i�idr�;�li��' �b��l' : metaphorical views
ATT-Meta: application of reverse mapping
: is already used : he i s " .. . . . ...
& additional reasoning
�:
logical
�!����� �
(target-lo-source)
.....----1
forms
logical forms in
source domain tenns
additional knowledge about entities, situations, etc,
relevant (0 the discourse
ATT·Meta output filtering:
ECG semantic schemas
ECG processing, e.g. refinement of schemas, suggestion of constructions
checking to see output
corpus-derived knowledge
to this point has
of conventional metaphorical
adequate meaning
phraseology
in context
- "'" '"" sentences model "" 0[' discourse
Fig. 1: Schematic of Gen-Meta system: Understanding (stages in system development shown in single-lined boxes, output in double-lined box, selected arrows are labeled with material being piped from one stage to next)
give, example (3) outlines how information from the ATT-Meta logical form can be used to search PB, in order to try to match possible PB entries, e.g., by deriving possible predicate and associated arguments induced from the ATT-Meta logical form (this example is rather schematic, and for further details about such information, see Section (IV-B) below).
Fig. 2: Schematic of Gen-Meta system: Generation (stages in system development shown in solid single-lined boxes, output in double-lined box, dashed-lined boxes contain additional notes about a particular stage, selected arrows are labeled with material being piped from one stage to next). Note also that PB = PropBank.
IV.
SURFACE REALIZATION
A. Theoretical framework for NLG
(3) the_episode(give, john, mary, coldvirus) -+ ( give.Ol, AO=john, Al=coldvirus, A2=mary ) Once there is a match with a PB entry, information from both the ATT-Meta logical form and the PB entry is combined to construct Conll-style graphs [22] as inputs to the realisation system; for instance, the structure of such a graph for example (3) is represented in Figure (4) (in Section (IV-B) below). If there is no match, i.e. if the logical form in question finds no equivalent PB entry, the system employs a template to generate a suitable representation on-the-fiy.2 Moreover, given that the system knows the source-to-target domain mapping being performed, and that we have access to information about the typical phraseology used for specific metaphorical mappings from our corpus studies, then at this point the system can potentially add information about such preferred phraseology, to be passed on to the realisation engine; we are currently investigating ways of implementing this within the pipeline. Finally, we should point out an additional feature of the system, demonstrating the richness of our approach, is that the A I system is able to check the contextual adequacy of the meaning of the final output to be delivered to the realizer; an implementation of this additional feature is also currently being planned. 2Developing ways of better dealing with such gaps in key resources within our pipeline is currently a key area of development for our overall approach.
339
The theoretical framework underlying our the surface re alization module in our system is the Meaning-Text Theory (MIT, [23]). The MTT model supports fine-grained annota tion at the three main levels of the linguistic description of written language: semantics, syntax and morphology, while facilitating a coherent transition between them via intermediate levels of deep-syntax and deep-morphology; such a smooth transition is especially relevant to NLG since deep NLG is this paper is seen as a sequence of mappings between an abstract representation and a text (see Section IV-C). In total, thus five strata are foreseen. A t each stratum, a clearly defined type of linguistic phenomena is described in terms of distinct dependency structures. Semantic Structures (SemSs) are predicate-argument struc tures in which the relations between predicates and their arguments are numbered in accordance with the order of the arguments. Deep-syntactic structures (DSyntSs) are dependency trees, with the nodes labeled by meaningful ("deep") lexical units (LUs) and the edges by actant relations I, II, Ill, ... , VI (in accordance with the syntactic valency pattern of the governing LU) or one of the following three circumstantial relations: AITR(ibutive), COORD(inative), APPEND(itive). Surface-Syntactic Structures (SSyntSs) are dependency trees in which the nodes are labeled by open or closed class lexemes and the edges by grammatical function relations of the type subject, oblique_object, adverbial, modifier, etc.
TAAI2015
Tainan, Taiwan
Nov. 20-22, 2015
Deep-Morphological Structures (DMorphSs) are chains of lexemes in their base form (with inflectional and PoS features being associated to them in terms of attribute-feature pairs) be tween which a precedence relation ('b(efore)' in our examples) is defined and which are grouped in terms of constituents. Surface-Morphological Structures (SMorphSs) are chains of inflected word forms, i.e., sentences as they appear in the corpus, except that orthographic contractions still did not take place.
Document plan
onceptualizatloo
- l lUlgu age-independe llt conceptual - cone.ept aggregarion
The MARQUIS generator, which we use as a starting point for our surface realization module, is based on the Meaning Text Theory; its general architecture is shown in Figure 3
Conceptual Ser.
B. Overview and starting point
Semantle1zation - IIUIpping to hll1gu4\gc.-dcl/Cndcnt mCllning1l
In Gen-Meta, the generation of metaphorical expressions takes place at an abstract level: the previous modules output a graph in which meaning-bearing units (nodes) are connected through predicate-argument relations according to the Prop Bank terminology [21]. In other words, in the input to surface realization module, content selection, discourse structuring, sentence planning and most lexicalization of meaning-bearing have already taken place. Figure (4) shows such a structure, together with the features associated to each node: the predi cate give.OJ has three arguments labeled AD, AJ, A2, and one "adjunct-like" argument AM ; John and Mary are specified as named entities, while coldvirus is not, and give.OJ is specified with respect to its tense (past), its aspect (neutral) and its force (declarative).
., - communicative organization
� Semanlic Str.
Deep . yntllxii:izlItio - mapping of semantic str.to
•
Snrface synta:ddzalioll
•
•
C.
- gramJtlllllcal ,
Unlike in MARQUIS, in which the edges are labeled with classic argument numbers (l, 2, 3, etc.), in Gen Meta the edge labels are the ones used in the PropBank annotation, which number the arguments starting from AD or from AJ depending on if the predicate is considered to have an external argument or not. In MARQUIS, a communicative structure is superim posed on the semantic structure, which constrains how the sentence will be realized, in particular through the theme/rheme oppositions (see [24]).
System details
The surface realization system is implemented as a se quence of graph transduction grammars that work together 340
- rough
words de!l;:nn.
sentence structure del. Surfac:e-syntaUk Str.
Unlike in MARQUIS, most concepts are already lex icalized at the semantic level; only more complex concepts do not have their definitive lemmatized form at this stage (e.g., coldvirus, which is usually realized as cold). The words are not connected to lexical resources used in MARQUIS: at this point, there is no information about the part-of-speech of words, or about how they combine together (does give require a preposition on one of its dependents? if yes which one? and under which conditions?).
deep-syntactic str.
�ep-synl.actic SIr.
The surface realization pipeline starts at a level which corresponds to the Semantic Structure used in MARQUIS (see Figure 3). However, there are some important differences with this structure, which constrain the way the generator has to be adapted: •
structure constr.
- reference structure innod.
LiDeari:l.arioll
- word order dei.ermi nati on -agreement - Stlrface punctuatiOIl
y �
0
Topological SIr.
Morpbologizotion
- insertion of inflectional
info['fIl.
Ie> I Morphological Slr. Tn�etio'n - fin.al form of me lI"ords - contraction and elision
Fig. 3: The MARQUIS system architecture (adapted from [4, p.938])
TAAI2015
yesterday
Tainan, Taiwan
Nov. 20-22, 2015
yesterday.O1
give.Ol
John
pos=RB
tense=PAST
NE=YES
NE=NO
NE=YES
force=DECL
force=DECL
pos=NN
pos=NN
pos=NN
aspect=NEUT
aspect=NEUT
give.Ol
John
tense=PAST
NE=YES
coldvirus Mary NE=NO
NE=YES
coldvirus.Ol Mary
pos=VB
Fig. 4: A sample input to surface realization: John gave a cold to Mary yesterday
with lexical resources (dictionaries). In this section we briefly describe these two kinds of resources. J) Lexicon: The most important lexical resource is the lexicon, which contains information information about the words and their combinatorial properties. We have to ensure that the vocabulary to be generated is covered by the lexicon; Figure (5) shows the lexicon entry for give.OJ
Like in any dictionary, each entry of the lexicon must be unique, which is why the keys are the combination of lemma, part-of-speech, and sense ID. Figure (5) shows that the predicate give.OJ is a verb, that its sense ID according to PropBank is OJ, that its lemma is give, that it has three arguments AD, AJ and A2, which map to the deep-syntactic relations I, II, and III respectively, and that when its third argument is realized, it need the preposition to by default (see [25] for one way of obtaining automatically such a resource). 2) Grammars: With respect to the grammars, given the differences between Figure (4) and the input expected by the generator, a pre-processing stage is necessary and the Semantic Structure -7 Deep-Syntactic Structure transduction has to be reimplemented. The pre-processing grammar aims at tagging the nodes with part-of-speech (PoS) in order to connect them to their corresponding lexical entry. For this, rules check whether a node with its sense ID is found in the lexicon, and if several PoS candidates are found, other rules perform a basic disambiguation. The rules also assign a default sense ID (OJ) for the non-named entity words that are not disambiguated. Figure (6) shows the output of the pre-processing stage.
Fig. 6: A sample PoS tagged semantic structure
structure onto a deep-syntactic structure. The main differences between the two types of representation are that (i) the former can be a graph, while the latter cannot (it must be a tree), and (ii) the set of edge labels neutralizes the difference between "external" and "non-external" arguments (see [26] for more details about this distinction in the PropBank annotation). In other words, this grammar has to identify the root in the semantic graph and map the edge labels to the MARQUIS nomenclature, while normalizing the argument numbers thanks to the mappings provided in the lexicon. In Figure (7), which shows the deep-syntactic structure corresponding to the input in Figure (4), finding the root is not a big issue, since there is only one verb, but in the case of sentences with more than one verb, the system is able to decide which verb is the main one and which verb(s) is (are) embedded (e.g., John gave Mary a cold that he caught yesterday). However, since most words have already been chosen in the previous steps, the lexicalization process is reduced to its simplest expression: a concept like coldvirus is simply associ ated to a surface form cold, which is used as a substitute. The semantic-deep-syntax mapping also ensures that all needed features have a value at this stage; for example, if the tense is missing, present is chosen as default, and if the definiteness of a noun is not defined, as is the case with cold, it is set by default to indefinite. From the structure in Figure (7), the same pipeline as in the MARQUIS system can be applied. First, the functional elements (auxiliaries, required prepositions, determiners) are
The next step is to map this PropBank-like semantic
"give_V B_Ol" { pos : "V B" pbsenseID : "0l" lemma : "give" gp : { A O: {rel:I} A l:{rel:II} A 2:{rel:III, prep:"to"} } }
yesterday
give
John
cold
Mary
pos=RB
tense=PAST
NE=YES
NE=NO
NE=YES
force=DECL
pos=NN
pos=NN
pos=NN
aspect=NEUT
def=INDEF
pos=VB
Fig. 7: Deep-syntactic structure obtained from Figure (6)
Fig. 5: A sample lexicon entry for give
341
TAAI2015
Tainan, Taiwan
Nov. 20-22, 2015
__--------� EXT �------�
� f\ � ,----,. r->t � John
give
a
cold
to Mary yesterday
tense=PAST num=SG num=SG mood=IND
� yesterday pos=RB
give
rMOD� John
cold
pers=3
tMOD\
a
Mary
num=SG
to
tense=PAST NE=YES NE=NO pos=DT NE=YES pos=IN force=DECL pos=NN pos=VB
pers=3
mood=IND
num=SG
pos=NN
pos=NN
num=SG
num=SG
Fig. 10: Topological structure obtained from Figure (8)
Fig. 8: Surface-syntactic structure obtained from Figure (7)
introduced in the tree, the labels are mapped to the surface syntactic dependency relations, and morphological information about the lexical units, such as person or gender, is retrieved in the lexicon (see Figure (8)). The system also allows for generating alternative realizations, for example in the case of dative shift: give someone something, as opposed to give something to someone. In a general manner, if a metaphorical use of a verb prefers one realization over another one, we can encode this information in the lexicon in order to control better the application of the rules. The nodes are then ordered and the morphological features are percolated among the elements of the tree (see Figure (10)). For the implementation of the linearization module, there are two types of rules: (i) the rules that order a dependent with respect to its governor, and (ii) the rules that order siblings with respect to one another. The subject (SBJ), for instance, is typically realized before the governing verb, and before all its siblings in a neutral sentence, except for relative pronouns, which are always before the clause they introduce. Figure (9) is a screen shot of a linearization rule of type (ii) as seen in the graph transduction environment. The graph transduction rule in Figure (9) maps a part on the input graph with the left side; in this case, it looks for three nodes ?XI (which is a verb), ?YI and ?Zl, for which a relation SBJ links the first two nodes, and an undefined relation ?r links ?XI and ?Zl, for which there is a special condition that
Right side
left side
:?XI {
rc:?Yr
{
c:pos = 'VB"
rc: ?YI
c:SBJ-> c:?YI {}
'rc:bubble
c:?r-> c:?ZI {}
'rc:- rc:?Zr {rc:< = > ?ZI}
yes
=
- rc:?Zr {
==
relative_pronoun
· rc:bubble
=
Morphological agreement is also performed with respect to the surface-syntactic structure: for instance, the subject passes its person and number to its governing verb, while the noun passes its number to its determiner. In the final stage, the final form of the words with all their morphological information is generated, with two-level morphology automata or morphological dictionaries. The output of the generation process described in this section is John gave a cold to Mary yesterday. If there were more information in the input semantic structure, the output would be different. For instance, in the case of the cold being possessed by John, the output would be John gave his cold to Mary yesterday; if Mary was the possessor, it would be John gave her cold to Mary yesterday.3 V.
CONCLUSION
By combining A I techniques for producing metaphorical meanings, with corpus-based approaches for identifying con ventionalised forms of metaphorical expressions, and finally techniques for deep generation of natural language, Gen-Meta has a number of advantages over existing approaches. First, Gen-Meta utilises deep AI reasoning to increase flexibility in generating underlying content. Further, the data-driven aspects of our approach enables a more flexible approach to capturing the conventionality of much metaphorical language. Finally, by linking our content generation to an existing, and successful approach to deep NLG, we are able to take advantage of a sophisticated and powerful approach to realising surface patterns. For future work, we will explore ways of better controlling the conventionality of the surface forms of expressing specific metaphors, based on corpus studies: so that, given a specific
rc: ?ZI '?ZI.spos
indicates that this node cannot be a relative pronoun. This left side makes three matches on the structure in Figure (8): in the three cases ?XI and ?YI are respectively give and John, and ?Zl is once yesterday, once cold, and once to. The right side describes, on the one hand, a context (elements preceded by rc:), and, on the other hand, what action(s) to perform. The right side in Figure (9) looks for two nodes ?Yr and ?Zr that correspond to ?YI and ?YI respectively, and that have already been built by another rule (rc: means 'right context'). The rule establishes a precedence relation between the subject and its three siblings (precedence is indicated by the tilde symbol).
yes
}
3 Interestingly, the system is able to handle both anaphoric as well as cataphoric reference, and we will be exploring its capacity to generate these and other discourse-level phenomena in future work.
Fig. 9: A sample linearization rule
342
TAAI2015
Tainan, Taiwan
metaphorical mapping between source and target domains, we will have the option of trying to realise the preferred, conventional wording for this mapping. A t the same time, it should be pointed out that we are not tied to conventional metaphorical mappings, given the involvement of an A I system with deep reasoning capacity, and we also have plans to investigate ways of generating novel metaphorical mappings where possible. Finally, a well-known problem with rule-based generation is the coverage provided by the grammars; for further experiments, surface realization from deep-syntactic structure can be performed with an existing off the shelf statistical generator [27]. ACKNOW LEDGMENT
The authors would like to thank Leo Wanner, A licia Burga and Roberto Carlini for their support with the surface realization pipeline. We also acknowledge financial support for parts of this work through a Marie Curie International Incoming Fellowship (project 330569) (awarded to: A .G. as fellow, J.B. as P.L).
Nov. 20-22, 2015
[13]
R. Hervas, R. P. Costa, H. Costa, P. Gervas, and F. C. Pereira, "Enrich ment of automatically generated texts using metaphor," in MiCAI 2007: Advances in Artificial Intelligence, ser. Lecture Notes in Computer Science, A. Gelbukh and A. Kuri Morales, Eds. Springer Berlin Heidelberg, 2007, vol. 4827, pp. 944-954.
[14]
D. Fass, "Review of "A computational model of metaphor interpreta tion" by James H. Martin. Academic Press 1990." Comput. Linguist., vol. 17, no. I, pp. 106-110, Mar. 1991.
[IS]
J. A. Barnden, "Metaphor and artificial intelligence: Why they matter to each other," in The Cambridge Handbook of Metaphor and Thought, ser. Cambridge Handbooks in Psychology, R. Gibbs, Ed. Cambridge: Cambridge University Press, 2008, pp. 311-338.
[16]
J. Feldman, "Embodied language, best-fit analysis, and formal compo sitionality," Physics of Life Reviews, vol. 7, no. 4, pp. 385-410, 2010.
[17]
J. E. Bryant, "Best-fit constructional analysis," Ph.D. dissertation, EECS Department, University of California, Berkeley, Aug 2008.
[18]
W. Croft and D. A. Cruse, Cognitive Linguistics, ser. Cambridge Textbooks in Linguistics. Cambridge University Press, 2004.
[19]
B. Bohnet, A. Langjahr, and L. Wanner, "A development environment for an MTT-based sentence generator."
[20]
A. Gargett and J. Barnden, "Modeling the interaction between sensory and affective meanings for detecting metaphor," NAACL HLT 2015, p. 21, 2015.
[21]
M. Palmer, P. Kingsbury, and D. Gildea, "The Proposition Bank: An annotated corpus of semantic roles," Computational Linguistics, vol. 31, pp. 71-105, 2005.
[22]
J. Hajic, M. Ciaramita, R. Johansson, D. Kawahara, M. A. Marti, L. Marquez, A. Meyers, J. Nivre, S. Pad6, J. Stepanek, P. Straiiak, M. Surdeanu, N. Xue, and Y. Zhang, in Proceedings of the 13th
REFERENCES [1] [2]
G. Lakoff and M. Johnson, Metaphors We Live By. Chicago, 1980.
L. Cameron, "Metaphor and talk," in The Cambridge Handbook of
Metaphor and Thought, ser. Cambridge Handbooks in Psychology,
R. Gibbs, Ed. 197-211. [3]
[4]
University of
L. Wanner, B. Bohnet, N. Bouayad-Agha, F. Lareau, and D. NickJaB, "MARQUIS: Generation of user-tailored multilingual air quality bul letins," Applied Artificial Intelligence, vol. 24, no. 10, pp. 914-952, 2010. R. Dale and E. Reiter, Building natural language generation systems. Cambridge, UK: Cambridge University Press, 2000.
[6]
A. Deignan, "Corpus linguistics and metaphor," in The Cambridge Handbook of Metaphor and Thought, ser. Cambridge Handbooks in Psychology, R. Gibbs, Ed. Cambridge: Cambridge University Press, 2008, pp. 280-294. T. Veale and Y. Hao, "Comprehending and generating apt metaphors: a web-driven, case-based approach to figurative language," in Proceedings of the 22nd national conference on Artificial intelligence - Volume 2,
ser. AAAl'07. [8]
[9]
AAAI Press, 2007, pp. 1471-1476.
A. Terai and M. Nakagawa, "A neural network model of metaphor generation with dynamic interaction," in Proceedings of the i9th international Conference on Artificial Neural Networks: Part I, ser. ICANN 09. Berlin, Heidelberg: Springer-Verlag, 2009, pp. 779-788.
P. S. Jacobs, "Knowledge-intensive natural language generation," Arti
jicial Intelligence, vol. 33, no. 3, pp. 325-378, 1987.
[10]
J. H. Martin, "A computational theory of metaphor," University of California at Berkeley, Berkeley, CA, USA, Tech. Rep., 1988.
[11]
M. A. Jones, "Generating a specific class of metaphors," in Proceed ings of the 30th annual meeting on Association for Computational
Linguistics, ser. ACL '92. Stroudsburg, PA, USA: Association for Computational Linguistics, 1992, pp. 321-323.
[12]
Shared Task.
[23]
J. A. Barnden, "Metaphor and context: A perspective from articial intelligence," in Metaphor and Discourse, A. Musolff and J. Zinken, Eds. Pal grave Macmillan, 2009, pp. 79-94.
[5]
[7]
Conference on Computational Natural Language Learning (CoNLL):
Cambridge: Cambridge University Press, 2008, pp.
C. Su and C. Zhou, "Constraints for automated generating chinese metaphors," in Proceedings of the Third International Conference on Information Technology and Applications (ICITA'05) Volume 2 - Volume 02, ser. ICITA '05. 2005, pp. 367-370.
Washington, DC, USA: IEEE Computer Society,
343
[24]
l. Mel'cuk, Dependency Syntax: Theory and Practice. University of New York Press, 1988. ,
--
Communicative
Organization
in
Natural
Semantic-Communicative Structure of Sentences.
Benjamins, 2001.
Albany: State
Language:
The
Philadelphia: John
[25]
S. Mille and L. Wanner, "Towards large-coverage detailed lexical resources for data-to-text generation," in Proceedings of the First In ternational Workshop on Data-to-text Generation, Edinburgh, Scotland, 2015.
[26]
O. Babko-Malaya, Propbank Annotation Guidelines, 2005. [Online]. Available: http://verbs.colorado.edu/�mpalmer/projects/ace/ PBguidelines.pdf
[27]
M. Ballesteros, B. Bohnet, S. Mille, and L. Wanner, "Data-driven sentence generation with non-isomorphic trees," in Proceedings of the
the
2015
Association
Conference for
of
the
Computational
North
American
Linguistics:
Chapter
Human
of
Language
Technologies. Denver, Colorado: Association for Computational Linguistics, May-June 2015, pp. 387-397. [Online]. Available: http://www.ac1web.orgianthology/NI5-1042