Effective and Efficient Query-aware Snippet Extraction for Web Search (2022)

Abstract: Query-aware webpage snippet extraction is widely used in search engines to help users better understand the content of the returned webpages before clicking. The extracted snippet is expected to summarize the webpage in the context of the input query. Existing snippet extraction methods mainly rely on handcrafted features of overlapping words, which cannot capture deep semantic relationships between the query and webpages. Another idea is to extract the sentences which are most relevant to queries as snippets with existing text matching methods. However, these methods ignore the contextual information of webpages, which may be sub-optimal. In this paper, we propose an effective query-aware webpage snippet extraction method named DeepQSE. In DeepQSE, the concatenation of title, query and each candidate sentence serves as an input of query-aware sentence encoder, aiming to capture the fine-grained relevance between the query and sentences. Then, these query-aware sentence representations are modeled jointly through a document-aware relevance encoder to capture contextual information of the webpage. Since the query and each sentence are jointly modeled in DeepQSE, its online inference may be slow. Thus, we further propose an efficient version of DeepQSE, named Efficient-DeepQSE, which can significantly improve the inference speed of DeepQSE without affecting its performance. The core idea of Efficient-DeepQSE is to decompose the query-aware snippet extraction task into two stages, i.e., a coarse-grained candidate sentence selection stage where sentence representations can be cached, and a fine-grained relevance modeling stage. Experiments on two datasets validate the effectiveness and efficiency of our methods.

## introduction given an input search query, search engines such as google foot_0 and bing foot_1 , not only return the urls and the titles of the relevant webpages, but also show the query-aware snippets of these webpages, aiming to help users better understand the webpage content before clicking. these webpage snippets are usually one or two sentences extracted from the webpage, which can not only summarize the key content of the webpage, but also be relevant to the input query. some examples are shown in figure 1 . for the query 'einstein' and the webpage of 'albert einstein -wikipedia', a good snippet is a brief introduction of einstein's life. while for the query 'einstein achievement', a good snippet would be sentences describing his influence on science. in other words, the snippet is a summarization of the webpage in the context of input query. although query-aware webpage snippet extraction is important and useful, it is very rarely studied. only a few works exist in this field, and most of them are based on simple word-level text matching method @xcite . for example, @xcite proposed to utilize the number of overlapping words between queries and sentences in webpages to extract snippets. @xcite proposed to select snippets through the summation of kullback-leibler divergence or tf-idf weight of overlapping words between queries and sentences in webpages. however, these methods rely on counting features of overlapping words, and cannot capture the deep semantic relation between query and webpage. in this paper, we propose an effective queryaware webpage snippet extraction method for web search, named deepqse 3 . in deepqse, given an input query and a webpage with multiple sentences, we first learn query-aware sentence representations for each sentence to capture the fine-grained relevance between query, sentence and webpage title using a query-aware sentence encoder. then we model the query-sentence relevance in the context of the whole webpage using a document-aware relevance encoder. since the query and each webpage sentence are jointly modeled, the online inference speed of deepqse can be slow, while the search engines have extremely high requirements for low latency. thus, we further design an efficient version of deepqse named efficient-deepqse, aiming to significantly improve the inference speed of deep-qse and keep its performance as much as possible. the key idea of efficient-deepqse is to decompose the query-aware webpage snippet extraction task into two stages, i.e., coarse-grained candidate sentence selection and fine-grained relevance modeling. the coarse-grained candidate sentence selection aims to select a moderate number of most potential sentences for snippet extraction using a bi-encoder where sentence representations can be cached for fast online serving. the fine-grained relevance modeling stage aims to capture the deep semantic relevance between the query and the candidate sentences selected by the previous stage using query-aware cross-encoders. we conducted many experiments on two real-world datasets, which verify the effectiveness and efficiency of our approach. the contributions of this paper are as follows: ## methodology in this section, we give the problem formulation of query-aware snippet extraction. then we introduce our deepqse and efficient-deepqse in detail.