Text Generation
Transformers
Safetensors
Chinese
English
mistral
Taiwan
ROC
zhtw
F1
Formosa-1
Mistral
chat
instruct
conversational
text-generation-inference
Instructions to use lianghsun/F1-24B-Instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use lianghsun/F1-24B-Instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="lianghsun/F1-24B-Instruct") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("lianghsun/F1-24B-Instruct") model = AutoModelForCausalLM.from_pretrained("lianghsun/F1-24B-Instruct") 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=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use lianghsun/F1-24B-Instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "lianghsun/F1-24B-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": "lianghsun/F1-24B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/lianghsun/F1-24B-Instruct
- SGLang
How to use lianghsun/F1-24B-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 "lianghsun/F1-24B-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": "lianghsun/F1-24B-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 "lianghsun/F1-24B-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": "lianghsun/F1-24B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use lianghsun/F1-24B-Instruct with Docker Model Runner:
docker model run hf.co/lianghsun/F1-24B-Instruct
Model Card for F1-24B-Instruct
F1-24B-Instruct 是 Formosa-1(F1) 系列的 24B 指令微調模型,建構於 F1-24B-Base 之上,以繁體中文指令對話資料完成 SFT,提供 24B 級繁中對話與在地語境之回答能力。
⚠️ 規格重點: 本模型為 24B 參數、純文本單模態,已完成指令微調可直接對話。
Model Details
24B 級模型在能力與部署成本之間提供良好平衡,適合企業級應用。F1-24B-Instruct 在 F1-24B-Base 之繁中 CPT 底座上做指令微調,目標是讓繁中對話模型在 24B 級規模具備穩定的台灣語境理解與回答能力。
核心特點 (Key Features)
- 24B 級繁中對話:能力與成本兼顧,適合中大型企業繁中應用部署。
- 台灣語境對齊:訓練資料以繁中與台灣常見任務為主,補強原版 Mistral-Small-24B 在繁中流暢度與在地語境上的不足。
- F1 家族成員:可與 F1-24B-Reasoner、F1-24B-Instruct-Cybersecurity 等專業版本互補使用。
Model Description
- Developed by: Liang Hsun Huang
- Funded by: APMIC
- Base model: lianghsun/F1-24B-Base
- Model type: MistralForCausalLM (Transformers)
- Language(s) (NLP): Traditional Chinese, English
- License: MIT
- Finetuned from model: lianghsun/F1-24B-Base
Model Sources
- Repository: lianghsun/F1-24B-Instruct
Citation
@misc{f1_24b_instruct,
title = {F1-24B-Instruct: A Traditional Chinese Instruction-Tuned Mistral-24B Model for Taiwan},
author = {Huang, Liang Hsun},
year = {2025},
howpublished = {\url{https://huggingface.co/lianghsun/F1-24B-Instruct}}
}
Acknowledge
- 特此感謝 APMIC 的算力支援。
Model Card Authors
Model Card Contact
- Downloads last month
- -
Model tree for lianghsun/F1-24B-Instruct
Base model
mistralai/Mistral-Small-24B-Base-2501 Finetuned
lianghsun/F1-24B-Base