Compatibility
Minecraft: Java Edition
26.1.2
Platforms
Links
Tags
Creators
Details
Licensed Apache-2.0
Published 2 days ago
onnx-spigot
A Spigot plugin that runs local ONNX LLM models, provides in-game chat via a trigger, and exposes a Bukkit service API for dependent plugins.
Features
- Local ONNX inference from
plugins/onnx-spigot/models/ - In-game chat trigger (default:
@llm <message>) - Single permission gate:
onnxspigot.llm.use - Public Bukkit API registered through
ServicesManager
Model Folder
Place your model files in:
plugins/onnx-spigot/models/<model-name>/
Required files:
*.onnx(for examplemodel.onnx)- Tokenizer data:
tokenizer.json, orvocab.json
Optional files:
merges.txt(used for better BPE merges whenvocab.jsonis used)tokenizer_config.json(special token IDs)config.json(model metadata)
Set <model-name> in plugins/onnx-spigot/config.yml under llm.model.
Model Support
- Supported: Qwen 2 ONNX models
- Supported: Qwen 3 ONNX models
- Not supported: Gemma models
Qwen3-0.6B-ONNX (Confirmed Working)
-
Download the model from: https://huggingface.co/onnx-community/Qwen3-0.6B-ONNX
-
Create a folder at
plugins/onnx-spigot/models/Qwen3-0.6B-ONNX/. -
Copy the model files into that folder:
*.onnx(for examplemodel.onnx)tokenizer.jsonorvocab.json- Optional:
merges.txt,tokenizer_config.json,config.json
-
Set this in
plugins/onnx-spigot/config.yml:llm: model: "Qwen3-0.6B-ONNX"
API Usage (from another plugin)
import org.bukkit.Bukkit;
import org.bukkit.plugin.RegisteredServiceProvider;
import tr.alperendemir.onnxSpigot.api.OnnxChatApi;
RegisteredServiceProvider<OnnxChatApi> registration =
Bukkit.getServicesManager().getRegistration(OnnxChatApi.class);
if (registration != null) {
OnnxChatApi api = registration.getProvider();
api.generate("Explain redstone clocks in one paragraph.")
.thenAccept(response -> Bukkit.getLogger().info(response));
}
Build
./gradlew.bat clean build


