Repository navigation
Catalog search: typo tolerance and aliases - #1051
Merged
Merged
Conversation
Optional "aliases" on adapter JSONs (AdapterMeta, listAdapters, validator, docs) for former names, translations, short forms and umbrella brands. Added to 24 adapters: Mercado Livre, amoCRM, Facebook/Meta on the Meta connectors, Twitter, D365, Navision, SAP B1, lexoffice, base.com, Sendinblue, AdWords and others. Aliases do not change adapter versions.
One search module (backend adapters/catalog-search.ts, byte-identical copy
in frontend lib/, checked by a spec) replaces the scorer in
setup_find_connectors and the store's matchesSearch:
- stopwords in en/de/es/it/pt/fr dropped ("bot de telegram" -> telegram);
- direct matches ranked: whole name or alias, word, word start, other text;
- fewer than 3 direct results: Damerau-Levenshtein fallback on slug, name
and aliases (1 edit for 4-6 letters, 2 for longer, same first letter for
short words), capped and ranked below direct matches;
- a multi-word query with no full match falls back to partial matches;
- a one-letter query matches only an exact slug, name or alias.
catalog_search events now carry missing words from every surface and
match=direct|fuzzy|partial, so typo-rescued searches stay visible.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
From the 12 Oct demand review: 11 workspaces got nothing for typos such as "telgram" (Telegram is the most-searched term), and "mercado livre", "amocrm" and "facebook" found nothing.
What changes
One search module,
adapters/catalog-search.ts, now drives three places: the chat find tools (setup_find_connectors/anythingmcp_find_connectors), the store and /welcome. The frontend keeps a copy, and a test fails if the two drift apart.How a query is matched:
Aliases. There is a new optional
aliasesfield on adapters, and 24 adapters get it, e.g. Mercado Livre, amoCRM, Twitter, Sendinblue, OTRS, D365 and GA4.Logging.
catalog_searchevents now carrymissingandmatch(direct/fuzzy/partial), so searches rescued by typo matching are still counted.Unlisted adapters never appear, on Cloud or self-hosted.