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

[Bug]: Orama search results are sometimes very long and unformatted #656

Closed
GiyoMoon opened this issue Apr 6, 2024 · 7 comments · Fixed by #660
Closed

[Bug]: Orama search results are sometimes very long and unformatted #656

GiyoMoon opened this issue Apr 6, 2024 · 7 comments · Fixed by #660
Assignees
Labels
bug Something isn't working pending review Awaiting review by team members.

Comments

@GiyoMoon
Copy link
Contributor

GiyoMoon commented Apr 6, 2024

📝 Issue Description

Sometimes, depending on the result, orama outputs very long and unformatted search results.

📋 On which page(s) it occurs

On all pages

🤔 Expected Behavior

The search results should always be shortened like this:
image

👀 Current Behavior

Sometimes, depending on the result, orama outputs very long and unformatted search results. Here I'm searching for few and the results are a mess:
image

🖥️ Browser

Chromium Engine Version 123.0.6312.106

📄 Additional Information

No response

@GiyoMoon GiyoMoon added bug Something isn't working pending review Awaiting review by team members. labels Apr 6, 2024
@GiyoMoon GiyoMoon changed the title [Bug]: Orama search result is sometimes very long and unformatted [Bug]: Orama search results are sometimes very long and unformatted Apr 6, 2024
@atilafassina
Copy link
Member

Orama searchbox does not have syntax highlighting for the results (the Summary AI feature does).

if it's not easy to have it on SearchBox, we could perhaps add a new entry to the entries frontmatter with a text-only description (no code-snippets).

Wdyt, @LadyBluenotes / @SaraVieira ?

@SaraVieira
Copy link
Contributor

I think this is on our side, we could add syntax highlights but honestly descriptions shouldn't have them, what about a trim to like 200 characters? What y'all think?

@GiyoMoon
Copy link
Contributor Author

GiyoMoon commented Apr 8, 2024

I think it would be best to exclude code snippets there. It also results in things like here where it actually renders an input and checkbox:
image

@GiyoMoon
Copy link
Contributor Author

GiyoMoon commented Apr 8, 2024

It feels like it's an issue with the search algorithm, because usually the searched word is marked bold and here, the search query few doesn't even occur in the description text and it just results in a really large text that seems random. Perhaps a fuzzy search that behaves weirdly?

@SaraVieira
Copy link
Contributor

Honestly this an awesome find, bad bug but incredible on how cursed it is either way lol

Gonna try to get a new release today that removes all the code snippets from the results

@SaraVieira
Copy link
Contributor

Okay this PR #660 fixes the code, I am now fixing the fact that these descriptions are way too long

@SaraVieira
Copy link
Contributor

fixed by #660

ended up doing all in there

cc @danieljcafonso

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working pending review Awaiting review by team members.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants