Embedding the search page
The search page component provides a full search interface with AI-generated answers, search results, and a text input — suitable for a dedicated search page on your site. Unlike the chat widget, which floats over your content, the search page embeds directly into your page layout.
Basic installation
Section titled “Basic installation”Add a container element and the search page script to your HTML:
<div id="quant-search"></div><script src="https://ai.quantcdn.io/v1/search-page.js" data-site-id="YOUR_SITE_ID" data-container="quant-search" data-theme="light" data-show-ai-answer="true" data-results-limit="10"></script>Replace YOUR_SITE_ID with your project’s site ID.
Configuration options
Section titled “Configuration options”Customise the search page using data attributes on the script tag:
| Attribute | Required | Default | Description |
|---|---|---|---|
data-site-id | Yes | — | Your project’s site ID |
data-container | Yes | — | ID of the container element |
data-theme | No | light | Colour theme: light or dark |
data-show-ai-answer | No | true | Show AI-generated summary above results |
data-results-limit | No | 10 | Maximum number of search results to display |
AI answers
Section titled “AI answers”When enabled, the search page displays an AI-generated summary above the traditional search results, synthesised from your indexed content. This gives visitors a direct answer to their query without needing to click through to individual pages.
To disable AI answers, set data-show-ai-answer="false":
<script src="https://ai.quantcdn.io/v1/search-page.js" data-site-id="YOUR_SITE_ID" data-container="quant-search" data-show-ai-answer="false"></script>When AI answers are disabled, the search page functions as a traditional search results page.
Next steps
Section titled “Next steps”- Chat widget — Add a floating chat button for conversational search
- Managing the index — View, search, and manage indexed pages
- Settings — Configure allowed domains and rate limits