OpenESM
Collection
6 items • Updated • 1
OpenESM d12 model trained on ClimbMix. This repository contains the pretraining checkpoint without optimizer state conversion.
model.ckpt: Lightning checkpoint.modeling_esm.py: standalone model and checkpoint loader.tokenizer/tokenizer.pkl: serialized ESM tokenizer.tokenizer/token_bytes.pt: token byte table for BPB evaluation.The 160M label describes the model parameter count. Training
token counts are intentionally omitted from the repository name and file names.
import torch
from modeling_esm import load_checkpoint
model, tokenizer, hparams, device = load_checkpoint(
"model.ckpt",
tokenizer_path="tokenizer",
)
tokens = tokenizer.encode("Hello world", append=tokenizer.get_bos_token_id())
input_ids = torch.tensor([tokens], device=device)
logits = model(input_ids)
print(logits.shape)
The code and checkpoint format are maintained in the OpenESM repository.