I'm not exactly sure what you are asking. You can however construct a RAG based on a training corpus and then if you ask questions that when vecroized have no sufficiently similar match in your corpus you tell your llm to just say it cant answer that question.
Concretely, index the tax documents into your data base then ask a question about Mount Everest. Vectorize that question and search your vectoized corpus for something similar. Find nothing then instruct your llm to formulate a response saying it could not answer
Comments
I'm not exactly sure what you are asking. You can however construct a RAG based on a training corpus and then if you ask questions that when vecroized have no sufficiently similar match in your corpus you tell your llm to just say it cant answer that question.
Concretely, index the tax documents into your data base then ask a question about Mount Everest. Vectorize that question and search your vectoized corpus for something similar. Find nothing then instruct your llm to formulate a response saying it could not answer