I'm using autocomplete on a field in Azure Search... it works great, however I want the autocomplete results to return the next "x" number of words (like in the following screenshot https://learn.microsoft.com/en-us/azure/search/index-add-suggesters)
I've tried all three Autocomplete types "oneTerm", "twoTerms" and "oneTermWithContext" however none of those give me the expected results.
I expect to type "tom clan" and autocomplete should return "tom clancys rainbow six siege"
Excellent point about the documentation showing several words in the example and the autocomplete API only supporting up to two terms ahead. I think we should update the example to better reflect the actual behavior of the API.
If you are interested, please create a feedback item for the API enhancement you suggested so it can collect some votes: https://feedback.azure.com/forums/263029-azure-search
Thanks!
Mike Carter
Azure Search product team
Related
I am trying to create a list item with a multiselect field, according to the m365 spo documentation. It feels like I have tried all possible variations, but I cannot get it to work at all.
Is there any official guide as to the syntax for a multi-select value?
Ok, for whomever bangs their heads against this in the future, the format for the seeds of a multi-lookup field is the following:
Id;Value;#
Where ;# is the separator. You may use # as a wildcard for a value, ending up with the following example where I am adding the related entities with Id 3 and 5 to the seed:
3;#;#5;#
or one single entity:
1;#
or three entities:
2;#;#3;#;#5;#
There seems to be a tiny bit of tolerance on the trailing value, but I did not experiment much with this.
PS: it works, and I am very happy, but dear reader know this: if you feel the need for some eye-bleach after reading this, you are not alone!
We have monorepo, my team responsible for 3 of 20 packages/folder of repository, but sometimes we need to touch others packages/folders.
For reviewing teammates changes every member should add “team_label” for ability to filter by this label or to keep opened several tabs with merge requests for each author/team member.
Preferable could be filtering MRs something like this by one of the author:
author: username1 OR author:username2 OR author:username3
We are using GitLab Enterprise Edition 12.6.2-ee
upd:
discussed in gitlab docs comments and there is no ability to filter merge requests even with advanced search
Advanced Search does currently not have the facets available that you use in the dedicated issue or MR search
https://docs.gitlab.com/ee/user/search/index.html#comment-4776091890
Feature proposal:
https://gitlab.com/gitlab-org/gitlab/issues/7826
To filter merge request and all the other kind of thing you want to search for you can read this guide on how to search with filters:
GitLab Filter Guide
Anyway if you want a quick suggestion you have to go in the "Merge request" section of your sidebar menu. After that, you can see on the upper part of the tables where all the merge request are listed a little search bar that says "Search or filter results..." if you click on that a little dropdown opens up to suggest you how to use the search bar.
To search in a list of all the authors you have to input the following: author: (this will let you see a little dropdown with all the authors) or you can search directly with an author name putting a "#" before his name.
If you want to concatenate more filter criteria you have to put AND or OR as you would do in a SQL query. But anything is well explained in the guide.
Unfortunately to date you can't search merge requests with an OR query - and although gitlab states that successive clauses should be ANDed together a quick test suggests that in fact an arbitrary single clause is applied.
See e.g. https://forum.gitlab.com/t/mr-filtering-by-multiple-authors/33864
I am using Amazon Api to search for item. I am doing a simple
amazon.ItemSearch(Keywords="Sachin Tendulkar", SearchIndex="All", ResponseGroup="ItemAttributes")
But the result is not a popular Sachin Tendulkar book or the best search I would want.
How can I get multiple results in Item Search ?
How can I get the most popular search result?
amazon.ItemSearch(Keywords="UC Berkeley", SearchIndex="All", ResponseGroup="ItemAttributes")
gives even worse results.
Is there an option in the API that I am missing? Thanks
If you're not getting the results you expect, adjusting the SearchIndex option to something other than "All" can often help improve the results by making a less broad search.
If you change it to "Books", do you get the expected results for "Sachin Tendulkar"?
In case that doesn't fix the problem, do you get expected results for really common searches like "Apple TV"? And when you search for "Sachin Tendulkar" or others on Amazon.com do you the items returned by your API request show up at all (perhaps even pages down)?
We have a website where users put up ads for stuff they want to sell, with parameters such as price, location, title and description. These can then be searched for using sphinx and allowing users to specify min- and maxprice, a location with a searchradius (using google maps) etc. Users can choose to save these searches and get emails when new ads appear that fit their search. Herein lies the problem: We want to perform a reverse search every time an ad is posted. With the price, location, title and description as parameters we want to search through all the saved "searches" and get the ones that would have found the ad. The min- and maxprice should just be performed in a query i suppose, and some Quorom syntax to get all ads with at least 2 or mby just 1 occurance in the title/description. Our problem lies mostly in the geo-search. How do we find all searches where the "search-circles" would include our newly posted location without performing a search for every saved search?
That is the main-question, any comment on our suggested solution to the other problems is also very welcome. Thank you in advance / Jenny
The standard 'geo-search' support on sphinx should work just as well on a Prospective Index, as a normal retrospective search.
Having built a sphinx 'index' of all the saved searches...
And you run a query using the 'ad' as the search query:- rather than the 'filter' using a fixed radius, you just use the radius from the attribute (ie the radius stored on the particular query) - if using the API cant use setFilterRange directly, need to use setSelect, to make a new virtual attribute.
$cl->setSelect("*,IF(#geodist<radius,1,0) as myfilter");
$cl->setFilter('myfilter',array(1));
(and yes, the min/maxprice can just be done with normal filters too - just inverting the logic to that you would use in a retrospective search)
... the complication is in the 'full-text' query, if the saved search is anything more than a single keyword, but you appear to have already figured out that part.
I have one issue which I am in desperate need for your help. I am on Magento ver. 1.6.1.0, whenever I am searching with a sentence like "baby's cute shoes" in magento then the results are not accurate but when I search only a word like "cute" or "shoes" then it gives me the result.
I have a feeling that magento is not able to search a sentence but it is able to search products with words. Is there anything I can do to better optimize the search in magento?
The options for search can be found in the backend under System > Catalog > Catalog search, you probably have search type set to LIKE. You will potentially get better results using FULLTEXT mode.
Magento does not search the entered string as a full sentence. Instead it splits (tokenizes) your search string into words and will search for products containing ANY of these words (implementing "OR" logic). So if you are searching for "red shoes", it will find everything containing words "red" OR containing words "shoes". Obviously it is not very useful in most cases as it will produce a lot of totally irrelevant results.
You can check this free extension to refine your search: Catalog Search Refinement FREE. This extension modifies the search behavior to only find the products that have ALL keywords ("AND" logic in other words). This will find only products that have both "red" and "shoes" keywords. There is also Advanced Search version of that extension that also looks up for similar words based on phonetic distance among other things as well as weighted search attributes, allowing to bubble up the most relevant products.
I got my issue resolved by this link - https://stackoverflow.com/questions/1953715/magento-search-not-returning-expected-results
I went to this line in app/code/core/Mage/CatalogSearch/Model/Resource/Fulltext.php
and did this (below)
copy app/code/core/Mage/CatalogSearch/Model/Mysql4/Fulltext.php to app/code/local/Mage/CatalogSearch/Model/Mysql4/Fulltext.php
line 341 - 343 app/code/local/Mage/CatalogSearch/Model/Mysql4/Fulltext.php
if ($like) {
$likeCond = '(' . join(' OR ', $like) . ')';
}
change into
if ($like) {
$likeCond = '(' . join(' AND ', $like) . ')';
}
Also make sure to change the order in which the results are shown. Default Magento is to serve it backwards.
Add the following to /app/design/frontend/default/default/layout/catalogsearch.xml
<reference name="search_result_list">
<action method="setDefaultDirection"><string>asc</string></action>
<action method="setDefaultOrder"><string>relevance</string></action>
</reference>
Between the following:
<catalogsearch_result_index translate="label">
...
</catalogsearch_result_index>
Stock Magento search needs a few tweaks to get it functional. The Like search was changed from AND logic to OR logic in 1.5/1.6 and gives better results when reverted back to AND logic. This has been solved in several threads over in the Magento forums on Magento's website. Another fix is to to chop the s off of plurals which is also addressed over there.
The reason for cutting trailin "s" is that most people don't search for "an oil pressure gauge", but "oil pressure gauges" which gives total misses when you're selling a "0-100 psi Oil Pressure Gauge". Also alias all items ending in "ies" to their singular. Rarely do you sell an "rc aircraft batteries", it will be specific like "1200aH aircraft battery" and so your less savvy customer's searches never match.
"Baby's cute shoes" will never register a hit unless it shows up in the items you use to populate the Fulltext search index. Who sells an item called "baby's cute shoes" anyway? I usually synonym these types of searches to hit a specific category where the items are listed. Some customer searches are just too subjective to match the objective nature of product search (actual items vs. nebulous idea).