Downloads · 30 days
286
8% of all-time downloads
RichardErkhov/matsant01_-_STEMerald-2b-gguf
matsant01_-_STEMerald-2b-gguf is a machine learning model from RichardErkhov. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
Downloads · 30 days
286
8% of all-time downloads
All-time downloads
3.6K
Public
Repo size
30.7 GB
Likes
0
Public
Click a slice to open those files.
.gguf35.6 GB · 100%
From the Hugging Face model README
Quantization made by Richard Erkhov.
STEMerald-2b - GGUF
| Name | Quant method | Size |
|---|---|---|
| STEMerald-2b.Q2_K.gguf | Q2_K | 1.08GB |
| STEMerald-2b.IQ3_XS.gguf | IQ3_XS | 1.16GB |
| STEMerald-2b.IQ3_S.gguf | IQ3_S | 1.2GB |
| STEMerald-2b.Q3_K_S.gguf | Q3_K_S | 1.2GB |
| STEMerald-2b.IQ3_M.gguf | IQ3_M | 1.22GB |
| STEMerald-2b.Q3_K.gguf | Q3_K | 1.29GB |
| STEMerald-2b.Q3_K_M.gguf | Q3_K_M | 1.29GB |
| STEMerald-2b.Q3_K_L.gguf | Q3_K_L | 1.36GB |
| STEMerald-2b.IQ4_XS.gguf | IQ4_XS | 1.4GB |
| STEMerald-2b.Q4_0.gguf | Q4_0 | 1.44GB |
| STEMerald-2b.IQ4_NL.gguf | IQ4_NL | 1.45GB |
| STEMerald-2b.Q4_K_S.gguf | Q4_K_S | 1.45GB |
| STEMerald-2b.Q4_K.gguf | Q4_K | 1.52GB |
| STEMerald-2b.Q4_K_M.gguf | Q4_K_M | 1.52GB |
| STEMerald-2b.Q4_1.gguf | Q4_1 | 1.56GB |
| STEMerald-2b.Q5_0.gguf | Q5_0 | 1.68GB |
| STEMerald-2b.Q5_K_S.gguf | Q5_K_S | 1.68GB |
| STEMerald-2b.Q5_K.gguf | Q5_K | 1.71GB |
| STEMerald-2b.Q5_K_M.gguf | Q5_K_M | 1.71GB |
| STEMerald-2b.Q5_1.gguf | Q5_1 | 1.79GB |
| STEMerald-2b.Q6_K.gguf | Q6_K | 1.92GB |
| STEMerald-2b.Q8_0.gguf | Q8_0 | 2.49GB |
language: en license: apache-2.0 datasets:
Model name: STEMerald-2b
Model description: STEMerald-2b is a fine-tuned version of the Gemma-2b model, designed specifically for answering university-level STEM multiple-choice questions. This model leverages advanced fine-tuning techniques, including Supervised Fine-Tuning (SFT) and Direct Preference Optimization (DPO), to enhance its accuracy and reliability in providing educational support.
<p align="center"> <img src="STEMerald_pic.jpeg" alt="STEMerald picture" width="400"/> </p>Base Model: Gemma-2b
Architecture: Decoder-only Language Model (Causal)
Parameters: 2.51 billion
Quantized Version: STEMerald-2b-4bit (with 4-bit NormalFloat)
Training Framework: PyTorch with Hugging Face Transformers
The model was fine-tuned on a variety of datasets tailored for STEM education, including:
The training process for STEMerald-2b involved multiple steps:
The performance of STEMerald-2b was evaluated using various metrics:
| Model Version | Accuracy (Non-Quantized) | Accuracy (Quantized) |
|---|---|---|
| it-ORCA-DPO-MCQA (STEMerald-2b) | 0.750 | 0.720 |
| it-DPO-MCQA | 0.744 | 0.720 |
| it-MCQA | 0.736 | 0.700 |
| it-ORCA-MCQA | 0.722 | 0.714 |
| MCQA | 0.702 | 0.654 |
| DPO-MCQA | 0.694 | 0.674 |
| Gemma-it-OneShot | 0.546 | 0.520 |
| Gemma-it | 0.518 | 0.518 |
Micro-averaged accuracy over three MCQA test sets(EPFL MCQA, ScienceQA and ARC).
STEMerald-2b can be utilized as a STEM course assistant, providing support in areas such as:
While STEMerald-2b aims to provide accurate and helpful responses, it is important to consider potential ethical implications:
STEMerald-2b offers a promising solution for enhancing STEM education through advanced language model capabilities. By leveraging fine-tuning techniques and comprehensive datasets, it aims to provide accurate and accessible learning support for students.
You can use the model directly with the transformers library:
from transformers import AutoModelForCausalLM, AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("matsant01/STEMerald-2b")
model = AutoModelForCausalLM.from_pretrained("matsant01/STEMerald-2b")
input_text = "Question: What is the derivative of x^2? \nOptions: A. 4x B. 2*x^2 C. 2x D. 2\nAnswer:"
inputs = tokenizer(input_text, return_tensors="pt")
outputs = model.generate(**inputs)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
For the quantized version, use:
from transformers import AutoModelForCausalLM, AutoTokenizer, BitsAndBytesConfig
quantization_config = BitsAndBytesConfig(
load_in_4bit=True,
bnb_4bit_compute_dtype=torch.bfloat16,
bnb_4bit_quant_type="nf4"
)
tokenizer = AutoTokenizer.from_pretrained("matsant01/STEMerald-2b-4bit")
model = AutoModelForCausalLM.from_pretrained("matsant01/STEMerald-2b-4bit", quantization_config=quantization_config)
We acknowledge the contributions of the EPFL and Stack Exchange communities for their invaluable datasets, and the Hugging Face team for their support and tools that made this project possible.
For any questions or feedback, please contact: