vortex_torch.indexerΒΆ
Indexer-side operator API.
This module collects the core ops used on the indexer path of vFlow pipelines. These operators are typically applied to query tensors or intermediate scoring tensors to construct sparse routing decisions (e.g., top-k page selection, attention scoring, pagewise normalization).
Included components:
Matrix operations:
GeMM,GeMVfor page-tiled GEMM/GEMV used in similarity scoring.Output routing:
topKfor selecting sparse page indices based on per-token scores.Reductions:
Max,Mean,Min,L2Norm,Sumfor aggregating scores along query or key dimensions.Scans / normalization:
Softmax,Normalizefor in-place probability and magnitude normalization.Data layout transforms:
Transposefor switching between [B, N, D] and [B, D, N] style views.Binary/unary elementwise ops:
Maximum,Minimum,Multiply,Add,Relu,Sigmoid,Silu,Add_Mul,Abs.Utilities:
utils_sglangfor SGLang-related helpers.Runtime context:
Context,get_ctx()for accessing per-step dynamic state (page offsets, head count, max token budget, etc.).
These operators constitute the standard toolkit for building sparse attention indexers in vFlow-compatible systems.
Modules