Instructions to use MadlabOSS/LFM2-2.6B-SDG-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="MadlabOSS/LFM2-2.6B-SDG-GGUF", filename="LFM2-2.6B-SDG-f16.gguf", )
llm.create_chat_completion( messages = "No input example has been defined for this model task." )
- Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16 # Run inference directly in the terminal: llama-cli -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16 # Run inference directly in the terminal: llama-cli -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16 # Run inference directly in the terminal: ./llama-cli -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Use Docker
docker model run hf.co/MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
- LM Studio
- Jan
- Ollama
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with Ollama:
ollama run hf.co/MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
- Unsloth Studio new
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for MadlabOSS/LFM2-2.6B-SDG-GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for MadlabOSS/LFM2-2.6B-SDG-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for MadlabOSS/LFM2-2.6B-SDG-GGUF to start chatting
- Pi new
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "MadlabOSS/LFM2-2.6B-SDG-GGUF:F16" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Run Hermes
hermes
- Docker Model Runner
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with Docker Model Runner:
docker model run hf.co/MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
- Lemonade
How to use MadlabOSS/LFM2-2.6B-SDG-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull MadlabOSS/LFM2-2.6B-SDG-GGUF:F16
Run and chat with the model
lemonade run user.LFM2-2.6B-SDG-GGUF-F16
List all available models
lemonade list
Madlab Synthetic Data Generator
π§ Overview
The Madlab SDG 2.6B is part of the MadlabOSS Synthetic Data Generator family β a suite of small, efficient synthetic data generators designed for ruleβconsistent, semantically coherent variation.
This model was trained on a closed-source dataset created through a multi-stage synthetic data generation process using a modified Madlab training pipeline.
π Intended Use
This model is optimized for:
- Madlab synthetic data generation
It is not intended as a general-purpose chatbot.
π§© Model Details
Base Model: LFM2-2.6B
Parameter Count: 2.6 Billion
Training Type: Supervised fine-tuning
Sequence Length: 1024
Precision: FP16
Framework: PyTorch / Transformers
π¦ Training Data
The model was trained on:
- 1444 compressed and encoded dataset pairs
- High variation in output
- Preservation of semantic meaning
- Data entirely generated with Madlab
ποΈ Training Procedure
Hyperparameters
- Epochs: 6
- Batch size: 48
- Learning rate: cosine schedule, peak ~4e-5
- Optimizer: AdamW
- Gradient clipping: 1.0
- Gradient accumulation: 1
Hardware
Training was performed on:
- RTX 6000 Blackwell (96GB)
π Evaluation
Synthetic Data Expansion Benchmark
A curated set of 30 input/target pairs was programmatically expanded using a Python script.
Metrics include seed pairs covered, total variation count, and semantic quality.
The task is to generate 5 variations of each incoming pair.
| Run | Model | Semantic Quality | Variations | Seeds Covered | Efficiency (Variations/Param) | Dataset |
|---|---|---|---|---|---|---|
| 1 | LFM2-350M-16 | 6.5 | 94 | 23 | 268.57 | Madlab sdg small |
| 2 | LFM2-350M-16 | 3.5 | 46 | 11 | 131.43 | base model |
| 3 | LFM2-350M-f16 | 6.5 | 97 | 22 | 277.14 | Madlab sdg small |
| 4 | Qwen3-coder-30B-instruct-q8 | 8.2 | 149 | 26 | 4.97 | base model |
| 5 | LFM2-350M-f16 | 7.5 | 136 | 21 | 388.57 | Madlab sdg medium |
| 6 | LFM2-2.6B-f16 | 9.0 | 137 | 25 | 52.69 | Madlab sdg medium |
| 7 | LFM2-2.6B-f16 | 9.9 | 180 | 25 | 69.23 | Madlab sdg large |
| 8 | LFM2-2.6B-f16 | 6.2 | 157 | 20 | 60.38 | Madlab sdg test |
| 9 | LFM2-2.6B-f16 | 10.0 | 248 | 27 | 95.38 | Madlab sdg large |
| 10 | Qwen3-235B-q3-k_m | 9.5 | 150 | 27 | 0.64 | base model |
| 11 | LFM2.5-1.2B-instruct-f16 | 9.1 | 244 | 30 | 203.33 | Madlab sdg large |
Qualitative Behavior
- Overperforms in variation count
- Maintains strict semantic correctness
π Safety
This model is a synthetic data generator. It is not designed for conversational use and is not suitable for anything other than generating synthetic datasets.
It is not designed for:
- Political advice
- Medical advice
- Legal advice
- General-purpose conversation
β οΈ Limitations
- Not a general assistant
- Not trained for coding, math, or open-domain reasoning
- May refuse tasks outside the Madlab SDG scope
- Downloads last month
- 27
16-bit