Text Generation
Transformers
PyTorch
Safetensors
English
idefics
image-text-to-text
multimodal
text
image
image-to-text
text-generation-inference
Instructions to use HuggingFaceM4/idefics-80b-instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use HuggingFaceM4/idefics-80b-instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="HuggingFaceM4/idefics-80b-instruct")# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("HuggingFaceM4/idefics-80b-instruct") model = AutoModelForMultimodalLM.from_pretrained("HuggingFaceM4/idefics-80b-instruct", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use HuggingFaceM4/idefics-80b-instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "HuggingFaceM4/idefics-80b-instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HuggingFaceM4/idefics-80b-instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/HuggingFaceM4/idefics-80b-instruct
- SGLang
How to use HuggingFaceM4/idefics-80b-instruct 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 "HuggingFaceM4/idefics-80b-instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HuggingFaceM4/idefics-80b-instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "HuggingFaceM4/idefics-80b-instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HuggingFaceM4/idefics-80b-instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use HuggingFaceM4/idefics-80b-instruct with Docker Model Runner:
docker model run hf.co/HuggingFaceM4/idefics-80b-instruct
Commit History
-
text generation inference infos
a14d258
-
revert tokenizer update (#9)
- Revert "Upload tokenizer.json (#8)" (ddb9e0429104eb0d8f69110e88c8b036eeaa3f7b)4b5c078 -
Upload tokenizer.json (#8)
- Upload tokenizer.json (258a8ee5ea0755ff34142ffece44d0ce9f7789c0) Co-authored-by: Nicolas Patry <Narsil@users.noreply.huggingface.co>d93a6e8 -
Update added_tokens.json
907a7af -
Upload tokenizer
29a2b65
-
Update tokenizer_config.json
5a06c17 -
Update special_tokens_map.json
8eb5f82
-
Update readme and doc from the 80b repo
761c5ab -
set the correct vision_config.hidden_act (#4)
- set the correct vision_config.hidden_act (eca1af7e5b8df0a5daf621c5447af1fc8559155c) Co-authored-by: Stas Bekman <stas@users.noreply.huggingface.co>9a6ed1e
-
Update readme and doc from the 80b repo
3bcd940 -
Update readme and doc from the 80b repo
1648537
-
Update readme and doc from the 80b repo
83f9046 -
Update readme and doc from the 80b repo
a2a5c48 -
Update readme and doc from the 80b repo
b56116a -
Update readme and doc from the 80b repo
64c8644
-
Update readme and doc from the 80b repo
52afb70
-
Update readme and doc from the 80b repo
1138740
-
Update README.md
a7e32ef -
revert
4dce551 -
add tokenizer.json for fast tokenizer
e128d75 -
Update README from idefics-80b
6d380f1 -
Update README from idefics-80b
4cf4362
-
Create README.md
676b50a
-
add safetensors
hugo@huggingface.codb61980
-
update 80b instruct to latest model trained
efd2373
-
Update tokenizer_config.json
489226f
-
Update config.json (#5)
6b82e8d -
s|IdeficsForCausalLM|IdeficsForVisionText2Text|g
a9325f0
-
Create preprocessor_config.json
5674075 -
Update config.json
0979cbf
-
First commit
aca8e0b -
initial commit
Victor Sanhd53eea0