Create a PDF RAG with No Code using Google Cloud

Kirupa Avatar

Go to https://console.cloud.google.com/ and login using your google account

After the login, In the search box search for “vertex ai search”

Create a Search App

Create a Search App by choosing “Custom Search(general)”

Leave the following default options as is and add a name for you app and you company

Create RAG Data for your App

Under the Data Tab, Click create “Create data store”

Choose ‘Cloud Storage’ as the data source

I have already uploaded my PDF files to a bucket called ‘no-code-rag’ and I will be specifying this bucket.

Add a Name to your data store. I want the app to parse my layouts in the PDF hence I am choosing ‘Layout Parser’ as the Document Parsing option and click ‘Create’ at the bottom.

Once the Data store is created, the screen will take you to final step in the search app creation process. Click ‘create’

Once you search app is successfully created, you will see the following screen

Go to Data Section and check the ‘Activity’ tab to see whether your PDF files have been successfully imported (in other words RAG’d) into your search APP.

Do not proceed to the next step until the import is completed.

I have one item failed to import. But I am not going to worry about it for the sake of this exercise. Rest of my files have been RAG’d.

Testing the APP

Go to ‘App Overview’ and click ‘Preview’

The preview page looks as follows with a search bar and you can search for the contents in the PDF files

I am going to search for the word ‘Christiana Amanpour’ which is inside a table layout in a PDF file called 1704.04368.pdf

Let us search for ‘Christiana Amanpour’. The search has shown the correct result as 1704.04368.pdf

Calling the App as REST Api

Now your app is ready, you can start using it.

Under ‘App Overview’ Click ‘Integration’.

I am going to call the app via REST Api and the code for Rest call can be found under ‘Integration’. I am going to make the call in my ‘Cloud Shell’

That’s it ! You have created your first AI RAG app without a single line of code.


Leave a comment