tbilisi-ai-lab/kona-sft-mix-2.6M
Viewer • Updated • 2.61M • 1.11k • 1
How to use tbilisi-ai-lab/kona2-12B-Instruct with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="tbilisi-ai-lab/kona2-12B-Instruct")
messages = [
{"role": "user", "content": "Who are you?"},
]
pipe(messages) # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("tbilisi-ai-lab/kona2-12B-Instruct")
model = AutoModelForCausalLM.from_pretrained("tbilisi-ai-lab/kona2-12B-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]:]))How to use tbilisi-ai-lab/kona2-12B-Instruct with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "tbilisi-ai-lab/kona2-12B-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": "tbilisi-ai-lab/kona2-12B-Instruct",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/tbilisi-ai-lab/kona2-12B-Instruct
How to use tbilisi-ai-lab/kona2-12B-Instruct with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "tbilisi-ai-lab/kona2-12B-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": "tbilisi-ai-lab/kona2-12B-Instruct",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'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 "tbilisi-ai-lab/kona2-12B-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": "tbilisi-ai-lab/kona2-12B-Instruct",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'How to use tbilisi-ai-lab/kona2-12B-Instruct with Docker Model Runner:
docker model run hf.co/tbilisi-ai-lab/kona2-12B-Instruct
Kona2-12B-Instruct is a 12-billion parameter instruction-tuned language model for Georgian and English. Built on Kona2-12B-Base through supervised fine-tuning (SFT), it excels at chat, question answering, and function calling.
| Property | Value |
|---|---|
| Parameters | 12B |
| Architecture | Mistral (Transformer) |
| Context Length | 32K tokens |
| Languages | Georgian (ka), English (en), other (limited) |
| Training | Supervised Fine-Tuning (SFT) |
| Training Examples | ~2.8M instructions |
| Function Calling | Yes (Hermes format) |
| Base Model | kona2-12B-Base |
| Dataset | Examples | Description |
|---|---|---|
| kona-sft-mix-2.6M | 2,606,173 | Mixed instruction dataset (KA/EN) |
| kona-sft-function-calling-115k | ~115K | Function calling (English) |
| kona-sft-function-calling-ka-93k | ~93K | Function calling (Georgian) |
Data Sources Include:
pip install transformers torch accelerate
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained(
"tbilisi-ai-lab/kona2-12B-Instruct",
torch_dtype="auto",
device_map="auto"
)
tokenizer = AutoTokenizer.from_pretrained("tbilisi-ai-lab/kona2-12B-Instruct")
messages = [
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "რა არის საქართველოს დედაქალაქი?"}
]
inputs = tokenizer.apply_chat_template(
messages,
return_tensors="pt",
add_generation_prompt=True
).to(model.device)
outputs = model.generate(inputs, max_new_tokens=256, temperature=0.7)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
See the tokenizer's jinja template (tokenizer_config.json) for details on how function calling is formatted.
tools = [
{
"type": "function",
"function": {
"name": "get_weather",
"description": "Get current weather for a location",
"parameters": {
"type": "object",
"properties": {
"location": {"type": "string", "description": "City name"}
},
"required": ["location"]
}
}
}
]
messages = [
{"role": "system", "content": "You are a helpful assistant with access to tools."},
{"role": "user", "content": "What's the weather in Tbilisi?"}
]
inputs = tokenizer.apply_chat_template(
messages,
tools=tools,
return_tensors="pt",
add_generation_prompt=True
).to(model.device)
outputs = model.generate(inputs, max_new_tokens=256)
# Output will include <tool_call>{"name": "get_weather", "arguments": {"location": "Tbilisi"}}</tool_call>
| Model | Description |
|---|---|
| kona2-12B-Base | Pre-trained base model |
| kona2-12B | DPO-aligned version (recommended) |
| kona2-small-3.8B | Smaller 3.8B model |
@misc{tbilisi2025kona2instruct,
title = {Kona2-12B-Instruct: A Georgian Instruction-Tuned Language Model},
author = {Tbilisi AI Lab Team},
year = {2025},
publisher = {Hugging Face},
howpublished = {\url{https://huggingface.co/tbilisi-ai-lab/kona2-12B-Instruct}}
}
This model is released under the Apache 2.0 License.
Base model
mistralai/Mistral-Nemo-Base-2407