Response-Quality-Assessment / scripts /run_precompute.sh
Ryoya Awano
deploy: fix MedLFQA Marginal mode sample matching
19fc84f
raw
history blame contribute delete
785 Bytes
#!/usr/bin/env bash
# Run demo/precompute.py inside the Singularity container.
# Usage: bash scripts/run_precompute.sh
set -euo pipefail
REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
source "${REPO_ROOT}/.env"
singularity exec \
--bind "${DATA_ROOT}/data:${REPO_ROOT}/data" \
--bind "${DATA_ROOT}/index_store:${REPO_ROOT}/index_store" \
--bind "${HF_HOME}:${HF_HOME}" \
--env HF_HOME="${HF_HOME}" \
--env OPENAI_API_KEY="${OPENAI_API_KEY}" \
--env DATA_ROOT="${REPO_ROOT}" \
--pwd "${REPO_ROOT}" \
"${SIF_DIR}/response_quality.sif" \
python -m demo.precompute
echo ""
echo "Generated:"
echo " ${REPO_ROOT}/demo/data/thresholds.csv"
echo " ${REPO_ROOT}/demo/data/samples.json"
echo ""
echo "Commit these files: git add demo/data/ && git commit"