Skip to content

Ruan-Yixiang/LLM-RDF

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

License

LLM-RDF

LLM-RDF: Large language model (LLM)-based reaction development framework.

The code and data repository of "Accelerated end-to-end chemical synthesis development with large language models".

Deployment

Please refer to the demo.mp4 file provided to use the web application.

Docker (Recommended, may take a few minutes)

  1. Pull Docker Images
# AMD64
docker pull ruanyixiang/llm_rdf_back:latest
docker pull ruanyixiang/llm_rdf_front:latest
# ARM64
docker pull ruanyixiang/llm_rdf_back:arm
docker pull ruanyixiang/llm_rdf_front:arm
  1. Run Back-End Service
docker run -p {BACKEND_PORT}:81 -d ruanyixiang/llm_rdf_back
  1. Run Front-End Service
    Replace {BACKEND_URL} with the actual backend deployment URL.
    Replace {OPENWEBUI_URL} with the actual OpenWebUI deployment URL (unnecessary).
docker run --env=BACKEND_URL={BACKEND_URL} --env=VUE_APP_OPENWEBUI_URL={OPENWEBUI_URL} -p {FRONTEND_PORT}:83 -d ruanyixiang/llm_rdf_front
# Example
docker run --env=BACKEND_URL="http://127.0.0.1:81" -p 83:83 -d ruanyixiang/llm_rdf_front
  1. Access the Application
    {FRONTEND_URL}/main
    Example: http://127.0.0.1:83/main main

Manual Deployment (Not recommended, It may only work successfully on Intel CPU Windows 10.)

  1. Clone the repository:
git clone https://github.com/Ruan-Yixiang/LLM-RDF.git
cd LLM-RDF
  1. Install the backend environment
    Use conda to install the dependencies listed in requirements.txt:
# Create a new conda environment named 'llm_rdf_back' with Python 3.8
conda create -n llm_rdf_back python=3.8

# Activate the newly created environment
conda activate llm_rdf_back

# Install the required Python packages from requirements.txt
pip install -r Backend\ Files/requirements.txt
  1. Run Back-End Service
    You can modify the backend url in backend/backend.py
cd Backend\ Files/
python backend/backend.py
  1. Install Node.js (v16.16.0) on your device
  2. Install the npm
    In a new terminal, navigate to the frontend directory and install npm:
cd frontend
npm install -g [email protected]
  1. Run Front-End Service
    You can modify the backend_url and openwebui_url in vue.config.js
npm run dev

License

LLM-RDF is distributed under an MIT License.