Model Card for Model ID
LoRA weights for "mistralai_Mistral-7B-Instruct-v0.2"
Model Description
Fine-tuned model to talk like middle school students, using typos/grammar errors. Trained on student Q&As physics topics such as PE/KE/LCE including pulley/ramp examples.
- Developed by: Nora T
- Finetuned from model: mistralai_Mistral-7B-Instruct-v0.2
Additional Sources
- Repository: [More Information Needed]
- Paper [optional]: [More Information Needed]
- Demo [optional]: [More Information Needed]
How to Get Started:
- Load Mistral model first:
from peft import PeftModel # for fine-tuning
from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline, GenerationConfig, GPTQConfig, BitsAndBytesConfig
model_name_or_path = "mistralai/Mistral-7B-Instruct-v0.2"
nf4_config = BitsAndBytesConfig( # quantization 4-bit
load_in_4bit=True,
bnb_4bit_quant_type="nf4",
bnb_4bit_use_double_quant=True,
bnb_4bit_compute_dtype=torch.bfloat16
)
model = AutoModelForCausalLM.from_pretrained(model_name_or_path,
device_map="auto",
trust_remote_code=False,
quantization_config=nf4_config,
revision="main")
tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
- Load in LoRA weights:
lora_model_path = "{path_to_loras_folder}/mistralai_Mistral-7B-Instruct-v0.2-testgen-LoRAs" # load loras
model = PeftModel.from_pretrained(
model, lora_model_path, torch_dtype=torch.float16, force_download=True,
)
Direct Use
Recommendations
Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
Training Hyperparams
- LoRA Rank: 128
- LoRA Alpha: 32
- Batch Size: 64
- Cutoff Length: 256
- Learning rate: 3e-4
- Epochs: 4
- LoRA Dropout: 0.05
Training Data
Trained on raw text file
Training Procedure
Trained using an open-source web-ui:
Training Hyperparameters
- Training regime: [More Information Needed]
Testing Data, Factors & Metrics
Model Examination [optional]
Technical Specifications [optional]
Compute Infrastructure
[More Information Needed]
Hardware Requirements
[More Information Needed]
Citation [optional]
Framework versions
- PEFT 0.7.1
- Downloads last month
- 0
Model tree for ntseng/mistralai_Mistral-7B-Instruct-v0.2-testgen-LoRAs
Base model
mistralai/Mistral-7B-Instruct-v0.2