Open vlandham opened 8 years ago
So, this would be used after tokens2pos
, right? As in:
textkit text2words test.md | textkit tokens2pos | textkit filterpos NNP,JJ
In that case it's going to be a new type of command, one that operates on a csv file containing a list of (word,pos).
| awk '/(NNP|JJ)\r$/'
already works, although the \r is not meant to be there I guess (see https://github.com/learntextvis/textkit/issues/40#issuecomment-271165000 )
filterpos
will have to specify which POS's to keep.
will probably need a helper function to output all POS codes and their meanings.