Update prosty-rag.cmd
Browse files- prosty-rag.cmd +4 -3
prosty-rag.cmd
CHANGED
|
@@ -12,8 +12,9 @@ echo \" >/dev/null ">NUL "\" \`" <#"
|
|
| 12 |
:; [ ! -f $indeksator ] && echo Pobieranie $indeksator... && curl -Lo $indeksator https://huggingface.co/jglowa/prosty-rag/resolve/main/indeksator.cmd?download=true && chmod +x $indeksator && echo Gotowe!
|
| 13 |
:; [ ! -f $dbfile ] && ./$indeksator
|
| 14 |
:; # Uruchamianie
|
| 15 |
-
:;
|
| 16 |
-
:;
|
|
|
|
| 17 |
:; ./$llamafile --server --v2 --prompt "$prompt" --flash-attn 1 $@ &
|
| 18 |
:; echo "Uruchamianie czatu na stronie http://localhost:8080 w przegl膮darce..." && sleep 5 && xdg-open "http://localhost:8080" || open "http://localhost:8080"; wait; exit $?
|
| 19 |
:; # Windows:
|
|
@@ -26,7 +27,7 @@ set indeksator=indeksator.cmd
|
|
| 26 |
set "prompt=Jeste艣 pomocnym asystentem. Odpowiedz na pytania u偶ytkownika korzystaj膮c z podanego kontekstu, zawieraj膮cego wybrane fragmenty plik贸w. Na ko艅cu podaj odwo艂anie do pliku 藕r贸d艂a. Je艣li nie potrafisz odpowiedzie膰, to napisz to. Nie zmy艣laj."
|
| 27 |
:; # Instalacja
|
| 28 |
if not exist %llamafile% echo Pobieranie %llamafile%... && curl -Lo %llamafile% https://huggingface.co/jglowa/prosty-rag/resolve/main/prosty-rag.llamafile?download=true && echo Gotowe^!
|
| 29 |
-
if not exist %embedfile% echo Pobieranie %embedfile%... && curl -Lo %embedfile% https://huggingface.co/asg017/embedfile/resolve/refs%2Fpr%2F2/bge-m3.embedfile?download=true && echo Gotowe^!
|
| 30 |
if not exist %indeksator% echo Pobieranie %indeksator%... && curl -Lo %indeksator% https://huggingface.co/jglowa/prosty-rag/resolve/main/indeksator.cmd?download=true && echo Gotowe^!
|
| 31 |
if not exist %dbfile% call %indeksator%
|
| 32 |
:; # Uruchamianie
|
|
|
|
| 12 |
:; [ ! -f $indeksator ] && echo Pobieranie $indeksator... && curl -Lo $indeksator https://huggingface.co/jglowa/prosty-rag/resolve/main/indeksator.cmd?download=true && chmod +x $indeksator && echo Gotowe!
|
| 13 |
:; [ ! -f $dbfile ] && ./$indeksator
|
| 14 |
:; # Uruchamianie
|
| 15 |
+
:; echo "Uruchamianie serwera embedfile na http://localhost:8081..."
|
| 16 |
+
:; ncat -lkc 'read -r req; q="${req#*\?q=}"; q="${q%% *}"; q="${q//+/ }"; q=$(printf "%b" "${q//%/\\x}"); printf "HTTP/1.0 200 OK\r\nContent-Type: text/plain; charset=utf-8\r\n\r\n%s" "$(./bge-m3.embedfile search prosty-rag.db "$q")"' localhost 8081 &
|
| 17 |
+
:; echo "Uruchamianie serwera llamafile na http://localhost:8080..."
|
| 18 |
:; ./$llamafile --server --v2 --prompt "$prompt" --flash-attn 1 $@ &
|
| 19 |
:; echo "Uruchamianie czatu na stronie http://localhost:8080 w przegl膮darce..." && sleep 5 && xdg-open "http://localhost:8080" || open "http://localhost:8080"; wait; exit $?
|
| 20 |
:; # Windows:
|
|
|
|
| 27 |
set "prompt=Jeste艣 pomocnym asystentem. Odpowiedz na pytania u偶ytkownika korzystaj膮c z podanego kontekstu, zawieraj膮cego wybrane fragmenty plik贸w. Na ko艅cu podaj odwo艂anie do pliku 藕r贸d艂a. Je艣li nie potrafisz odpowiedzie膰, to napisz to. Nie zmy艣laj."
|
| 28 |
:; # Instalacja
|
| 29 |
if not exist %llamafile% echo Pobieranie %llamafile%... && curl -Lo %llamafile% https://huggingface.co/jglowa/prosty-rag/resolve/main/prosty-rag.llamafile?download=true && echo Gotowe^!
|
| 30 |
+
if not exist %embedfile% echo Pobieranie %embedfile%... && curl -Lo %embedfile% https://huggingface.co/asg017/embedfile/resolve/refs%%2Fpr%%2F2/bge-m3.embedfile?download=true && echo Gotowe^!
|
| 31 |
if not exist %indeksator% echo Pobieranie %indeksator%... && curl -Lo %indeksator% https://huggingface.co/jglowa/prosty-rag/resolve/main/indeksator.cmd?download=true && echo Gotowe^!
|
| 32 |
if not exist %dbfile% call %indeksator%
|
| 33 |
:; # Uruchamianie
|