Skip to content

v0.28: Smart cropping #1687

@guimachiavelli

Description

@guimachiavelli

Currently, when using attributesToCrop, Meilisearch will start cropping at the first occurrence of any search term. If a user searches for 'white car', cropping of 'the woman in the white shirt drove a white car' will be centred on the first 'white', even though the second occurrence includes both terms.

With v0.28, a new cropping algorithm will instead centre cropping so it includes the highest possible number of search terms. We are calling this "smart cropping."

References

PR: meilisearch/milli#483
Issue on core: meilisearch/meilisearch#2299
SME: @ManyTheFish

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions