450 likes | 732 Views
Joint Entity and Relation Extraction using Card-Pyramid Parsing . Rohit J. Kate Raymond J. Mooney. Entity and Relation Extraction. Information Extraction is the task of extracting structured information from text Entity Extraction Person, Location, Organization Relation Extraction
E N D
Joint Entity and Relation Extraction using Card-Pyramid Parsing Rohit J. Kate Raymond J. Mooney
Entity and Relation Extraction • Information Extraction is the task of extracting structured information from text • Entity Extraction Person, Location, Organization • Relation Extraction Located_In(Location, Location) Work_For(Person, Organization) OrgBased_In(Organization, Location) Live_In(Person, Location) Kill(Person, Person)
Work_For OrgBased_In Live_In OrgBased_In Located_In Live_In Person Location Location Other Organization Entity and Relation Extraction Austin lives in Los Angeles, California and works there for an American company called ABC Inc.
Entity and Relation Extraction • Traditionally, entity and relation extraction is done in a pipeline • First entities are extracted • Then relations are extracted assuming that the extracted entities are correct
Entity and Relation Extraction • However, relations can influence entity extraction Live_In Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Person? Location? Person Location
OrgBased_In Entity and Relation Extraction • Relations can also influence extracting other relations Work_For Live_In Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Person Location Organization
Joint Entity and Relation Extraction • Both entity and relation extraction can benefit if done jointly • Correct errors of each other • Influence each other • A brute force algorithm to find the most probable joint extraction is intractable • If there are n entities in a sentence then O(n2) possible relations between them and for r relation labels O(rn^2) possibilities • We present a new method for joint extraction
Joint Entity and Relation Extraction • Treat it analogous to parsing with the following productions: • Entity productions: • Person Candidate_entity • Location Candidate_entity • Organization Candidate_entity • Relation productions: • Located_In Location Location • Work_For Person Organization • OrgBased_In Organization Location • Live_InPerson Location • KillPerson Person
Work_For OrgBased_In Live_In OrgBased_In Located_In Live_In Person Location Location Other Organization Joint Entity and Relation Extraction • However, many entities are in multiple relations, with a lot of overlapping • Context-free grammar (CFG) tree structure is not adequate • We introduce a new structure we call card-pyramid Austin lives in Los Angeles, California and works there for an American company called ABC Inc.
Person Location Location Other Organization Person Location Organization Location Other Joint Entity and Relation Extraction using Card-Pyramid Work_For OrgBased_In Live_In OrgBased_In Located_In Live_In Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Work_For OrgBased_In Not_Related Live_In Not_Related OrgBased_In Located_In Live_In Not_Related Not_Related Candidate entities (Austin) (Los Angeles) (California) (American) (ABC Inc)
Joint Entity and Relation Extraction using Card-Pyramid • Entities and their relations are compactly represented in a card-pyramid graph • Joint entity and relation extraction reduces to finding the most probable joint labeling of its nodes • We developed an efficient bottom-up card-pyramid parsing algorithm which uses dynamic programming and beam search, given entity and relation classifiers
Distinction from CFG Tree CFG Tree Card-Pyramid No overlap Overlap
Distinction from CFG Tree CFG Tree Card-Pyramid No overlap Overlap
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing • Assumes candidate entities are given • Can be obtained automatically [Punyakanok & Roth, 2001] • Use a simple heuristic, like all noun-phrase chunks • In the worst case include every substring, they will get label Other if they are none of the given types Austin lives in Los Angeles, California and works there for an American company called ABC Inc.
Beam Beam element (Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Apply entity classifiers at the leaf nodes SVM with standard features: words, POS tags, capitalization, gazetteer, suffixes etc.
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Apply relation classifiers bottom-up at the internal nodes relating leftmost and rightmost leaves SVM with word subsequence kernel for before, between and after patterns of the two entities [Bunescu & Mooney, 2005]
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Consider every combination of children’s beam elements
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Work_For Per Org
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Work_For Per Org
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc.
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Located_In Loc Loc
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc.
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Live_In Per Loc
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Relations with in-between entities are also used as features, for e.g. “Live_In -- Located_In” In general, any features can be used from the sub-card-pyramid underneath. Live_In Per Loc …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Divide the probability which gets multiplied twice. Live_In Per Loc …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. A beam element represents a sub-card-pyramid. …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. An O(1) check for consistency of overlap. ………….. X
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. An O(1) check for consistency of overlap. X …………..
(Austin) (Los Angeles) (California) (American) (ABC Inc) Card-Pyramid Parsing Austin lives in Los Angeles, California and works there for an American company called ABC Inc. Most probable card-pyramid is represented by the top beam element at the root. An approximation because of the finite beam size. …………..
Training Classifiers • Obtain correctly labeled card-pyramids for the annotated sentences in the training data • Collect the positive examples for all the classifiers from the labels of the card-pyramids • Positive examples for an entity classifier become negative examples for all other entity classifiers • Pairs of entities with correct entity types but not related by a relation become negative examples for that relation’s classifier
Related Work • Roth & Yih [2004, 2007] • Employs independent entity and relation classifiers • Uses linear programming to find a consistent global solution from the classifier outputs • Output of other classifiers can’t be used as features • Riedel et al. [2009] • Solves a related problem of extracting bio-molecular events and their arguments using Markov Logic Network • Single joint probabilistic model • Restricts extractors’ learning algorithm to Markov Logic Network’s learning algorithm, for example, cannot use kernel-based SVM for relation extraction • Kate & Mooney [2006] • Parse using a suite of classifiers to find the most probable semantic parse
Experiments • Dataset used by Roth & Yih [2004, 2007] • Number of sentences: 1437 • Entities: Person (1685), Location (1968), Organization (978), Other (705) • Relation Extraction Located_In(Location, Location) (406) Work_For(Person, Organization) (394) OrgBased_In(Organization, Location) (451) Live_In(Person, Location) (521) Kill(Person, Person) (268) Not_Related (17007)
Experiments • Performed five-fold cross-validation • Measured: • Precision (percentage of output labels correct) • Recall (percentage of gold-standard labels correctly identified) • F-measure (harmonic mean) • Compared with: • A pipelined approach using our entity and relation classifiers • Best results of Roth & Yih [2007] on joint extraction
Results: Entity Extraction F-measure
An unusual sentence with 20 Locations separated by commas. Results: Relation Extraction F-measure
A General Method to Extract Structured Information from a Sentence • Encode what you want to extract and constraints between them in the productions • Train a classifier for every production • Apply the classifiers to find the most probable structure allowed by the productions to jointly find the structured information
Future Work • Extract higher order relations: relations between relations such as temporal or causal relations • Jointly perform co-reference resolution with entity and relation extraction • Add a new production: CorefPerson Person • Model the structure of card-pyramid using a probabilistic graphical model • A kernel to compute similarity between two card-pyramids and use it for relation classifier
Conclusions • Introduced a card-pyramid structure for joint entity and relation extraction • Compactly encode entities and relations in a sentence • Joint extraction reduces to jointly labeling the nodes • Presented an efficient parsing algorithm for joint labeling • Experiments demonstrated benefits of the approach
Thanks! Questions?