Skip to content

Commit 1fc6d46

Browse files
authored
chore(deps): bump llama.cpp to '1d36b3670b285e69e58b9d687c770a2a0a192194 (#5307)
chore(deps): bump llama.cpp to '1d36b3670b285e69e58b9d687c770a2a0a192194' Signed-off-by: Ettore Di Giacinto <[email protected]>
1 parent 05848b2 commit 1fc6d46

File tree

7 files changed

+23
-23
lines changed

7 files changed

+23
-23
lines changed

.env

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@
7676

7777
### Define a list of GRPC Servers for llama-cpp workers to distribute the load
7878
# https://github.com/ggerganov/llama.cpp/pull/6829
79-
# https://github.com/ggerganov/llama.cpp/blob/master/examples/rpc/README.md
79+
# https://github.com/ggerganov/llama.cpp/blob/master/tools/rpc/README.md
8080
# LLAMACPP_GRPC_SERVERS=""
8181

8282
### Enable to run parallel requests

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ BINARY_NAME=local-ai
66
DETECT_LIBS?=true
77

88
# llama.cpp versions
9-
CPPLLAMA_VERSION?=d7a14c42a1883a34a6553cbfe30da1e1b84dfd6a
9+
CPPLLAMA_VERSION?=1d36b3670b285e69e58b9d687c770a2a0a192194
1010

1111
# whisper.cpp version
1212
WHISPER_REPO?=https://github.com/ggerganov/whisper.cpp

backend/cpp/llama/Makefile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,8 @@ llama.cpp:
5959
git checkout -b build $(LLAMA_VERSION) && \
6060
git submodule update --init --recursive --depth 1 --single-branch
6161

62-
llama.cpp/examples/grpc-server: llama.cpp
63-
mkdir -p llama.cpp/examples/grpc-server
62+
llama.cpp/tools/grpc-server: llama.cpp
63+
mkdir -p llama.cpp/tools/grpc-server
6464
bash prepare.sh
6565

6666
rebuild:
@@ -70,13 +70,13 @@ rebuild:
7070

7171
purge:
7272
rm -rf llama.cpp/build
73-
rm -rf llama.cpp/examples/grpc-server
73+
rm -rf llama.cpp/tools/grpc-server
7474
rm -rf grpc-server
7575

7676
clean: purge
7777
rm -rf llama.cpp
7878

79-
grpc-server: llama.cpp llama.cpp/examples/grpc-server
79+
grpc-server: llama.cpp llama.cpp/tools/grpc-server
8080
@echo "Building grpc-server with $(BUILD_TYPE) build type and $(CMAKE_ARGS)"
8181
ifneq (,$(findstring sycl,$(BUILD_TYPE)))
8282
+bash -c "source $(ONEAPI_VARS); \

backend/cpp/llama/grpc-server.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ struct server_params
5252
{
5353
std::string hostname = "127.0.0.1";
5454
std::vector<std::string> api_keys;
55-
std::string public_path = "examples/server/public";
55+
std::string public_path = "tools/server/public";
5656
std::string chat_template = "";
5757
int32_t port = 8080;
5858
int32_t read_timeout = 600;

backend/cpp/llama/patches/01-llava.patch

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
diff --git a/examples/llava/clip.cpp b/examples/llava/clip.cpp
1+
diff --git a/tools/llava/clip.cpp b/tools/llava/clip.cpp
22
index 3cd0d2fa..6c5e811a 100644
3-
--- a/examples/llava/clip.cpp
4-
+++ b/examples/llava/clip.cpp
3+
--- a/tools/llava/clip.cpp
4+
+++ b/tools/llava/clip.cpp
55
@@ -2608,7 +2608,7 @@ bool clip_image_batch_encode(clip_ctx * ctx, const int n_threads, const clip_ima
66
struct ggml_tensor * patches = ggml_graph_get_tensor(gf, "patches");
77
int* patches_data = (int*)malloc(ggml_nbytes(patches));

backend/cpp/llama/prepare.sh

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,22 +7,22 @@ for patch in $(ls patches); do
77
patch -d llama.cpp/ -p1 < patches/$patch
88
done
99

10-
cp -r CMakeLists.txt llama.cpp/examples/grpc-server/
11-
cp -r grpc-server.cpp llama.cpp/examples/grpc-server/
12-
cp -rfv json.hpp llama.cpp/examples/grpc-server/
13-
cp -rfv utils.hpp llama.cpp/examples/grpc-server/
10+
cp -r CMakeLists.txt llama.cpp/tools/grpc-server/
11+
cp -r grpc-server.cpp llama.cpp/tools/grpc-server/
12+
cp -rfv json.hpp llama.cpp/tools/grpc-server/
13+
cp -rfv utils.hpp llama.cpp/tools/grpc-server/
1414

15-
if grep -q "grpc-server" llama.cpp/examples/CMakeLists.txt; then
15+
if grep -q "grpc-server" llama.cpp/tools/CMakeLists.txt; then
1616
echo "grpc-server already added"
1717
else
18-
echo "add_subdirectory(grpc-server)" >> llama.cpp/examples/CMakeLists.txt
18+
echo "add_subdirectory(grpc-server)" >> llama.cpp/tools/CMakeLists.txt
1919
fi
2020

2121
## XXX: In some versions of CMake clip wasn't being built before llama.
2222
## This is an hack for now, but it should be fixed in the future.
23-
cp -rfv llama.cpp/examples/llava/clip.h llama.cpp/examples/grpc-server/clip.h
24-
cp -rfv llama.cpp/examples/llava/clip-impl.h llama.cpp/examples/grpc-server/clip-impl.h
25-
cp -rfv llama.cpp/examples/llava/llava.cpp llama.cpp/examples/grpc-server/llava.cpp
26-
echo '#include "llama.h"' > llama.cpp/examples/grpc-server/llava.h
27-
cat llama.cpp/examples/llava/llava.h >> llama.cpp/examples/grpc-server/llava.h
28-
cp -rfv llama.cpp/examples/llava/clip.cpp llama.cpp/examples/grpc-server/clip.cpp
23+
cp -rfv llama.cpp/tools/llava/clip.h llama.cpp/tools/grpc-server/clip.h
24+
cp -rfv llama.cpp/tools/llava/clip-impl.h llama.cpp/tools/grpc-server/clip-impl.h
25+
cp -rfv llama.cpp/tools/llava/llava.cpp llama.cpp/tools/grpc-server/llava.cpp
26+
echo '#include "llama.h"' > llama.cpp/tools/grpc-server/llava.h
27+
cat llama.cpp/tools/llava/llava.h >> llama.cpp/tools/grpc-server/llava.h
28+
cp -rfv llama.cpp/tools/llava/clip.cpp llama.cpp/tools/grpc-server/clip.cpp

backend/cpp/llama/utils.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// https://github.com/ggerganov/llama.cpp/blob/master/examples/server/utils.hpp
1+
// https://github.com/ggerganov/llama.cpp/blob/master/tools/server/utils.hpp
22

33
#pragma once
44

0 commit comments

Comments
 (0)