Building Trust in LLM Answers: Highlighting Source Texts in PDFs | by Angela & Kezhan Shi | Dec, 2024


100% accuracy isn’t everything: helping users navigate the document is the real value

So, you are building a RAG system or using an LLM to chat with documents. But users often ask: how can we trust the answers?

Moreover, we frequently hear about hallucinations, which undermine users’ trust.

If we build an application but fail to show users where the answers come from, the application might become unusable in some cases.

In this article, I’ll share an approach to address this concern. By linking every answer generated by the LLM to its source text in the document, we can build transparency and trust. This method not only provides clear evidence for the answers but also allows users to verify the results directly within the PDF.

Sometimes, the generated answer may not be perfectly accurate, but being able to locate the correct source text is already helpful for the user.

Let’s take an example of this paper from arxiv.org. We can imagine this use case:

Image by author — presentation of the document

The first step in this approach is to extract the text from the PDF in a structured format.

Source link

#Building #Trust #LLM #Answers #Highlighting #Source #Texts #PDFs #Angela #Kezhan #Shi #Dec