mirror of
https://github.com/ivabus/pantry
synced 2024-11-25 09:55:06 +03:00
19 lines
396 B
C++
Executable file
19 lines
396 B
C++
Executable file
#!/bin/sh
|
|
|
|
set -e
|
|
test -n "$VERBOSE" && set -x
|
|
|
|
D="$(cd "$(dirname "$0")"/.. && pwd)"
|
|
VERSION="$(basename "$D")"
|
|
MODEL_DIR="${XDG_DATA_HOME:-$HOME/.local/share}/models/alpaca-LoRA"
|
|
|
|
export PATH="$D/tbin:$PATH"
|
|
|
|
alpaca.cpp-fetch-model "$MODEL_DIR" "$VERSION"
|
|
|
|
if test "$1" != '--fetch'; then
|
|
exec "$D"/tbin/alpaca.cpp \
|
|
--color \
|
|
--model "$MODEL_DIR"/ggml-alpaca-7b-q4.bin \
|
|
"$@"
|
|
fi
|