Skip to content

Commit

Permalink
fix sorted
Browse files Browse the repository at this point in the history
  • Loading branch information
Hanif Yuli Abdillah P committed Apr 17, 2024
1 parent b8e6e02 commit 64144e1
Show file tree
Hide file tree
Showing 6 changed files with 2 additions and 2 deletions.
Binary file removed dist/lexifuzz_ner-0.0.5-py3-none-any.whl
Binary file not shown.
Binary file removed dist/lexifuzz_ner-0.0.5.tar.gz
Binary file not shown.
Binary file added dist/lexifuzz_ner-0.0.6-py3-none-any.whl
Binary file not shown.
Binary file added dist/lexifuzz_ner-0.0.6.tar.gz
Binary file not shown.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "lexifuzz-ner"
version = "0.0.5"
version = "0.0.6"
authors = ["Hanif Yuli Abdillah P <[email protected]>"]
description = "Python package for detecting entities in text based on a dictionary and fuzzy similarity"
readme = "README.md"
Expand Down
2 changes: 1 addition & 1 deletion src/lexifuzz_ner/ner.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def handle_slicing(data=None):
indices_covered.add((start, end))

# Update the entities in the data dictionary
data['entities'] = new_entities
data['entities'] = sorted(new_entities, key=lambda x: (x['index']['start']))
return data

def annotate_text(entities = None):
Expand Down

0 comments on commit 64144e1

Please sign in to comment.