Image-Text-to-Text
Transformers
Safetensors
internvl_chat
feature-extraction
openspatial
spatial-reasoning
vision-language
conversational
custom_code
Instructions to use VINHYU/OpenSpatial-InternVL3-8B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use VINHYU/OpenSpatial-InternVL3-8B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="VINHYU/OpenSpatial-InternVL3-8B", trust_remote_code=True) messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("VINHYU/OpenSpatial-InternVL3-8B", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use VINHYU/OpenSpatial-InternVL3-8B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "VINHYU/OpenSpatial-InternVL3-8B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "VINHYU/OpenSpatial-InternVL3-8B", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/VINHYU/OpenSpatial-InternVL3-8B
- SGLang
How to use VINHYU/OpenSpatial-InternVL3-8B 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 "VINHYU/OpenSpatial-InternVL3-8B" \ --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": "VINHYU/OpenSpatial-InternVL3-8B", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'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 "VINHYU/OpenSpatial-InternVL3-8B" \ --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": "VINHYU/OpenSpatial-InternVL3-8B", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use VINHYU/OpenSpatial-InternVL3-8B with Docker Model Runner:
docker model run hf.co/VINHYU/OpenSpatial-InternVL3-8B
|
Download README.md from VINHYU/OpenSpatial-InternVL3-8B: direct link, hf CLI and curl.
- Browser
- Download file 1.19 kB
-
https://huggingface.co/VINHYU/OpenSpatial-InternVL3-8B/resolve/main/README.md
- Command line
-
hf download hf://VINHYU/OpenSpatial-InternVL3-8B/README.md
-
curl -L -o README.md https://huggingface.co/VINHYU/OpenSpatial-InternVL3-8B/resolve/main/README.md
1.19 kB
metadata
license: apache-2.0
base_model: OpenGVLab/InternVL3-8B
pipeline_tag: image-text-to-text
library_name: transformers
tags:
- openspatial
- spatial-reasoning
- vision-language
OpenSpatial-InternVL3-8B
OpenSpatial-InternVL3-8B is an OpenSpatial model fine-tuned for spatial understanding and reasoning. This repository contains full, inference-ready model weights.
- Project: https://github.com/VINHYU/OpenSpatial
- Paper: https://arxiv.org/abs/2604.07296
- Training data: https://huggingface.co/datasets/jdopensource/JoyAI-Image-OpenSpatial
- Base model: https://huggingface.co/OpenGVLab/InternVL3-8B
Loading
Use transformers the version recommended by InternVL3 for this checkpoint.
from transformers import AutoModel, AutoTokenizer
model_id = "VINHYU/OpenSpatial-InternVL3-8B"
model = AutoModel.from_pretrained(
model_id,
torch_dtype="auto",
low_cpu_mem_usage=True,
trust_remote_code=True,
).eval().cuda()
tokenizer = AutoTokenizer.from_pretrained(
model_id, trust_remote_code=True, use_fast=False
)
Please refer to the OpenSpatial repository and the base model repository for full usage instructions, limitations, and license terms.