Instructions to use sionic-ai/Wasabi-30B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use sionic-ai/Wasabi-30B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="sionic-ai/Wasabi-30B") 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 AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("sionic-ai/Wasabi-30B") model = AutoModelForMultimodalLM.from_pretrained("sionic-ai/Wasabi-30B", device_map="auto") 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?"} ] }, ] inputs = processor.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=256) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use sionic-ai/Wasabi-30B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "sionic-ai/Wasabi-30B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "sionic-ai/Wasabi-30B", "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/sionic-ai/Wasabi-30B
- SGLang
How to use sionic-ai/Wasabi-30B 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 "sionic-ai/Wasabi-30B" \ --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": "sionic-ai/Wasabi-30B", "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 "sionic-ai/Wasabi-30B" \ --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": "sionic-ai/Wasabi-30B", "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 sionic-ai/Wasabi-30B with Docker Model Runner:
docker model run hf.co/sionic-ai/Wasabi-30B
Wasabi-30B
Wasabi-30B is Sionic AI's Japanese document fine-tune of Muse Glimmer 30B. It transcribes page images into Markdown, including headings, paragraphs, tables and mathematical notation.
The checkpoint is provided as merged BF16 weights in two safetensors shards, approximately 60 GB in total. No separate adapter or base-model download is needed.
Document processing
Fine-tuning focuses on Japanese text structure, paragraph continuity and faithful transcription. The full document-processing pipeline also handles page orientation, complex layouts and small text annotations through preprocessing and output refinement.
The complete pipeline is maintained in Sionic AI's private Wasabi repository, accessible to authorized collaborators. The Docker package supplied for evaluation includes the full inference pipeline and its runtime assets.
Quickstart
This example transcribes one upright page image. Convert PDFs to page images first. Allow GPU memory for the weights, image processing and generated tokens; device_map="auto" distributes the model across available devices.
Install PyTorch for your CUDA environment, then:
pip install "transformers==5.15.0" accelerate pillow huggingface_hub
Save the following as transcribe.py and run python transcribe.py page.jpg > page.md:
import argparse
from pathlib import Path
import torch
from huggingface_hub import hf_hub_download
from PIL import Image, ImageOps
from transformers import AutoModelForImageTextToText, AutoProcessor
parser = argparse.ArgumentParser()
parser.add_argument("image")
parser.add_argument("--rotate", type=int, choices=[0, 90, 180, 270], default=0,
help="Additional clockwise rotation in degrees")
args = parser.parse_args()
model_id = "sionic-ai/Wasabi-30B"
processor = AutoProcessor.from_pretrained(model_id)
model = AutoModelForImageTextToText.from_pretrained(
model_id, dtype=torch.bfloat16, device_map="auto"
).eval()
prompt_path = hf_hub_download(model_id, "prompt.txt")
prompt = Path(prompt_path).read_text(encoding="utf-8")
with Image.open(args.image) as source:
image = ImageOps.exif_transpose(source).convert("RGB")
if args.rotate:
image = image.rotate(-args.rotate, expand=True)
messages = [{"role": "user", "content": [
{"type": "image", "image": image},
{"type": "text", "text": prompt},
]}]
inputs = processor.apply_chat_template(
messages, add_generation_prompt=True, tokenize=True,
return_dict=True, return_tensors="pt", reasoning_strength="low",
).to(model.device)
with torch.inference_mode():
output = model.generate(**inputs, max_new_tokens=8192, do_sample=False)
generated = output[0, inputs["input_ids"].shape[1]:]
print(processor.decode(generated, skip_special_tokens=True))
The example applies EXIF orientation metadata. For a page still turned sideways, use python transcribe.py page.jpg --rotate 90 > page.md. Automatic visual orientation correction is part of the private pipeline.
Use the included transcription prompt with the supplied chat template. The example covers direct model inference. For deployment support, contact Sionic AI.
File checksums are provided in SHA256SUMS.
Limitations
- Dense or low-quality pages can lose text, table structure or reading order.
- Use upright page images and check important details against the source.
- Retrieval, question answering and general chat require separate evaluation.
Licence and attribution
Wasabi-30B is released under AGPL-3.0. See LICENSE and NOTICE for terms and attribution.
The base model is Muse Glimmer 30B, revision 97c77dff50b2797bcc558fa2d909761dbc575c59. Its Apache-2.0 licence and publisher usage policy are included in notices/.
- Downloads last month
- 39