From 5d81e2f2d8ffd0773a96f68441cd005c3546216f Mon Sep 17 00:00:00 2001 From: Gabriel Luiz Freitas Almeida Date: Thu, 13 Jul 2023 09:02:10 -0300 Subject: [PATCH] =?UTF-8?q?=F0=9F=93=9D=20docs(loading=5Fdocument.mdx):=20?= =?UTF-8?q?update=20title=20and=20content=20to=20provide=20a=20clearer=20a?= =?UTF-8?q?nd=20more=20comprehensive=20guide=20on=20how=20to=20populate=20?= =?UTF-8?q?a=20Prompt=20variable=20with=20a=20document?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ✨ feat(loading_document.mdx): add step-by-step instructions on how to define a Prompt variable and connect a WebBaseLoader to it for loading a document into the variable 🔀 chore(loading_document.mdx): reorganize and rephrase the content to improve readability and clarity --- docs/docs/guides/loading_document.mdx | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/docs/docs/guides/loading_document.mdx b/docs/docs/guides/loading_document.mdx index fa1235e6c..9a5c79efb 100644 --- a/docs/docs/guides/loading_document.mdx +++ b/docs/docs/guides/loading_document.mdx @@ -3,15 +3,19 @@ import useBaseUrl from "@docusaurus/useBaseUrl"; import ZoomableImage from "/src/theme/ZoomableImage.js"; import ReactPlayer from "react-player"; -# Loading a document into a Prompt variable +# Populating a Prompt Variable with a Document ## Overview -The following example shows how to load a document into a Prompt variable. -First, we define a Prompt variable in the PromptTemplate component, -then we connect a WebBaseLoader to that variable and build the flow. +This walkthrough provides a step-by-step guide on how to load a document into a Prompt variable. It is a simple two-part process: -Once the building is complete, we can start chatting having the content of the document in the context of the conversation. +1. **Prompt Variable Definition:** We start by defining a Prompt variable within the PromptTemplate component. This variable will serve as the placeholder for our document's content. + +2. **WebBaseLoader Connection:** Next, we link a WebBaseLoader to the Prompt variable we've just created. This will facilitate the flow building process and ensure the content of the document is properly loaded. + +Upon successful completion of these steps, you'll be able to start a chat with the document's content readily available within the conversational context. This provides seamless integration of the document into the chat, enhancing the user's experience by making relevant information more accessible. + +Please follow the steps outlined in the interactive guide to understand the process in detail.