TurkishCodeMan - CSM-1B (LoRA Fine-tuned)
📌 Model Summary
This is a LoRA fine-tuned version of unsloth/csm-1b, trained for text-to-speech (TTS) tasks.
The model was trained using Unsloth for 2x faster finetuning and Hugging Face’s TRL library.
- Base Model:
unsloth/csm-1b
- Fine-tuning Method: LoRA
- Training Frameworks: Unsloth, TRL
- Dataset: TurkishCodeMan/tts-medium-clean
- Languages: English, Turkish
- License: Apache-2.0
🚀 Intended Use
- Convert text to high-quality speech.
- Research and experimentation in TTS models.
- Transfer learning and downstream fine-tuning.
⚠️ Not intended for harmful or malicious use (hate speech, deepfakes, etc.).
🛠️ Training Details
- Method: LoRA low-rank adaptation on transformer layers.
- Batch Size: 16 (8 × gradient_accumulation=2).
- Epochs: 3
- Trainable Parameters: ~29M of 1.66B (≈1.75% trained).
- Hardware: 1x GPU.
- Optimizer: AdamW.
- Learning Rate Schedule: Linear decay with warmup.
📊 Dataset
The model was fine-tuned on TurkishCodeMan/tts-medium-clean.
This dataset contains clean speech-text pairs suitable for TTS tasks.
🔧 How to Use
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained("TurkishCodeMan/csm-1b-tts-lora")
tokenizer = AutoTokenizer.from_pretrained("TurkishCodeMan/csm-1b-tts-lora")
text = "Hi !"
inputs = tokenizer(text, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=200)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))