Run this model with HF Jobs
Run Akash1207/llama-3.2-3b-classification-merged on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/Akash1207/llama-3.2-3b-classification-merged. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/Akash1207/llama-3.2-3b-classification-merged on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/Akash1207/llama-3.2-3b-classification-merged. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/Akash1207/llama-3.2-3b-classification-merged. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use Akash1207/llama-3.2-3b-classification-merged with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Akash1207/llama-3.2-3b-classification-merged with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Akash1207/llama-3.2-3b-classification-merged") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Akash1207/llama-3.2-3b-classification-merged") model = AutoModelForCausalLM.from_pretrained("Akash1207/llama-3.2-3b-classification-merged", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Akash1207/llama-3.2-3b-classification-merged with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Akash1207/llama-3.2-3b-classification-merged" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Akash1207/llama-3.2-3b-classification-merged", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Akash1207/llama-3.2-3b-classification-merged
- SGLang
How to use Akash1207/llama-3.2-3b-classification-merged with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Akash1207/llama-3.2-3b-classification-merged" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Akash1207/llama-3.2-3b-classification-merged", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Akash1207/llama-3.2-3b-classification-merged" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Akash1207/llama-3.2-3b-classification-merged", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Unsloth Desktop
- Docker Model Runner
How to use Akash1207/llama-3.2-3b-classification-merged with Docker Model Runner:
docker model run hf.co/Akash1207/llama-3.2-3b-classification-merged
Llama 3.2 3B โ Fine-Tuned Language Model
Developed by: Akash1207
Base Model: unsloth/Llama-3.2-3B-Instruct-bnb-4bit
Model Architecture: Llama 3.2
Parameters: 3 Billion
Fine-Tuning Framework: Unsloth
Training Library: Hugging Face Transformers & TRL
Model Task: Text Generation / Instruction Following
Language: English
1. Model Overview
This repository contains a fine-tuned version of the Llama 3.2 3B Instruct language model, developed using the Unsloth framework and Hugging Face TRL library.
The primary objective of this project is to explore the practical implementation of Large Language Model (LLM) fine-tuning, understand Transformer-based architectures, and experiment with adapting pretrained language models for specialized tasks.
The model builds upon the pretrained capabilities of Llama 3.2 3B and undergoes additional training to adapt its responses to the fine-tuning dataset and target objectives.
The training workflow leverages Unsloth's optimized implementation, which supports up to 2ร faster fine-tuning compared with conventional implementations under supported configurations.
2. Base Model Information
This model is fine-tuned from:
Base Model: Unsloth/Llama-3.2-3B-Instruct-bnb-4bit
| Attribute | Details |
|---|---|
| Model Family | Llama 3.2 |
| Parameters | 3 Billion |
| Architecture | Transformer |
| Model Type | Causal Language Model |
| Base Model | Llama 3.2 3B Instruct |
| Base Precision | 4-bit quantized |
| Language | English |
| Fine-Tuning | Supervised fine-tuning workflow |
| Framework | Unsloth |
| Training Library | Hugging Face TRL |
3. Technologies and Frameworks
The following technologies were used in the model development workflow.
- Unsloth: Optimized framework for efficient Large Language Model fine-tuning.
- Hugging Face Transformers: Model loading, tokenization and text generation.
- Hugging Face TRL: Training infrastructure for language model fine-tuning.
- PyTorch: Deep learning framework.
- Hugging Face Hub: Model hosting, versioning and distribution.
4. Fine-Tuning Workflow
The model development process follows a pretrained-model fine-tuning workflow.
Training Pipeline
- Load the pretrained Llama 3.2 3B Instruct model.
- Initialize the tokenizer and model configuration.
- Prepare the training dataset.
- Configure the fine-tuning process.
- Apply the selected fine-tuning strategy.
- Train the model using the Unsloth-optimized workflow.
- Save the fine-tuned model.
- Upload the model artifacts to Hugging Face Hub.
- Evaluate the model using test samples.
Training Objective
The primary objective is to adapt the pretrained language model to the target dataset while exploring efficient fine-tuning techniques and understanding how pretrained Transformer models can be specialized for downstream applications.
5. Model Evaluation
The fine-tuned model was evaluated using a sample-based classification task involving three predefined categories.
Target Categories
SALES_TEAMTECH_TEAMSUPPORT_TEAM
The evaluation measures whether the generated model output correctly matches the expected category.
Overall Performance
| Metric | Result |
|---|---|
| Total Test Samples | 10 |
| Correct Predictions | 6 |
| Incorrect Predictions | 4 |
| Overall Accuracy | 60% |
| Error Rate | 40% |
Accuracy
The model achieved an overall accuracy of:
60% (6 correct predictions out of 10 test samples).
Class-wise Evaluation
| Category | Correct | Total | Recall |
|---|---|---|---|
| SALES_TEAM | 3 | 3 | 100% |
| TECH_TEAM | 0 | 4 | 0% |
| SUPPORT_TEAM | 3 | 3 | 100% |
Confusion Matrix
The following matrix represents the observed predictions.
| Actual / Predicted | SALES | TECH | SUPPORT |
|---|---|---|---|
| SALES_TEAM | 3 | 0 | 0 |
| TECH_TEAM | 1 | 0 | 3 |
| SUPPORT_TEAM | 0 | 0 | 3 |
Evaluation Observations
The evaluation reveals the following findings:
- The model correctly identified all tested SALES_TEAM samples.
- The model correctly identified all tested SUPPORT_TEAM samples.
- The model struggled to identify TECH_TEAM samples.
- TECH_TEAM samples were incorrectly classified as either SALES_TEAM or SUPPORT_TEAM.
- The model did not generate TECH_TEAM as a prediction in the evaluation samples.
These results indicate that the model requires further optimization, particularly in distinguishing technical-team-related inputs from support-related and sales-related inputs.
6. Performance Analysis
The initial evaluation demonstrates that the model can recognize certain target categories successfully, but its classification performance is not yet consistent across all categories.
The most significant challenge is the identification of TECH_TEAM samples.
Potential areas for improvement include:
- Improving dataset balance.
- Increasing the number of training samples.
- Improving the diversity of technical-team examples.
- Reducing ambiguity between TECH_TEAM and SUPPORT_TEAM.
- Experimenting with different training configurations.
- Evaluating the model using a larger unseen test dataset.
7. Intended Use Cases
This model is intended for:
- Large Language Model fine-tuning experiments.
- Natural Language Generation.
- Instruction-following experiments.
- Conversational AI development.
- Text classification experimentation.
- Transformer architecture research and learning.
- Educational and personal AI/ML projects.
8. Limitations
The model has several limitations that should be considered.
- The evaluation dataset currently contains only 10 test samples.
- Classification performance varies significantly across target categories.
- TECH_TEAM identification requires further improvement.
- The model may generate incorrect or misleading outputs.
- The model may inherit biases and limitations from its pretrained base model.
- Performance on larger, unseen datasets has not yet been established.
The reported evaluation metrics should be treated as preliminary rather than as evidence of production-level performance.
9. Future Improvements
Potential future development directions include:
- Expanding the training and evaluation datasets.
- Improving category representation and data quality.
- Experimenting with different fine-tuning configurations.
- Performing systematic hyperparameter optimization.
- Comparing the pretrained model against the fine-tuned model.
- Evaluating precision, recall and F1-score on a larger test set.
- Testing generalization on previously unseen samples.
10. Acknowledgements
This project builds upon the work of the open-source AI community.
Special thanks to:
These tools and resources make efficient experimentation with modern Large Language Models more accessible.
11. Developer Information
Developed by: Akash1207
Hugging Face: https://huggingface.co/Akash1207
Project Area: Artificial Intelligence and Machine Learning
Focus Areas:
- Large Language Models
- Transformer Architectures
- LLM Fine-Tuning
- Generative AI
- Deep Learning
This project represents a practical exploration of efficient Large Language Model fine-tuning using Unsloth and the Hugging Face ecosystem.
- Downloads last month
- -
Model tree for Akash1207/llama-3.2-3b-classification-merged
Base model
meta-llama/Llama-3.2-3B-Instruct