When using the Raffle API, search results are designed to be fast and accurate, retrieving the most relevant parts of your content based on the user’s query. However, the default behavior of the API may not always produce results that look cohesive or polished, especially in terms of descriptions. This step explains the default behavior of search results, their limitations, and why customization may improve your user experience.
By default, the Raffle API analyzes your content and returns the most relevant sections as search results. These sections are the parts of a document or webpage that match the user’s query. While this ensures accuracy, the descriptions in search results can sometimes feel incomplete or disjointed because they are directly extracted from larger bodies of text.
For example, a default search result might include:
“Dedicated support. Case studies around AI - use have been collated by…”
This snippet matches the query but might lack important context, such as what “case studies” refers to or where to find additional information.
content
The content field in search results focuses on relevance to the user’s query, but it has some limitations:
This can result in accurate but less intuitive search results.
Customization allows you to enhance search results by adding metadata, improving their relevance and appearance. Benefits include:
By using CSS Metadata Selectors, you can extract specific details from a webpage, such as:
These enhancements make results:
Now that you understand the limitations of default search results, move to Step 2: Configuring CSS Metadata Selectors to learn how to set up and use metadata for richer, more polished results.
2 - Metadata Selectors