Skip to main content

Go API

Package clikart is the Go binding for the ClikaRT on-device inference runtime, over the runtime's versioned C ABI.

Load opens libClikaRT.so at run time (dlopen through cgo) and performs the two-arm handshake: a runtime that cannot serve the requested abi version, or whose api table carries a layout fingerprint other than the one this package compiled against and was generated from, is refused with a readable error before the first call. Runtime failures surface as *Error carrying the machine-readable CodeName (which survives release obfuscation; branch on it, never on the message text).

This package is the only one that touches the shared library; dependent packages (modelverse) reach the runtime through it and ship no copy of libClikaRT.so.

Constants

AbiVersion

const AbiVersion uint32 = C.CLIKA_RT_ABI_VERSION

AbiVersion is the C ABI version this package is written against: the header's CLIKA_RT_ABI_VERSION macro, read through cgo, never a literal typed here (a hand copy silently drifts from the table it names).

LayoutFingerprint

const LayoutFingerprint = "62095add0a8b74e8d06165d714e0aebcd785cb7f6a1fab1e13c325a17301dac3"

LayoutFingerprint is the api-table layout fingerprint of the C header this generated surface was emitted from. Load compares it against the fingerprint the runtime's table carries before the first call; a mismatch means these bindings must be regenerated against that runtime's header.

NameKind
Activationtype
Apitype
AttentionOptionstype
AttentionOverCacheOptionstype
AttentionVarlenOptionstype
AudioInfotype
CaptureScopetype
CompiledFunctiontype
ComputeApitype
ConvTranspose1dOptionstype
ConvTranspose2dOptionstype
ConvTranspose3dOptionstype
DataTypetype
DeformConvOptionstype
Devicetype
DimOrIntKindtype
EagerScopetype
Elementtype
EncodeOptionstype
Encodedtype
Errortype
GeluModetype
GenerateRotaryCacheOptionstype
GgufCheckpointtype
GridSampleModetype
GridSamplePaddingModetype
GroupQueryAttentionOptionstype
GroupQueryAttentionVarlenOptionstype
HashTensorModetype
ImageInfotype
IndexBoundtype
IndexBoundKindtype
IndexEntrytype
IndexEntryKindtype
IndexSlicetype
InterpModetype
MemoryStatstype
MeshgridIndexingtype
ModModetype
ModelGraphtype
MoeOptionstype
MoeRoutingtype
MropeRotaryEmbeddingOptionstype
MropeRotaryEmbeddingQkVarlenOptionstype
MropeRotaryEmbeddingVarlenOptionstype
OnnxAttrKindtype
OnnxModeltype
PadModetype
PixelShuffleModetype
ProfileSessiontype
QTensortype
QcomputeModetype
QconvInplaceToDenseOptionstype
QconvInplaceToDenseOutScaleOptionstype
QconvInplaceToQuantizedOptionstype
QconvToDenseOptionstype
QconvTranspose1dToDenseOptionstype
QconvTranspose1dWoqOptionstype
QconvTranspose2dToDenseOptionstype
QconvTranspose2dWoqOptionstype
QconvTranspose3dToDenseOptionstype
QconvTranspose3dWoqOptionstype
QconvTransposeInplaceToDenseOptionstype
QconvTransposeInplaceToDenseOutScaleOptionstype
QconvTransposeInplaceToQuantizedOptionstype
QconvTransposeToDenseOptionstype
QconvTransposeWoqOptionstype
QconvWoqOptionstype
QdeformConvToDenseOptionstype
QdeformConvWoqOptionstype
QmatmulInplaceToDenseOutScaleOptionstype
QmoeToDenseOptionstype
QmoeWoqOptionstype
QuantileInterptype
QuantizationConfigtype
QuantizedCheckpointMethodtype
Reductiontype
RopeScalingtype
RotaryEmbeddingOptionstype
RotaryEmbeddingQkOptionstype
RotaryEmbeddingQkVarlenOptionstype
RotaryEmbeddingVarlenOptionstype
RotaryModetype
RoundingModetype
Scalartype
ScalarKindtype
ScalarOrTensortype
ScalarOrTensorKindtype
ScatterReduceModetype
Statetype
Statustype
StftOptionstype
Streamtype
StreamOrDevicetype
StreamOrDeviceKindtype
StreamingDecodertype
StringListtype
SwigluFusiontype
SynchronousStreamScopetype
Tensortype
TensorListtype
TensorStatustype
TensorsContainertype
TokenListtype
Tokenizertype
TraceSessiontype
TracingScopetype
ZerosConventiontype