đ DataPilot/ArrowMint-Gemma3-4B-YUKI-v0.1
This model is a Japanese language model developed specifically for the dialogue capabilities of AItubers (AI VTubers). It is based on Google's google/gemma-3-4b-it
.
đ Quick Start
First, install the necessary libraries. Gemma 3 requires transformers
4.50.0 or later.
pip install -U transformers accelerate Pillow
⨠Features
DataPilot/ArrowMint-Gemma3-4B-YUKI-v0.1
is a Japanese language model developed specifically for the dialogue capabilities of AItubers (AI VTubers). Based on the base model google/gemma-3-4b-it
, we used Unsloth for efficient fine-tuning and synthetic datasets to create multiple specialized models. Finally, we merged these models using mergekit
to combine the advantages of each model and aim for a higher-performance model.
The soul (AI) of an AItuber is particularly required to have the following capabilities:
- Multi-turn performance: The ability to maintain a natural flow of dialogue over a long period.
- Prompt following performance: The ability to faithfully follow the user's instructions and character settings (prompts) and generate consistent responses.
- Lightweight: The model size and inference speed to enable real-time response generation and operation in limited resource environments.
ArrowMint-Gemma3-4B-YUKI-v0.1
is designed and developed to meet these required capabilities.
đģ Usage Examples
Basic Usage
Inference with Images
from transformers import AutoProcessor, Gemma3ForConditionalGeneration
from PIL import Image
import requests
import torch
model_id = "DataPilot/ArrowMint-Gemma3-4B-YUKI-v0.1"
model = Gemma3ForConditionalGeneration.from_pretrained(
model_id, device_map="auto"
).eval()
processor = AutoProcessor.from_pretrained(model_id)
messages = [
{
"role": "system",
"content": [{"type": "text", "text": "You are a kind and a bit clumsy AI assistant named 'Yuki'. Support the user and sometimes tell jokes to lighten the mood. If the user is feeling down, please encourage them."}]
},
{
"role": "user",
"content": [
{"type": "image", "image": "https://web.archive.org/web/20250331074254/https://www.nsozai.jp/photos/2013/10/08/img/DSC_0176_p.jpg"},
{"type": "text", "text": "Isn't this a great image? It makes you feel the arrival of spring and hope..."}
]
}
]
inputs = processor.apply_chat_template(
messages, add_generation_prompt=True, tokenize=True,
return_dict=True, return_tensors="pt"
).to(model.device, dtype=torch.bfloat16)
input_len = inputs["input_ids"].shape[-1]
with torch.inference_mode():
generation = model.generate(**inputs, max_new_tokens=100, do_sample=False)
generation = generation[0][input_len:]
decoded = processor.decode(generation, skip_special_tokens=True)
print(decoded)
Inference without Images
from transformers import AutoProcessor, Gemma3ForConditionalGeneration
import torch
model_id = "DataPilot/ArrowMint-Gemma3-4B-YUKI-v0.1"
model = Gemma3ForConditionalGeneration.from_pretrained(
model_id, device_map="auto"
).eval()
processor = AutoProcessor.from_pretrained(model_id)
messages = [
{
"role": "system",
"content": [{"type": "text", "text": "You are a kind and a bit clumsy AI assistant named 'Yuki'. Support the user and sometimes tell jokes to lighten the mood. If the user is feeling down, please encourage them."}]
},
{
"role": "user",
"content": [
{"type": "text", "text": "I'm tired from work today. Please list five ways to refresh myself and relieve fatigue."}
]
}
]
inputs = processor.apply_chat_template(
messages, add_generation_prompt=True, tokenize=True,
return_dict=True, return_tensors="pt"
).to(model.device, dtype=torch.bfloat16)
input_len = inputs["input_ids"].shape[-1]
with torch.inference_mode():
generation = model.generate(**inputs, max_new_tokens=100, do_sample=False)
generation = generation[0][input_len:]
decoded = processor.decode(generation, skip_special_tokens=True)
print(decoded)
đ Documentation
Mergekit Configuration
This model was created using the following mergekit
configuration file:
merge_method: model_stock
base_model: unsloth/gemma-3-4b-it
models:
- model: DataPilot/ArrowMint-Gemma3-4B-ChocoMint-code
- model: DataPilot/ArrowMint-Gemma3-4B-ChocoMint-jp
- model: DataPilot/ArrowMint-Gemma3-4B-ChocoMint-instruct-v0.1
- model: DataPilot/ArrowMint-Gemma3-4B-ChocoMint-instruct-v0.2
dtype: bfloat16
pad_to_multiple_of: 512
tokenizer_source: base
name: gemma3-4b-ft
đ License
This model inherits the license of the base model google/gemma-3-4b-it
. The license of google/gemma-3-4b-it
is the Gemma Terms of Use.
For more details, please refer to the following link:
https://ai.google.dev/gemma/terms
When using the model, please comply with the Gemma Terms of Use and related policies (such as the policy on prohibited uses).
https://ai.google.dev/gemma/prohibited_use_policy
Information Table
Property |
Details |
Model Type |
Text Generation |
Base Model |
google/gemma-3-4b-it |
License |
Gemma Terms of Use |