
echo "Please select an option:"
echo "1. Start As 4-bit Precision"
echo "2. Start As 8-bit Precision"
echo "3. Start As 16-bit Precision"
echo "4. Start As 32-bit Precision"
echo

read -p "Enter your choice (1-4): " choice

echo "Please select an option:"
echo "1. Start Without Gradio Share"
echo "2. Start With Gradio Share"
echo

read -p "Enter your choice (1-2): " choice2

cd CogVLM
source ./venv/bin/activate
cd ..

case $choice in
    1)
        quant=4
        ;;
    2)
        quant=8
        ;;
    3)
        quant=16
        ;;
    4)
        quant=32
        ;;
esac

if [ "$choice2" == "2" ]; then
    python web_app_CogVLM.py --quant $quant --share
else
    python web_app_CogVLM.py --quant $quant
fi

read -p "Press enter to continue..."
