Page MenuHomePhabricator

Completion Suggester: Searching for a subpage title using the search bar at the top of the page doesn't propose it for autocomplete
Closed, ResolvedPublic


With the completion suggester (currently-beta) feature enabled...

If a subpage like Blah/Yada exists, typing Yada into the search bar at the top of a page doesn't offer any auto-complete suggestions. I think it should treat the page title as if it were "Yada" for search purposes, since to a human, the page title really is Yada. The fact that it happens to be a sub-page is irrelevant. My test case on mediawiki was Team Practices Group/Glossary.

I filed a separate similar task for basic prefix search..

Event Timeline

ksmith raised the priority of this task from to Needs Triage.
ksmith updated the task description. (Show Details)
ksmith updated the task description. (Show Details)
ksmith set Security to None.

the wider question revolves around how to tokenize the completion suggester. Today it maintains the same functionality it had before, where it had to be a strict prefix from the very beginning. This is something we very much could support, although there is a question of how much bigger it makes the index (since the completion suggester index has to be stored in memory).

iirc we were planning to revisit this after updating to the new version of elasticsearch completion suggester, which relaxes some of the requirement to store the entire completion search data structure in java heap

debt triaged this task as Medium priority.Aug 22 2016, 9:52 PM
debt moved this task from needs triage to This Quarter on the Discovery-Search board.
debt added a subscriber: debt.

Let's do some homework on this and see how big it would make the index. We can make the decision to work on it (or not) after that.

Change 308755 had a related patch set uploaded (by DCausse):
CompletionSuggester: add support for subphrase/subpage suggestions

I've built 4 new completion suggester indices:

Unfortunately the impact on the index size is not negligible (with replicas you need to multiply by 3):

  • with subpages: 2 534 391 vs 1 863 375
  • with subphrases: 3 522 931 vs 1 863 375
  • enwikisource with subpages: 84 667 658 vs 55 566 373
  • enwikisource with subphrases: 169 753 118 vs 55 566 373

If this feature is really useful we should enable it on a case by case basis, one option would be to reduce the number of replicas from 2 to 1 for these wikis.

I've lost the little html demo we used to evaluate the completion suggester, should I take some time to rebuild one to compare current vs. subpages vs subphrases?

I threw together a quick js demo like we had on suggesty in the past, it works from any relforge-search domain at /w/completion-demo.html, as in:

To make it slightly harder to lose like the code on suggesty, also made a pastie: P3995

Let's review the demo and see how things are looking

Change 308755 merged by jenkins-bot:
CompletionSuggester: add support for subphrase/subpage suggestions

Change 281468 had a related patch set uploaded (by DCausse):
Allow user to customize search suggestion profile.

Change 281468 merged by jenkins-bot:
Allow users to customize search suggestion profile

Code work is done, this will be deployed with T146208