A GPT-2 style character-level transformer trained on classical philosophy texts, implemented in Julia with Flux.jl. The first model in the Julia SLM lineage — a minimal proof-of-concept that established the training and serving infrastructure.
Model Family Context
MicroJulia is the starting point of an architectural progression:
Each character maps directly to a token ID. No subword segmentation — the model must learn word boundaries, morphology, and syntax from individual characters.
Trade-offs:
Simpler tokenizer implementation
No OOV (out-of-vocabulary) issues
Model must spend capacity on character-level patterns
Less efficient than BPE for the same context window
Model Details
Parameter
Value
Architecture
GPT-2 style (pre-norm Transformer)
Tokenizer
Character-level (~28 characters)
Position encoding
Learned position embeddings
Normalization
LayerNorm
Activation
GELU
Output projection
Separate Dense (not weight-tied)
Framework
Julia + Flux.jl
Exact dimensions (vocab_size, n_embd, n_layer, n_head, block_size) are stored in the checkpoint hyperparams dict and loaded dynamically.
Training
Value
Dataset
Classical philosophy texts
Tokenizer
Character-level mapping
Framework
Julia + Flux.jl
Hardware
Google Colab / NVIDIA GPU
Precision
Float32
Implementation Notes
Causal Masking
Uses a pre-computed additive upper-triangular mask (global constant):