Skip to main content

Module classic_bert

Module classic_bert 

Source
Expand description

ClassicBert architecture (BGE-small-en-v1.5).

12-layer BERT with learned position embeddings, GELU activation, fused QKV projections, and CLS pooling. This is the original BERT architecture used by BGE-small.

Weight structures are generic over the tensor type T, which is Driver::Tensor when wired to a backend. The ModelArch implementation composes Driver primitives into the full forward pass.

Structsยง

ClassicBertArch
ClassicBert architecture: BGE-small-en-v1.5.
ClassicBertLayerWeights
Weights for one ClassicBert encoder layer.
ClassicBertWeights
Full ClassicBert model weights, generic over tensor type.