Package-level declarations
Types
Basic math operations for graph-based execution
Convolutional operations
Single source of truth for convolution output-shape arithmetic.
A generic operation that can be used when a specialized operation class is not available.
Input tensor operation for graph representation
Linear algebra operations
Pooling operations
Optimized matrix multiplication for quantized weight formats (Q8_0, Q4_K).
Activation functions
Shape operations
Scaled dot-product attention operation for tape recording. Output shape = query shape: batch, nHeads, seqLen, headDim
Additional shape operations
Optimized matrix multiplication for BitNet-style ternary weights.
Interpolation modes for 2D upsampling.
Result of graph validation
Properties
Metadata key used to carry a TensorEncoding on a TensorSpec.
Physical storage encoding carried on this spec, or null if the producer did not populate it.
Functions
Infer a TensorEncoding from a concrete TensorData instance, or return null when the layout is dense / unknown. Single source of truth for the data-subclass → encoding mapping so trace builders and loaders agree.
Extension function for Q4_K matmul.
Extension function for Q8_0 matmul.
Extension function for convenient ternary matmul. Use this when you know the weight is ternary-quantized.
Return a copy of this spec with encoding stored in its metadata map. Passing null removes the entry; passing a non-null value adds or replaces it, leaving all other metadata untouched.