Downloads · 30 days
0
kaya-go/kaya
kaya is a other model from kaya-go. Use it for the other task on the model card, and read the license before you ship it in a product. It is set up for onnxruntime. The card lists the license as mit.
This repository contains ONNX-converted versions of KataGo neural network models for the game of Go (Baduk/Weiqi).
Downloads · 30 days
0
Access
Public
Updated Dec 27, 2025
Repo size
1.5 GB
Likes
3
Public
Click a slice to open those files.
.onnx1 GB · 100%
From the Hugging Face model README
This repository contains ONNX-converted versions of KataGo neural network models for the game of Go (Baduk/Weiqi).
These models power the Kaya app, a web-based Go application with AI-powered game analysis and move suggestions.
These models are converted from the official KataGo PyTorch checkpoints to ONNX format for use in web-based and cross-platform applications.
| Model | Description |
|---|---|
kata1-b28c512nbt-adam-s11165M-d5387M | 28 blocks, 512 channels |
kata1-b28c512nbt-s12043015936-d5616446734 | 28 blocks, 512 channels |
Each model is available in three versions:
.fp32.onnx - Full precision (FP32) - Recommended for browser/WASM.fp16.onnx - Half precision (FP16) - For native apps (CoreML, CUDA, WebGPU).uint8.onnx - Quantized (UINT8) - ~4x smaller, for memory-constrained devicesimport onnxruntime as ort
import numpy as np
# Load the model (use .fp32.onnx for browser/WASM, .fp16.onnx for native apps)
session = ort.InferenceSession("kata1-b28c512nbt-adam-s11165M-d5387M.fp32.onnx")
# Prepare inputs (batch_size, channels, height, width)
bin_input = np.random.randn(1, 22, 19, 19).astype(np.float32)
global_input = np.random.randn(1, 19).astype(np.float32)
# Run inference
outputs = session.run(None, {
"bin_input": bin_input,
"global_input": global_input
})
policy, value, miscvalue, moremiscvalue, ownership, scoring, futurepos, seki, scorebelief = outputs
import * as ort from "onnxruntime-web";
// Use .fp32.onnx for WASM backend, or .uint8.onnx for smaller download size
const session = await ort.InferenceSession.create(
"kata1-b28c512nbt-adam-s11165M-d5387M.fp32.onnx"
);
const binInput = new ort.Tensor(
"float32",
new Float32Array(1 * 22 * 19 * 19),
[1, 22, 19, 19]
);
const globalInput = new ort.Tensor(
"float32",
new Float32Array(1 * 19),
[1, 19]
);
const results = await session.run({
bin_input: binInput,
global_input: globalInput,
});
| Name | Shape | Description |
|---|---|---|
bin_input | [batch, 22, height, width] | Board features (binary planes) |
global_input | [batch, 19] | Global features |
| Name | Shape | Description |
|---|---|---|
policy | [batch, 2, moves] | Move policy logits |
value | [batch, 3] | Win/loss/draw predictions |
miscvalue | [batch, ...] | Miscellaneous value outputs |
moremiscvalue | [batch, ...] | Additional value outputs |
ownership | [batch, 1, height, width] | Territory ownership prediction |
scoring | [batch, 1, height, width] | Scoring prediction |
futurepos | [batch, 2, height, width] | Future position prediction |
seki | [batch, 4, height, width] | Seki detection |
scorebelief | [batch, ...] | Score belief distribution |
These models are derived from the KataGo project by David J. Wu (lightvector).
The original KataGo neural network weights are released under the MIT License.
This ONNX conversion and the associated tooling are also released under the MIT License.
If you use these models, please cite the original KataGo paper:
@article{wu2019accelerating,
title={Accelerating Self-Play Learning in Go},
author={Wu, David J.},
journal={arXiv preprint arXiv:1902.10565},
year={2019}
}
Special thanks to: