Out of Context Reasoning
Collection
4 items β’ Updated
How to use eac123/olmo3-7b-exp1b-lora128-e5 with PEFT:
from peft import PeftModel
from transformers import AutoModelForCausalLM
base_model = AutoModelForCausalLM.from_pretrained("allenai/Olmo-3-1025-7B")
model = PeftModel.from_pretrained(base_model, "eac123/olmo3-7b-exp1b-lora128-e5")How to use eac123/olmo3-7b-exp1b-lora128-e5 with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="eac123/olmo3-7b-exp1b-lora128-e5") # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("eac123/olmo3-7b-exp1b-lora128-e5")
model = AutoModelForCausalLM.from_pretrained("eac123/olmo3-7b-exp1b-lora128-e5")How to use eac123/olmo3-7b-exp1b-lora128-e5 with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "eac123/olmo3-7b-exp1b-lora128-e5"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "eac123/olmo3-7b-exp1b-lora128-e5",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker model run hf.co/eac123/olmo3-7b-exp1b-lora128-e5
How to use eac123/olmo3-7b-exp1b-lora128-e5 with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "eac123/olmo3-7b-exp1b-lora128-e5" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "eac123/olmo3-7b-exp1b-lora128-e5",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker run --gpus all \
--shm-size 32g \
-p 30000:30000 \
-v ~/.cache/huggingface:/root/.cache/huggingface \
--env "HF_TOKEN=<secret>" \
--ipc=host \
lmsysorg/sglang:latest \
python3 -m sglang.launch_server \
--model-path "eac123/olmo3-7b-exp1b-lora128-e5" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "eac123/olmo3-7b-exp1b-lora128-e5",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'How to use eac123/olmo3-7b-exp1b-lora128-e5 with Docker Model Runner:
docker model run hf.co/eac123/olmo3-7b-exp1b-lora128-e5
axolotl version: 0.15.0
# ββ Continued Pretraining: 7B on 8ΓA40 (48GB) ββ
base_model: allenai/Olmo-3-1025-7B
tokenizer_type: AutoTokenizer
# plugins:
# - axolotl.integrations.cut_cross_entropy.CutCrossEntropyPlugin
# ββ Data ββ
datasets:
- path: data/1b/all.jsonl
type: completion
field: completion
dataset_prepared_path: last_run_prepared
# ββ Sequence / packing ββ
sequence_len: 2048
sample_packing: true
pad_to_sequence_len: true
# NOTE: do NOT enable group_by_length with sample_packing
# ββ Batch sizing ββ
# Per-GPU: 4 seqs Γ 2048 tok = 8k tokens/step/GPU
# Global: 4 Γ 4 accum Γ 8 GPUs = 128 effective seqs/step
# micro_batch_size: 4
# gradient_accumulation_steps: 4
micro_batch_size: 4
gradient_accumulation_steps: 1
# ββ Training ββ
train_on_inputs: true
optimizer: adamw_8bit
lr_scheduler: cosine
learning_rate: 3e-4
#warmup_steps: 20
#max_steps: 100
warmup_ratio: 0.03
num_epochs: 50 # apparently we can use this instead of max_steps?
weight_decay: 0.01
# ββ Precision / memory ββ
bf16: auto
tf32: true
flash_attention: true
gradient_checkpointing: true
# ββ DeepSpeed ZeRO Stage 2 ββ
deepspeed: train/axolotl-cpt/ds_stage2.json
# ββ Logging ββ
logging_steps: 1
save_strategy: steps
save_steps: 20
save_total_limit: 40
use_wandb: true
wandb_name: "olmo3-7b-exp1b-lora"
wandb_project: "out-of-context-chatbots"
# -- qlora --
load_in_8bit: false
load_in_4bit: false
adapter: lora
lora_r: 128
use_rslora: true
lora_alpha: 32
#lora_dropout: 0.05
lora_target_linear: true
lora_target_modules:
- gate_proj
- down_proj
- up_proj
- q_proj
- v_proj
- k_proj
- o_proj
This model is a fine-tuned version of allenai/Olmo-3-1025-7B on the data/1b/all.jsonl dataset.
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
Base model
allenai/Olmo-3-1025-7B