Recruitment process enhanced by Graph Neural Networks (GNNs)
- Install uv
Clone the repo and change directory:
git clone https://github.com/dartt0n/gnn-recruitment.git && cd gnn-recruitmentDifferent python notebooks are available in the experiments directory.
| Notebook | Colab |
|---|---|
| 001-gin-shared | |
| 002-sage-shared | |
| 003-gat-shared | |
| 004-rgnn-shared | |
| 005-cgnn-shared |
To run them, you need to install the dependencies. The best way to do it is to use uv.
git clone https://github.com/dartt0n/gnn-recruitment.git && cd gnn-recruitment
uv sync # install base dependencies
uv pip install torch-scatter torch-sparse -f https://data.pyg.org/whl/torch-2.5.0+cpu.html # for cpu
uv pip install torch-scatter torch-sparse -f https://data.pyg.org/whl/torch-2.5.0+cu121.html # for gpu
uv sync --extra cli # if you want to use CLI
uv sync --extra jupyter # if you want to use Jupyter
uv sync --extra cli --extra jupyter # for bothHowever, if you are using Google Colab, Kaggle, or InnoDataHub you can just add the following command at the top of the notebook:
- Google Colab or Kaggle
!pip install datasets lightning wandb sentence-transformers polars torch-geometric torch-scatter torch-sparse -f https://data.pyg.org/whl/torch-2.5.0+cu121.html- InnoDataHub
!pip install datasets lightning wandb sentence-transformers polars torch-geometric torch-scatter torch-sparse -f https://data.pyg.org/whl/torch-2.1.1+cu119.htmluv sync # install base dependencies
uv pip install torch-scatter torch-sparse -f https://data.pyg.org/whl/torch-2.5.0+cpu.html # for cpu
uv pip install torch-scatter torch-sparse -f https://data.pyg.org/whl/torch-2.5.0+cu121.html # for gpu
uv sync --extra cli # if you want to use CLI
uv sync --extra jupyter # if you want to use Jupyter
uv sync --extra cli --extra jupyter # for both# access help
uv run gnnr --help
uv run gnnr data --help
uv run gnnr data generate --help
# generate data with synthetic data
uv run gnnr data generate --output ./data
# or
uv run gnnr data generate --output ./data --no-synthetic
# also generate synthetic data
uv run gnnr data generate --output ./data --synthetic
# specify model to use for embeddings
uv run gnnr data generate --output ./data \
--synthetic \
--model sentence-transformers/all-MiniLM-L12-v2
# only synthetic data
uv run gnnr data synthetic \
--model sentence-transformers/all-MiniLM-L12-v2 \
--output ./dataExport dataset for different visualization tools
uv run gnnr data export \
[edgelist|graphml|gexf|dot] \
--input data/dataset/edges.json \
--output ~/Downloads/edgelist.csvuv run ruff format .