Installation and Setup Guide

This guide provides detailed instructions for installing and configuring pat2vec.

Requirements

Core Services:

  • CogStack: An operational instance for data retrieval.

  • Elasticsearch: The backend for CogStack.

  • MedCAT: For medical concept annotation.

Local Setup:

  • Python: Version 3.10 or higher.

  • Virtual Environment: Requires the python3-venv package (or equivalent for your OS).



Installation on Windows

  1. Clone the repository:

    git clone https://github.com/SamoraHunter/pat2vec.git
    
  2. Run the installation script: This script sets up the Python virtual environment.

    cd pat2vec
    install.bat
    
  3. Activate the environment:

    pat2vec_env\Scripts\activate
    

Post-Installation Configuration

After running the installation script, you must configure your environment.

1. Elasticsearch Credentials

Your credentials should be placed in a file named credentials.py in the parent directory of your pat2vec clone. The install_pat2vec.sh script automatically copies a template for you.

IMPORTANT: This file contains sensitive information and should never be committed to version control.

The structure should look like this: