Cinephile Mistral LoRA

This model is a LoRA (Low-Rank Adaptation) fine-tuned adapter built on top of Mistral-7B-Instruct v0.2 to generate responses in the style of a cinephile โ€” emotionally aware, analytical, and expressive about films.


Important Note

This repository contains ONLY LoRA adapter weights, not the full model.

  • This model cannot run independently
  • You must load the base model first and then apply this adapter

Base Model

Model: mistralai/Mistral-7B-Instruct-v0.2
Type: Instruction-tuned large language model
Parameters: ~7B


What This Model Does

After applying this adapter, the model:

  • Recommends movies with deeper reasoning
  • Analyzes themes, emotions, and storytelling
  • Responds like a cinephile or film critic
  • Uses expressive and immersive language

Requirements

pip install transformers peft accelerate torch

Usage

from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
import torch

base_model_name = "mistralai/Mistral-7B-Instruct-v0.2"
lora_model_name = "prathamesh0710/cinephile-mistral-lora"

# Load tokenizer
tokenizer = AutoTokenizer.from_pretrained(base_model_name)

# Load base model
base_model = AutoModelForCausalLM.from_pretrained(
    base_model_name,
    torch_dtype=torch.float16,
    device_map="auto"
)

# Load LoRA adapter
model = PeftModel.from_pretrained(base_model, lora_model_name)

# Format prompt
def format_prompt(user_input):
    return f"<s>[INST] {user_input} [/INST]"

# Optional: stronger cinephile personality
# def format_prompt(user_input):
#     return f"<s>[INST] You are a passionate cinephile. {user_input} [/INST]"

# Run inference
prompt = format_prompt("Suggest a movie like Fight Club")

inputs = tokenizer(prompt, return_tensors="pt").to("cuda")

outputs = model.generate(
    **inputs,
    max_new_tokens=200,
    temperature=0.7,
    top_p=0.9
)

print(tokenizer.decode(outputs[0], skip_special_tokens=True))

Performance Tips

  • Use GPU (CUDA) for best performance
  • Use float16 to reduce memory usage

Tune:

  • temperature โ†’ creativity
  • top_p โ†’ diversity
  • max_new_tokens โ†’ response length

Training Details

  • Method: LoRA (QLoRA, 4-bit)
  • Dataset Size: ~2,279 samples
    • ~2,000 movie-related
    • ~279 personality-based
  • Goal: Style tuning (cinephile personality), not knowledge expansion

Limitations

  • Not a full movie knowledge base
  • May hallucinate details
  • Focuses more on tone and expression than factual accuracy

Why LoRA Instead of Full Model

  • Much smaller (~100MB vs ~13GB)
  • Faster to load
  • Easier to fine-tune
  • Requires base model to run

Summary

This is a lightweight cinephile personality layer on top of Mistral.

Mistral โ€” but speaking like a film critic.


Acknowledgements

  • Base model: Mistral AI
  • Fine-tuning: LoRA using Hugging Face ecosystem
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for prathamesh0710/cinephile-mistral-lora

Adapter
(1200)
this model