Skip to content

Latest commit

 

History

26 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Medical Annotation Tool

Notice

This repository does not contain the model or the data the model was trained as the data is sensitive.

Introduction

This annotation tool is intended to allow medical professionals to annotate investigation reports using the SIRch taxonomy.

alt text

Pre-requisites

HuggingFace API Token

A HuggingFace API token is required for fine-tuning the model.

The token can be obtained by:

  1. Signing up to HuggingFace here
  2. Generating a new API token here.

WSL (Windows Subsystem for Linux)

At the time of writing, Ollama is not supported on Windows. As such, WSL for Windows is required to run the backend on Windows.

To install WSL, follow the instructions here, then proceed to install the backend as per the instructions below in the WSL terminal.

Installation

Backend

To install the required packages, run the following command:

cd backend
conda create -n medical-annotation-tool python=3.11
conda activate medical-annotation-tool
pip install -r requirements.txt

Create a .env file in the backend directory with the following content:

HUGGINGFACE_TOKEN=YOUR_HUGGINGFACE_TOKEN

Install Ollama by running the command:

curl -fsSL https://ollama.com/install.sh | sh

Install Mistral 7B by running the command:

ollama install mistral-7b
ollama list

Then run the following command to start the backend:

python main.py

Frontend

Node.js is required to run the frontend. It can be downloaded from here.

To install the required packages, run the following command:

cd frontend
npm install

Then run the following command to start the frontend:

npm start

Notebooks

This directory contains the notebooks used to quickly test and evaluate the model using different prompting techniques, hyper-parameters, and datasets.

To install the required packages, run the following command:

cd notebooks
conda create -n notebooks python=3.11
conda activate notebooks
pip install -r requirements.txt

Then run the following command to start the Jupyter notebook server:

jupyter notebook

Usage

The frontend can be accessed at:

http://localhost:3000

The backend API for annotation can be accessed at:

http://localhost:5000/annotate

About

No description, website, or topics provided.

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages