Sunday, November 2, 2014

A note on Prepositional phrases

For one of my research projects, I was looking at different components in constituency parser output namely Verbal phrases (henceforth called VP), Noun phrases (henceforth NP) and Prepositional phrases (henceforth PP). It is interesting to note that in both VPs and NPs, the head of the phrases is not so surprisingly Verb and a Noun respectively. However when it comes to prepositional phrases, we have 2 different categories.
  1. PPs that function as adjectives (in other words answer questions such as what/which/how many etc..,)
  2. PPs that function as adverbs (in other words answers questions such as how/when/where/why etc..,)
One other way to look at PPs as adjectives is to realize that they talk about a Noun (like an adjective does). Similarly PPs as adverbs talk about a verb. 

Based on this distinction I started looking at openNLP chunker's output. By looking at the points 1 and 2, I devised a simple heuristic as follows:


Problem: Find whether a PP is adverbial or adjective

Solution: 
Heuristic 1: If the PP is first chunk in a sentence or is immediately preceded by VP, then it is more likely to be an adverbial.

Heuristic 2: If the PP is immediately preceded by a NP, it is more likely to be adjective PP. 

I dont have any metric to report for these 2 heuristics, however. 

References: