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

Reasons for not working queryRule #151

Open
pixelkoduje opened this issue Feb 24, 2023 · 5 comments
Open

Reasons for not working queryRule #151

pixelkoduje opened this issue Feb 24, 2023 · 5 comments

Comments

@pixelkoduje
Copy link

For what technical reasons are these features not working with the latest typesense?
queryRuleCustomData
queryRuleContext

@jasonbosco
Copy link
Member

While Typesense server supports query rules (called overrides / curation in Typesense), we don't support returning custom data or context in overrides yet. So we would need to first add these features to Typesense server, before we can add support in the adapter.

Could you open separate issues for each in Typesense repo, along with your use-case for each of these? We can then prioritize based on demand.

@pixelkoduje
Copy link
Author

I believe that if we do at least part of this element - and suggestions (out of the box), we can chase even algolia very quickly. I think that dynamic widgets were already a milestone. Because it's such a hot feature.

@pixelkoduje
Copy link
Author

Hello @jasonbosco.
https://www.algolia.com/doc/api-reference/widgets/query-rules/react-hooks/
It is the same as dynamicWidget. It just tracks and returns results - based on what's active. I don't think it matters, in the context of typesense. It would be nice if you did that with the new update. For larger projects, this is a useful feature - including my project I wrote about.
image
Also works, but returns no results.

@pixelkoduje
Copy link
Author

From what I can see there is no problem to implement this. Even if we download e.g. "banners" from an external collection - we use multisearch after all. Let's do that and typesense will be fully ready replacement instead of algolia.

@jasonbosco
Copy link
Member

In the case of dynamicWidgets, it requires facet data and this information is already returned by the Typesense Server API response and this adapter just transforms those facet counts to a format that dynamicWidgets understands.

But in the case of the query rules related widgets, the Typesense Server API does not return the data required to transform it to the instantsearch format, since Typesense Server API does not support these particular features (query rule context and query rule user data)...

If you're anyway using multi-search to download banners, one thing you could do is, use transformItems in the hits or infiniteHits widgets to access particular items in the search results?

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

No branches or pull requests

2 participants