Run this model with HF Jobs
Run tiiuae/Falcon-H1-0.5B-Instruct on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/tiiuae/Falcon-H1-0.5B-Instruct. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/tiiuae/Falcon-H1-0.5B-Instruct on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/tiiuae/Falcon-H1-0.5B-Instruct. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/tiiuae/Falcon-H1-0.5B-Instruct. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use tiiuae/Falcon-H1-0.5B-Instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use tiiuae/Falcon-H1-0.5B-Instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="tiiuae/Falcon-H1-0.5B-Instruct") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("tiiuae/Falcon-H1-0.5B-Instruct") model = AutoModelForCausalLM.from_pretrained("tiiuae/Falcon-H1-0.5B-Instruct", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.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(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use tiiuae/Falcon-H1-0.5B-Instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "tiiuae/Falcon-H1-0.5B-Instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "tiiuae/Falcon-H1-0.5B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/tiiuae/Falcon-H1-0.5B-Instruct
- SGLang
How to use tiiuae/Falcon-H1-0.5B-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 "tiiuae/Falcon-H1-0.5B-Instruct" \ --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": "tiiuae/Falcon-H1-0.5B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "tiiuae/Falcon-H1-0.5B-Instruct" \ --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": "tiiuae/Falcon-H1-0.5B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use tiiuae/Falcon-H1-0.5B-Instruct with Docker Model Runner:
docker model run hf.co/tiiuae/Falcon-H1-0.5B-Instruct
Commit History
-
Update README.md
Verified signature8f2587c
-
revert chat template
Verified signaturefaa83b7
-
Update config.json (#7)
Verified signature- Update config.json (62ac9dad1f9a5bd6b8e435e842615d6070c30fd6)a3beb78 -
fix: remove `add_generation_prompt` from H1 tokenizers (#6)
Verified signature- fix: remove `add_generation_prompt` from H1 tokenizers (b12082a9a0fc606b797e3a84cc13dcc1fafa8f96)72f31da -
Update README.md
Verified signature27ec235
-
Fix special tokens for generation (#4)
Verified signature- Fix special tokens for generation (dbdd99c51d4099c8d3a8fbe89805cde363327383) Co-authored-by: Younes B <ybelkada@users.noreply.huggingface.co>6cf476b -
Update README.md
Verified signature68e6c94 -
Update README.md
Verified signature8edad51 -
Update README.md
Verified signaturea4216bb
-
Update chat template (#2)
Verified signature- Update chat template (e7ee59abe99d4b8796077a088e10b4ba01fad044) Co-authored-by: Rhaiem <DhiyaEddine@users.noreply.huggingface.co>2505080
-
Update README.md
Verified signature7778fd5 -
Update tokenizer_config.json
Verified signature14eb8f9 -
Update README.md
Verified signaturedd538e9 -
Update README.md
Verified signature208f78c -
Update README.md
Verified signature5d90ac0
-
Create README.md
Verified signature49b5f98
-
Update chat_template.jinja (#1)
Verified signature- Update chat_template.jinja (b1813daeb2cc8ec87e9976149483bf23fd5b5db8) - Update chat_template.jinja (82b913433a90e91a6d31ba99a934bcc3e3d8c91a) - Update chat_template.jinja (bc7c908a7a2a1227e4858dcdb01fe4ef6f6a2780) - Update chat_template.jinja (31a4f29a2c0bb91657384d3d6caa0fa96a6fe871)839c48b
-
Upload folder using huggingface_hub
Verified signature992ce7d -
Upload folder using huggingface_hub
Verified signature2de20b6 -
initial commit
Verified signature3e0b146