Back to Projects
Theo

Theo

The first open-source biblical language model family trained from scratch in Brazilian Portuguese

Open Source Brazilian AI Milestone

Project Overview

Theo is believed to be the first family of Transformer language models trained entirely from scratch on biblical content in Brazilian Portuguese — built by a solo developer, fully open source, with no pretrained weights from any external model.

Almost every LLM that can discuss the Bible in Portuguese is either a translation of an English model, a fine-tune on top of a large multilingual base (LLaMA, Mistral, etc.), or proprietary. Theo is none of those things. It is a ground-up experiment: custom tokenizer, custom architecture, custom training pipeline — shaped entirely by the Word, from the very first weight initialization.

The project spans four model sizes — 7.4M, 27.3M, 69.3M, and 76.8M real parameters — each trained in two phases: Continual Pre-Training (CPT) on a corpus of 457 million tokens of biblical and theological content, then Supervised Fine-Tuning (SFT) on nearly 19,000 theological conversations. The result, together with the flagship Theo-500M, is 10 open-source checkpoints, all available on HuggingFace under Apache 2.0.

The 78M Chat model — the largest completed — was rated B / 7.5 in qualitative evaluation. It maintains a consistent personality (warm, curious, evangelical, Brazilian), engages naturally with questions of faith, cites biblical context, and asks questions back. For a model trained entirely from scratch at this scale, that's remarkable.

Theo also proves something broader: you don't need a team, a research lab, or millions of dollars to train a real language model. You need curiosity, a cloud GPU, and time.

Honestly — I used to think training a model from scratch was simply impossible for someone like me. Something reserved for research labs, massive teams, and budgets I'd never have. Theo proved me completely wrong, and that changes everything. This project didn't just work — it genuinely excited me about where this can go. I want to go much deeper: bigger architectures, richer corpora, models that actually push the boundary of what a small specialized LLM can do. This is only the beginning.

By the Numbers

What went into building Theo

457M
tokens in the biblical training corpus
265k
theological documents curated
19k
theological conversations for fine-tuning
16k
token BPE vocabulary, trained from scratch
4
model sizes (7.4M → 76.8M parameters)
8
open-source checkpoints on HuggingFace
12+
Christian sites scraped — the largest single source was Com Ele, my own platform with 200k+ rich biblical pieces
< $100
total GPU cost for all 4 models

All Models

Five sizes, two variants each — Base (CPT) for research, Chat (SFT) for conversations

Theo-10M 7.4M real parameters
Layers: 4
d_model: 256
Heads: 4
Context: 512 tokens
FFN: 1,024
Vocab: 16k BPE
Theo-25M 27.3M real parameters
Layers: 6
d_model: 512
Heads: 8
Context: 512 tokens
FFN: 2,048
Vocab: 16k BPE
Theo-50M 69.3M real parameters
Layers: 8
d_model: 768
Heads: 8
Context: 512 tokens
FFN: 3,072
Vocab: 16k BPE
Theo-78M 76.8M real parameters
Layers: 9
d_model: 768
Heads: 8
Context: 1,024 tokens
FFN: 3,072
Rating: B / 7.5
Theo-500M 493.8M real parameters
Layers: 24
d_model: 1,280
Heads: 16
Context: 1,024 tokens
FFN: 5,120
Corpus: 1B tokens
RELEASED

The Next Generation Is Here

What started as a solo experiment became something much bigger. Theo-500M is live — the most powerful model in the Theo family, and it's not even close to what came before.

Theo-500M ~493.8M real parameters
Released Flagship
1B
tokens in the corpus
43k
fine-tuning examples
493M
real parameters
6×
larger than Theo-78M
Layers24
Attention Heads16
d_model1,280
d_ff (FFN)5,120
Context Length1,024 tokens
Gradient CheckpointingEnabled

This isn't an incremental update. Theo-500M is a completely different class of model — deeper, wider, trained on twice the data, with more than double the fine-tuning examples of the entire previous family combined. I thought I had pushed my limits with the 78M. I was wrong.

Training Pipeline

From raw text to a model that understands faith — built entirely from scratch

1

Corpus Construction

12+ Christian websites were scraped and processed alongside multiple Portuguese Bible translations to build a corpus of 265,000 documents — totaling 457 million tokens. Sources include theological commentaries, sermons, doctrinal articles, devotionals, and apologetics, all in Brazilian Portuguese.

2

BPE Tokenizer Training

A custom Byte-Pair Encoding tokenizer with 16,000 tokens was trained from scratch on the biblical corpus — not adapted from an existing tokenizer. It achieves a density of 1.26 tokens per word in Brazilian Portuguese, optimized for the theological vocabulary of the domain.

3

Continual Pre-Training (CPT)

Four decoder-only Transformer architectures — 10M, 25M, 50M, and 78M — were trained from random initialization on the full corpus for 2 epochs each. No weights from any external model were used at any point. Training ran on an NVIDIA L40S 48GB via RunPod.

4

Supervised Fine-Tuning (SFT)

Each base model was fine-tuned on ~19,000 theological conversation pairs generated with a Qwen 35B teacher model — question/answer dialogues covering faith, Scripture, Christian life, and the personality of Theo. This phase transforms a text-completion model into a conversational assistant.

What Makes Theo Different

Not a fine-tune. Not a translation. Something built from nothing.

Trained From Scratch

No pretrained weights. No transfer learning. Theo's architecture, tokenizer, and training pipeline were built independently — which means its representations are shaped entirely by biblical content, not by web-scale English data that had to be unlearned.

Exclusively Biblical

Every token Theo was trained on comes from the Bible, biblical commentary, theology, or Christian writing in Portuguese. The result is a model with deep domain specialization — it understands the language of Scripture at a structural level, not just superficially.

Natively Brazilian

The tokenizer, corpus, and fine-tuning data are all in Brazilian Portuguese. Theo wasn't translated or adapted — it thinks in PT-BR from the ground up. In 2026, there is no other publicly available LLM like it in this language and domain.

Built by One Person

Theo was designed, trained, evaluated, and released by a single developer — no team, no research institution, no budget beyond cloud GPU hours. It demonstrates that the barrier to entry for training real language models is lower than most people think.

Scaling Laws in Practice

The four model sizes exist to demonstrate scaling in action. Each generation shows measurable improvement in coherence, grammar, and personality. The progression from 7.4M to 76.8M parameters is a live experiment in how language emerges with scale.

Fully Open Source

All 10 model checkpoints, the tokenizer, the training code, and the inference scripts are publicly available on HuggingFace under the Apache 2.0 license. Anyone can download, fine-tune, or build on top of Theo — no restrictions, no fees.

Technology Stack

Built with open tools, trained on open data

Python

PyTorch

NVIDIA L40S

RunPod

HuggingFace

Mac M4 (dev)

Explore Theo

All 10 models are open source and ready to run. Clone, fine-tune, or build on top.