Instructions to use VertexAGI/prism-caption-2-micro with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use VertexAGI/prism-caption-2-micro with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="VertexAGI/prism-caption-2-micro") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("VertexAGI/prism-caption-2-micro") model = AutoModelForCausalLM.from_pretrained("VertexAGI/prism-caption-2-micro", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - MLX
How to use VertexAGI/prism-caption-2-micro with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("VertexAGI/prism-caption-2-micro") prompt = "Write a story about Einstein" messages = [{"role": "user", "content": prompt}] prompt = tokenizer.apply_chat_template( messages, add_generation_prompt=True ) text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use VertexAGI/prism-caption-2-micro with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf VertexAGI/prism-caption-2-micro:Q4_K_M # Run inference directly in the terminal: llama cli -hf VertexAGI/prism-caption-2-micro:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf VertexAGI/prism-caption-2-micro:Q4_K_M # Run inference directly in the terminal: llama cli -hf VertexAGI/prism-caption-2-micro:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf VertexAGI/prism-caption-2-micro:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf VertexAGI/prism-caption-2-micro:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf VertexAGI/prism-caption-2-micro:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf VertexAGI/prism-caption-2-micro:Q4_K_M
Use Docker
docker model run hf.co/VertexAGI/prism-caption-2-micro:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use VertexAGI/prism-caption-2-micro with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "VertexAGI/prism-caption-2-micro" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "VertexAGI/prism-caption-2-micro", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/VertexAGI/prism-caption-2-micro:Q4_K_M
- SGLang
How to use VertexAGI/prism-caption-2-micro 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 "VertexAGI/prism-caption-2-micro" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "VertexAGI/prism-caption-2-micro", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "VertexAGI/prism-caption-2-micro" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "VertexAGI/prism-caption-2-micro", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use VertexAGI/prism-caption-2-micro with Ollama:
ollama run hf.co/VertexAGI/prism-caption-2-micro:Q4_K_M
- Unsloth Desktop
- MLX LM
How to use VertexAGI/prism-caption-2-micro with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Interactive chat REPL mlx_lm.chat --model "VertexAGI/prism-caption-2-micro"
Run an OpenAI-compatible server
# Install MLX LM uv tool install mlx-lm # Start the server mlx_lm.server --model "VertexAGI/prism-caption-2-micro" # Calling the OpenAI-compatible server with curl curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "VertexAGI/prism-caption-2-micro", "messages": [ {"role": "user", "content": "Hello"} ] }' - Docker Model Runner
How to use VertexAGI/prism-caption-2-micro with Docker Model Runner:
docker model run hf.co/VertexAGI/prism-caption-2-micro:Q4_K_M
- Lemonade
How to use VertexAGI/prism-caption-2-micro with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull VertexAGI/prism-caption-2-micro:Q4_K_M
Run and chat with the model
lemonade run user.prism-caption-2-micro-Q4_K_M
List all available models
lemonade list
- Atomic Chat
Prism Caption 2 Micro
Prism Caption 2 Micro is a chat-titling model — given the first user message of a conversation, it generates a short, specific, correctly-formatted title (4-6 words, title case, naming the actual subject). Fine-tuned via LoRA on LiquidAI's LFM2-700M, switching base models from the Qwen3-0.6B lineage used in 1 Mini/1.5 Micro.
Part of the Prism family of small, single-purpose models.
Why LFM2-700M
LFM2-700M was chosen over the previous Qwen3-0.6B base on Liquid AI's own published evaluations:
| Model | Params | MMLU | IFEval |
|---|---|---|---|
| Qwen3-0.6B | ~600M | 44.93 | 64.24 |
| LFM2-700M | 742M | 49.9 | 72.23 |
LFM2-700M beats Qwen3-0.6B on both general knowledge/reasoning and instruction-following, and Liquid AI's architecture is purpose-built for edge/local inference — reported at roughly 2x Qwen3's CPU decode/prefill throughput at a comparable parameter count. For a small, single-purpose model meant to run cheaply and locally, that combination of higher instruction-following accuracy and faster inference made it a clear upgrade over the previous base.
Model Details
| Base model | LiquidAI/LFM2-700M |
| Fine-tuning base checkpoint | mlx-community/LFM2-700M-4bit |
| Architecture | LFM2 -- hybrid short-convolution / attention (16 blocks total, 6 full-attention, 10 short-conv) |
| Fine-tuning method | LoRA (rank 8, scale 20.0, 16 layers) |
| Fine-tuning framework | MLX / mlx-lm, on Apple Silicon |
| License | LFM Open License v1.0 |
Training Data
Fine-tuned on 10,000 examples (9,000 train / 1,000 validation) of synthetic chat-titling pairs, distilled across a mix of four teacher models as their individual free-tier availability shifted over the course of generation:
| Teacher | Examples | Share |
|---|---|---|
openai/gpt-oss-20b (NIM) |
5,339 | 53.4% |
nvidia/nemotron-3.5-lightning-30b-a3b (NIM) |
3,201 | 32.0% |
poolside/laguna-s-2.1:free (OpenRouter) |
1,027 | 10.3% |
openai/gpt-oss-120b (NIM) |
433 | 4.3% |
1,207 unique topics, 6,601 unique generated titles. The teacher-cycling approach (alternating every ~2 minutes between models) was adopted mid-run after single-teacher generation kept stalling on free-tier rate limits -- spreading load across several capable teachers kept throughput high without any provider getting hammered continuously.
Training Procedure
- Method: LoRA fine-tuning (rank 8, scale 20.0, dropout 0.0, 16 layers -- full model depth)
- Optimizer: Adam, learning rate 1e-5
- Sequence length: 256 tokens
- Training steps: 6,000 iterations, validation every 200 steps
- Final validation loss: 0.196 (down from 8.054 at initialization) -- the final checkpoint had the best validation loss of the run, no earlier checkpoint needed
- Throughput: ~1.22 it/sec, ~537 tokens/sec, peak memory 1.6GB -- fast and light even on a memory-capped consumer machine
Evaluation
Compared against base LFM2-700M and the previous-generation Prism Caption 1.5 (Qwen3-0.6B) on a hand-authored held-out topic set with zero overlap against the training bank. Run three times at increasing scale to confirm the result wasn't a small-sample artifact:
| Held-out size | Base LFM2-700M (issues / relevant / avg words) | Prism Caption 1.5 | Prism Caption 2 |
|---|---|---|---|
| 24 topics | 8/24, 18/24, 7.5w | 1/24, 21/24, 3.3w | 0/24, 24/24, 4.7w |
| 145 topics | 35/145, 107/145, 5.8w | 9/145, 129/145, 3.9w | 0/145, 145/145, 5.0w |
| 275 topics | 69/275, 205/275, 5.9w | 13/275, 249/275, 4.0w | 0/275, 273/275, 5.0w |
"Issues" = formatting problems (too long/short/terse, leaked preamble, trailing punctuation, multiline). "Relevant" = title shares a non-stopword with the source topic.
Prism Caption 2 produced zero formatting issues across all 275 held-out topics in the final run, with 99.3% relevance -- the strongest and most consistent result of any Prism Caption generation. It also directly fixes 1.5's known failure mode: 1.5 averaged 3.3-4.0 words and occasionally over-compressed into vague titles ("Shoulder Sleep Matters" for a mattress question), while v2 lands at a natural ~5-word average and consistently names the actual subject ("Choosing Mattress for Side Sleepers").
Formats available
This repo includes both:
| Format | File | Notes |
|---|---|---|
| MLX (4-bit) | model.safetensors + config |
For Apple Silicon via mlx-lm |
| GGUF (Q4_K_M) | prism_caption_2_micro_Q4_K_M.gguf |
For llama.cpp and compatible runtimes (LM Studio, Ollama, etc.) |
Usage -- MLX
from mlx_lm import load, generate
model, tokenizer = load("VertexAGI/prism-caption-2-micro")
messages = [{"role": "system", "content": (
"You name chat conversations. Given the user's first message, reply with ONLY a short, "
"specific chat title (4-6 words, title case, no quotes, no punctuation at the end, no "
"preamble). The title MUST name the main subject of the message -- do not over-abbreviate "
"into something vague. Nothing else -- just the title."
)}, {"role": "user", "content": "Any advice on how to fix a leaking kitchen faucet?"}]
text = tokenizer.apply_chat_template(messages, add_generation_prompt=True, tokenize=False)
response = generate(model, tokenizer, prompt=text, max_tokens=24)
print(response)
Usage -- GGUF (llama.cpp)
llama-cli -hf VertexAGI/prism-caption-2-micro -m prism_caption_2_micro_Q4_K_M.gguf \
-sys "You name chat conversations. Given the user's first message, reply with ONLY a short, specific chat title (4-6 words, title case, no quotes, no punctuation at the end, no preamble). The title MUST name the main subject of the message -- do not over-abbreviate into something vague. Nothing else -- just the title." \
-p "Any advice on how to fix a leaking kitchen faucet?"
Limitations
Trained on a synthetic dataset distilled from a shifting mix of teacher models rather than a single consistent one; some stylistic inconsistency between examples from different teachers may be present. Titling behavior is only validated on English, conversational, everyday-topic inputs -- highly technical or non-English inputs are untested.
License
LFM Open License v1.0, inherited from the LFM2-700M base model. Free for research/non-commercial use and for commercial use under $10M annual revenue.
- Downloads last month
- 252
4-bit
Model tree for VertexAGI/prism-caption-2-micro
Base model
LiquidAI/LFM2-700M