1
0

run-converted-model.sh 532 B

1234567891011121314151617181920
  1. #!/bin/bash
  2. set -e
  3. # First try command line argument, then environment variable, then file
  4. CONVERTED_MODEL="${1:-"$CONVERTED_MODEL"}"
  5. # Final check if we have a model path
  6. if [ -z "$CONVERTED_MODEL" ]; then
  7. echo "Error: Model path must be provided either as:" >&2
  8. echo " 1. Command line argument" >&2
  9. echo " 2. CONVERTED_MODEL environment variable" >&2
  10. exit 1
  11. fi
  12. echo $CONVERTED_MODEL
  13. cmake --build ../../build --target llama-logits -j8
  14. ../../build/bin/llama-logits -m "$CONVERTED_MODEL" "Hello, my name is"