Question

I'm hoping somebody can point me in the right direction to learn about separating out actions from a bunch of text.

Suppose I have this text

Drop off the dry cleaning, and go to the corner store and pick-up a jug of milk and get a pint of strawberries.
Then, go pick up the kids from school. First, get John who is in the daycare next to the library, and then get Sam who is two blocks away. 
By the time you've got the kids, you'll need to stop by the doctors office for the perscription. Tim's flight arrives at 4pm. 
It's American Airlines flight 331 arriving from Dallas. It will be getting close to rush hour, so make sure you leave yourself enough time.

I'm trying to have it split up into

Drop off the dry cleaning,
 and go to the corner store and pick-up a jug of milk and get a pint of strawberries.
Then, go pick up the kids from school. First, get John who is in the daycare next to the library, and then get Sam who is two blocks away. 
By the time you've got the kids, you'll need to stop by the doctors office for the perscription.
 Tim's flight arrives at 4pm. 
It's American Airlines flight 331 arriving from Dallas. It will be getting close to rush hour, so make sure you leave yourself enough time.

I haven't been able to find anything in my searches that is specifically action based. It would need to be smarter than just picking out verbs, as there are multiple verbs that are sometimes associated with one action for, instance the second item has 'go','pick-up' and 'get', but that is all part of a single action. Of course, "Tim's flight" is only suggests an action with the present participle, with the verb coming toward the end of the segment.

Any suggestions on where to look to do this kind of thing? Things to watch-out for, recommended readings, etc. etc.

Was it helpful?

Solution

Simple approach: parse the text using [your favorite parser], then select the sentences or SBAR phrases that are in the imperative mood. The Stanford Parser just so happens to have "Improved recognition of imperatives" in its very latest release.

There's probably no need for machine learning beyond what is already incorporated in standard parser programs.

OTHER TIPS

This domain is called Information Extraction.

The general approach to sentence understanding is either:

  • extract a Part-Of-Speech tagged parse-tree (Python spaCy.io, nltk, CoreNLP etc.)
  • extract a word-vector (e.g. word2vec)
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top