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

Feat: adds TF-IDF #169

Merged
merged 20 commits into from
Nov 14, 2022
Merged

Feat: adds TF-IDF #169

merged 20 commits into from
Nov 14, 2022

Conversation

micheleriva
Copy link
Member

@micheleriva micheleriva commented Nov 5, 2022

This PR is a rewrite of #149. More complete info to come as soon as out of draft status.

Stages:

  • Preload term frequencies in documents
  • Calculate TF-IDF scores on search
  • Remove frequencies on document deletion
  • Calculate cosine similarity on TF-IDF-based scoring vectors to be done in the future

@micheleriva micheleriva marked this pull request as ready for review November 11, 2022 12:53
This was referenced Nov 11, 2022
Copy link
Contributor

@ShogunPanda ShogunPanda left a comment

Choose a reason for hiding this comment

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

Minor nits, but the rest looks great!

src/prefix-tree/node.ts Outdated Show resolved Hide resolved
src/utils.ts Outdated Show resolved Hide resolved
src/utils.ts Show resolved Hide resolved
src/utils.ts Outdated Show resolved Hide resolved
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