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

v1.8 hybrid search changes #4548

Merged
merged 13 commits into from Apr 4, 2024
Merged

v1.8 hybrid search changes #4548

merged 13 commits into from Apr 4, 2024

Conversation

dureuill
Copy link
Contributor

@dureuill dureuill commented Apr 3, 2024

Implements the search changes from the usage page

⚠️ Breaking changes in an experimental feature:

  • Removed the _semanticScore. Use the _rankingScore instead.
  • Removed vector in the response of the search (output was too big).
  • Removed all the vectors from the vectorSort ranking score details
    • target vector appearing in the name of the rule
    • matched vector appearing in the details of the rule

Other user-facing changes

  • Added semanticHitCount, indicating how many hits were returned from the semantic search. This is especially useful in the hybrid search.
  • Embed lazily: Meilisearch no longer generates an embedding when the keyword results are "good enough".
  • Graceful embedding failure in hybrid search: when doing hybrid search (semanticRatio in ]0.0, 1.0[), an embedding failure no longer causes the search request to fail. Instead, only the keyword search is performed. When doing a full vector search (semanticRatio==1.0), a failure to embed will still result in failing that search.

@dureuill dureuill added this to the v1.8.0 milestone Apr 3, 2024
@dureuill dureuill requested a review from Kerollmops April 3, 2024 09:00
@dureuill dureuill mentioned this pull request Apr 3, 2024
7 tasks
@dureuill dureuill requested a review from a team April 4, 2024 13:49
meilisearch/src/routes/indexes/search.rs Outdated Show resolved Hide resolved
Co-authored-by: Tamo <tamo@meilisearch.com>
Copy link
Member

@irevoire irevoire left a comment

Choose a reason for hiding this comment

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

Thanks,
bors merge

meili-bors bot added a commit that referenced this pull request Apr 4, 2024
4548: v1.8 hybrid search changes r=irevoire a=dureuill

Implements the search changes from the [usage page](https://meilisearch.notion.site/v1-8-AI-search-API-usage-135552d6e85a4a52bc7109be82aeca42#40f24df3da694428a39cc8043c9cfc64)

### ⚠️ Breaking changes in an experimental feature:

- Removed the `_semanticScore`. Use the `_rankingScore` instead.
- Removed `vector` in the response of the search (output was too big).
- Removed all the vectors from the `vectorSort` ranking score details
  - target vector appearing in the name of the rule
  - matched vector appearing in the details of the rule

### Other user-facing changes

- Added `semanticHitCount`, indicating how many hits were returned from the semantic search. This is especially useful in the hybrid search.
- Embed lazily: Meilisearch no longer generates an embedding when the keyword results are "good enough".
- Graceful embedding failure in hybrid search: when doing hybrid search (`semanticRatio in ]0.0, 1.0[`), an embedding failure no longer causes the search request to fail. Instead, only the keyword search is performed. When doing a full vector search (`semanticRatio==1.0`), a failure to embed will still result in failing that search.

Co-authored-by: Louis Dureuil <louis@meilisearch.com>
Copy link
Contributor

meili-bors bot commented Apr 4, 2024

Build failed:

  • Tests on windows-2022

@dureuill
Copy link
Contributor Author

dureuill commented Apr 4, 2024

bors merge

Copy link
Contributor

meili-bors bot commented Apr 4, 2024

Build succeeded:

@meili-bors meili-bors bot merged commit b1844b0 into main Apr 4, 2024
10 checks passed
@meili-bors meili-bors bot deleted the improve_hybrid_search branch April 4, 2024 16:40
@meili-bot meili-bot added the v1.8.0 PRs/issues solved in v1.8.0 released on 2024-05-06 label May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
v1.8.0 PRs/issues solved in v1.8.0 released on 2024-05-06
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants