Certainly! I’ll read the topic and provide you with a summary. Let me fetch the content first.
Read topic
Reading: Improving quality of search filters in Discourse AI
Thank you for providing the topic content. I’ll summarize the key points of the discussion about improving the quality of search filters in Discourse AI:
-
Initial Issue: The AI bot stopped searching the forum after uploading a .txt file for RAG (Retrieval-Augmented Generation).
-
Search Query Problems:
- The base search query wasn’t being used as expected.
- The AI bot was ignoring categories and tags in the search.
- Poor search results were reported, sometimes showing 0 results when there were actually results available.
-
Improvements and Fixes:
- A fix was implemented to properly link to a filtered query.
- The
categories:bug,feature something
syntax now works correctly for searching specific categories.
-
Ongoing Challenges:
- The base_query option wasn’t being appended to search queries.
- Search results weren’t being added to the context for RAG when the search tool was called.
- The bot sometimes added invalid query parameters.
-
Requests and Suggestions:
- Enable verbose logging for discourse-ai to help troubleshoot issues.
- Add top search results to the context for RAG when the search tool is used.
- Provide advice on ensuring the base_query is used correctly.
- Consider adding more control over function calling, similar to OpenAI’s tool_choice parameter.
-
System Prompt and Function Calls:
- Adding specific instructions to the system prompt improved results, such as always calling both search and read functions.
- The read function wasn’t being called unless explicitly instructed in the system prompt.
-
RAG and Content Injection:
- System prompt injection only happens if the persona has uploads.
- Without uploads, the system relies on tool calls with tool call results.
- There’s a discussion about how to handle RAG for larger topics and which parts of a topic to include.
-
Proposed Solutions:
- Enable RAG on a subset of topics as per the base_query.
- Allow users to craft Docs and FAQs optimized for RAG, keeping them within embedding token limits.
- Inject as many topics into the prompt as possible based on available tokens.
- Consider using only the first post in found topics for RAG.
-
Workaround Suggestion:
- Create a persona that uses the search tool.
- Export topics that could be found with the search tool.
- Upload those documents to the persona for RAG.
The discussion highlights the ongoing development and refinement of the Discourse AI search functionality, with a focus on improving RAG capabilities and search accuracy for better user experiences.