This project is not covered by Drupal’s security advisory policy.
AI Answers turns an existing AI Agent into a RAG-powered search answer engine: a visitor asks a question and gets a written answer built only from your own site content, with citations that link back to the source.
If your site already holds good content but people struggle to find the right page, AI Answers gives them one place to ask in plain language and read a direct answer, instead of scanning a list of search hits. Every answer is grounded strictly in sources the agent retrieves itself through its own ai_search:rag_search tool, and never from the model's general knowledge, so the response stays true to your site and always shows where each fact came from. It is designed around a "Search Anywhere, Answer Here" pattern, so a search box in your header, a prompt on a landing page and a field in the sidebar can all feed the same shared answer region.
Features
The basic functionality is a question in, a grounded answer out. A Question block posts a visitor's question to the AI Answers API, which runs a retrieval through the agent's tool and composes a written answer from what it finds. An Answer block renders that response together with its cited sources.
- Search Anywhere, Answer Here. Place any number of question input blocks across the site and point them at a single shared answer block.
- Grounded answers only. Responses are built strictly from sources the agent retrieves through its own
ai_search:rag_searchtool, restricted to a single forced, hidden index so the model can't be prompted into querying elsewhere. A brand-new question always runs a fresh retrieval first; a follow-up question lets the agent decide whether to search again or reuse the previous sources. A turn that ends with no usable sources returns the configured no-answer message. That's guaranteed on the standard JSON response; the live-streaming response relies on the agent's own instructions to do the same. - Citations as rendered entities. Answers carry inline
[n]citations that resolve to the underlying content, rendered through a view mode you choose. - Reading content, not chat. Answers are presented as clean, readable output rather than a conversational bubble interface.
- Streaming or single response. The question endpoint can stream tokens as they arrive, or return one complete answer.
- Follow-up and feedback. Optional follow-up questions and thumbs feedback, persisted when logging is enabled, with optional trace correlation through Langfuse.
- Cacheable blocks. The blocks are lightweight, static shells that Drupal can cache. The answer itself arrives over the API via vanilla JavaScript.
Use it when your visitors have questions your content already answers but cannot easily locate: product and service documentation, support and knowledge bases, policy or HR portals, intranets, or any content-rich site where a direct answer beats a list of links.
Post-Installation
The full walkthrough is at Getting started in the full documentation: setting up a vector-database-backed Search API index, configuring an AI Agent's RAG/Vector Search tool with a forced, hidden index, enabling AI Answers for that agent, placing the blocks, and granting the module's permissions to the right roles.
Documentation
Full documentation is published at https://project.pages.drupalcode.org/ai_answers/, including the getting-started walkthrough above, an architecture overview of the request/answer pipeline, a list of known gaps, and a decision log recording why the module is shaped the way it is.
Additional Requirements
Beyond Drupal core, this module requires:
- AI (
ai) - AI Agents (
ai_agents) - AI Search (
ai_search)
Recommended modules/libraries
- AI Logging (
ai_logging): recommended. Without it, feedback has nowhere to persist. - Langfuse: optional. Adds trace correlation for observability; see Optional: Langfuse observability for setup. Feedback scores don't reach Langfuse yet: that's a known upstream limitation. The thumbs up/down control itself still works and still saves feedback when AI Logging is enabled.
Project information
- Project categories: Artificial Intelligence (AI), Site search
- Ecosystem: AI Search
3 sites report using this module
- Created by dropsolid_admin on , updated
This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.
Releases
Development version: 1.0.x-dev updated 11 Aug 2026 at 15:04 UTC


