Model Architecture
The model incorporates modern architectural improvements over standard transformers:
- RoPE (Rotary Position Embeddings): Encodes relative spatial/temporal positions effectively across sequences.
- GQA (Grouped-Query Attention): Shares key-value heads across multiple query heads to reduce memory bandwidth overhead.
- SwiGLU: Replaces traditional ReLU/GELU activations in the feed-forward networks for superior language modeling capabilities.
- KV Caching: Pre-allocated buffer-based key-value caching enables fast, efficient token-by-token text generation.
Data Loading & Preparation
The pipeline supports high-throughput downloading and sharding for massive pretraining datasets like Hugging Face FineWeb, alongside instruction-tuning data like Alpaca.
This model has been pushed to the Hub using the PytorchModelHubMixin integration:
- Code: Source Code