#!/bin/bash # Setup RunPod pour fine-tuning pmsi-coder # Usage : bash setup.sh set -e echo "=== Setup fine-tuning PMSI-coder sur RunPod ===" # Installer Unsloth + dépendances pip install --no-deps "unsloth[cu124-ampere-torch250] @ git+https://github.com/unslothai/unsloth.git" pip install --no-deps unsloth_zoo pip install trl datasets peft accelerate bitsandbytes sentencepiece protobuf # Wandb optionnel pip install wandb 2>/dev/null || echo "wandb non installé (optionnel)" echo "" echo "=== Setup terminé ===" echo "" echo "Vérifiez que les fichiers data/ sont présents :" ls -lh data/pmsi_train.jsonl data/pmsi_eval.jsonl 2>/dev/null || echo " MANQUANT ! Uploadez les datasets." echo "" echo "Pour lancer :" echo " python train_runpod.py --epochs 3 --export-gguf" echo "" echo "Estimation A100 40GB : ~2-3h pour 3 epochs" echo "Estimation A100 80GB : ~1.5-2h pour 3 epochs"