It’s possible to have your searches search first with an
AND based operator if you customize the search request on your server’s side before it is sent to your Swiftype engine.
Some customers use our jQuery client library along with their own custom function(s) as a way to insert an
AND operator between each search term typed in by the end user.
For example, if someone types apple pen pineapple into the search box (and you have the search on your site set to insert the
AND operator), your custom script could process and send the query as apple AND pen AND pineapple once the search request is submitted.
When the formatted request is received by Swiftype we’ll apply the boolean operators and return the expected results, excluding those partial phrase matches.
Ways we’ve seen folks achieve this within their UX is by having a dropdown that allows the end user to select which operator to use in their search, triggering the preferred processing function. Or, even more simply, instead of writing custom logic you could include some informational text near the search input that informs the user that
OR, & “quotation” boolean operators are supported.
If you’d prefer your engine to return only
AND based results by default setting (making it so users would need to manually add
OR to their request to get partial matches), we can make that adjustment to your engine from our end. Just let us know!