I am using a View with a search filter on this page: hidden link I also have Relevanssi installed on our site. I've checked all of the Relevanssi settings and everything looks good, I have given a lot of weight to the title of the post vs content, and I have rebuilt the index.
The problem is that the search results are terrible. I can search for a word and the top 10-20 results don't even contain that word. However, when I go to Dashboard > Admin Search the results are perfect. How can I get the View search results closer to what I see on the Admin Search?
I have weighted the title so much higher than the content in Relevanssi's search setting that this doesn't make sense. Are these settings not applied to the Toolset search?
Well - you will require to check this with Relevanssi support as when you use Relevanssi integration Toolset's role is just passing the whole query to Relevanssi and Relevanssi handles further.
I also noticed the all posts are not indexed. It get stuck after:
Indexed 316 posts (total 624), processed 624 / 1287.
Please get in touch with Relevanssi support and share what is your expected output and they will help you to adjust the relevanssi query accordingly.
I asked the makers of Relevanssi about this first, and they said they didn't know anything about Toolset or how it handles the query or results, which is why I came here. Can you please tell me in a more specific and technical way how Toolset interacts with Relevanssi so I can tell them, and then ask them what might be the problem?
when you use the Relevanssi integration the search query will be passed over to Relevanssi, having said that relevenssi will the reponsible to handle, build and run the query.
I see there are number of hooks available as per their doc:
I see the indexing issue on the staging site, I can't explain that, but on the live production site there is no indexing issue. It has indexed all pages, posts, and the 'film' custom post type.
Relevanssi support has walked me through a few different searches of the site. The problem is that the site results outside of Toolset are all working as expected. In fact, admin search and basic site search of a word in the 'film' post type get the same excellent results. The results in the Toolset View are almost a complete inversion of the admin search results-- those posts that appear at the top of the admin search are at the very bottom of the View search. It's not a complete 1:1 inversion, but very close.
The only ordering options in Relevanssi are to order by relevance or post date, and I have it set to 'relevance' (the default). There is no "inverse relevance" option, but that appears to be what the View is doing with the results it is getting from Relevanssi.