anupamaditya/dia-therapy-dataset
Viewer β’ Updated β’ 9.85k β’ 5
How to use iteshxt/dia-convo-v1.2c with Unsloth Studio:
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for iteshxt/dia-convo-v1.2c to start chatting
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for iteshxt/dia-convo-v1.2c to start chatting
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for iteshxt/dia-convo-v1.2c to start chatting
pip install unsloth
from unsloth import FastModel
model, tokenizer = FastModel.from_pretrained(
model_name="iteshxt/dia-convo-v1.2c",
max_seq_length=2048,
)petrioteer/dia-convo-v1.2c is a conversational mental-health-focused LLM designed for Gen Z, built on top of Qwen2.5-7B-Instruct and fine-tuned using dia-therapy-dataset. This model powers Dia-Therapist, an empathetic AI that offers mental health support while being context-aware, brief, and emotionally intelligent.
This model is tuned to offer:
It does not replace professional therapy.
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
model_name = "petrioteer/dia-convo-v1.2c"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForCausalLM.from_pretrained(
model_name,
device_map="auto",
torch_dtype=torch.float16
)
prompt = """
### Instruction:
Your name is Dia, a mental health therapist Assistant Bot. Provide guidance on mental health topics only and avoid others. Don\'t give medical advice. Keep responses short and relevant.
### Input:
I'm feeling overwhelmed with my classes. I can't seem to focus.
### Response:
"""
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
outputs = model.generate(
**inputs,
max_new_tokens=100,
temperature=0.3,
top_p=0.85,
top_k=40,
do_sample=True,
eos_token_id=tokenizer.eos_token_id,
)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
from unsloth import FastLanguageModel
from transformers import AutoTokenizer
model_name = "petrioteer/dia-convo-v1.2c"
model, tokenizer = FastLanguageModel.from_pretrained(
model_name=model_name,
max_seq_length=2048,
load_in_4bit=True,
device_map="auto",
)
FastLanguageModel.for_inference(model)
prompt = """
### Instruction:
Your name is Dia, a mental health therapist Assistant Bot. Provide guidance on mental health topics only and avoid others. Don\'t give medical advice. Keep responses short and relevant.
### Input:
I just feel numb and disconnected from everyone lately.
### Response:
"""
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
outputs = model.generate(
**inputs,
max_new_tokens=100,
temperature=0.3,
top_p=0.85,
top_k=40,
do_sample=True,
repetition_penalty=1.2,
no_repeat_ngram_size=4,
eos_token_id=tokenizer.eos_token_id,
)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
If you use Dia-Convo in research, demos, or builds, consider citing or linking back to this repo and dataset authors.
Built with β€οΈ & care by Itesh (aka petrioteer) β¨