diff --git a/Makefile b/Makefile index 220930b6..41ce34e7 100644 --- a/Makefile +++ b/Makefile @@ -6,7 +6,7 @@ BINARY_NAME=local-ai DETECT_LIBS?=true # llama.cpp versions -CPPLLAMA_VERSION?=3e1d29348b5d77269f6931500dd1c1a729d429c8 +CPPLLAMA_VERSION?=6bf28f0111ff9f21b3c1b1eace20c590281e7ba6 # whisper.cpp version WHISPER_REPO?=https://github.com/ggerganov/whisper.cpp diff --git a/backend/cpp/llama/CMakeLists.txt b/backend/cpp/llama/CMakeLists.txt index 031e4964..2cd5ffd7 100644 --- a/backend/cpp/llama/CMakeLists.txt +++ b/backend/cpp/llama/CMakeLists.txt @@ -2,7 +2,7 @@ ## XXX: In some versions of CMake clip wasn't being built before llama. ## This is an hack for now, but it should be fixed in the future. set(TARGET myclip) -add_library(${TARGET} clip.cpp clip.h llava.cpp llava.h) +add_library(${TARGET} clip.cpp clip.h clip-impl.h llava.cpp llava.h) install(TARGETS ${TARGET} LIBRARY) target_include_directories(myclip PUBLIC .) target_include_directories(myclip PUBLIC ../..) diff --git a/backend/cpp/llama/grpc-server.cpp b/backend/cpp/llama/grpc-server.cpp index ded46b1c..18dfdc64 100644 --- a/backend/cpp/llama/grpc-server.cpp +++ b/backend/cpp/llama/grpc-server.cpp @@ -514,7 +514,7 @@ struct llama_server_context LOG_INFO("Multi Modal Mode Enabled", {}); clp_ctx = clip_init(params.mmproj.path.c_str(), clip_context_params { /* use_gpu */ has_gpu, - /*verbosity=*/ 1, + /*verbosity=*/ GGML_LOG_LEVEL_INFO, }); if(clp_ctx == nullptr) { LOG_ERR("unable to load clip model: %s", params.mmproj.path.c_str()); diff --git a/backend/cpp/llama/prepare.sh b/backend/cpp/llama/prepare.sh index 4c8393b9..eabd93c5 100644 --- a/backend/cpp/llama/prepare.sh +++ b/backend/cpp/llama/prepare.sh @@ -21,6 +21,7 @@ fi ## XXX: In some versions of CMake clip wasn't being built before llama. ## This is an hack for now, but it should be fixed in the future. cp -rfv llama.cpp/examples/llava/clip.h llama.cpp/examples/grpc-server/clip.h +cp -rfv llama.cpp/examples/llava/clip-impl.h llama.cpp/examples/grpc-server/clip-impl.h cp -rfv llama.cpp/examples/llava/llava.cpp llama.cpp/examples/grpc-server/llava.cpp echo '#include "llama.h"' > llama.cpp/examples/grpc-server/llava.h cat llama.cpp/examples/llava/llava.h >> llama.cpp/examples/grpc-server/llava.h