Downloads · 30 days
7
4% of all-time downloads
dheeyantra/dhee-chat-mistral-ml
dhee-chat-mistral-ml is a machine learning model from dheeyantra. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as apache-2.0.
A fine-tuned Malayalam conversational model based on mistralai/Mistral-7B-v0.3 , optimized for Malayalam language understanding and generation.
Downloads · 30 days
7
4% of all-time downloads
All-time downloads
157
Public
Parameters
7.2B
14.5 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors14.5 GB · 100%
From the Hugging Face model README
A fine-tuned Malayalam conversational model based on mistralai/Mistral-7B-v0.3 , optimized for Malayalam language understanding and generation.
ai4bharat/indic-aligndheeyantra/dhee-chat-mistral-mlThis model is intended for use in Malayalam conversational applications, such as chatbots and virtual assistants. As it is fine-tuned on the ai4bharat/indic-align dataset, its knowledge and conversational style are primarily shaped by this data.
Limitations:
You can use the following Python code to load and run inference with the dheeyantra/dhee-chat-mistral-ml model:
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
model_path = "dheeyantra/dhee-chat-mistral-ml"
# Load tokenizer and model
tokenizer = AutoTokenizer.from_pretrained(model_path)
model = AutoModelForCausalLM.from_pretrained(model_path)
# Move model to GPU if available
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
model.to(device)
# Prepare chat messages
messages = [
{"role": "User", "content": "എത്ര വേദങ്ങളുണ്ട്?"},
{"role": "Dhee", "content": "നാല് വേദങ്ങളുണ്ട്: ഋഗ്വേദം, യജുർവേദം, സാമവേദം, അഥർവവേദം."},
{"role": "User", "content": "ഋഗ്വേദത്തെക്കുറിച്ച് കൂടുതൽ പറയൂ?"}
]
# Apply chat template to get prompt
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
# Tokenize prompt
inputs = tokenizer(prompt, return_tensors="pt").to(device)
# Generate output
with torch.no_grad():
output_ids = model.generate(
**inputs,
max_new_tokens=64,
do_sample=True,
temperature=0.9,
top_p=0.95,
pad_token_id=tokenizer.eos_token_id
)
# Decode generated text
generated_text = tokenizer.decode(output_ids[0][inputs['input_ids'].shape[-1]:], skip_special_tokens=True)
results = [{"generated_text": generated_text}]
print("Generated text:")
print(results[0]['generated_text'])
This model is provided as-is. Users should be aware of its potential limitations and biases before deploying it in any application. Responsible AI practices should be followed.
The model was fine-tuned using the following LoRA and training parameters:
r: 16target_modules: ["q_proj", "k_proj", "v_proj", "o_proj", "gate_proj", "up_proj", "down_proj"]lora_alpha: 16lora_dropout: 0bias: "none"use_gradient_checkpointing: "unsloth"use_rslora: Falseloftq_config: Nonegradient_accumulation_steps: 4warmup_ratio: 0.03fp16: Trueoptim: "adamw_8bit"max_seq_length: 32768We extend our sincere gratitude to the following organizations for their invaluable contributions to this project:
If you use this model in your research or applications, please cite:
@misc{dheenxtgen2025,
title={ dhee-chat-mistral-ml : A Compact Language Model for Malayalam},
author={Dheeyantra Research Labs},
year={2025},}
}