Skip to content

Commit

Permalink
fixed a bug that caused people to not be recognized
Browse files Browse the repository at this point in the history
  • Loading branch information
jlowryduda committed Nov 29, 2017
1 parent 0e3c5fc commit 0c4ad55
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions conceptnet5/readers/cc_cedict.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,9 +128,6 @@ def handle_file(filename, output_file):
if 'Taiwan pr.' in definition or 'also pr.' in definition:
continue

# Remove clarifying information in parenthesis
definition = PAREN_REGEX.sub('', definition)

# Check if it's the definition matches a person syntax, i.e. includes a date range
person_match = re.match(DATE_RANGE_REGEX, definition)
if person_match:
Expand Down Expand Up @@ -174,6 +171,9 @@ def handle_file(filename, output_file):
out.write(edge)
continue

# Remove clarifying information in parenthesis
definition = PAREN_REGEX.sub('', definition)

# Handle variants/word forms and abbreviations
if re.match(VARIANT_REGEX, definition) or re.match(ABBR_REGEX, definition):
variants = extract_han_characters(definition)
Expand Down

0 comments on commit 0c4ad55

Please sign in to comment.