GPT ignoring attached knowledge document, making up stuff

I have a custom GPT with an attached TXT knowledge document around 20 pages long. Sometimes it gives perfect answers but other times it will give answers that are completely different from what is in the attached knowledge. When it hallucinates the answers, it even claims it has sourced the data from the knowledge document, even though it’s completely made up.

My instructions are:
“ALWAYS search your knowledge before answering.’”

1 Like

This behaviour might be caused by the way you have phrased your GPT instructions. If you could share them here, we could take a closer look and indicate what changes might help.

I simply have it now as ‘ALWAYS search your knowledge before answering.’

And it does not do it consistently.

Hallucinations often materialize when the model does not find relevant information in the knowledge base. Rather than have it make up answers in those case, you can add an instruction such as “If insufficient information is available in the knowledge base, strictly return the answer Not enough information available to answer this question”. You can further tailor this to fit your needs but the basic idea is that you instruct the model to default to a certain behaviour if a question cannot be answered.

If you find that it also hallucinates when information is available in your knowledge file, then you need to further specify your instructions. For instance, it often helps to provide details about what information is covered in the knowledge file, how the information is structured etc.

1 Like

Thank you. I’ve updated the instructions with an overview of the knowledge. It works slightly better, but it’s still not properly referencing the knowledge.

For example, I ask ‘what is the guest policy’ and in the response it gives generic information like ‘guests are typically allowed to stay for a limited duration’, despite the knowledge explicitly stating the exact number of days. And it’s like this for most prompts, it is just not assuming the knowledge properly.

BTW it was working really well a few months ago when I last tried it. I’ve come back to it in the last few days and the results have been disappointing.

2 Likes

Another observation, sometimes it will hallucinate facts. Then I ask ‘where did you get this from’, it then searches the knowledge (and takes longer to do this then the initial response) and says ‘sorry the documentation did not specifically mention this’. (But in the initial response it got MOST of it correct, but some hallucinations)

On some occasions it will take time on the first response to do ‘searching my knowledge’ and will give great answers. But other times it seems to not do this, give a quicker response, which is mostly correct but has some hallucinations

Thanks for the additional information.

This is an example of query that is very generic. As a result, it is not unusual that the GPT’s responses lack specificity and comprehensiveness. If you are looking to get more targeted responses, then you need to implement an approach where the model requests the user to further detail the question if the initial query is too broad.

Alternatively, if you expect similar questions across your user base you could also change the way you organize the knowledge file and instead include in the file question-answer pairs.

I can’t speak much to the fact why the GPT’s behaviour might have changed. Several users have been reporting different behaviours after GPTs were migrated to the new gpt-40 model. Every model responds (slightly) differently to instructions and you might need to spend some time calibrating your existing instructions to fully get it to work again.

1 Like

@Habitat3375

I built a sample GPT for you to test how it works only using knowledge file without using “common reference” or “general knowledge”. I added a TXT file with 213 pages that has 99 unique recipes. You may see it HERE, also you can see its instruction end of the chat. You can modify it for your needs.

I have been experiencing the same thing today. I even changed my config/initialisation script to check my attachment by pages and sections.

It reported back correctly for about 10 pages but then, while reporting it was still looking at my attachment, it was coming back with what looked like real sections from a Service Operations document. I have never uploaded anything like this. This is extremely worrying.

As a test, you might consider structuring your knowledge as a csv file. I’ve had better luck using this method.

I find asking for ‘Reasoning’ helps, ask something like

“Give reasonings for your decisions, explain why from the document you have given the response you have.”

1 Like