CoolFace
Modelpublic

dogtooth/open-lm-3b-202301-stage1-sft

sourceHugging Faceapple-asclupdated 5mo agoView on Hugging Face
0likes19downloads
Model Card

Open LM 3B — Stage1 SFT (Knowledge Cutoff January 2023)

Stage1 supervised fine-tune of the Apple Open LM 3B oracle model with knowledge cutoff January 2023, from the TiC-LM (Time-Continual Language Modeling) / Chrononauts project.

Fine-tuned with LLaMA-Factory (finetuning_type: full, DeepSpeed ZeRO-2, 3 epochs).

Model Details

PropertyValue
Base modeldogtooth/open-lm-3b-202301
ArchitectureLLaMA-style with QK norm (OpenLMForCausalLM, custom code)
Parameters~2.8B
Knowledge cutoffJanuary 2023
Vocab size50,432
Context length2,048
SFT frameworkLLaMA-Factory (full FT, DeepSpeed ZeRO-2)
Chat template`Human: {prompt}<endoftext>\nAssistant: {response}<endoftext>`

Usage

python
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch

model = AutoModelForCausalLM.from_pretrained(
    "dogtooth/open-lm-3b-202301-stage1-sft",
    dtype=torch.bfloat16,
    device_map="auto",
    trust_remote_code=True,
)
tokenizer = AutoTokenizer.from_pretrained(
    "dogtooth/open-lm-3b-202301-stage1-sft", trust_remote_code=True
)

prompt = "Human: What is the capital of France?<|endoftext|>\nAssistant:"
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
out = model.generate(**inputs, max_new_tokens=200, do_sample=False)
print(tokenizer.decode(out[0][inputs.input_ids.shape[1]:], skip_special_tokens=False))

Repository Contents

  • —Final model weights at the repo root (model-*.safetensors)
  • —Intermediate checkpoints in checkpoint-1000/, checkpoint-2000/, checkpoint-2346/ (DeepSpeed optimizer shards global_step*/ were omitted to keep upload size manageable; only HF-format weights + tokenizer + config are included per checkpoint)
  • —trainer_state.json, trainer_log.jsonl, all_results.json, train_results.json

Citation

bibtex
@article{jain2024ticlm,
  title={Time-Continual Learning from a Streaming Language Model},
  author={Jain, Ameya and Ramesh, Aakanksha and Li, Tianjian and others},
  journal={arXiv preprint arXiv:2410.14660},
  year={2024}
}