Skip to content

mindfulMachineLath/QA-document-learning

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AI QA over PDF & documents

A minimal code base for creating AI apps to do Question Answering (QA) over PDF documents, completely locally.

This project is inspired by local-ai-stack. However, their stack is entirely javascript based, and I needed a python based backend, so decided to create this project.

QA.for.document.mp4

Stack

How to get started

  1. Clone this repo:
git@github.com:undersky0827/QA-document-learning.git
  1. Install backend dependencies:
cd backend/app
pip install -r requirements.txt
  1. Install frontend dependencies:
cd frontend
npm install
  1. Start the Qdrant vector database (you need Docker). See here for other options information:
docker run -p 6333:6333 qdrant/qdrant
  1. Install Ollama Instructions are here

  2. Run the FastApi server (from inside backend directory):

python app/main.py
  1. Open a new terminal and start the React development server (from inside frontend):
npm start

Change Configurations

You can change configurations in .config file, such as the embedding model, chunk size, and chunk overlap. If you plan to use Qdrant Cloud, you can or you can create your own .env file and set necessary api keys.

Additional Use Cases

Although current app only support pdf files, it's very straightforward to add other types of files such as text files, etc. Also, you can easily add the open-ended chat in addition to QA over document use case.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published