lucidrains/x-transformers
A full-featured PyTorch transformer library implementing encoder-decoder, GPT-style decoder-only, and BERT-style encoder-only architectures.

This repository provides a complete transformer implementation in PyTorch with support for encoder-only, decoder-only, and encoder-decoder architectures. It includes experimental features from various research papers, enabling users to build BERT-style, GPT-style, and full encoder-decoder models with configurable dimensions, depth, attention heads, and sequence lengths. The library is installable via pip and designed for researchers and practitioners implementing transformer-based models.