Skip to content

Commit f0c816e

Browse files
committed
feat(WASI-NN,ggml): bump llama.cpp b5835 (#4249)
The reranking option is changed in this PR[1]. [1]: ggml-org/llama.cpp#14208 Signed-off-by: hydai <[email protected]>
1 parent ec0a4d5 commit f0c816e

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

cmake/WASINNDeps.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ function(wasmedge_setup_llama_target target)
330330
FetchContent_Declare(
331331
llama
332332
GIT_REPOSITORY https://github.com/ggml-org/llama.cpp.git
333-
GIT_TAG b5640
333+
GIT_TAG b5835
334334
GIT_SHALLOW FALSE
335335
)
336336
FetchContent_MakeAvailable(llama)

plugins/wasi_nn/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ wasmedge_add_library(wasmedgePluginWasiNN
2222
include(WASINNDeps)
2323
wasmedge_setup_wasinn_target(wasmedgePluginWasiNN PLUGINLIB)
2424

25-
set(WASMEDGE_WASI_NN_VERSION "0.1.26" CACHE STRING "WasmEdge WASI-NN library version")
25+
set(WASMEDGE_WASI_NN_VERSION "0.1.27" CACHE STRING "WasmEdge WASI-NN library version")
2626
set(WASMEDGE_WASI_NN_SOVERSION "0" CACHE STRING "WasmEdge WASI-NN library soversion")
2727

2828
# Handle the version of the WASI-NN plugin

plugins/wasi_nn/wasinn_ggml.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1386,7 +1386,10 @@ ErrNo parseMetadata(Graph &GraphRef, LocalConfig &ConfRef,
13861386
GraphRef.Params.embd_sep = EmbdSep;
13871387
}
13881388
if (Doc.at_key("reranking").error() == simdjson::SUCCESS) {
1389-
auto Err = Doc["reranking"].get<bool>().get(GraphRef.Params.reranking);
1389+
bool Reranking = false;
1390+
auto Err = Doc["reranking"].get<bool>().get(Reranking);
1391+
GraphRef.Params.embedding = true;
1392+
GraphRef.Params.pooling_type = LLAMA_POOLING_TYPE_RANK;
13901393
if (Err) {
13911394
RET_ERROR(ErrNo::InvalidArgument,
13921395
"Unable to retrieve the reranking option."sv)

0 commit comments

Comments
 (0)