Text Generation
Transformers
Safetensors
Thai
English
qwen2
openthaigpt
qwen
reasoning
conversational
Eval Results (legacy)
text-generation-inference
Instructions to use openthaigpt/openthaigpt-1.6-72b-instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use openthaigpt/openthaigpt-1.6-72b-instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="openthaigpt/openthaigpt-1.6-72b-instruct") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("openthaigpt/openthaigpt-1.6-72b-instruct") model = AutoModelForCausalLM.from_pretrained("openthaigpt/openthaigpt-1.6-72b-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=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use openthaigpt/openthaigpt-1.6-72b-instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "openthaigpt/openthaigpt-1.6-72b-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": "openthaigpt/openthaigpt-1.6-72b-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/openthaigpt/openthaigpt-1.6-72b-instruct
- SGLang
How to use openthaigpt/openthaigpt-1.6-72b-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 "openthaigpt/openthaigpt-1.6-72b-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": "openthaigpt/openthaigpt-1.6-72b-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 "openthaigpt/openthaigpt-1.6-72b-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": "openthaigpt/openthaigpt-1.6-72b-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use openthaigpt/openthaigpt-1.6-72b-instruct with Docker Model Runner:
docker model run hf.co/openthaigpt/openthaigpt-1.6-72b-instruct
Add Run-it-locally section: official Ollama tag + GGUF quants
Browse files
README.md
CHANGED
|
@@ -50,6 +50,16 @@ model-index:
|
|
| 50 |
| 💬 General Thai chat and coding | [OpenThaiGPT 1.6 72B](https://huggingface.co/openthaigpt/openthaigpt-1.6-72b-instruct) |
|
| 51 |
| 💻 Limited GPU | [OpenThaiGPT 1.5 7B](https://huggingface.co/openthaigpt/openthaigpt1.5-7b-instruct) |
|
| 52 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 53 |
## Highlights
|
| 54 |
- **Advanced Thai language model** with 72 billion parameters
|
| 55 |
- **Strong reasoning capabilities** in both Thai and English
|
|
|
|
| 50 |
| 💬 General Thai chat and coding | [OpenThaiGPT 1.6 72B](https://huggingface.co/openthaigpt/openthaigpt-1.6-72b-instruct) |
|
| 51 |
| 💻 Limited GPU | [OpenThaiGPT 1.5 7B](https://huggingface.co/openthaigpt/openthaigpt1.5-7b-instruct) |
|
| 52 |
|
| 53 |
+
## âš¡ Run it locally
|
| 54 |
+
|
| 55 |
+
```bash
|
| 56 |
+
ollama run openthai/openthai-1.6-72b
|
| 57 |
+
```
|
| 58 |
+
|
| 59 |
+
Official GGUF quants (Q4_K_M / Q5_K_M / Q8_0):
|
| 60 |
+
[openthaigpt/openthaigpt-1.6-72b-instruct-GGUF](https://huggingface.co/openthaigpt/openthaigpt-1.6-72b-instruct-GGUF)
|
| 61 |
+
— ~48 GB RAM/VRAM in 4-bit. Step-by-step guide: [openthai.aieat.or.th/ollama](https://openthai.aieat.or.th/ollama)
|
| 62 |
+
|
| 63 |
## Highlights
|
| 64 |
- **Advanced Thai language model** with 72 billion parameters
|
| 65 |
- **Strong reasoning capabilities** in both Thai and English
|