This repo contains the code for the FUNUus! MuRAG System -- a multimodal RAG-based Assistant to explore the FUNDus! database.
Note that this only works for LT and HCDS members. If you are not a member, you can request access to the data by contacting the Florian Schneider.
- Create a folder
datain the root of the project - Copy the DataFrames from
/ltstorage/shares/projects/fundus-murag/datato thedatafolder - Contact Florian Schneider to get the Google Service Acoount Credentials file and place it in the
datafolder (or create a new one with your Google Cloud account)
- Navigate to the
dockerfolder - Run
./setup-folders.shto create the necessary folders for the Docker volumes - Edit the
.env.examplefile and save it as.envwith the modified values
- Run
docker compose pullto pull the necessary images - Run
docker compose up -dto start the system - Run
docker compose logs -fto see the logs of the running containers
- Create a virtual environment with Python 3.10
- Navigate to repository root
- Install the requirements with
pip install -r requirements.txt - Get the data as described in the Docker section
- Navigate to the
dockerfolder - Run
./setup-folders.shto create the necessary folders for the Docker volumes - Edit the
.env.dev.examplefile and save it as.env.devwith the modified values - Navigate back to the repository root
- Edit the
config/config.dev.example.yamlfile and save it asconfig/config.dev.yamlwith the modified values
You only need to do this if you want to run the ML service locally, e.g., to change the Embedding Model or add new functionality. Otherwise, skip this.
- Navigate to repository root
- In the
src/fundus_murag/ml/server.pyfile, set the port to a random number (e.g., 23456) - Run
CUDA_VISIBLE_DEVICES=1 PYTHONPATH=src FUNDUS_ML_DEV_MODE=1 python src/fundus_murag/ml/server.pyto start the ML service in development mode - Check the logs to see on which port the service is running. You will need this port to start the MESOP application
- Navigate to the
dockerfolder - (Optional) If you run the ML service in development mode, remove the
fundusmlprofile from the.env.dev - Run
docker compose --env-file .env.dev upin atmuxor similar shell to start the dev containers (i.e., Weaviate) - Run
curl http://localhost:<YOUR_FUNDUS_ML_EXPOSED_PORT>/embedto check whether the FUNDus ML Service is up and running. This should print sth. like{"detail":"Method Not Allowed"}
- Navigate to repository root
- Select a port of your choice (e.g., the
FUNDUS_UI_EXPOSEDdefined in thedocker/.envfile) - Run
FUNDUS_CONFIG_FILE=config.dev.yaml PYTHONPATH=src mesop --port <PORT OF YOUR CHOICE> src/fundus_murag/ui/main.pyto start the FUNDus MuRAG application. - Open your browser and navigate to
http://localhost:<PORT OF YOUR CHOICE>to see the application. Don't forget to forward the port if you are running the application on a remote server.