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

Add FTS for app name and windows name and fix CI pipeline #967

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Yashashwini2003
Copy link
Contributor

@Yashashwini2003 Yashashwini2003 commented Dec 14, 2024


name: pull request
about: submit changes to the project
title: "[pr] "
labels: ''
assignees: ''


description

brief description of the changes in this pr.

related issue: #

how to test

add a few steps to test the pr in the most time efficient way.

if relevant add screenshots or screen captures to prove that this PR works to save us time.

if you think it can take more than 30 mins for us to review, we will pay between $20 and $200 for someone to review it for us, just ask in the pr.

/claim #964
Fixes #964

Copy link

vercel bot commented Dec 14, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
screenpipe ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 15, 2024 1:04am

Copy link

algora-pbc bot commented Dec 14, 2024

💵 To receive payouts, sign up on Algora, link your Github account and connect with Stripe.

@louis030195
Copy link
Collaborator

hmm no

@louis030195
Copy link
Collaborator

did you read the code?

@louis030195
Copy link
Collaborator

we already have fts on these columns

you need to change db.rs code and make sure tests pass of course

@Yashashwini2003
Copy link
Contributor Author

It seems in db.rs the FTS has been added for app name and windows name and also there are tests too. I think have to run them and check their functionality. But pipeline is failing to check with that tests

@louis030195
Copy link
Collaborator

louis030195 commented Dec 14, 2024

i usually do cargo test and it works

here's the thing to change (and other similar queries)

AND (?6 IS NULL OR ocr_text.app_name LIKE '%' || ?6 || '%' COLLATE NOCASE)

LIKE is very inefficient, O(n) while FTS is O(logn) for search so it would likely make search with window/app name more than 1000x faster

also if you make this one work better:
#901

not super important but i'd add tip for it

@Yashashwini2003
Copy link
Contributor Author

Yashashwini2003 commented Dec 14, 2024

@louis030195 I am too fixing the build :) Idk why CI is flaky with all compilation errors

@Yashashwini2003
Copy link
Contributor Author

Yashashwini2003 commented Dec 14, 2024

@louis030195 Finally it got compiled! Can you merge this PR? I will push new pr for FTS.
I have just removed /claim and Fix

@Yashashwini2003 Yashashwini2003 changed the title Add FTS for app name and windows name fix CI pipeline Dec 15, 2024
@Yashashwini2003 Yashashwini2003 changed the title fix CI pipeline Add FTS for app name and windows name and fix CI pipeline Dec 15, 2024
@@ -13,6 +13,9 @@ use xcap_macoswin::{Monitor, Window, XCapError};
#[cfg(target_os = "linux")]
use xcap::{Monitor, Window, XCapError};

#[cfg(target_os = "windows")]
use xcap_win::{Monitor, Window, XCapError};
Copy link
Collaborator

Choose a reason for hiding this comment

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

?

Copy link
Collaborator

Choose a reason for hiding this comment

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

can you remove this change

@louis030195
Copy link
Collaborator

does not compile

@louis030195
Copy link
Collaborator

any update

@Yashashwini2003
Copy link
Contributor Author

Fill fix them

@Yashashwini2003
Copy link
Contributor Author

Yashashwini2003 commented Dec 19, 2024

@louis030195 Can I fix all this on weekend?
I will make sure to complete this issue

@louis030195
Copy link
Collaborator

@louis030195 Can I fix all this on weekend? I will make sure to complete this issue

sure

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

Successfully merging this pull request may close these issues.

[bounty] use fts for window name and app name
2 participants