AllEx is a web-based immersive virtual lab platform that allows users to perform various experiments in an XR environment. It is developed as part of the SPARCS Science Hackathon 2024.
@vladmandic/human
.@vladmandic/human
for real-time hand detection and gesture recognitiongit clone https://github.com/JJong84/ALLeX.git
cd ALLeX
python3 -m venv venv
source venv/bin/activate
pip install fastapi uvicorn sqlalchemy pymysql
cd web
npm install
CREATE DATABASE allex;
USE allex;
-- Create the `labs` table
CREATE TABLE labs (
id INT AUTO_INCREMENT PRIMARY KEY,
lab_name VARCHAR(255) NOT NULL,
goal VARCHAR(255) NULL
);
-- Create the `substances` table
CREATE TABLE substances (
substance_id INT AUTO_INCREMENT PRIMARY KEY,
substance_name VARCHAR(255) NOT NULL
);
-- Create the `lab_inventory` table
CREATE TABLE lab_inventory (
entity_id INT AUTO_INCREMENT PRIMARY KEY,
lab_id INT,
substance_id INT,
x INT,
y INT,
case_type VARCHAR(255),
FOREIGN KEY (lab_id) REFERENCES labs(id) ON DELETE CASCADE,
FOREIGN KEY (substance_id) REFERENCES substances(substance_id) ON DELETE CASCADE
);
-- Create the `experiments` table
CREATE TABLE experiments (
substance_id1 INT,
substance_id2 INT,
color_change VARCHAR(255),
explosion TINYINT,
FOREIGN KEY (substance_id1) REFERENCES substances(substance_id) ON DELETE CASCADE,
FOREIGN KEY (substance_id2) REFERENCES substances(substance_id) ON DELETE CASCADE
);
config.py
file:DB_HOST=localhost
DB_USER=root
DB_PASS=yourpassword
DB_NAME=alex
cd server
uvicorn main:app --reload
cd web
npm run dev
AllEx/
│
├── server/ # Backend (python, fastapi, MySQL)
│ ├── .gitignore
│ ├── .gitkeep
│ ├── config.py
│ ├── crud.py
│ ├── database.py
│ ├── main.py
│ ├── models.py
│ ├── schemas.py
│ └── routers
│ ├── experiments.py
│ ├── inventory.py
│ ├── labs.py
│ ├── substances.py
│ └── __init__.py
│
├── web/ # Frontend (React, TypeScript)
│ ├── public/
│ ├── src/
│ │ ├── components/ # React components
│ │ ├── App.tsx # Main App component
│ │ └── main.tsx # Entry point for React app
│ ├── vite.config.ts # Vite configuration
│ └── index.html # Main HTML template
│
├── README.md # Project documentation
└── package.json # Project metadata and dependencies
We welcome contributions! To get started:
Please follow our coding standards and ensure your code passes all linting and testing requirements.
This project is licensed under the MIT License. See the LICENSE file for details.