Instructions to use veyra-ai/veyra3-5m-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use veyra-ai/veyra3-5m-base with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="veyra-ai/veyra3-5m-base")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("veyra-ai/veyra3-5m-base") model = AutoModelForCausalLM.from_pretrained("veyra-ai/veyra3-5m-base") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use veyra-ai/veyra3-5m-base with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "veyra-ai/veyra3-5m-base" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "veyra-ai/veyra3-5m-base", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/veyra-ai/veyra3-5m-base
- SGLang
How to use veyra-ai/veyra3-5m-base with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "veyra-ai/veyra3-5m-base" \ --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": "veyra-ai/veyra3-5m-base", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
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 "veyra-ai/veyra3-5m-base" \ --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": "veyra-ai/veyra3-5m-base", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use veyra-ai/veyra3-5m-base with Docker Model Runner:
docker model run hf.co/veyra-ai/veyra3-5m-base
Veyra3 5M Base
Veyra3 5M Base is a tiny Gemma4-style causal language model trained as an architecture and pipeline smoke test.
This repository is a native Hugging Face Transformers compatibility export using gemma4_text / Gemma4ForCausalLM.
Important fidelity note
The faithful checkpoint artifact is the ONNX export in veyra-ai/veyra3-5m-base-onnx-int8. This Transformers repo uses HF's native Gemma4 implementation, which has stricter architecture expectations than the training smoke-test model. The exporter copied every compatible trained tensor into native Gemma4ForCausalLM and kept HF-only tensors initialized by Transformers. See conversion_report.json for details.
Model metadata
- Repo:
veyra-ai/veyra3-5m-base - Native architecture:
Gemma4ForCausalLM - Native model type:
gemma4_text - Faithful local parameter count before native conversion:
4,377,856 - Checkpoint tokens seen:
350486528 - Best validation loss from checkpoint:
4.382341027259827 - Context length:
4096 - Sliding window:
512 - Vocab size:
4096 - HF layer types:
['sliding_attention', 'sliding_attention', 'sliding_attention', 'full_attention', 'sliding_attention', 'full_attention']
Conversion summary
- copied_exact: 54
- copied_partial_overlap: 1
- hf_only_keep_native_init: 30
Load
from transformers import AutoTokenizer, AutoModelForCausalLM
tok = AutoTokenizer.from_pretrained('veyra-ai/veyra3-5m-base', trust_remote_code=False)
model = AutoModelForCausalLM.from_pretrained('veyra-ai/veyra3-5m-base', trust_remote_code=False)
- Downloads last month
- 752