SlideShare a Scribd company logo
1 of 40
Download to read offline
Query relaxation
A rewriting technique between search and recommendations
René Kriegler, @renekrie
Haystack - The Search Relevance
Conference
24 April 2019
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
About me
More than 10 years experience as a freelance search consultant, often in a role
for OpenSource Connections
Focus:
- Search relevance optimisation
- E-commerce search
- Solr
- Coaching teams to establish search within their organisation
Organiser of MICES - Mix-Camp E-commerce Search (Berlin, 19 June,
mices.co, right after Berlin Buzzwords)
Maintainer of Querqy (OSS query rewriting library - github.com/renekrie/querqy)
2
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
No results
3
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
No results - strategies
Apply synonyms and hyponyms (laptop = notebook; shoes => trainers)
Spelling correction (Did you mean ...? / We’ve searched for ...)
Also search in low-quality data fields
Loosen boolean constraints (AND -> OR, mm<100%)
Apply hypernyms (boots => shoes)
Use more distant semantic relation (beard balm => trimmer)
Show more general recommendations (related to user’s shopping history,
popular items)
4
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
No results - strategies
Apply synonyms and hyponyms
Spelling correction
Also search in low-quality data fields
Loosen boolean constraints
Apply hypernyms
Use more distant semantic relation
Show more general recommendations
5
Explainable?
(in e-commerce search)
Don’t want to tell
mm: no; AND/OR: yes, but bad UX
Don’t need to tell
Can be hard
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
No results - Query relaxation
6
Explainable!
(& conversational!)
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation
Which query term should be removed?
7
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation - intuition
8
iphone 9 => iphone 9
(*) iphone 9 => iphone 9
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation - intuition
9
iphone 9 plus => iphone 9 plus
(?) iphone 9 plus => iphone 9 plus
(?) iphone 9 plus => iphone 9 plus
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation - intuition
10
black boots => black boots
(*) black boots => black boots
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation - intuition
11
purple boots => purple boots
(?) purple boots => purple boots
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation - intuition
12
(?) usb charger 12v => usb charger 12v
(?) usb charger 12v => usb charger 12v
(?) usb charger 12v => usb charger 12v
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query intent & information need
Apply synonyms and hyponyms
Spelling correction
Also search in low-quality data fields
Loosen boolean constraints
Apply hypernyms
Use more distant semantic relation
Show more general recommendations
13
Trying to match original information
need
Remotely related to user intent
Query relaxation
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation
14
“A popular approach to cope with empty-answers is query relaxation, which attempts to reformulate the
original query into a new query, by removing or relaxing conditions, so that the result of the new query
is likely to contain the items of interest for that user.” (Mottin et al., 2013)
“We present a method which we call relaxation for expanding deductive database and logic
programming queries. The set of answers obtained with the relaxation method includes both answers
deduced traditionally and answers related in some way with the original query. The relaxation method
expands the scope query by relaxing the constraints implicit in the query.” (Gaasterland et al., 1992)
“An extended query-document matching system is described in this study that relaxes the stringent
requirements of the conventional Boolean retrieval operations.” (Salton et al., 1983)
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Query relaxation
15
=> How can we find the best query term to be removed from the query so that
“... the result of the new query is likely to contain the items of interest for that user”
“... answers [are] related in some way with the original query” ?
=> How can we test, compare and optimise solutions?
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Online testing
16
Click-through-rate / hit rate
Exit rate / time spent on site
=> Do we manage to keep the user interacting with our site?
=> similar to recommendations / exploratory search
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Finding the term to be dropped: data sets
17
Data sets for training and evaluation
Find pairs:
- a long query having 0 results
- a corresponding relaxed query having results
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Finding the term to be dropped: data sets
18
FREQ: Query frequencies
- Have we observed the original and the relaxed query before? (We want to
make sure that we produce a meaningful query.)
COOC: Query cooccurrences per session
- Have the original and rewritten query occurred together in a session?
=> Can we find the original/rewritten query pair in tracking data? How often?
(more often is better)
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
0 - Drop random term (baseline)
19
Remove a random term from the query
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
1 - Drop shortest term
20
Remove the shortest term from the query
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
2 - Drop shortest non-alphabetical term
21
Remove the shortest term that doesn’t contain any alphabetical character
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
3 - Combined 1 and 2
22
Remove the shortest term that doesn’t contain any alphabetical character, fall
back to removing shortest term if all terms have >=1 alphabetical character
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
4/5 - Drop most/least frequent term
23
Remove the term with the highest/lowest index frequency
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
6/7 - Drop term with highest/lowest entropy
24
Remove the term with the highest/lowest entropy across navigational categories
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
8 - Keep most similar query (Word2vec)
25
Use the rewritten query that is most similar to the original query based on
Word2vec embeddings [as mentioned in D.Tunkelang, Query relaxation,
https://bit.ly/2ItxF3Z]
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Word2vec (CBOW)
26
w (t-2)
pepe jeans
w(t)
projection
Input
Output
slim cut
w (t-1) w (t+1) w (t+2)
london
london
Sequence of words
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
8 - Keep most similar query (Word2vec)
27
Use the rewritten query that is most similar to the original query based on
Word2vec embeddings
Train Word2Vec embeddings
- word = query term, window = query
- 300 dimensions
Use sum of word(=term) vectors to represent the queries (original/rewritten)
Calculate cosine similarity between original query and each rewritten query
Use rewritten query that is most similar to the original query
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
8 - Keep most similar query (Word2vec)
28
Use the rewritten query that is most similar to the original query based on
Word2vec embeddings
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
9 - Keep most similar query (Query2vec)
29
Use the rewritten query that is most similar to the original query based on query
embeddings
[Grbovic et al., Scalable Semantic Matching of Queries to Ads in Sponsored Search Advertising. SIGIR
2016]
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
‘Query2vec’ (CBOW)
30
q (t-2)
smartphone smartphone 64g
q (t)
projection
Input
Output
iphone iphone 64g
q (t-1) q (t+1) q (t+2)
galaxy 64g
galaxy 64g
Queries in a session
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
9 - Keep most similar query (Query2vec)
31
Use the rewritten query that is most similar to the original query based on Query
embeddings
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
10 - MNN with Word2vec input
32
Predict the term to be dropped using a multi-layer neural network (MNN) with
Word2vec embeddings as input.
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
10 - MNN with Word2vec input
33
0: 0.01
1:-0.94
...
300: 0.18
0: 0.63
1: 0.56
...
300: 0.04
0:-0.59
1: 0.02
...
300: 0.77
0: 0.00
1: 0.00
...
300: 0.00
0: 0.00
1: 0.00
...
300: 0.00
0: 0.00
1: 0.00
...
300: 0.00
0: 0.00
1: 0.00
...
300: 0.00
0: 0.00
1: 0.00
...
300: 0.00
nike boots 11
0: 0 0: 1 0: 0 0: 0 0: 0 0: 0 0: 0 0: 0
2 hidden layers
Input
Output
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
10 - MNN with Word2vec input
34
Predict the term to be dropped using a multi-layer neural network (MNN) with
Word2vec embeddings as input
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
11 - MNN / Word2vec plus wordshape
35
Predict the term to be dropped using a multi-layer neural network (MNN) with
Word2vec embeddings and wordshape features as input.
Add additional dimensions to the input vector:
- Word length
- Number of digits
- Does the word have an ‘e’ in the penultimate or ultimate position?
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
11 - MNN / Word2vec plus wordshape
36
...
301: 4.00
302: 0.00
303: 1.00
...
301: 5.00
302: 0.00
303: 0.00
...
301: 2.00
302: 2.00
303: 0.00
...
301: 0.00
302: 0.00
303: 0.00
...
301: 0.00
302: 0.00
303: 0.00
...
301: 0.00
302: 0.00
303: 0.00
...
301: 0.00
302: 0.00
303: 0.00
...
301: 0.00
302: 0.00
303: 0.00
nike boots 11
0: 0 0: 1 0: 0 0: 0 0: 0 0: 0 0: 0 0: 0
2 hidden layers
Input
Output
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
11 - MNN / Word2vec plus wordshape
37
Predict the term to be dropped using a multi-layer neural network (MNN) with
Word2vec embeddings and wordshape features as input.
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
11/12 - MNN / Word2vec plus term stats
38
Predict the term to be dropped using a multi-layer neural network (MNN) with
Word2vec embeddings and per-field DF or index frequency.
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Conclusion
39
Query relaxation:
- best understood as a query recommendation
- information need not necessarily matched but relaxed query still related to
user intent
- can be communicated nicely to the user (‘conversational’)
Best approach to find term to be dropped:
- Multi-layer neural network with Word2Vec plus wordshape features as
inputs. It can be extended to incorporate further features and optimisation
targets.
Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie)
Thank you!
http://www.rene-kriegler.com
@renekrie
40

More Related Content

What's hot

Lexical Semantics, Semantic Similarity and Relevance for SEO
Lexical Semantics, Semantic Similarity and Relevance for SEOLexical Semantics, Semantic Similarity and Relevance for SEO
Lexical Semantics, Semantic Similarity and Relevance for SEO
Koray Tugberk GUBUR
 
The 5 Habits of Breakthrough Innovators
The 5 Habits of Breakthrough InnovatorsThe 5 Habits of Breakthrough Innovators
The 5 Habits of Breakthrough Innovators
Amy Jo Kim
 
Semantic Content Networks - Ranking Websites on Google with Semantic SEO
Semantic Content Networks - Ranking Websites on Google with Semantic SEOSemantic Content Networks - Ranking Websites on Google with Semantic SEO
Semantic Content Networks - Ranking Websites on Google with Semantic SEO
Koray Tugberk GUBUR
 

What's hot (20)

Joshua Slayton
Joshua SlaytonJoshua Slayton
Joshua Slayton
 
Off Page SEO Strategies
Off Page SEO StrategiesOff Page SEO Strategies
Off Page SEO Strategies
 
Northstar Metrics and OKR
Northstar Metrics and OKRNorthstar Metrics and OKR
Northstar Metrics and OKR
 
How To Optimize Your Product Using Analytics by Dan Olsen
How To Optimize Your Product Using Analytics by Dan OlsenHow To Optimize Your Product Using Analytics by Dan Olsen
How To Optimize Your Product Using Analytics by Dan Olsen
 
Lexical Semantics, Semantic Similarity and Relevance for SEO
Lexical Semantics, Semantic Similarity and Relevance for SEOLexical Semantics, Semantic Similarity and Relevance for SEO
Lexical Semantics, Semantic Similarity and Relevance for SEO
 
Dwolla Startup Pitch Deck
Dwolla Startup Pitch DeckDwolla Startup Pitch Deck
Dwolla Startup Pitch Deck
 
Scaling Search Campaigns With Bulk Uploads and Ad Customizers (SMX 2023)
Scaling Search Campaigns With Bulk Uploads and Ad Customizers (SMX 2023)Scaling Search Campaigns With Bulk Uploads and Ad Customizers (SMX 2023)
Scaling Search Campaigns With Bulk Uploads and Ad Customizers (SMX 2023)
 
The 5 Habits of Breakthrough Innovators
The 5 Habits of Breakthrough InnovatorsThe 5 Habits of Breakthrough Innovators
The 5 Habits of Breakthrough Innovators
 
SMX_DevTools_Monaco_2.pdf
SMX_DevTools_Monaco_2.pdfSMX_DevTools_Monaco_2.pdf
SMX_DevTools_Monaco_2.pdf
 
SEO-Presentation-2023.pptx
SEO-Presentation-2023.pptxSEO-Presentation-2023.pptx
SEO-Presentation-2023.pptx
 
Growth Hacking / Marketing 101: It's about process
Growth Hacking / Marketing 101: It's about processGrowth Hacking / Marketing 101: It's about process
Growth Hacking / Marketing 101: It's about process
 
Introduction to Full Stack Web3 Social with Lens Protocol and Next.js
Introduction to Full Stack Web3 Social with Lens Protocol and Next.jsIntroduction to Full Stack Web3 Social with Lens Protocol and Next.js
Introduction to Full Stack Web3 Social with Lens Protocol and Next.js
 
Get Content Crawled & Ranked Faster: 5 Tips From An SEO Expert
Get Content Crawled & Ranked Faster: 5 Tips From An SEO ExpertGet Content Crawled & Ranked Faster: 5 Tips From An SEO Expert
Get Content Crawled & Ranked Faster: 5 Tips From An SEO Expert
 
Semantic Content Networks - Ranking Websites on Google with Semantic SEO
Semantic Content Networks - Ranking Websites on Google with Semantic SEOSemantic Content Networks - Ranking Websites on Google with Semantic SEO
Semantic Content Networks - Ranking Websites on Google with Semantic SEO
 
Regular Expressions for Regular Joes (and SEOs)
Regular Expressions for Regular Joes (and SEOs)Regular Expressions for Regular Joes (and SEOs)
Regular Expressions for Regular Joes (and SEOs)
 
Mastering GA4: How To Use The New Google Analytics Like A Pro
 Mastering GA4: How To Use The New Google Analytics Like A Pro Mastering GA4: How To Use The New Google Analytics Like A Pro
Mastering GA4: How To Use The New Google Analytics Like A Pro
 
Blue Ribbon Mastermind Presentation
Blue Ribbon Mastermind PresentationBlue Ribbon Mastermind Presentation
Blue Ribbon Mastermind Presentation
 
How to Plan and Execute a Go-to-market Campaign for an Atlassian Add-on
How to Plan and Execute a Go-to-market Campaign for an Atlassian Add-onHow to Plan and Execute a Go-to-market Campaign for an Atlassian Add-on
How to Plan and Execute a Go-to-market Campaign for an Atlassian Add-on
 
Website and seo audit checklist
Website and seo audit checklistWebsite and seo audit checklist
Website and seo audit checklist
 
Search Engine Optimization
Search Engine OptimizationSearch Engine Optimization
Search Engine Optimization
 

Similar to Query relaxation - A rewriting technique between search and recommendations

Presentation by vikas dubey
Presentation by vikas dubeyPresentation by vikas dubey
Presentation by vikas dubey
PMI_IREP_TP
 
Nowadays the Reliance on electrical energy became very curcial. th.docx
Nowadays the Reliance on electrical energy became very curcial. th.docxNowadays the Reliance on electrical energy became very curcial. th.docx
Nowadays the Reliance on electrical energy became very curcial. th.docx
vannagoforth
 
Running Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docx
Running Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docxRunning Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docx
Running Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docx
toltonkendal
 
Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...
Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...
Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...
CASRAI
 
, please see the feedback within your paper and in the scoring rub.docx
, please see the feedback within your paper and in the scoring rub.docx, please see the feedback within your paper and in the scoring rub.docx
, please see the feedback within your paper and in the scoring rub.docx
madlynplamondon
 

Similar to Query relaxation - A rewriting technique between search and recommendations (20)

Delivering balanced solutions by nu cognitive for pints with pdx product mana...
Delivering balanced solutions by nu cognitive for pints with pdx product mana...Delivering balanced solutions by nu cognitive for pints with pdx product mana...
Delivering balanced solutions by nu cognitive for pints with pdx product mana...
 
Balancing Business + Usage + Technology by Daniel Walsh nuCognitive Product M...
Balancing Business + Usage + Technology by Daniel Walsh nuCognitive Product M...Balancing Business + Usage + Technology by Daniel Walsh nuCognitive Product M...
Balancing Business + Usage + Technology by Daniel Walsh nuCognitive Product M...
 
Formulating an Effective Search Query
Formulating an Effective Search QueryFormulating an Effective Search Query
Formulating an Effective Search Query
 
Balancing Business + Usage + Technology Workshop by Daniel Walsh nuCognitive
Balancing Business + Usage + Technology Workshop by Daniel Walsh nuCognitiveBalancing Business + Usage + Technology Workshop by Daniel Walsh nuCognitive
Balancing Business + Usage + Technology Workshop by Daniel Walsh nuCognitive
 
Improving Research Visibility Part 6: Academic Social Networking
Improving Research Visibility Part 6: Academic Social NetworkingImproving Research Visibility Part 6: Academic Social Networking
Improving Research Visibility Part 6: Academic Social Networking
 
Strategyfordummies
StrategyfordummiesStrategyfordummies
Strategyfordummies
 
Digital Strategy for dummies
Digital Strategy for dummiesDigital Strategy for dummies
Digital Strategy for dummies
 
SEJ Webinar_How To Supercharge Your Keyword Research with Powerful Topic Clus...
SEJ Webinar_How To Supercharge Your Keyword Research with Powerful Topic Clus...SEJ Webinar_How To Supercharge Your Keyword Research with Powerful Topic Clus...
SEJ Webinar_How To Supercharge Your Keyword Research with Powerful Topic Clus...
 
I'm a Recruiter, Not a Data Scientist!
I'm a Recruiter, Not a Data Scientist!I'm a Recruiter, Not a Data Scientist!
I'm a Recruiter, Not a Data Scientist!
 
Select a Research Brand Name
Select a Research Brand NameSelect a Research Brand Name
Select a Research Brand Name
 
925 plenary rexer_using our laptop
925 plenary rexer_using our laptop925 plenary rexer_using our laptop
925 plenary rexer_using our laptop
 
Funding model technorama antwerp - may 2017 copy
Funding model   technorama antwerp - may 2017 copyFunding model   technorama antwerp - may 2017 copy
Funding model technorama antwerp - may 2017 copy
 
Publishing Procedure and Strategies to Improve Research Visibility and Impact
Publishing Procedure and Strategies to Improve Research Visibility and ImpactPublishing Procedure and Strategies to Improve Research Visibility and Impact
Publishing Procedure and Strategies to Improve Research Visibility and Impact
 
Presentation by vikas dubey
Presentation by vikas dubeyPresentation by vikas dubey
Presentation by vikas dubey
 
Nowadays the Reliance on electrical energy became very curcial. th.docx
Nowadays the Reliance on electrical energy became very curcial. th.docxNowadays the Reliance on electrical energy became very curcial. th.docx
Nowadays the Reliance on electrical energy became very curcial. th.docx
 
Running Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docx
Running Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docxRunning Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docx
Running Head TOWN GUIDE ANDROID APPLICATION5TOWN GUIDE ANDROI.docx
 
ClickZ Live: Smart Analytics
ClickZ Live: Smart AnalyticsClickZ Live: Smart Analytics
ClickZ Live: Smart Analytics
 
Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...
Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...
Project Credit: Amy Brand - Beyond authorship: recognising the contributions ...
 
Long Tail Keyword Suggestion for Sponsored Search Advertising
Long Tail Keyword Suggestion for Sponsored Search AdvertisingLong Tail Keyword Suggestion for Sponsored Search Advertising
Long Tail Keyword Suggestion for Sponsored Search Advertising
 
, please see the feedback within your paper and in the scoring rub.docx
, please see the feedback within your paper and in the scoring rub.docx, please see the feedback within your paper and in the scoring rub.docx
, please see the feedback within your paper and in the scoring rub.docx
 

Recently uploaded

一比一原版麦考瑞大学毕业证成绩单如何办理
一比一原版麦考瑞大学毕业证成绩单如何办理一比一原版麦考瑞大学毕业证成绩单如何办理
一比一原版麦考瑞大学毕业证成绩单如何办理
cyebo
 
Abortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotec
Abortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotecAbortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotec
Abortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotec
Abortion pills in Riyadh +966572737505 get cytotec
 
一比一原版阿德莱德大学毕业证成绩单如何办理
一比一原版阿德莱德大学毕业证成绩单如何办理一比一原版阿德莱德大学毕业证成绩单如何办理
一比一原版阿德莱德大学毕业证成绩单如何办理
pyhepag
 
Exploratory Data Analysis - Dilip S.pptx
Exploratory Data Analysis - Dilip S.pptxExploratory Data Analysis - Dilip S.pptx
Exploratory Data Analysis - Dilip S.pptx
DilipVasan
 
一比一原版纽卡斯尔大学毕业证成绩单如何办理
一比一原版纽卡斯尔大学毕业证成绩单如何办理一比一原版纽卡斯尔大学毕业证成绩单如何办理
一比一原版纽卡斯尔大学毕业证成绩单如何办理
cyebo
 
一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理
一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理
一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理
pyhepag
 
一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理
pyhepag
 

Recently uploaded (20)

Easy and simple project file on mp online
Easy and simple project file on mp onlineEasy and simple project file on mp online
Easy and simple project file on mp online
 
Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPsWebinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
 
Pre-ProductionImproveddsfjgndflghtgg.pptx
Pre-ProductionImproveddsfjgndflghtgg.pptxPre-ProductionImproveddsfjgndflghtgg.pptx
Pre-ProductionImproveddsfjgndflghtgg.pptx
 
Machine Learning for Accident Severity Prediction
Machine Learning for Accident Severity PredictionMachine Learning for Accident Severity Prediction
Machine Learning for Accident Severity Prediction
 
一比一原版麦考瑞大学毕业证成绩单如何办理
一比一原版麦考瑞大学毕业证成绩单如何办理一比一原版麦考瑞大学毕业证成绩单如何办理
一比一原版麦考瑞大学毕业证成绩单如何办理
 
Atlantic Grupa Case Study (Mintec Data AI)
Atlantic Grupa Case Study (Mintec Data AI)Atlantic Grupa Case Study (Mintec Data AI)
Atlantic Grupa Case Study (Mintec Data AI)
 
Abortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotec
Abortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotecAbortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotec
Abortion pills in Dammam Saudi Arabia// +966572737505 // buy cytotec
 
How I opened a fake bank account and didn't go to prison
How I opened a fake bank account and didn't go to prisonHow I opened a fake bank account and didn't go to prison
How I opened a fake bank account and didn't go to prison
 
Slip-and-fall Injuries: Top Workers' Comp Claims
Slip-and-fall Injuries: Top Workers' Comp ClaimsSlip-and-fall Injuries: Top Workers' Comp Claims
Slip-and-fall Injuries: Top Workers' Comp Claims
 
AI Imagen for data-storytelling Infographics.pdf
AI Imagen for data-storytelling Infographics.pdfAI Imagen for data-storytelling Infographics.pdf
AI Imagen for data-storytelling Infographics.pdf
 
2024 Q2 Orange County (CA) Tableau User Group Meeting
2024 Q2 Orange County (CA) Tableau User Group Meeting2024 Q2 Orange County (CA) Tableau User Group Meeting
2024 Q2 Orange County (CA) Tableau User Group Meeting
 
Supply chain analytics to combat the effects of Ukraine-Russia-conflict
Supply chain analytics to combat the effects of Ukraine-Russia-conflictSupply chain analytics to combat the effects of Ukraine-Russia-conflict
Supply chain analytics to combat the effects of Ukraine-Russia-conflict
 
一比一原版阿德莱德大学毕业证成绩单如何办理
一比一原版阿德莱德大学毕业证成绩单如何办理一比一原版阿德莱德大学毕业证成绩单如何办理
一比一原版阿德莱德大学毕业证成绩单如何办理
 
Exploratory Data Analysis - Dilip S.pptx
Exploratory Data Analysis - Dilip S.pptxExploratory Data Analysis - Dilip S.pptx
Exploratory Data Analysis - Dilip S.pptx
 
How can I successfully sell my pi coins in Philippines?
How can I successfully sell my pi coins in Philippines?How can I successfully sell my pi coins in Philippines?
How can I successfully sell my pi coins in Philippines?
 
MALL CUSTOMER SEGMENTATION USING K-MEANS CLUSTERING.pptx
MALL CUSTOMER SEGMENTATION USING K-MEANS CLUSTERING.pptxMALL CUSTOMER SEGMENTATION USING K-MEANS CLUSTERING.pptx
MALL CUSTOMER SEGMENTATION USING K-MEANS CLUSTERING.pptx
 
basics of data science with application areas.pdf
basics of data science with application areas.pdfbasics of data science with application areas.pdf
basics of data science with application areas.pdf
 
一比一原版纽卡斯尔大学毕业证成绩单如何办理
一比一原版纽卡斯尔大学毕业证成绩单如何办理一比一原版纽卡斯尔大学毕业证成绩单如何办理
一比一原版纽卡斯尔大学毕业证成绩单如何办理
 
一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理
一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理
一比一原版(Monash毕业证书)莫纳什大学毕业证成绩单如何办理
 
一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理一比一原版西悉尼大学毕业证成绩单如何办理
一比一原版西悉尼大学毕业证成绩单如何办理
 

Query relaxation - A rewriting technique between search and recommendations

  • 1. Query relaxation A rewriting technique between search and recommendations René Kriegler, @renekrie Haystack - The Search Relevance Conference 24 April 2019
  • 2. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) About me More than 10 years experience as a freelance search consultant, often in a role for OpenSource Connections Focus: - Search relevance optimisation - E-commerce search - Solr - Coaching teams to establish search within their organisation Organiser of MICES - Mix-Camp E-commerce Search (Berlin, 19 June, mices.co, right after Berlin Buzzwords) Maintainer of Querqy (OSS query rewriting library - github.com/renekrie/querqy) 2
  • 3. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) No results 3
  • 4. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) No results - strategies Apply synonyms and hyponyms (laptop = notebook; shoes => trainers) Spelling correction (Did you mean ...? / We’ve searched for ...) Also search in low-quality data fields Loosen boolean constraints (AND -> OR, mm<100%) Apply hypernyms (boots => shoes) Use more distant semantic relation (beard balm => trimmer) Show more general recommendations (related to user’s shopping history, popular items) 4
  • 5. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) No results - strategies Apply synonyms and hyponyms Spelling correction Also search in low-quality data fields Loosen boolean constraints Apply hypernyms Use more distant semantic relation Show more general recommendations 5 Explainable? (in e-commerce search) Don’t want to tell mm: no; AND/OR: yes, but bad UX Don’t need to tell Can be hard
  • 6. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) No results - Query relaxation 6 Explainable! (& conversational!)
  • 7. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation Which query term should be removed? 7
  • 8. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation - intuition 8 iphone 9 => iphone 9 (*) iphone 9 => iphone 9
  • 9. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation - intuition 9 iphone 9 plus => iphone 9 plus (?) iphone 9 plus => iphone 9 plus (?) iphone 9 plus => iphone 9 plus
  • 10. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation - intuition 10 black boots => black boots (*) black boots => black boots
  • 11. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation - intuition 11 purple boots => purple boots (?) purple boots => purple boots
  • 12. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation - intuition 12 (?) usb charger 12v => usb charger 12v (?) usb charger 12v => usb charger 12v (?) usb charger 12v => usb charger 12v
  • 13. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query intent & information need Apply synonyms and hyponyms Spelling correction Also search in low-quality data fields Loosen boolean constraints Apply hypernyms Use more distant semantic relation Show more general recommendations 13 Trying to match original information need Remotely related to user intent Query relaxation
  • 14. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation 14 “A popular approach to cope with empty-answers is query relaxation, which attempts to reformulate the original query into a new query, by removing or relaxing conditions, so that the result of the new query is likely to contain the items of interest for that user.” (Mottin et al., 2013) “We present a method which we call relaxation for expanding deductive database and logic programming queries. The set of answers obtained with the relaxation method includes both answers deduced traditionally and answers related in some way with the original query. The relaxation method expands the scope query by relaxing the constraints implicit in the query.” (Gaasterland et al., 1992) “An extended query-document matching system is described in this study that relaxes the stringent requirements of the conventional Boolean retrieval operations.” (Salton et al., 1983)
  • 15. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Query relaxation 15 => How can we find the best query term to be removed from the query so that “... the result of the new query is likely to contain the items of interest for that user” “... answers [are] related in some way with the original query” ? => How can we test, compare and optimise solutions?
  • 16. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Online testing 16 Click-through-rate / hit rate Exit rate / time spent on site => Do we manage to keep the user interacting with our site? => similar to recommendations / exploratory search
  • 17. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Finding the term to be dropped: data sets 17 Data sets for training and evaluation Find pairs: - a long query having 0 results - a corresponding relaxed query having results
  • 18. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Finding the term to be dropped: data sets 18 FREQ: Query frequencies - Have we observed the original and the relaxed query before? (We want to make sure that we produce a meaningful query.) COOC: Query cooccurrences per session - Have the original and rewritten query occurred together in a session? => Can we find the original/rewritten query pair in tracking data? How often? (more often is better)
  • 19. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 0 - Drop random term (baseline) 19 Remove a random term from the query
  • 20. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 1 - Drop shortest term 20 Remove the shortest term from the query
  • 21. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 2 - Drop shortest non-alphabetical term 21 Remove the shortest term that doesn’t contain any alphabetical character
  • 22. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 3 - Combined 1 and 2 22 Remove the shortest term that doesn’t contain any alphabetical character, fall back to removing shortest term if all terms have >=1 alphabetical character
  • 23. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 4/5 - Drop most/least frequent term 23 Remove the term with the highest/lowest index frequency
  • 24. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 6/7 - Drop term with highest/lowest entropy 24 Remove the term with the highest/lowest entropy across navigational categories
  • 25. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 8 - Keep most similar query (Word2vec) 25 Use the rewritten query that is most similar to the original query based on Word2vec embeddings [as mentioned in D.Tunkelang, Query relaxation, https://bit.ly/2ItxF3Z]
  • 26. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Word2vec (CBOW) 26 w (t-2) pepe jeans w(t) projection Input Output slim cut w (t-1) w (t+1) w (t+2) london london Sequence of words
  • 27. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 8 - Keep most similar query (Word2vec) 27 Use the rewritten query that is most similar to the original query based on Word2vec embeddings Train Word2Vec embeddings - word = query term, window = query - 300 dimensions Use sum of word(=term) vectors to represent the queries (original/rewritten) Calculate cosine similarity between original query and each rewritten query Use rewritten query that is most similar to the original query
  • 28. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 8 - Keep most similar query (Word2vec) 28 Use the rewritten query that is most similar to the original query based on Word2vec embeddings
  • 29. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 9 - Keep most similar query (Query2vec) 29 Use the rewritten query that is most similar to the original query based on query embeddings [Grbovic et al., Scalable Semantic Matching of Queries to Ads in Sponsored Search Advertising. SIGIR 2016]
  • 30. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) ‘Query2vec’ (CBOW) 30 q (t-2) smartphone smartphone 64g q (t) projection Input Output iphone iphone 64g q (t-1) q (t+1) q (t+2) galaxy 64g galaxy 64g Queries in a session
  • 31. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 9 - Keep most similar query (Query2vec) 31 Use the rewritten query that is most similar to the original query based on Query embeddings
  • 32. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 10 - MNN with Word2vec input 32 Predict the term to be dropped using a multi-layer neural network (MNN) with Word2vec embeddings as input.
  • 33. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 10 - MNN with Word2vec input 33 0: 0.01 1:-0.94 ... 300: 0.18 0: 0.63 1: 0.56 ... 300: 0.04 0:-0.59 1: 0.02 ... 300: 0.77 0: 0.00 1: 0.00 ... 300: 0.00 0: 0.00 1: 0.00 ... 300: 0.00 0: 0.00 1: 0.00 ... 300: 0.00 0: 0.00 1: 0.00 ... 300: 0.00 0: 0.00 1: 0.00 ... 300: 0.00 nike boots 11 0: 0 0: 1 0: 0 0: 0 0: 0 0: 0 0: 0 0: 0 2 hidden layers Input Output
  • 34. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 10 - MNN with Word2vec input 34 Predict the term to be dropped using a multi-layer neural network (MNN) with Word2vec embeddings as input
  • 35. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 11 - MNN / Word2vec plus wordshape 35 Predict the term to be dropped using a multi-layer neural network (MNN) with Word2vec embeddings and wordshape features as input. Add additional dimensions to the input vector: - Word length - Number of digits - Does the word have an ‘e’ in the penultimate or ultimate position?
  • 36. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 11 - MNN / Word2vec plus wordshape 36 ... 301: 4.00 302: 0.00 303: 1.00 ... 301: 5.00 302: 0.00 303: 0.00 ... 301: 2.00 302: 2.00 303: 0.00 ... 301: 0.00 302: 0.00 303: 0.00 ... 301: 0.00 302: 0.00 303: 0.00 ... 301: 0.00 302: 0.00 303: 0.00 ... 301: 0.00 302: 0.00 303: 0.00 ... 301: 0.00 302: 0.00 303: 0.00 nike boots 11 0: 0 0: 1 0: 0 0: 0 0: 0 0: 0 0: 0 0: 0 2 hidden layers Input Output
  • 37. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 11 - MNN / Word2vec plus wordshape 37 Predict the term to be dropped using a multi-layer neural network (MNN) with Word2vec embeddings and wordshape features as input.
  • 38. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) 11/12 - MNN / Word2vec plus term stats 38 Predict the term to be dropped using a multi-layer neural network (MNN) with Word2vec embeddings and per-field DF or index frequency.
  • 39. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Conclusion 39 Query relaxation: - best understood as a query recommendation - information need not necessarily matched but relaxed query still related to user intent - can be communicated nicely to the user (‘conversational’) Best approach to find term to be dropped: - Multi-layer neural network with Word2Vec plus wordshape features as inputs. It can be extended to incorporate further features and optimisation targets.
  • 40. Query relaxation - a rewriting technique between search and recommendations, Haystack, 24 April 2019, © René Kriegler (@renekrie) Thank you! http://www.rene-kriegler.com @renekrie 40