Skip to content
/ PDF-QA Public
forked from iMouth/PDF-QA

This is a QA platform for scientific paper.

Notifications You must be signed in to change notification settings

sadafrf/PDF-QA

 
 

Repository files navigation

PDF-QA

Demo

Demo


Pipeline

Screen Shot 2023-05-03 at 6 24 42 PM


How to Run

  1. Install Docker based on your operating system.
  2. If you have Nvidia GPUs follow the instructions to download nvidia-container-toolkit and nvidia-docker.

Method 1: With NVIDIA GPUS

Visit FastChat and follow their instructions to get the vicuna model. Also read their documentation on CPU and GPU requirements.

Place the model somewhere in the FastChat directory and update the --model-path in FastChat/start.sh.

Run the following command to see your Nvidia GPU information:

nvidia-smi

Using this information change the CUDA_VISIBLE_DEVICES in FastChat/start.sh and update --num-gpus accordingly.

Run the following command in the root directory to start up the services:

docker-compose up

NOTE: This will take some time the first time running this

Visit localhost:3000 to use PDF-QA.


Method 2: Without NVIDIA GPUS:

Visit FastChat and follow their instructions to get the vicuna model. Also read their documentation on CPU and GPU requirements.

Place the model somewhere in the FastChat directory and update the --model-path in FastChat/start.sh.

Change --device to cpu (or mps if you are on mac) in FastChat/start.sh.

Comment out or remove everything under deploy for both fastchat and grobid in docker-compose.yaml services.

Run the following command in the root directory to start up the services:

docker-compose up

NOTE: This will take some time the first time running this

Visit localhost:3000 to use PDF-QA.


Method 3: With CHATGPT

If you do not meet the GPU or CPU requirements and a ChatGPT api key you can do the following:

Comment out or remove the fastchat service in docker-compose.yaml

Make a .env file in backend directory with your API KEY in the following format:

CHATGPT_API_KEY=PLACE_KEY_HERE

Run the following command in the root directory to start up the services:

docker-compose up

Visit localhost:3000 to use PDF-QA.

About

This is a QA platform for scientific paper.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 95.4%
  • JavaScript 1.3%
  • HTML 1.1%
  • TypeScript 0.8%
  • Shell 0.7%
  • CSS 0.6%
  • Dockerfile 0.1%