#!/bin/bash

MODEL="$(realpath "$1")"
SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
echo "Serverdir: $SCRIPT_DIR"

if [ -z "$1" ]; then
	echo "USAGE: start.sh <path-to-model>"
	exit 1
fi

echo "Modelpath: $MODEL"

cd "$SCRIPT_DIR"
source "./venv/bin/activate"
python3 -m debugpy --listen 0.0.0.0:5679 flask_server.py --rkllm_model_path "$MODEL" --target_platform rk3588


