Autocomplete combines separate words into one

Created on 22 October 2024, 3 months ago

Problem/Motivation

I have been using Search API and Search API Autocomplete which have both been working almost perfectly, however I cannot resolve an issue where some suggestions combine separate words into one. From my troubleshooting, it seems that this happens to terms in the title field. I attached screenshots of what I mean. In both screenshots, the highlighted words are the title of content with the whitespace removed. You can also see what I mean where most of the autocomplete terms are fine, just not the titles.

I need help from somebody more familiar with this module better to help me figure out why autocomplete merges titles into a single word instead of keeping it the same as how it is displayed on the page.

Steps to reproduce

This issue seems to happen out of the box when I set up Search API Autocomplete and configure it to search the rendered HTML output and the Title field.

1) Install Search API and Search API Autocomplete
2) Configure both of these so that they index the title and the rendered HTML content so both can be searched
3) Search for a term

Settings Used:

- I configured it to only search content and selected the exact content I want to search using the index settings.
- In the fields section, I specified that the Rendered HTML Output and the Title is type Full Text.
- I went through the stemmer and tokenizer settings and ensured "Enable this processor on the following fields" is checkmarked for both Rendered HTML Output and Title on both processor settings.
- I left the whitespace characters as the default as the site is in English and uses the latin alphabet

πŸ’¬ Support request
Status

Active

Version

1.9

Component

Miscellaneous

Created by

πŸ‡¨πŸ‡¦Canada ciesinsg

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @ciesinsg
  • πŸ‡¦πŸ‡ΉAustria drunken monkey Vienna, Austria

    Could you please supply a few more details regarding your setup?

    1. Which search backend are you using – Database, Solr, or something else?
    2. Which suggester plugin(s) are you using for Autocomplete?
    3. Can you use your browser’s Web Developer Tools to retrieve the exact JSON response you receive from the autocomplete endpoint?
    4. In both your screenshots the offending suggestion is the highlighted one. Can you confirm that the suggestion still looks wrong if you move the highlight to a different row?
  • πŸ‡¨πŸ‡¦Canada ciesinsg

    Hi there, very sorry for the delay in replying.

    This can be chalked up to user (me) error. Upon further investigation, I found that the website content contained the combined words, so the module is working as intended.

    Closing the issue, and thanks anyways for trying to help!

Production build 0.71.5 2024