meilisearch-rust
meilisearch-rust copied to clipboard
[v1.13] Stabilize AI-powered search
Following the changes related to Meilisearch v1.13.0 mega issue:
Description
Integrate AI-powered search features as stabilized in Meilisearch v1.13.0.
Since AI-powered search was initially introduced Meilisearch v1.3 as an experimental feature an subsequently refined in later releases, some features may already be partially implemented. The goal of this issue is to update the SDK to align with the stabilized API in v1.13.0.
Specifications
Update settings to handle embedders
Docs: https://www.meilisearch.com/docs/reference/api/settings#embedders
- [ ]
embedderssetting. MethodsgetEmbedders,updateEmbedders,resetEmbedders. Also, the methodupdateSettingsshould be able to accept the newembeddersfield. Here is the list of the acceptable sub fields:- [ ]
sourcesub field is available and accepts:ollama,rest,openAI,huggingFaceanduserProvided - [ ]
apiKeysub field is available (string) - optional because not compatible with all sources. Only foropenAi,ollama,rest. - [ ]
modelsub field is available (string) - optional because not compatible with all sources. Only forollama,openAI,huggingFace - [ ]
documentTemplatesub field is available (string) - optional - [ ]
dimensions- optional because not compatible with all sources. Only foropenAi,huggingFace,ollama, andrest - [ ]
distribution- optional - [ ]
request- mandatory only if usingrestembedder - [ ]
response- mandatory only if usingrestembedder - [ ]
documentTemplateMaxBytes- optional - [ ]
revision- optional, only forhuggingFace - [ ]
headers- optional, only forrest - [ ]
binaryQuantized- optional
- [ ]
Update search to handle vector search and hybrid search
Docs: https://www.meilisearch.com/docs/reference/api/search
- [ ] Search
- [ ]
hybridsearch parameter, with sub fieldssemanticRatioandembedder.embedderis mandatory ifhybridis set. - [ ]
vectorparameter is available - [ ]
retrieveVectorsparameter available - [ ]
semanticHitCountin search response - [ ] Accept
_semanticScorein the search response (optional) - [ ]
vectorshould be returned in the search response, but optional (because depends on search parameters) - [ ]
_vectorsshould NOT be present in the search response
- [ ]
Add similar documents endpoint
Docs: https://www.meilisearch.com/docs/reference/api/similar
- [ ] Similar. Implement
searchSimilarDocumentsassociated with thePOST /indexes/:uid/similar. Do NOT implement withGET.