nus-cs2113-AY2223S2 / pe-dev-response

0 stars 0 forks source link

Function outputs are ambiguous #1118

Open nus-pe-bot opened 1 year ago

nus-pe-bot commented 1 year ago

image.png

image.png

Similar events output is completely random. Unsure how those are, quote from UG "Top 3 categories with names that are most similar to the provided keyword, along with the categories they belong to".

Created 10 categories as shown in the screenshot and used command "search ccc" to identify bug.


[original: nus-cs2113-AY2223S2/pe-interim#873] [original labels: type.FunctionalityBug severity.Low]

mingyuannus commented 1 year ago

Team's Response

Similarity between input string and category name is computed by finding the length of the longest common substring.

"ccc" and "cc": longest common substring is "cc", with a length of 2. "ccc" and "electricity bill": longest common substring is "c", with a length of 1. "ccc" and "c": longest common substring is "c", with a length of 1.

When the similarity computed is the same, items are ranked by index.

Therefore the output order is not completely random and working as intended.

Duplicate status (if any):

--