This content was uploaded by our users and we assume good faith they have the permission to share this book. If you own the copyright to this book and it is wrongfully on our website, we offer a simple DMCA procedure to remove your content from our site. Start by pressing the button below!
ng1
Building Consistent Dictionary Definitions
3
299
Parsing Syntactic Structures of Dictionary Definitions ˇ (in Czech – SSJC)
The frequencies of the different definition types is shown in Table 1. Basic tables show the main types of the syntactic patterns found within the noun dictionary ˇ When we tried to extent the recall of the parser rules the time definitions in SSJC. necessary for the analysis has increased enormously since the mechanism of the partial analysis is obviously not suitable for the exhaustive parsing. (Processing approx. 3700 entries took about 3 days.) Table 1. Frequencies of the different deffinition types. 1st file 2nd file # entries 3672 5935 not processed (%) 21.0 20.3 processed (%) 79.0 79.7 from processed: def1 (%) 13.0 11.6 def2 (%) 62.7 63.2 def3 (%) 18.0 18.5 def4 (%) 2.3 2.0 def5 (%) 0.1 0.1 def6 (%) 3.4 4.2 def7 (%) 0.4 0.4
syntactic structure
E E E E E E E
= = = = = = =
one-word-synonym ( Ng | Pg )+ ( Ng | Pg )+ Ap ( Ng | Pg )+ Ng Sr ( Ng | Pg )+ Ap ( Ng | Pg )+ Sr [kdo|co|nˇ ekdo|nˇ eco] .* [schopnost|neschopnost] .*
E in the examples of syntactic structures stands for the defined word (it is simple nominal group) in the definition. Ng can represent both simple nominal groups but also quite complicated recursive nominal groups (including the groups with coordination and genitive groups). Pg represents prepositional noun and pronoun groups (usually we use separate nonterminals Png and Ppg). Standard conventions of context-free syntax are used: (+ sign represents one or more repetition, * represents zero or more repetition, | stays for alternative etc.). It can be observed that the type of definition labelled def5 is not very frequent, but the question is whether the definitions of this type can be classified under def4/def3, ev. to which category they belong. def6 a def7 represent very specific types of the definitions established only on the base of the specific key word like kdo (who) that do not belong into any of the previous category. It can be said the definitions of the entries for whose no structure has been found usually can be intuitively classified as belonging to some of the groups 1-5. However, they display very complicated structures (e.g. very complicated attributive noun groups), that prevent the parser (the particular rules in it) from recognizing them. There are only few entries that do not belong into any of the introduced groups/categories, for example n´ azor, ˇze. . . (the opinion that. . . ). The examples of the analyses of the individual definitions is given in Table 2. Angle brackets mark out the particular groups forming definition body. Labels
300
K. Pala and E. Mr´ akov´ a Table 2. Examples of the different definition types. type def1 def2 def3
def4
def5
def6 def7
example (literal translation) droˇ zd´ı =
used here are more specific then the ones used in the formal desriptions of the particular definitions (but it is easy to transform them to the respective general form). If we examine the relations between syntactic and semantic structures of several selected definitions for the nouns like pˇr´ıstroj (apparatus), zaˇr´ızen´ı (device), stroj (machine) or nauka (doctrine) and obor (discipline) we can observe that the meaning of the nouns determines closely their valency frames which then decide about the syntactic structure of the definition. It can be also observed that the semantic nature of the headword also determines the meaning of genus proximum – e.g. in the case of amp´ermetr (ammeter) it has to be obviously apparatus which is further determined by the distinguishers describing the purpose of the apparatus – that it is designed for measuring, recording, determining, displaying etc. If our goal is to be able to process the dictionary definitions formally (algorithmically), then we have to deal with their valency frames as it can be demonstrated for the noun pˇr´ıstroj: valency frames for pˇr´ıstroj contain the prepositions k (to) with dative, na (on) with accusative, pro (for) with accusative. Apart from this noun pˇr´ıstroj can co-occur with a relative sentence and with verbal adjectives like mˇeˇr´ıc´ı (measuring), zapisuj´ıc´ı, zaznamen´ avaj´ıc´ı (recording), urˇcuj´ıc´ı (determining) etc. Some examples of typical beginnings of definitions with the keyword pˇr´ıstroj (apparatus) and their formal structures follow.
Building Consistent Dictionary Definitions
pˇr´ıstroj k mˇeˇren´ı <ˇceho> pˇr´ıstroj na mˇeˇren´ı <ˇceho> pˇr´ıstroj pro studium pˇr´ıstroj, j´ımˇz, kter´ ym, kter´ y pˇr´ıstroj zapisuj´ıc´ı zmˇeny pˇr´ıstroj ukazuj´ıc´ı zmˇeny pˇr´ıstroj mˇeˇr´ıc´ı kmitoˇcet pˇr´ıstroj ud´ avaj´ıc´ı rychlost pˇr´ıstroj urˇcuj´ıc´ı, kdy
301
(for measuring) (to measure) (for studying) (that, with what. . . ) (recording changes) (displaying changes) (measuring frequency) (determining speed) (determining when. . . )
As to semantic structure of the dictionary definitions, if we take the parsed syntactic structures of the processed dictionary definitions and extract their head noun groups representing (according to the parser) the GP pattern we obtain a list of expressions that are hyperonyms of the headwords in the dictionary definitions. This result can be regarded as reliable enough, thus in this way confirming our starting assumption that GP patterns can be processed and obtained from the dictionary definitions rather automatically. The next question is in what extent one can try to recognize the semantic structure of the distinguishers and if it can be done in a semi-automatic way. If we have a look at the distinguishers in our examples for apparatus (pˇr´ıstroj) we can see that typically they describe what the particular apparatus does, i.e. the activity of measuring, recording, determining, displaying. . . Thus we need to have a lexical (knowledge) database that knows everything about these devices and also formal means that would allow us to describe what the particular apparatus does, i.e. a set of predicates within an appropriate logical formalism, e.g. transparent intensional logic – TIL (Hor´ ak, 2002) that would allow us to describe the particular activities semantically. In Table 3 we show the same data for the selected items which contains Table 1 for the complete test files of the definition samples. In addition to the percentual representation of the particular definition types are shown also actual numbers of the appropriate examples (first column for every selected word). The meanings of labels used in this table are the following: all – number of definitions with the selected keyword, nonproc – those definitions from the above mentioned which were not processed by the parser, proc – processed definitions (all − nonproc), def1-def4 – numbers (percentages) of the particular definition types. It can be observed that apparatus, device and instrument display very similar distribution of the definition types (also stroj (machine) could be included into this group). This feature could be expected due to the similar meaning of all these words. On the other hand, discipline and doctrine are semantically close as well but their distributions of definition types are quite different. The reason is that valency frames of these wors are different. Definitions with the keyword nauka (discipline) almost always starts with nauka o (def2, doctrine about), whereas obor (discipline) is very often obor zab´yvaj´ıc´ı se <ˇc´ım> (def3, discipline dealing with). Definitition type distributions of nauka (discipline) and ˇcinnost (activity)
302
K. Pala and E. Mr´ akov´ a Table 3. Different deffinition types for the selected items. pˇr´ıstroj zaˇr´ızen´ı (apparatus) (device) all 174 118 nonproc 19 10.9% 19 16.1% proc 155 89.1% 99 83.9% def1 0 0.0% 0 0.0% def2 140 90.3% 88 88.9% def3 8 5.2% 3 3.0% def4 7 4.5% 8 8.1% nauka ˇcinnost (doctrine) (activity) all 85 71 nonproc 11 12.9% 1 1.4% proc 74 87.1% 70 98.6% def1 0 0.0% 0 0.0% def2 72 97.3% 68 97.1% def3 2 2.7% 2 2.9% def4 0 0.0% 0 0.0%
n´ astroj (instrument) 43 5 11.6% 38 88.4% 0 0.0% 32 84.2% 3 7.9% 3 7.9% m´ıstnost (room) 63 8 12.7% 55 87.3% 0 0.0% 48 87.3% 7 12.7% 0 0.0%
obor (discipline) 22 3 13.6% 19 86.4% 1 5.2% 7 36.8% 11 50.0% 0 0.0% stroj (machine) 51 3 5.9% 48 94.1% 1 2.1% 45 93.7% 1 2.1% 1 2.1%
are also similar. These are also semantically close words, but the distribution similarity here follows from the fact that most frequent definition structures of them – nauka o (doctrine about) and ˇcinnost
4
Conclusions
We can conclude that this sort of analysis appears to be useful and helps in testing the noun dictionary definitions for their syntactic and semantic consistency. Its results can be, in our opinion, applied later to semi-automatic preparation of the dictionary definitions thus saving a considerable amount of manual work. Therefore the following steps will be taken in building dictionary definitions (glosses) for the developed Czech WordNet and prepared Czech Lexical Database as well: – to use the different types of definitions for the different parts of speech in a systematic way, i.e. to use scheme GP + d1 , d2 , . . . , dn mostly for nouns, the definitions based on semantic components and troponymy relations for verbs and synonymical explanations combined with collocational examples for adjectives and adverbs, – to use the semantic classification of Czech verbs and integrate it appropriately into the dictionary definitions (glosses),
Building Consistent Dictionary Definitions
303
– to examine in a more detailed way the definitions with GP + d1 , d2 , . . . , dn pattern for nouns and to check whether the distinguishers can be inherited systematically between H/H trees, eventually to explore further how the properties represented by the distinguishers can be related and systematically organized, – to examine whether the distinguishers can also capture the relation of meronymy or holonymy and in the positive case to find out how frequent it is, – to explore more systematically the semantic structure the collocational examples using corpus data and integrate them systematically into the adjective dictionary definitions (glosses), – the ultimate goal of the mentioned steps is to obtain the systematic, formal and consistent dictionary definitions (glosses) for the entries (possibly taking form of synsets) in the Lexical Database and Czech WordNet.
References 1. Balkanet Project, 2001. 2. Buitelaar, P.: Corelex. Systematic Polysemy and Underspecification. Ph.D. Thesis, Computer Science, Brandeis University, 1998. 3. Collins Cobuild English Dictionary, ed. by J. Sinclair. Cobuild. London, Harper Collins Publishers, 1995. 4. Hor´ ak, A.: The Normal Translation Algorithm in Transparent Intensional Logic (for Czech). Ph.D. Thesis, Faculty of Informatics, Brno, March, 2002. 5. Leech, G., N.: Semantics. Harmondsworth, Penguin, 1974. 6. Levin, B.: English Verb Classes and Alternations. The University of Chicago, Chicago Press, Chicago, 1993. 7. Lyons, J.: Semantics. Cambridge University Press, Cambridge, 1977. 8. New Oxford Dictionary of English. edited by P. Hanks. Oxford University Press, Oxford, 1998. 9. Pala, K. and Smrˇz, P.: Slovko, Bratislava, 2001. 10. Pala, K. and Smrˇz, P.: Glosses in WordNet 1.5 and their Standardization, accepted at LREC, 2002. 11. Pustejovsky, J.: The Generative Lexicon, A Bradford Book, MIT Press, Cambridge, 1995. ˇ Dictionary of Written 12. Havr´ anek B. et al.: Slovn´ık spisovn´eho jazyka ˇcesk´eho (SSJC, Czech), Academia, Praha, 1960. 13. Vossen, P.: EuroWordNet 1, 2, Final Report, University of Amsterdam, CD ROM, 1999. ˇ aˇckov´ 14. Z´ a, E.: Partial Parsing (of Czech), Ph.D. Thesis, Masaryk University, Brno, 2002.
Is Shallow Parsing Useful for Unsupervised Learning of Semantic Clusters? Marie-Laure Reinberger and Walter Daelemans CNTS – University of Antwerp – Belgium {reinberg,daelem}@uia.ua.ac.be
Abstract. The context of this paper is the application of unsupervised Machine Learning techniques to building ontology extraction tools for Natural Language Processing. Our method relies on exploiting large amounts of linguistically annotated text, and on linguistic concepts such as selectional restrictions and co-composition. We work with a corpus of medical texts in English. First we apply a shallow parser to the corpus to get subject-verb-object structures. We then extract verb-noun relations, and apply a clustering algorithm to them to build semantic classes of nouns. We have evaluated the adequacy of the clustering method when applied to a syntactically tagged corpus, and the relevance of the semantic content of the resulting clusters. Keywords. Semantics, knowledge representation, machine learning, text mining, ontology, selectional restrictions, co-composition.
1
Introduction
Semantic representations are useful for many natural language processing tasks, including information retrieval, word sense disambiguation, and automatic translation. However, in order to deal adequately with problems such as polysemy, these representations should be sufficiently rich and fine-grained. Today, the use of powerful and robust language processing tools such as shallow parsers allows us to parse large text collections and thereby provide potentially relevant information for extracting semantic knowledge. In order to decide what information is relevant for modeling semantic representations, we need strong linguistic hypotheses to guide the automatic extraction process. In this paper, we present a first step in an attempt to build tools for ontology extraction from scratch, on the basis of specific domain texts. At the same time, we intend to process as much as possible using strictly unsupervised methods on linguistically annotated texts. We will present here in a first section our linguistic assumptions, followed by a description of the syntactic analysis we perform, a description of the semantic information extraction process, and an evaluation of our results. A. Gelbukh (Ed.): CICLing 2003, LNCS 2588, pp. 304–313, 2003. c Springer-Verlag Berlin Heidelberg 2003
Is Shallow Parsing Useful for Unsupervised Learning of Semantic Clusters?
2
305
Linguistic Assumptions
Due to the richness and the diversity of the information that a word may carry, efficient lexical semantic representations should contain a multitude of information of different kinds. In addition to the usual lexical information, these representations should include for example pragmatic information or knowledge of the world that might be useful to cope with problems such as ambiguity. In line with other data-oriented approaches to semantics, we start from the assumption that most of this information is present in plain texts in the way the words are organized and combined together to form complex expressions. The information that allows us to combine the right words together in order to produce meaningful expressions is assumed to be embedded in such texts, contained in the relations between the words of a complex expression. We take a broad perspective on these relations in that we do not restrict them to the hypernym/hyponym and meronymic relations, but that we also focus on information about the functionality of the concepts associated to a word (its uses, capacities etc.) that can be found in the way nouns and verbs, or nouns and adjectives are combined. The main problem lies then in finding a convenient way to get this information and retrieving it in an efficient way. We have chosen to begin this study by focusing on an unsupervised method, in order to gain insight in how far we could get (in terms of amount of and grain-size of the retrieved information) without human expertise. An important assumption underlying our method is the hypothesis that syntax and semantics are not independent in natural language. They are closely related and interconnected, and we will refer here to this assumption as the principle of selectional restrictions: the syntactic structure of an expression provides relevant information about its semantic content. The second hypothesis concerns the notion of co-composition [1]. Co-composition is an operation that occurs in the construction of meaning. If two elements compose an expression, each of them imposes semantic constraints on the other. In our studies, this is applied to the syntactic group noun-verb: the verb imposes restrictions on the noun, but the noun as well constrains the verb. In other words, each word in a noun-verb relation participates in building the meaning of the other word in this context ([2], [3]). Related to these assumptions, we can then define two major tasks: (i) accessing the information, and (ii) organizing the information. Of course those tasks are related as the nature of the information retrieved will in some way influence its future organization. Our purpose is to build a repository of lexical semantic information, ensuring evolvability and adaptability. This repository can be considered as a complex semantic network. We could also label it an ontology, considering that an ontology is a collection of organized knowledge relative to a particular domain. An important point is that we assume that the method of extraction and the organization of this semantic information should depend not only on the available material, but also on the intended use of the knowledge structure. There are different ways of organizing it, depending on its future use and on the specificity of the domain. In this paper, we deal with such a specific
306
M.-L. Reinberger and W. Daelemans
domain, but one of our future objectives is to test our methods and tools on different domains. This brings us to the choice, composition, and annotation of our corpus.
3
Syntactic Analysis
We take a special interest in the compositional aspects of noun-verb relations. In order to provide information about these relations automatically in our corpus, we used the memory-based shallow parser which is being developed in Tilburg and Antwerp [4]1 . This shallow parser takes plain text as input, performs tokenization, POS tagging and phrase boundary detection, and finally finds grammatical relations such as subject-verb and object-verb relations, which are particularly useful for us. The software was developed to be efficient and robust enough to allow shallow parsing of large amounts of text from various domains. In exploratory research, we used the Wall Street Journal corpus, but its vocabulary seemed not specific enough for our method, as we did not get enough occurrences for the different noun-verb pairs, at least for this first set of experiments on which we wanted to test the method. Consequently, we decided to test on texts representing more specific domains, and we used publicly available Medline abstracts, focusing on a particular medical subject. Our corpus is composed of the Medline abstracts retrieved by the Medline search engine under the queries “hepatitis A” and “hepatitis B”. It contains about 4 million words. The shallow parser was used to provide a linguistic analysis of each sentence of this corpus, allowing us to retrieve semantic information of various kinds.
4
Semantic Information Extraction
Our method can be divided into two tasks. In a first step, we have used the syntactic information to perform a clustering of the nouns according to their relations with the verbs of the corpus. The second step will consist in building hierarchical relations between the clustered nouns, and between nouns and verb, making use of the results of the clustering. 4.1
Clustering
Method As was mentioned earlier, the output of the shallow parser allows us to distinguish between noun-verb relations, where the noun appears as a subject in the expression, and noun-verb relations where it appears as an object. This lead us to focus particularly on the relation noun-verb and to use this information to operate a clustering on the nouns according to the verbs they combine with2 . 1 2
See http://ilk.kub.nl for a demo version. With noun, we refer to the head of an NP having a subject or object relation with the verb.
Is Shallow Parsing Useful for Unsupervised Learning of Semantic Clusters?
307
Considering that most words have more than one meaning, we perform a soft clustering, in order to allow a word to belong to different clusters([5]) that represent different uses or meanings for this word. The first step of the algorithm consists of processing the parsed text to retrieve the co-occurring noun-verb pairs, and remembering whether the noun appeared in a subject or in an object position. This step is performed with the use of a stoplist that skips all pairs implying the verbs to be or to have. We want to point out that we are not implying by doing so that those two verbs do not provide relevant information. They simply are too frequent and have such a broad meaning that we cannot, with this method and at this stage of the experiments, take them into account. We select then from the list we get the most frequent co-occurrences: the 100 most frequent noun-verb relations with the nouns appearing in the subject group, and the 100 most frequent relations where the noun is part of the object group. What we obtain is a list of verbs, each verb associated with a list of nouns that co-occur with it, either as subjects only or as objects only. Here is an extract of the list: – – – – – – – –
acquiring o: hepatitis infection virus disease associated o: diseases cirrhosis DNA polymerase carcinoma HCC compensated o: liver cirrhosis disease decompensated o: liver cirrhosis disease decreased s: rates prevalence serum incidence proportion number percentage estimated s: prevalence rate virus incidence risk estimate o: prevalence incidence risk number transmitted o: hepatitis infection disease
The next step consists of clustering these classes of nouns according to their similarity. The similarity measure takes into account the number of common elements and the number of elements that differ between two classes of nouns. Each class is compared to all other classes of nouns. For each pair of classes C1C2, the program counts the number of nouns common to both classes (sim), the number of nouns only present in C1 (dif1) and the number of nouns only present in C2 (dif2). If sim, dif1 and dif2 respect some predefined values the matching is considered to be possible. After the initial class has been compared to all other classes, all the possible matchings are compared and the one producing the largest new class is kept (in case of ties, the first one is kept). Each time a new cluster is created, the 2 classes involved are removed from the processed list. The whole process is iterated as long as at least one new matching occurs, resulting in the creation of a new cluster. We will describe the measures we used in the next section, along with the evaluation of the clustering. Results We display in Table 1 some examples of steady clusters that appear in the results for each experiment in a series of experiments. Intuitively, the examples reported here seem to make sense, given the verbs they are associated to. For example, the
308
M.-L. Reinberger and W. Daelemans Table 1. Examples of extracted clusters complete(o) contain(o) develop(o) analyse(s) decrease(s) starting(o) induce(o) identify(s) estimate(o) immunization antigen hepatitis aim incidence vaccine virus infection objective risk vaccination hepatitis disease purpose proportion protein cirrhosis study rate serum carcinoma
nouns associated to the verbs to decrease and to estimate all name something that can be counted or represented by a number. The nouns associated to the verb to complete name something that can be fragmented or incomplete. As we have used soft clustering, some words are associated to more than one cluster. This is the case for the word “hepatitis”, e.g., which appears of course very often in this corpus. As shown in the table, “hepatitis” is associated with other diseases in the cluster of nouns representing nouns that can be combined with “to develop”, and associated with other nouns representing things that can be considered as parts of a more important entity with the verb “to contain”. But this anecdotal, intuitive approach does not tell us a lot about the general, objective, relevance of our clusters. Therefore, we need a method to measure this relevance, to ensure that the clusters indeed contain related words. 4.2
Evaluation of the Clusters
We evaluate our clustering method at two different levels. The first level concerns the relevance of the clusters: do they associate semantically related words? The second level concerns the method itself: is the syntactic tagging really useful, or could we perform interesting clusters from unparsed text as well? Relevance Level We evaluated the relevance of the clusters with the help of WordNet. Considering that we cannot automatically label the relations that unite the nouns of our clusters, we hoped that the variety of relations proposed by WordNet would fit the relations our clustering algorithm has built. The semantic information provided by WordNet is only used in the evaluation process. We do not intent to correct or enlarge the clusters with this information, as we wish to stay as much as possible within the paradigm of unsupervised learning. We have extracted from WordNet all possible pairs consisting of two words present in the clusters, where the words of these pairs were linked in WordNet by a relation of synonymy, hypernymy, hyponymy or meronymy. The next step consisted of checking the presence of those pairs in the clusters. Of course, as the domain is very specific, not all the nouns present in the clusters are included
Is Shallow Parsing Useful for Unsupervised Learning of Semantic Clusters?
309
Table 2. Comparison of the percentage of words clustered and the average length of the clusters
E1.1 E1.2 E2.1 E2.2
Number of Number of % of words Av. length clusters words clustered of clusters 120 153 94% 8.87 28 105 64% 10.71 155 148 91% 5.39 32 108 66% 9.81
Table 3. Recall and negative recall values for the different clustering experiments
E1.1 E1.2 E2.1 E2.2
Number of Recall on Number of Negative WordNet pairs the pairs incorrect pairs recall 108 75% 11628 32% 75 57% 5460 21% 77 74% 10878 19% 77 65% 5778 21%
in WordNet. Here are some examples of word pairs that could be extracted from WordNet: hepatitis – disease (hypernymic relation) blood – cells (meronymic relation) aim – purpose (synonym) Due to the fact that we are aiming at elaborating tools, we concentrate on experimenting and testing. Therefore, our clustering is not yet supposed to classify as many nouns as possible. As we have reduced the input to the clustering method to the 100 most frequent relations noun(subject)-verb and the 100 most frequent relations noun(object)-verb, the set of nouns was limited to 163 (some nouns appearing in the two sets). In the first experiment (E1.1), our criteria were that two classes of nouns could be merged if they had more than 2 common elements (sim>2), and not more than 5 different elements (dif<6). Once the clustering process ended, we considered as clusters the sets that contained at least 3 nouns. From the initial set of 163 nouns, 153 were clustered, which represents 94% of them (see Table 2). We then fed WordNet with those 153 words, and we retrieved 108 pairs of words. As 27 of those pairs failed to appear in the clusters, we got, according to the “WordNet sample” a recall of 75%. An evaluation of the precision score was difficult to settle as we do not have a gold standard of the “real” clusters. We therefore estimate a “negative recall”, by generating incorrect pairs of words, and checking how many of them are present in the clusters. Those pairs are composed from non-related nouns, according to WordNet. We have generated
310
M.-L. Reinberger and W. Daelemans
about 11,000 pairs, of which about a third were present in the clusters, which in other words correponds to a negative recall of 32%. As the clustering is only a first step in an unsupervised ontology extraction process, it seemed sensible to focus on limiting the rate of errors and improve the results using other methods rather than investigating the mistakes. In order to improve the negative recall, we ran a new range of experiments (E2.1) where we allowed for more clusters to be formed (dif-sim<1). We kept the clusters containing two elements, but we eliminated the big clusters. A cluster was considered as too big when it contained more than 20 items, a number based on the biggest class associated to one verb. The same evaluation showed that about the same rate of words were clustered (91%). We obtained a good recall (74%), and a better negative recall (19%). The elimination of the big clusters improves the precision score and is balanced by the creation of more small clusters, which improves recall. The weakness of both sets of results lies in the high number of clusters produced: 120 clusters for the first experiment, and 155 clusters for the second. We tried to reduce the number of clusters by removing the smaller ones from both sets of previous results (experiments E1.2 and E2.2). We obtained for E1.2 a group of 28 clusters, which corresponds to 64% of the words, with a negative recall of 19%, but a recall of only 57%. The results for E2.2 were quite similar with a better recall of 65%. We conclude from this that relevant information can be found in the small-sized clusters, and that by removing the small clusters, we lose this information without improving the negative recall measure. The experiment that rates the best score according to our objectives is experiment E2.1. It gives us the lowest negative recall, a good recall, and a high rate of the set of initial words are clustered. Its weak point is the numerous clusters generated. But this clustering is only the first result in an ontology extraction tools process, and the next steps will aim at improving the results of the clustering and making the clusters more precise. A summary of the results discussed above appears in tables 2 and 3. Efficiency Level The second step of our evaluation consisted in comparing the results of the clustering algorithm on parsed text with the results we would get processing on plain text, in order to get a baseline. Our hypothesis is that the clustering performed on a syntactically analyzed text is more accurate than one performed on raw text. But we are also interested in the magnitude of the difference in performance between both methods: is it really worth the trouble to analyze the corpus syntactically, or can we get useful results already with raw text, results that we could then improve by retrieving more semantic information from more text? We ran a set of experiments on plain text, using bi-grams as the equivalent for plain text of the noun-verb pairs in the annotated text. We have compared the two methods on the basis of the number of words clustered. The clustering on annotated text worked on 163 words corresponding to the 200 most frequent
Is Shallow Parsing Useful for Unsupervised Learning of Semantic Clusters?
311
Table 4. Percentage of words clustered using parsed text and using plain text Nb of clusters E2.1 155 4000 m.f.bg 38 5000 m.f.bg 52
Nb of Nb of words % of words words clustered clustered 163 148 91% 1663 206 12% 1931 263 14%
Table 5. Recall and negative recall values for the clustering on parsed text and on plain text Nb of correct pairs E2.1 77 4000 m.f.bg 51 5000 m.f.bg 75
Recall Nb of negative Negative pairs recall 74% 10878 19% 29% 21037 6% 27% 34641 5%
relations, of which 148 were clustered in experiment E2.1. In the bigram experiment, it appeared that considering the 4000 most frequent bigrams corresponded to 1663 words and that 206 of those words were clustered at the end of the process. We ran the clustering algorithm on different numbers of bigrams, and the results were quite similar. As shown in Table 4, and considering that the bigrams, even with the use of a stoplist, select all kinds of words, the percentage of words contained in the clusters was very low, which means that a lot of words have to be taken into account to cluster only a (comparatively) small number of nouns. As expected, the recall on the clusters using the WordNet pairs was low, and never reaching more than 30%. The best measure we obtained for all bigram sets was the negative recall, which never went over 6%. We give the results in Table 5 for the 4000 and the 5000 most frequent bigrams. We can see there that a difference of 1000 bigrams does not change significantly the recall values. The results we get show that the use of annotated text improves the rate of words clustered and the recall. The difference of those two rates is important enough to balance the better negative recall, and to let us consider that performing a syntactic analysis prior to the clustering is useful.
5
Ongoing Work: Labeling and Building a Hierarchy
The next task in our project consists of labeling the relations between the nouns and building a hierarchy. To further pursue an unsupervised approach, the semantic labeling should be done automatically. We therefore do not intent to use WordNet and the different relations it proposes, but will try to get those semantic relations directly from the corpus.
312
M.-L. Reinberger and W. Daelemans
The clustering we are performing does not provide any information concerning the kind of relations between the clusters, hence between the words. However, the different elements of a cluster have something in common that can be specified as a relation. We can focus on two types of information: the relations between words belonging to the same cluster, and the relations between the clusters of nouns and the verbs associated to them according to the relation verb-noun (subject or object). We are planning to perform this by using methods involving pattern matching or association rules ([6]), and automatic methods for constructing hierarchies ([7], [8]).
6
Conclusions and Perspectives
We have shown that unsupervised learning methods can be used to retrieve semantic information from text when a shallow syntactic analysis is available. This syntactic analysis proved to be useful as the clustering performed on the parsed text gave better results than the one performed on plain text. The next step of this research is to elaborate the conceptual knowledge sets for the clusters of nouns. Another interesting extension would consist in considering the groups of verbs associated to the clusters of nouns. That information could allow us to cluster the verbs and get selectional preferences associated with classes of verbs, but also to relate nouns to verbs, where these relations represent the semantic functions of the concept associated with the noun. Yet another issue is the retrieval of the prepositions that introduce a nominal complement and use this information to make the information associated with nouns more specific. Acknowledgments. This research was carried out in the context of the OntoBasis project, sponsored by IWT (Institute for the Promotion of Innovation by Science and Technology in Flanders).
References 1. Pustejovsky, J.: The Generative Lexicon. MIT Press (1995) 2. Gamallo, P., Agustini, A., Lopes, G.P.: Selection restrictions acquisition from corpora. In: Proceedings EPIA-01, Springer-Verlag (2001) 3. Gamallo, P., Agustini, A., Lopes, G.P.: Using co-composition for acquiring syntactic and semantic subcategorisation. In: Proceedings of the Workshop SIGLEX-02 (ACL-02). (2002) 4. Daelemans, W., Buchholz, S., Veenstra, J.: Memory-based shallow parsing. In: Proceedings of CoNLL-99. (1999) 5. Faure, D., N´edellec, C.: Knowledge acquisition of predicate argument structures from technical texts using machine learning: The system asium. In: Proceedings EKAW-99. (1999) 6. Maedche, A., Staab, S.: Semi-automatic engineering of ontologies from text. In: Proceedings of SEKE-00. (2000) 7. Caraballo, S.A.: Automatic construction of a hypernym-labeled noun hierarchy from text. In: Proceedings ACL-99. (1999)
Is Shallow Parsing Useful for Unsupervised Learning of Semantic Clusters?
313
8. Berland, M., Charniak, E.: Finfing parts in very large corpora. In: Proceedings ACL-99. (1999) 9. Agirre, E., Martinez, D.: Learning class-to-class selectional preferences. In: Proceedings CoNLL-01. (2001) 10. Caraballo, S.A., Charniak, E.: Determining the specificity of nouns from text. In: Proceedings SIGDAT-99. (1999) 11. Gamallo, P., Gasperin, C., Agustini, A., Lopes, G.P.: Syntactic-based methods for measuring word similarity. In: Proceedings TSD-01, Springer-Verlag (2001) 12. Maedche, A., Staab, S.: Ontology learning for the semantic web. IEEE Intelligent Systems 16 (2001) 13. McCarthy, D., Carroll, J., Preiss, J.: Disambiguating noun and verb senses using automatically acquired selectional preferences. SENSEVAL-2 (2001) 14. Wagner, A., Mastropietro, M.: Collecting and employing selectional restrictions. Technical report (1996)
Experiments on Extracting Semantic Relations from Syntactic Relations Caroline Varaschin Gasperin and Vera L´ucia Strube de Lima Faculdade de Inform´atica PPGCC, PUCRS Av. Ipiranga, 6681 90619-900 Porto Alegre, RS, Brasil {caroline,vera}@inf.pucrs.br
Abstract. This work presents the results of the application of a technique for automatic extraction of semantic relations among words from a corpus. The technique used is the one proposed by Grefenstette in [1]. We brought contributions to the syntactic context notion in [1], aiming to improve the identification of semantically related words. Then, we carried on three different experiments using a Portuguese language corpus: the first one compares the original Grefenstette’s technique with the technique modified with our contributions, the second experiment investigates which syntactic relation is more relevant when identifying semantic relations, and the last experiment investigates the influence of the parser errors on the quality of the extracted semantic relations. Results and their analyses are detailed in this article.
1
Introduction
Identifying semantic relations among words in a corpus is an useful task mainly for automatic thesaurus/ontology building. A thesaurus can improve considerably the precision of systems for information retrieval, information extraction, document classification, machine translation, text summarization, and others. This work presents an extension of Grefenstette’s [1] strategy to obtain semantically similar words from corpora. This is a knowledge-poor syntax-based technique, like the ones in [2,3]. There are other kinds of techniques [4,5,6] that don’t use syntactic information. Grefenstette’s technique includes basically three steps: extracting the syntactic contexts of each noun in the corpus, comparing each pair of nouns using their syntactic contexts through a similarity measure, and building lists of most similar nouns for each noun in the corpus. The two main points that differentiate Grefenstette’s technique from other syntaxbased techniques to identify semantic relations between words are: the notion of syntactic context and the similarity measure. According to Grefenstette, each word that is syntactically related to a noun is part of its syntactic context. This way, each adjective, noun or verb that share a syntactic relation with a noun is recorded as a syntactic context of the noun. A. Gelbukh (Ed.): CICLing 2003, LNCS 2588, pp. 314–324, 2003. c Springer-Verlag Berlin Heidelberg 2003
Experiments on Extracting Semantic Relations from Syntactic Relations
315
The similarity measure used by Grefenstette is a weighted version of Jaccard’s measure, which assigns weights to each context extracted from the corpus, according to context frequencies in local (word) and global (corpus) scope. Our extension to Grefenstette’s technique is focused on the notion of syntactic context. We observed that some useful fine-grained syntactic information available in the corpus were not considered by Grefenstette when extracting the syntactic contexts. Our hypothesis is that this information could help considerably in identifying semantic relations between words. So, we decided to include the fine-grained information into the syntactic contexts. We carried on experiments to validate Grefenstette’s technique for Portuguese language, and also to validate the proposed extensions. The corpus used in the experiments consists of a 1,262,000-word subset of the FOLHANOT corpus, formed by news texts written in Brazilian Portuguese and syntactically analysed by the parser PALAVRAS [7]. We present a sample of the results, that is constituted by lists of words semantically related to some selected nouns. The analysis of such results is detailed, and a comparison between the lists generated through the original Grefenstette’s technique and the lists generated through the extended technique proposed is shown. We also carried on other two experiments: one to investigate which syntactic relation is more relevant when identifying semantic relations, and another to investigate the influence of the parser errors on the homogeneity of the generated lists of semantic related words. In the next sections, we explain our contribution to Grefenstette’s syntactic context notion. In section 3, we report our experiments to validate the proposed contributions. In section 4, we report our experiment to identify the most relevant syntactic relation. In section 5, we report our experiment to investigate the parser influence on the homogeneity of the word lists. In section 6, we present our concluding remarks. Finally, in section 7, we present the future phases of this work.
2
Syntax-Based Technique Adopted
Grefenstette’s work [1] presents a syntax-based technique to automatically extract semantic relations between words. (This task is the opposite to the one considered in [8], where possible syntactic relationships are shown to be predictable basing on the semantic similarity between words.) The technique adopted consists on extracting syntactic contexts for each noun in a partially parsed corpus. Each syntactic relation between a noun and another word generates a syntactic context for this noun. The following nominal syntactic relations are considered: ADJ (an adjective modifies a noun), NN (a noun modifies another noun) and NNPREP (noun modifies another noun, using a preposition). Verbal syntactic relations are also considered: SUBJ (a noun is the subject of a verb), DOBJ (a noun is the direct object of a verb) and IOBJ (a noun is the indirect object of a verb). Table 1 shows examples of some syntactic contexts. To find the semantic similarity between the nouns, one compares them through their syntactic contexts, using as similarity measure a weighted version of the binary Jaccard measure [1]. The weighted Jaccard measure considers a global and a local weight for each context. The global weight takes into account the amount of different words associated
316
C. Varaschin Gasperin and V.L. Strube de Lima Table 1. Examples of binary syntactic dependencies Sentence A cidade inicia a colheita da maior safre de sua hist´oria. (The city begins the crop of the largest production of its history.)
Noun cidade colheita safra
Contexts <SUBJ, iniciar>
with a given syntactic context in the corpus. The local weight is based on the frequency of occurrence of the context with a given word. By computing the similarity measure of all word pairs in the corpus, it’s possible to generate the list of the most similar words to each word in the corpus. 2.1 Adaptations to Portuguese Grefenstette relates [1] the experiments to validate his technique on identifying semantically similar words using English language corpora. Nevertheless, we applied the Grefenstette’s technique over a Portuguese corpus. We identified some points that had to be modified when using a Portuguese corpus: – using a Portuguese language parser or a parsed Portuguese corpus; – ignoring the syntactic relations NN, that do not occur in Portuguese: in general, the NN relations in English, are NNPREP in Portuguese. For example, the expression planet area (
Extentions to the Notion of Syntactic Context
We observed that Grefenstette doesn’t use all the information contained in the syntactic dependencies in the corpus. Considering other similar techniques ([3], [2]) and the hypothesis of new sorts of contexts or information that could enrich the existing contexts, we could extend the notion of syntactic context adopted in [1]. We propose the following four extensions to the Grefenstette’s notion of syntactic context. Explicit syntactic relation in context. According to Grefenstette’s notation, the contexts extracted from nominal relations (namely NN, ADJ, and NNPREP modifiers) do not keep the name of the particular syntactic relation. Grefenstette differentiates just the contexts derived from verbal syntactic relations (SUBJ, DOBJ e IOBJ). This way, words that function as adjectives and nouns generate identical contexts, even when they have different functions. For example, from the expressions a obriga¸ca˜ o do t´ecnico (“the obligation of the technician”) and o relat´orio t´ecnico (“the technical report”) the
Experiments on Extracting Semantic Relations from Syntactic Relations
317
same syntactic context
318
C. Varaschin Gasperin and V.L. Strube de Lima
syntactic context notion, the same context
3
Experiment 1
The first experiment we did was to validate the Grefenstette’s technique and the proposed extensions over a Portuguese corpus. We established a five-step procedure for this first experiment: 1. extracting the syntactic contexts from the corpus; 2. creating different sets of syntactic contexts: we created two sets for noun contexts one set according to Grefenstette’s syntactic context notion and another according to the extended notion, to be compared; 3. calculating the word similarity (using the weighted Jaccard similarity measure); 4. building the lists of similar words: using each context set, we generated a list of similar words for each noun of the corpus. To appreciate the results of the experiments, we randomly selected the lists of 10 nouns with different occurrence frequencies in the corpus. The two lists for each selected noun (lists generated with contexts according to each syntactic context notion, Grefenstette’s and extended ones) were compared to identify the contribution of the extension of the syntactic context notion considering improvement on the homogeneity of the lists of related nouns. To analyse the word lists, we took a subjective measure, the homogeneity, that means: if a list contains several words that we consider semantically related to the given word, this list is homogeneous. We didn’t find any systematic measure that could represent the lists homogeneity. On Table 2, we present the lists of the nouns semantically related to this 10 nouns. The rows G of the table correspond to the lists generated from Grefenstette’s technique, and the rows E correspond to the lists generated from the extended technique. We can state that the lists contain several semantically related nouns. The E lists are noisier than the G lists; for the most part, more semantically related words are present in the second lists, and even words that appear in both lists are well positioned1 in the G lists. For instance, the list of the noun mˆes contains: co-hyponyms like mar¸co, setembro, agosto; holonyms like ano, d´ecada; meronyms like dia, hora. The list of the noun mˆes generated from the set of extended contexts is considered more homogeneous than the list generated from the set of Grefenstette’s contexts, because: – nouns that appear in both lists, like agosto, are well positioned in the second list. Its position in the list is improved due to new contexts shared by agosto and mˆes, like 1
Ordering in the list of related words is related to the similarity value: the first word in the list is more closely related to the given word than the last word in the list.
Experiments on Extracting Semantic Relations from Syntactic Relations
319
Table 2. Lists of semantically related nouns cultura/ culture
G
produ¸ca˜ o/production teatro/theatre popula¸ca˜ o/population imprensa/press capital futebol/soccer jornal/newspaper filme/film cidade/city TV evento/event grupo/group m´usica/music banda/band mercado/market
E
teatro/thetre produ¸ca˜ o/production revista/magazine m´usica/music cinema edi¸ca˜ o/edition banda/band experiˆencia/experience popula¸ca˜ o/population arte/art pe¸ca/play tradi¸ca˜ o/tradiction capital literatura/literature imprensa/press
feij˜ao/ bean
G
sul-africanas/south-african
preparado/prepared
decep¸ca˜ o/deception
Casa/house
grana/money
ex´ercito/army minoria/minority molho/sauce Homem/man pastel/pastry Bar˜ao/baron gr˜ao/grain bon´e/cap fruto/fruit barro/clay
E
soja/soy carne/meat trigo/wheat milho/corn leite/milk arroz/rice cesta/basket gr˜ao/grain massa/pasta frango/chicken sugest˜ao/sugestion molho/sauce palestra/lecture fio/line ex´ercito/army
infla¸ca˜ o/ G inflation
custo/cost
´ındice/index
taxa/tax
faturamento/invoice
reajuste/ajust
investimento/investiment
juro/interest sal´ario/salary m´edia/average contrato/contract varia¸ca˜ o/variation expectativa/expectation moeda/currency velocidade/speed pista/track
E
taxa/tax custo/cost sal´ario/salary juro/interest m´edia/average ´ındice/index faturamento/invoice investimento/investiment n´ıvel/level varia¸ca˜ o/variation produtividade/productivity contrato/contract al´ıquota/aliquot pre¸co/price velocidade/speed
mˆes/ month
G
dia/day semana/week ano/year edi¸ca˜ o/edition hora/hour final fase/phase elei¸ca˜ o/election in´ıcio/beginning vez/time domingo/Sunday d´ecada/decade volume US$ agosto/August
E
semana/week dia/day agosto/August ano/year mar¸co/March edi¸ca˜ o/edition final setembro/September hora/hour d´ecada/decade outubro/October elei¸ca˜ o/election janeiro/January dezembro/December junho/June
perda/ loss
G
aumento/rise redu¸ca˜ o/reduction ganho/profit varia¸ca˜ o/variation economia/saving crescimento/growth ausˆencia/absense investimento/investment alta/increase m´edia/average expans˜ao/expansion reajuste/adjust faturamento/invoice queda/fall sal´ario/salary
E
reajuste/adjust aumento/rise crescimento/growth alta/increase economia/saving faturamento/invoice custo/cost preju´ızo/injury valor/value redu¸ca˜ o/reduction sal´ario/salary ausˆencia/absense investimento/investment varia¸ca˜ o/variation diminui¸ca˜ o/decrease
pesquisa/ G research
estudo/study teste/test dado/datum resultado/result programa/program lan¸camento/publication projeto/project filme/film trabalho/work plano/plan neg´ocio/business lista/list n´umero/number reuni˜ao/meeting experiˆencia/experience
E
estudo/study teste/test trabalho/work dado/datum resultado/result programa/program plano/plan campanha/campaign empresa/company projeto/project artigo/article grupo/group lan¸camento/publication experiˆencia/experience produ¸ca˜ o/production
proprie- G t´ario/ proprietor E
dono/owner
morador/resident
japonˆes/Japanese
concession´aria/concessionaire
gerente/manager
treinador/trainer editor Gol/gol seguradora/insurance agency associado/associate habitante/inhabitant assistente/assistant emenda/emend produtor/producer bicheiro/illegal banker dono/owner editor comerciante/seller gerente/manager trabalhador/worker menina/girl prefeito/mayor favorito/favorite
morador/resident
propriedade/property
cr´edito/credit
governador/governor
japonˆes/Japanese dona/owner associado/associate
regi˜ao/ re- G gion E
rua/street cidade/city praia/beach hotel ilha/island bairro/district a´ gua/water parque/park pista/track centro/middle bar viagem/trip capital local/place escrit´orio/office cidade/city ilha/islan bai