πŸ₯€ Hot Coco: Grab a Hot Coco and Start Coding

Never train an AI model again. Hot Coco is your personal, on-demand expert for PyTorch, Hugging Face Transformers, and Machine Learning.

Built on Mistral-7B and fine-tuned with QLoRA, Hot Coco skips the fluff and gets straight to the code. Whether you are debugging a CUDA error or architecting a new Transformer, just grab a Hot Coco and start coding.

πŸš€ Why Hot Coco?

  • 🎯 Specialized Expertise: Trained exclusively on high-quality PyTorch and ML data.
  • ⚑ Lightweight & Fast: Uses 4-bit quantization (QLoRA) to run smoothly on consumer hardware.
  • 🧠 Long Context: Handles up to 32k tokens, perfect for pasting entire scripts for debugging.
  • πŸ”’ Private & Secure: Keep your proprietary code safe by running it locally.

πŸ› οΈ Quick Start

1. Install Dependencies

pip install transformers peft accelerate bitsandbytes torch

2. Load Hot Coco

import torch
from transformers import AutoModelForCausalLM, AutoTokenizer, BitsAndBytesConfig
from peft import PeftModel
from huggingface_hub import login

# Authenticate for private repo access
login(token="YOUR_HF_TOKEN")

base_model_id = "mistralai/Mistral-7B-Instruct-v0.2"
adapter_id = "Raspberry-Pie/Hot-Coco"

# Configure 4-bit loading for efficiency
bnb_config = BitsAndBytesConfig(
    load_in_4bit=True,
    bnb_4bit_quant_type="nf4",
    bnb_4bit_compute_dtype=torch.float16
)

tokenizer = AutoTokenizer.from_pretrained(base_model_id)
base_model = AutoModelForCausalLM.from_pretrained(
    base_model_id,
    quantization_config=bnb_config,
    device_map="auto"
)

# Merge Hot Coco's expertise
model = PeftModel.from_pretrained(base_model, adapter_id)

3. Start Coding

prompt = "<s>[INST] Write a PyTorch training loop with gradient clipping. [/INST]"
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")

outputs = model.generate(**inputs, max_new_tokens=512)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))

πŸ“ Training Details

  • Base: Mistral-7B-Instruct-v0.2
  • Method: QLoRA (4-bit NF4)
  • Data: 1,800 curated examples from CodeAlpaca + Custom Identity Injection
  • Hardware: Trained on Kaggle T4 x2 GPUs

Built with ❀️ by Raspberry-Pie

Downloads last month
66
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for Raspberry-Pie/Hot-Coco

Adapter
(1195)
this model