AjayK47/Gemini-File

Ajay K

AI Model Developer
Google Gemini
LlamaIndex

Gemini-File

Pdf Query chat-bot using Gemini Pro model and Llama Index
Gemini-File is a Streamlit web application that allows users to upload PDF files, index their contents using the Gemini search engine from the Llama-Index library, and query the documents.

Features

Upload PDF files for indexing.
Perform text queries on the indexed documents.
Powered by the Gemini Pro model and Hugging Face embeddings.

Getting Started

Prerequisites

!! Strongly Recommend running this code while connected to GPU !!
Before you begin, ensure you have the following installed:
Python (>=3.6)
Llama-Index library
Google API key (set as an environment variable)
You can get this Google gemini APi key from Google AI Developer Website , you can easily signup and get one for free.

Google API Key Configuration

The Google API key is set as an environment variable. Ensure it is correctly configured before running the app.Usage

Uploading a PDF

Run the Streamlit app: streamlit run app.py
Access the app in your web browser.
Use the "Upload your PDF" button to upload a PDF file.

Customization

Using Other Embedding Models

You can customize the embedding model used for document indexing. Edit the 'app.py' file and modify the 'HuggingFaceEmbedding' instantiation:
# Example using a different Hugging Face model embed_model_custom = HuggingFaceEmbedding(model_name="your/own-model-name")
you can find best text embedding model for you with help of MTEB Leaderboard

Authors

Partner With Ajay
View Services

More Projects by Ajay