Turkish-Llama3-8B-Merged
Turkish-Llama3-8B-Merged is a merge of the following models using LazyMergekit:
- meta-llama/Meta-Llama-3-8B
- ytu-ce-cosmos/Turkish-Llama-8b-Instruct-v0.1
- ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1
π§© Configuration
base_model: meta-llama/Meta-Llama-3-8B
models:
- model: meta-llama/Meta-Llama-3-8B # Base model (retain strong foundational performance)
parameters:
weight: 1.0
- model: ytu-ce-cosmos/Turkish-Llama-8b-Instruct-v0.1 # High-quality Turkish instruction tuning
parameters:
weight: 0.7 # Increased weight for better instruction following
- model: ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1 # DPO-tuned for Turkish preferences
parameters:
weight: 0.5 # Balanced for alignment
# LoRA Adapters (focused on Turkish language/culture)
adapters:
- model: Yudum/llama3-lora-turkish # Core Turkish fine-tuning
parameters:
weight: 0.8 # Highest priority (language fundamentals)
- model: Yudum/Meta-Llama-3-8B-Instruct_tr_wiki_tr_wiki_mix # Turkish Wikipedia knowledge
parameters:
weight: 0.6 # Boost cultural/encyclopedic knowledge
- model: Kasimyildirim/Qwen2-turkish-comnibed-v5-lora # Additional Turkish data mix
parameters:
weight: 0.4 # Complementary reinforcement
merge_method: ties
parameters:
density: 0.5 # Slightly lower density to reduce noise
weight: 0.9 # Stronger weight retention for Turkish features
normalize: true
dtype: bfloat16
π» Usage
!pip install -qU transformers accelerate
from transformers import AutoTokenizer
import transformers
import torch
model = "matrixportal/Turkish-Llama3-8B-Merged"
messages = [{"role": "user", "content": "What is a large language model?"}]
tokenizer = AutoTokenizer.from_pretrained(model)
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
pipeline = transformers.pipeline(
"text-generation",
model=model,
torch_dtype=torch.float16,
device_map="auto",
)
outputs = pipeline(prompt, max_new_tokens=256, do_sample=True, temperature=0.7, top_k=50, top_p=0.95)
print(outputs[0]["generated_text"])
- Downloads last month
- 30
Inference Providers
NEW
This model isn't deployed by any Inference Provider.
π
Ask for provider support
Model tree for matrixportal/Turkish-Llama3-8B-Merged
Merge model
this model