diff --git a/README.md b/README.md index 98def50..71a6aac 100644 --- a/README.md +++ b/README.md @@ -40,6 +40,23 @@ Run the following Go CLI command in your project directory: go get -u github.com/anush008/fastembed-go ``` +## ℹī¸Ž Notice: + +The Onnx runtime path is automatically loaded on most environments. However, if you encounter +```sh +panic: Platform-specific initialization failed: Error loading ONNX shared library +``` +Set the `ONNX_PATH` env to your Onnx installation. +For eg, on MacOS: +```sh +export ONNX_PATH="/path/to/onnx/lib/libonnxruntime.dylib" +``` +On Linux: +```sh +export ONNX_PATH="/path/to/onnx/lib/libonnxruntime.so" +``` +You can find the Onnx runtime releases [here](https://github.com/microsoft/onnxruntime/releases). + ## 📖 Usage ```go @@ -107,23 +124,6 @@ if err != nil { } ``` -## ℹī¸Ž Notice: - -The Onnx runtime path is automatically loaded on most environments. However, if you encounter -```sh -panic: Platform-specific initialization failed: Error loading ONNX shared library -``` -Set the `ONNX_PATH` env to your Onnx installation. -For eg, on MacOS: -```sh -export ONNX_PATH="/path/to/onnx/lib/libonnxruntime.dylib" -``` -On Linux: -```sh -export ONNX_PATH="/path/to/onnx/lib/libonnxruntime.so" -``` -You can find the Onnx runtime releases [here](https://github.com/microsoft/onnxruntime/releases). - ## 🚒 Under the hood ### Why fast?