Image-Text-to-Text
Transformers
Safetensors
English
idefics3
medical
vqa
vision-language
healthcare
morocco
lora
smolvlm
conversational
Instructions to use doctoria/doctoria-rally-ai with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use doctoria/doctoria-rally-ai with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="doctoria/doctoria-rally-ai") 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)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("doctoria/doctoria-rally-ai") model = AutoModelForMultimodalLM.from_pretrained("doctoria/doctoria-rally-ai", 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=40) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use doctoria/doctoria-rally-ai with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "doctoria/doctoria-rally-ai" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "doctoria/doctoria-rally-ai", "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/doctoria/doctoria-rally-ai
- SGLang
How to use doctoria/doctoria-rally-ai 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 "doctoria/doctoria-rally-ai" \ --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": "doctoria/doctoria-rally-ai", "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 "doctoria/doctoria-rally-ai" \ --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": "doctoria/doctoria-rally-ai", "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 doctoria/doctoria-rally-ai with Docker Model Runner:
docker model run hf.co/doctoria/doctoria-rally-ai
Upload folder using huggingface_hub
Browse files- README.md +42 -0
- chat_template.jinja +2 -0
- config.json +194 -0
- generation_config.json +7 -0
- model.safetensors +3 -0
- processor_config.json +31 -0
- tokenizer.json +0 -0
- tokenizer_config.json +23 -0
README.md
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
library_name: transformers
|
| 4 |
+
pipeline_tag: image-text-to-text
|
| 5 |
+
tags: [medical, vqa, vision-language, healthcare, morocco, lora, smolvlm]
|
| 6 |
+
base_model: HuggingFaceTB/SmolVLM-256M-Instruct
|
| 7 |
+
datasets: [flaviagiammarino/vqa-rad]
|
| 8 |
+
language: [en]
|
| 9 |
+
---
|
| 10 |
+
|
| 11 |
+
# doctoria-rally-ai 🩺
|
| 12 |
+
|
| 13 |
+
Fine-tuned medical Vision-Language Model for **SahhaAI** — offline, private
|
| 14 |
+
wound-care & medical VQA for disconnected clinics in Morocco.
|
| 15 |
+
|
| 16 |
+
- **Base:** `HuggingFaceTB/SmolVLM-256M-Instruct` (SmolVLM)
|
| 17 |
+
- **Method:** LoRA fine-tune (PyTorch + PEFT, trained locally on Apple Silicon / MPS)
|
| 18 |
+
- **Data:** [VQA-RAD](https://huggingface.co/datasets/flaviagiammarino/vqa-rad) (radiology VQA, CC0)
|
| 19 |
+
- **Runs:** in-browser (WebGPU via transformers.js) and locally — data stays on device
|
| 20 |
+
|
| 21 |
+
## Benchmark (VQA-RAD test)
|
| 22 |
+
|
| 23 |
+
- Closed-ended accuracy: **0.439**
|
| 24 |
+
- Open-ended token-F1: **0.228**
|
| 25 |
+
- Speed: **19.0 tok/s** on Apple Silicon (MPS)
|
| 26 |
+
- See repo `finetune/BENCHMARK.md` for base-vs-fine-tuned analysis.
|
| 27 |
+
|
| 28 |
+
## Use
|
| 29 |
+
```python
|
| 30 |
+
from transformers import AutoProcessor, AutoModelForImageTextToText
|
| 31 |
+
from PIL import Image
|
| 32 |
+
m = AutoModelForImageTextToText.from_pretrained("doctoria/doctoria-rally-ai")
|
| 33 |
+
p = AutoProcessor.from_pretrained("doctoria/doctoria-rally-ai")
|
| 34 |
+
msgs = [{"role":"user","content":[{"type":"image"},{"type":"text","text":"Assess this wound."}]}]
|
| 35 |
+
text = p.apply_chat_template(msgs, add_generation_prompt=True)
|
| 36 |
+
inp = p(text=text, images=[[Image.open("wound.jpg")]], return_tensors="pt")
|
| 37 |
+
print(p.batch_decode(m.generate(**inp, max_new_tokens=128), skip_special_tokens=True)[0])
|
| 38 |
+
```
|
| 39 |
+
|
| 40 |
+
⚠ **Decision support, not a diagnosis.** A trained health worker stays in the loop.
|
| 41 |
+
|
| 42 |
+
— Author: **Jad Tounsi El Azzouzi** · part of SahhaAI · Apache-2.0
|
chat_template.jinja
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<|im_start|>{% for message in messages %}{{message['role'] | capitalize}}{% if message['content'][0]['type'] == 'image' %}{{':'}}{% else %}{{': '}}{% endif %}{% for line in message['content'] %}{% if line['type'] == 'text' %}{{line['text']}}{% elif line['type'] == 'image' %}{{ '<image>' }}{% endif %}{% endfor %}<end_of_utterance>
|
| 2 |
+
{% endfor %}{% if add_generation_prompt %}{{ 'Assistant:' }}{% endif %}
|
config.json
ADDED
|
@@ -0,0 +1,194 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"Idefics3ForConditionalGeneration"
|
| 4 |
+
],
|
| 5 |
+
"dtype": "float32",
|
| 6 |
+
"image_token_id": 49190,
|
| 7 |
+
"model_type": "idefics3",
|
| 8 |
+
"pad_token_id": 128002,
|
| 9 |
+
"scale_factor": 4,
|
| 10 |
+
"text_config": {
|
| 11 |
+
"_attn_implementation_autoset": false,
|
| 12 |
+
"_flash_attn_2_enabled": true,
|
| 13 |
+
"_name_or_path": "None",
|
| 14 |
+
"add_cross_attention": false,
|
| 15 |
+
"architectures": [
|
| 16 |
+
"VLlama3ForCausalLM"
|
| 17 |
+
],
|
| 18 |
+
"attention_bias": false,
|
| 19 |
+
"attention_dropout": 0.0,
|
| 20 |
+
"bos_token_id": 1,
|
| 21 |
+
"cross_attention_hidden_size": null,
|
| 22 |
+
"decoder_start_token_id": null,
|
| 23 |
+
"dtype": "float32",
|
| 24 |
+
"eos_token_id": 2,
|
| 25 |
+
"finetuning_task": null,
|
| 26 |
+
"head_dim": 64,
|
| 27 |
+
"hidden_act": "silu",
|
| 28 |
+
"hidden_size": 576,
|
| 29 |
+
"initializer_range": 0.041666666666666664,
|
| 30 |
+
"intermediate_size": 1536,
|
| 31 |
+
"is_decoder": false,
|
| 32 |
+
"is_llama_config": true,
|
| 33 |
+
"max_position_embeddings": 8192,
|
| 34 |
+
"mlp_bias": false,
|
| 35 |
+
"model_type": "llama",
|
| 36 |
+
"neftune_noise_alpha": 0.0,
|
| 37 |
+
"num_attention_heads": 9,
|
| 38 |
+
"num_hidden_layers": 30,
|
| 39 |
+
"num_key_value_heads": 3,
|
| 40 |
+
"pad_token_id": 2,
|
| 41 |
+
"perceiver_config": {
|
| 42 |
+
"_attn_implementation_autoset": false,
|
| 43 |
+
"_name_or_path": "",
|
| 44 |
+
"add_cross_attention": false,
|
| 45 |
+
"architectures": null,
|
| 46 |
+
"attention_dropout": 0.0,
|
| 47 |
+
"bad_words_ids": null,
|
| 48 |
+
"begin_suppress_tokens": null,
|
| 49 |
+
"bos_token_id": null,
|
| 50 |
+
"chunk_size_feed_forward": 0,
|
| 51 |
+
"cross_attention_hidden_size": null,
|
| 52 |
+
"decoder_start_token_id": null,
|
| 53 |
+
"diversity_penalty": 0.0,
|
| 54 |
+
"do_sample": false,
|
| 55 |
+
"early_stopping": false,
|
| 56 |
+
"encoder_no_repeat_ngram_size": 0,
|
| 57 |
+
"eos_token_id": null,
|
| 58 |
+
"exponential_decay_length_penalty": null,
|
| 59 |
+
"finetuning_task": null,
|
| 60 |
+
"forced_bos_token_id": null,
|
| 61 |
+
"forced_eos_token_id": null,
|
| 62 |
+
"hidden_act": "silu",
|
| 63 |
+
"id2label": {
|
| 64 |
+
"0": "LABEL_0",
|
| 65 |
+
"1": "LABEL_1"
|
| 66 |
+
},
|
| 67 |
+
"is_decoder": false,
|
| 68 |
+
"is_encoder_decoder": false,
|
| 69 |
+
"label2id": {
|
| 70 |
+
"LABEL_0": 0,
|
| 71 |
+
"LABEL_1": 1
|
| 72 |
+
},
|
| 73 |
+
"length_penalty": 1.0,
|
| 74 |
+
"max_length": 20,
|
| 75 |
+
"min_length": 0,
|
| 76 |
+
"model_type": "vllama3",
|
| 77 |
+
"no_repeat_ngram_size": 0,
|
| 78 |
+
"num_beam_groups": 1,
|
| 79 |
+
"num_beams": 1,
|
| 80 |
+
"num_key_value_heads": 1,
|
| 81 |
+
"num_return_sequences": 1,
|
| 82 |
+
"output_attentions": false,
|
| 83 |
+
"output_hidden_states": false,
|
| 84 |
+
"output_scores": false,
|
| 85 |
+
"pad_token_id": null,
|
| 86 |
+
"prefix": null,
|
| 87 |
+
"problem_type": null,
|
| 88 |
+
"pruned_heads": {},
|
| 89 |
+
"qk_layer_norms_perceiver": false,
|
| 90 |
+
"remove_invalid_values": false,
|
| 91 |
+
"repetition_penalty": 1.0,
|
| 92 |
+
"resampler_depth": 6,
|
| 93 |
+
"resampler_head_dim": 96,
|
| 94 |
+
"resampler_n_heads": 16,
|
| 95 |
+
"resampler_n_latents": 64,
|
| 96 |
+
"return_dict": true,
|
| 97 |
+
"return_dict_in_generate": false,
|
| 98 |
+
"sep_token_id": null,
|
| 99 |
+
"suppress_tokens": null,
|
| 100 |
+
"task_specific_params": null,
|
| 101 |
+
"temperature": 1.0,
|
| 102 |
+
"tf_legacy_loss": false,
|
| 103 |
+
"tie_encoder_decoder": false,
|
| 104 |
+
"tie_word_embeddings": true,
|
| 105 |
+
"tokenizer_class": null,
|
| 106 |
+
"top_k": 50,
|
| 107 |
+
"top_p": 1.0,
|
| 108 |
+
"torch_dtype": null,
|
| 109 |
+
"torchscript": false,
|
| 110 |
+
"transformers_version": "4.46.0",
|
| 111 |
+
"typical_p": 1.0,
|
| 112 |
+
"use_bfloat16": false
|
| 113 |
+
},
|
| 114 |
+
"pixel_shuffle_factor": 4,
|
| 115 |
+
"prefix": null,
|
| 116 |
+
"pretraining_tp": 1,
|
| 117 |
+
"pruned_heads": {},
|
| 118 |
+
"qk_layer_norms": false,
|
| 119 |
+
"rms_norm_eps": 1e-05,
|
| 120 |
+
"rope_interleaved": false,
|
| 121 |
+
"rope_parameters": {
|
| 122 |
+
"rope_theta": 100000,
|
| 123 |
+
"rope_type": "default"
|
| 124 |
+
},
|
| 125 |
+
"sep_token_id": null,
|
| 126 |
+
"task_specific_params": null,
|
| 127 |
+
"tf_legacy_loss": false,
|
| 128 |
+
"tie_encoder_decoder": false,
|
| 129 |
+
"tie_word_embeddings": false,
|
| 130 |
+
"tokenizer_class": null,
|
| 131 |
+
"torchscript": false,
|
| 132 |
+
"transformers.js_config": {
|
| 133 |
+
"kv_cache_dtype": {
|
| 134 |
+
"fp16": "float16",
|
| 135 |
+
"q4f16": "float16"
|
| 136 |
+
}
|
| 137 |
+
},
|
| 138 |
+
"use_bfloat16": false,
|
| 139 |
+
"use_cache": true,
|
| 140 |
+
"use_resampler": false,
|
| 141 |
+
"vocab_size": 49280
|
| 142 |
+
},
|
| 143 |
+
"tie_word_embeddings": false,
|
| 144 |
+
"transformers.js_config": {
|
| 145 |
+
"kv_cache_dtype": {
|
| 146 |
+
"fp16": "float16",
|
| 147 |
+
"q4f16": "float16"
|
| 148 |
+
}
|
| 149 |
+
},
|
| 150 |
+
"transformers_version": "5.12.1",
|
| 151 |
+
"use_cache": true,
|
| 152 |
+
"vision_config": {
|
| 153 |
+
"_attn_implementation_autoset": false,
|
| 154 |
+
"add_cross_attention": false,
|
| 155 |
+
"attention_dropout": 0.0,
|
| 156 |
+
"bos_token_id": null,
|
| 157 |
+
"cross_attention_hidden_size": null,
|
| 158 |
+
"decoder_start_token_id": null,
|
| 159 |
+
"dtype": "float32",
|
| 160 |
+
"eos_token_id": null,
|
| 161 |
+
"finetuning_task": null,
|
| 162 |
+
"hidden_act": "gelu_pytorch_tanh",
|
| 163 |
+
"hidden_size": 768,
|
| 164 |
+
"image_size": 512,
|
| 165 |
+
"initializer_range": 0.02,
|
| 166 |
+
"intermediate_size": 3072,
|
| 167 |
+
"is_decoder": false,
|
| 168 |
+
"layer_norm_eps": 1e-06,
|
| 169 |
+
"max_image_size": {
|
| 170 |
+
"longest_edge": 512
|
| 171 |
+
},
|
| 172 |
+
"model_type": "idefics3_vision",
|
| 173 |
+
"num_attention_heads": 12,
|
| 174 |
+
"num_channels": 3,
|
| 175 |
+
"num_hidden_layers": 12,
|
| 176 |
+
"pad_token_id": null,
|
| 177 |
+
"patch_size": 16,
|
| 178 |
+
"prefix": null,
|
| 179 |
+
"pruned_heads": {},
|
| 180 |
+
"sep_token_id": null,
|
| 181 |
+
"size": {
|
| 182 |
+
"longest_edge": 2048
|
| 183 |
+
},
|
| 184 |
+
"task_specific_params": null,
|
| 185 |
+
"tf_legacy_loss": false,
|
| 186 |
+
"tie_encoder_decoder": false,
|
| 187 |
+
"tie_word_embeddings": false,
|
| 188 |
+
"tokenizer_class": null,
|
| 189 |
+
"torchscript": false,
|
| 190 |
+
"use_base_siglip": true,
|
| 191 |
+
"use_bfloat16": false
|
| 192 |
+
},
|
| 193 |
+
"vocab_size": 49280
|
| 194 |
+
}
|
generation_config.json
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_from_model_config": true,
|
| 3 |
+
"bos_token_id": 0,
|
| 4 |
+
"eos_token_id": 49279,
|
| 5 |
+
"pad_token_id": 2,
|
| 6 |
+
"transformers_version": "5.12.1"
|
| 7 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a48242fb6a93fc68a661415d1015b0e184307d33862ff5f97e55319c9af82bc7
|
| 3 |
+
size 1025998224
|
processor_config.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"image_processor": {
|
| 3 |
+
"do_convert_rgb": true,
|
| 4 |
+
"do_image_splitting": true,
|
| 5 |
+
"do_normalize": true,
|
| 6 |
+
"do_pad": true,
|
| 7 |
+
"do_rescale": true,
|
| 8 |
+
"do_resize": true,
|
| 9 |
+
"image_mean": [
|
| 10 |
+
0.5,
|
| 11 |
+
0.5,
|
| 12 |
+
0.5
|
| 13 |
+
],
|
| 14 |
+
"image_processor_type": "Idefics3ImageProcessor",
|
| 15 |
+
"image_std": [
|
| 16 |
+
0.5,
|
| 17 |
+
0.5,
|
| 18 |
+
0.5
|
| 19 |
+
],
|
| 20 |
+
"max_image_size": {
|
| 21 |
+
"longest_edge": 512
|
| 22 |
+
},
|
| 23 |
+
"resample": 1,
|
| 24 |
+
"rescale_factor": 0.00392156862745098,
|
| 25 |
+
"size": {
|
| 26 |
+
"longest_edge": 2048
|
| 27 |
+
}
|
| 28 |
+
},
|
| 29 |
+
"image_seq_len": 64,
|
| 30 |
+
"processor_class": "Idefics3Processor"
|
| 31 |
+
}
|
tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_prefix_space": false,
|
| 3 |
+
"backend": "tokenizers",
|
| 4 |
+
"bos_token": "<|im_start|>",
|
| 5 |
+
"clean_up_tokenization_spaces": false,
|
| 6 |
+
"eos_token": "<end_of_utterance>",
|
| 7 |
+
"errors": "replace",
|
| 8 |
+
"extra_special_tokens": [
|
| 9 |
+
"<fake_token_around_image>",
|
| 10 |
+
"<image>",
|
| 11 |
+
"<end_of_utterance>"
|
| 12 |
+
],
|
| 13 |
+
"is_local": false,
|
| 14 |
+
"legacy": false,
|
| 15 |
+
"local_files_only": false,
|
| 16 |
+
"model_max_length": 8192,
|
| 17 |
+
"pad_token": "<|im_end|>",
|
| 18 |
+
"processor_class": "Idefics3Processor",
|
| 19 |
+
"tokenizer_class": "GPT2Tokenizer",
|
| 20 |
+
"truncation_side": "left",
|
| 21 |
+
"unk_token": "<|endoftext|>",
|
| 22 |
+
"vocab_size": 49152
|
| 23 |
+
}
|