MaartenGr / MaartenGr/PolyFuzz
results of get_matches() are not sorted by similarity score for all the values
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 803
- Forks
- 72
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
I was running polyfuzz tfidf model to get the matches but few rows of the result was not sorted as per the top_n similarity score.
```python
tfidf_model = PolyFuzz(tfidf_matcher)
tfidf_model.match(from_list, to_list)
tfidf_model.get_matches()
```
eg:
| | From | To | Similarity | To_2 | Similarity_2 | To_3 | Similarity_3 | To_4 | Similarity_4 | To_5 | Similarity_5 |
|---:|:------------------------------|:------------------------------|-------------:|:---------------------------------|---------------:|:------------------------------------------|---------------:|:------------------------------------|---------------:|:----------------------------|---------------:|
| 21 | 3 IN 1 LAVENDER & CAMOMILE | 2 IN 1 LAVENDER & CAMOMILE | 0.938 | 3 IN 1 LAVENDER & CAMOMILE | 1 | 3 IN 1 LAVENDER | 0.771 | 3 IN 1 LAVENDER & CHAMOMILE | 0.831 | LAVENDER CAMOMILE | 0.764 |
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with the shown PolyFuzz(tfidf_matcher), match(), and get_matches() calls, using the example row as a check. Start at the get_matches() entry point and trace how the TF-IDF results become the similarity columns. Done means every returned row orders its matches consistently by descending similarity score.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- search
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100