Skip to content

Commit

Permalink
simple fix for bug reported by Tuan-Anh in processing the following e…
Browse files Browse the repository at this point in the history
…xample tweet:

Early Engagement Consultant - American Express: ( #Madison , WI) http://t.co/zCOAvdsJ #BusinessMgmt #Job #Jobs #TweetMyJobs
  • Loading branch information
Alan authored and Alan committed Oct 31, 2012
1 parent 3b8f3ec commit cb5112e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/pos_tag/features.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,8 @@ def _check_bigrams(self, word1, word2, use_first):
bigram = word1 + '_' + word2
new_features = []
for dict_name, d in self.bigram_dictionaries.iteritems():
if bigram in d.token_pos_set:
if bigram != ":_(" and bigram in d.token_pos_set:
print bigram
tag1, tag2 = d.token_pos_set[bigram].items()[0][0].split('_')
tag = (use_first and tag1) or tag2
ttype = (use_first and 'AFTER') or 'BEFORE'
Expand Down

0 comments on commit cb5112e

Please sign in to comment.