Open grtjn opened 8 years ago
Suppressing qtext by default in this particular case of typeahead suggest, might be more intuitive actually..
I wonder if this should be a search:suggest()
RFE ...
Also, there's a cursor-position
parameter that lets you limit how much of the text to match: http://docs.marklogic.com/REST/GET/v1/suggest.
Do you picture overriding this consistently for an application, as a toggle, or an a per-call basis?
Cursor position just influences which part to replace or expand. It does not constraint value suggestions.
Those are constrained by the qtext and structured query in the combined query post body. And the qtext is effectively from the previous time you submitted a search. But if you are extending or replacing the search string, then that would be confusing.
So i'm actually thinking the default should be to suppress qtext.. but a toggle somewhere might be wise too..
A co-worker was playing with typeahead in slush, and noticed that if you search for
eyeColor:blue
first (and actually apply that), and then continue typing with for instanceOR eyeColor:b
, you only get a suggestion for blue, and not for brown or any other value.We applied the following line as a workaround (around line 1185), but maybe this should be permanent, or a toggle/option? We do have an options argument, right?