Provides JNI bindings for bert.cpp.
Available in Maven Central.
implementation("io.vacco.bert:bert.jni:<LATEST_VERSION>>")
Since bert.cpp
does not appear to be tracking release versions, this library will be in sync with specific commits from its repository.
0.1.0-cd2170d
Where 0.1.0
is the version number for this library, and cd2170d
is the bert.cpp
commit used to build the native code.
See test cases for example use.
The following bert.cpp
models appear to work correctly when loading their f16
variants.
all-MiniLM-L12-v2
all-MiniLM-L6-v2
multi-qa-MiniLM-L6-cos-v1
- Only Linux is supported at the moment. PRs for other Operating systems are welcome and encouraged.
- A custom build for
ggml
,bert.cpp
and the JNI bindings is needed until this issue gets resolved. - Not all converted GGML models may load successfully. Please open an issue if a specific model crashes.