Instructions to use sasa2000/minicpm-v-4.6-text-only with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use sasa2000/minicpm-v-4.6-text-only with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="sasa2000/minicpm-v-4.6-text-only") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("sasa2000/minicpm-v-4.6-text-only") model = AutoModelForCausalLM.from_pretrained("sasa2000/minicpm-v-4.6-text-only") 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]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use sasa2000/minicpm-v-4.6-text-only with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "sasa2000/minicpm-v-4.6-text-only" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "sasa2000/minicpm-v-4.6-text-only", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/sasa2000/minicpm-v-4.6-text-only
- SGLang
How to use sasa2000/minicpm-v-4.6-text-only 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 "sasa2000/minicpm-v-4.6-text-only" \ --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": "sasa2000/minicpm-v-4.6-text-only", "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 "sasa2000/minicpm-v-4.6-text-only" \ --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": "sasa2000/minicpm-v-4.6-text-only", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use sasa2000/minicpm-v-4.6-text-only with Docker Model Runner:
docker model run hf.co/sasa2000/minicpm-v-4.6-text-only
MiniCPM-V-4.6 Text-Only
This is a text-only extraction of openbmb/MiniCPM-V-4.6.
It keeps the Qwen3.5 text backbone and tokenizer assets, and removes the vision/multimodal components.
This repository is not an official OpenBMB release.
Conversion
- Source model:
openbmb/MiniCPM-V-4.6 - Source revision:
d7f5ed8d15462c508d4f9d9ce5a0cf1fe8d87bcc - Source architecture:
MiniCPMV4_6ForConditionalGeneration - Target model type:
qwen3_5_text - Target architecture:
Qwen3_5ForCausalLM - Kept tensors: 320
- Dropped tensors: 459
- Dropped components:
model.vision_tower.* - Weight format: single
model.safetensors
The original VLM config stores the text backbone under text_config and the weights under
model.language_model.*. The extracted checkpoint strips that prefix and writes a standalone
Qwen3.5 text CausalLM config for AutoModelForCausalLM.
Validation
Validated locally with Transformers:
AutoConfig.from_pretrained(...)loads asQwen3_5TextConfigAutoTokenizer.from_pretrained(...)loads successfullyAutoModelForCausalLM.from_pretrained(..., torch_dtype="auto", low_cpu_mem_usage=True)loads asQwen3_5ForCausalLM- A tiny forward pass succeeds and returns logits with shape
(1, 1, 248094) - The safetensors file contains 320 tensors
- No vision/projector/language wrapper tensor names remain
- The safetensors header matches the file size and tensor offsets
The model uses Qwen3.5 text linear-attention layers. Without optional fast-path packages, Transformers falls back to the torch implementation.
Usage
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "sasa2000/minicpm-v-4.6-text-only"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
torch_dtype="auto",
device_map="auto",
)
messages = [{"role": "user", "content": "Explain why the sky looks blue."}]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
with torch.no_grad():
output_ids = model.generate(**inputs, max_new_tokens=128)
print(tokenizer.decode(output_ids[0], skip_special_tokens=True))
Limitations
This checkpoint is text-only. Image and video inputs are not supported because the vision tower, multimodal processing assets, and related preprocessing files were removed.
Please review the upstream model card and license for the original model's intended use, limitations, and terms.
- Downloads last month
- 20
Model tree for sasa2000/minicpm-v-4.6-text-only
Base model
openbmb/MiniCPM-V-4.6