<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw" -->

---
title: Lab #3: Implementing RAG to build a “Chat with Multiple...
description: This post explains how to build a 'Chat with Multiple PDFs' app using Retrieval-Augmented Generation (RAG), and covers its benefits, such as reducing model...
canonical: https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Lab #3: Implementing RAG to build a “Chat with Multiple PDFs” app | daily.dev
og:description: This post explains how to build a 'Chat with Multiple PDFs' app using Retrieval-Augmented Generation (RAG), and covers its benefits, such as reducing model...
og:url: https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw
og:image: https://api.daily.dev/og/posts/BRHLVY4pw.png
og:image:alt: Lab #3: Implementing RAG to build a “Chat with Multiple PDFs” app
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Lab #3: Implementing RAG to build a “Chat with Multiple PDFs” app

**[GoPenAI](https://daily.dev/sources/gopenai)** · 8 min read · 22 upvotes · 2 comments

## Summary

This post explains how to build a 'Chat with Multiple PDFs' app using Retrieval-Augmented Generation (RAG), and covers its benefits, such as reducing model hallucination and enhancing reliability. It details phases for pre-processing and inference, including loading, chunking, and embedding data into a vector database, and setting up a retrieval chain using Langchain and OpenAI integration.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://blog.gopenai.com/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-88c1d7cd5d19>

## Community discussion

Top comments from developers on daily.dev.

**@fasa** · 0 upvotes

> ![image](https://res.cloudinary.com/daily-now/image/upload/s--vwNxOs4w--/f_auto/v1727717563/ugc/content_2a07677f-800b-47d3-b5c6-816f03373000)

**@fasa** · 0 upvotes

> ![image](https://res.cloudinary.com/daily-now/image/upload/s--JC9nTa3G--/f_auto/v1727717570/ugc/content_e5980c70-5648-423f-ae79-e91c61ebc225)

---

Tags: [#llm](https://daily.dev/tags/llm), [#openai](https://daily.dev/tags/openai), [#langchain](https://daily.dev/tags/langchain), [#rag](https://daily.dev/tags/rag)

[View this post on daily.dev](https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Lab #3: Implementing RAG to build a “Chat with Multiple PDFs” app","url":"https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw"},"datePublished":"2024-07-03T11:10:21.374Z","dateModified":"2024-10-05T17:07:04.637Z","description":"This post explains how to build a 'Chat with Multiple PDFs' app using Retrieval-Augmented Generation (RAG), and covers its benefits, such as reducing model...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/13b6dac3efa06fb4de1d505461ef906d?_a=AQAEuiZ","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/13b6dac3efa06fb4de1d505461ef906d?_a=AQAEuiZ","isAccessibleForFree":true,"articleSection":"GoPenAI","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"GoPenAI","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/f34dfd0c312c4a59b897eb64ad28d895","url":"https://daily.dev/sources/gopenai"},"commentCount":2,"discussionUrl":"https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":22},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":2}],"keywords":"llm,openai,langchain,rag","timeRequired":"PT8M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"GoPenAI","item":"https://daily.dev/sources/gopenai"},{"@type":"ListItem","position":3,"name":"Lab #3: Implementing RAG to build a “Chat with Multiple PDFs” app"}]}
{"@context":"https://schema.org","@type":"WebPage","@id":"https://daily.dev/posts/lab-3-implementing-rag-to-build-a-chat-with-multiple-pdfs-app-brhlvy4pw","comment":[{"@type":"Comment","text":"","datePublished":"2024-09-30T17:32:45.248Z","url":"https://daily.dev/posts/BRHLVY4pw#c-R3dOJ9lE0","author":{"@type":"Person","name":"FA SA","url":"https://daily.dev/fasa","image":"https://media.daily.dev/image/upload/s--wmXVWu9i--/f_auto/v1727562625/avatars/avatar_Z44v23u0fyZHvnocRmzbc"}},{"@type":"Comment","text":"","datePublished":"2024-09-30T17:32:51.710Z","url":"https://daily.dev/posts/BRHLVY4pw#c-6qfWE1kWO","author":{"@type":"Person","name":"FA SA","url":"https://daily.dev/fasa","image":"https://media.daily.dev/image/upload/s--wmXVWu9i--/f_auto/v1727562625/avatars/avatar_Z44v23u0fyZHvnocRmzbc"}}]}
```

