What are Natural Language Queries?
A natural language query is a question that people would normally ask, such as:
- ✅ "How do I make hummus?" 🥙
- 🚫 Instead of: "hummus recipe ingredients steps"
Everyday Language:
NLQs are expressed in the language we use daily. They don’t follow strict grammatical rules or form complete sentences.
Lack of Explicit Intent:
These queries don’t clearly state their purpose or the complete intent behind them.
Nickname:
Because of this, they are also known as Intent Queries or Queries with a Specific Minor Intent.
Expected Search Result:
Since the query is brief and informal, the search engine should return an answer that is straightforward and doesn’t overwhelm the user with unnecessary details or structure.
Natural Language Queries vs. Factual Queries 📚
Not Factual Queries:
NLQs differ from factual queries. They’re more about expressing intent rather than seeking a single, clear-cut fact.
Example:
- NLQ: "How do I make hummus?"
- Factual Query: "What is the capital of France?"
The NLQ is open-ended and can lead to multiple possible answers, methods, or recipes.
Multiple Intents:
NLQs can have several underlying intents because they often include non-factual information.
Example: In "How do I make hummus?", the query implies:
- There might be various methods (blending, mashing, etc.).
- Different types of hummus might exist.
- The personal pronoun "I" suggests a personal approach, which can vary from person to person.
Answer-Seeking Version:
To extract a more general response, the search system might convert it to an answer-seeking query such as:
- Revised Query: "How to do hummus"
- Purpose: To provide a concise set of steps or a general guide rather than multiple, varied responses.
Additional Insight:
Google also creates heading-text pairs to understand the topics of different sub-sections within an article, helping to break down complex NLQs into manageable parts.
3. Variable and Non-Variable Portions in Intent Templates 🔄
A. Non-Variable Portion
Definition: This is the fixed part of the query that remains constant.
Example: In the query "How do I make hummus?", the term "hummus" is the non-variable part.
Importance: It defines the core topic of the query.
B. Variable Portion
Definition: The parts of the query that can change depending on the user’s specifics. These could include details like:
- Place: "in my kitchen", "at a restaurant"
- Method: "quickly", "slow-cooked"
- Tool: "with a blender", "using a mortar and pestle"
- Style/Personal Attributes: The pronoun "I" could vary based on who is asking—child, woman, man, adult, or even a blind person.
Example: The query might vary to "How do I make vegan hummus?" or "How do I make spicy hummus?"
Purpose: It personalizes or tailors the query to meet the specific needs or preferences of the user.
C. Intent Templates in Action
Usage: Intent templates help map out the structure of NLQs to recognize patterns such as:
- X Causes: e.g., "What causes headaches?"
- X Reasons: e.g., "Reasons for insomnia"
Benefit: Even if someone searches for just X (a single element), the intent template can help the search system assign the correct context and return relevant natural language results.
Processing Authoritative Sources: Generating Heading-Text Pairs 📄✂️
A. Parsing Documents
What Happens: The system parses documents from authoritative sources (trusted websites, scholarly articles, etc.).
Result: It extracts heading-text pairs—a heading (or title) and the text (paragraphs or lists) that appear under it.
Example:
- Heading: "How to Make Hummus"
- Text: Step-by-step instructions for preparing hummus.
B. Associating with Intent Templates
Intent Templates: Predefined structures that represent common question formats.
They help categorize queries into question categories (e.g., recipes, DIY instructions).
Process: Each heading-text pair is matched with an intent template based on its content. The system determines the topic and question category for the pair.
Example: The heading "How to Make Hummus" fits an intent template with:
- Non-variable portion: "hummus"
- Variable portion: Could be the method or style (e.g., "vegan," "spicy").
Storage: The heading-text pair is stored in a data store keyed by its topic and question category.
Mapping Queries to Stored Information 🗺️🔑
Receiving a Query
User Action: A user types a natural language query, for instance, "how do I make hummus?"
System Task: The system parses the query and identifies which intent template it corresponds to.
Determining the Topic: Using the intent template, the system extracts the topic (here, "hummus") and matches the query to a specific question category (e.g., recipe instructions).
Retrieving and Presenting Answers
Data Lookup: The system retrieves heading-text pairs from the data store that match the query's topic and question category.
Enhanced Search Result: The user is presented with an enhanced result that includes one or more of these heading-text pairs.
Display Example: A paragraph or list that provides step-by-step instructions for making hummus, directly from an authoritative source.
4. Creating & Using Intent Templates 🔄📑
A. Generating Intent Templates
Step 1: Collect Intent Questions: Obtain questions from authoritative sources and previous search records.
Step 2: Generate Potential Templates: Create candidate templates by analyzing the structure of these questions.
Step 3: Frequency Analysis: Determine how often each potential template occurs.
Step 4: Select Top Templates: Choose the most frequently occurring templates as the official intent templates.
Example: A frequently occurring template might be "How do I make [variable]?"
Here, the non-variable portion is "How do I make", and the variable portion is the topic, e.g., "hummus" or "toffee".
B. Associating Queries with Intent Templates
Matching Process: When a new query comes in, the system generates potential templates from its terms. It then checks if one of these matches a stored intent template.
Variable & Non-Variable Portions:
- Non-variable portion: Remains constant (e.g., "How do I make").
- Variable portion: Extracted from the query (e.g., "hummus").
Outcome: The query is assigned a question category based on the template, enabling accurate retrieval of relevant answers.
5. Combining with Snippet-Based Results 📃🔍
Dual Approach: In addition to natural language answers, the system may also generate snippet-based search results.
Ranking and Display: Both types of results are ranked using the same ranking algorithm. If snippet-based results duplicate the natural language answers, they may be removed to streamline the output.
User Benefit: Users get a clean, concise result that combines detailed answers with relevant snippets when necessary.
Example: You might see a natural language answer (a paragraph explaining the hummus recipe) above or alongside a short snippet from a website.
6. Advantages of This Enhanced Search Approach 🚀✨
Direct Answers: Provides complete, high-quality natural language answers directly in the search results.
Efficiency: Users can quickly view and compare answers from multiple authoritative sources without loading full documents.
Increased Confidence: Detailed answers give users assurance that the authoritative sources contain the information they need.
Optimized for Low-Volume Queries: Even if natural language queries have lower search volumes than keyword queries, the system can still deliver high-quality results.
Flexibility: The system may even convert a natural language query into a keyword query to improve snippet results if necessary.
Example: For a query like "how do I make toffee?", users receive a detailed, authoritative answer that includes diverse methods and steps, rather than a list of unrelated snippets.