Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

approximate sentence match logic adapter and its docs #272

Merged
merged 5 commits into from
Sep 3, 2016

Conversation

sumn2u
Copy link
Collaborator

@sumn2u sumn2u commented Sep 3, 2016

Jaccard index is found to have better performance in approximate sentence matching so implement it.

sentence_match = input_statement
# Find the matching known statement
for statement in statement_list:
ratio = self.is_ci_lemma_stopword_set_match(input_statement.text, statement.text)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure if this works. Where is ratio being used?

@sumn2u
Copy link
Collaborator Author

sumn2u commented Sep 3, 2016

ratio is added here if there is ratio it will return result :) @gunthercox


def is_ci_lemma_stopword_set_match(self,a, b, threshold=0.5):
"""Check if a and b are matches."""
print("ask",a)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This print statement will have to be removed before this gets merged.

@gunthercox gunthercox merged commit 0cbf777 into gunthercox:master Sep 3, 2016
@gunthercox
Copy link
Owner

Thank you! Looks good 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants