How to use from
llama.cpp
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh
# Start a local OpenAI-compatible server with a web UI:
llama serve -hf M37labsorg/ade-extract-3b-v1:Q4_K_M
# Run inference directly in the terminal:
llama cli -hf M37labsorg/ade-extract-3b-v1:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama serve -hf M37labsorg/ade-extract-3b-v1:Q4_K_M
# Run inference directly in the terminal:
llama cli -hf M37labsorg/ade-extract-3b-v1:Q4_K_M
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 M37labsorg/ade-extract-3b-v1:Q4_K_M
# Run inference directly in the terminal:
./llama-cli -hf M37labsorg/ade-extract-3b-v1:Q4_K_M
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 M37labsorg/ade-extract-3b-v1:Q4_K_M
# Run inference directly in the terminal:
./build/bin/llama-cli -hf M37labsorg/ade-extract-3b-v1:Q4_K_M
Use Docker
docker model run hf.co/M37labsorg/ade-extract-3b-v1:Q4_K_M
Quick Links

ade-extract-3b-v1

Published by M37 Labs (M37labsorg), the organisation of Hugging Face user engagepy, who maintains it. Built with SLM Forge.

Fine-tuned locally with SLM Forge on 2026-09-25.

Goal: Rebuild ADE Extract as a consistent JSON-only information extractor: report only facts explicitly stated in the text, use null for missing optional details, and return an empty events list when no adverse effect is stated. Train a clean adapter from the original base; treat the result as an experimental extraction aid, not medical advice, and do not claim commercial clearance for the ADE Corpus v2 data unless its license is verified. Base model: mlx-community/Qwen2.5-3B-Instruct-4bit Runs on: Apple Silicon Macs with 8 GB unified memory or more.

Lineage

  1. SFT (job 50): train_loss 0.018, peak_mem_gb 7.15, val_loss_start 0.875, val_loss 0.025

Usage

pip install mlx-lm
mlx_lm.generate --model M37labsorg/ade-extract-3b-v1 --prompt "Hello"

Recommended sampling

{
  "temperature": 0.7,
  "top_p": 0.95
}

System prompt

Extract only what the text explicitly states. Return only valid JSON in exactly this shape: {"events":[{"drug":null,"adverse_effect":"...","evidence_span":"...","severity":null,"dosage":null,"action_taken":null}]}. Include one event per explicitly described adverse effect. Fill drug, adverse_effect, severity, dosage, and action_taken only when each is stated in the text; otherwise use JSON null. Do not infer a drug-event link from timing alone, or infer causality, severity, dosage, or actions. Quote the shortest exact, contiguous evidence span supporting the event. If no adverse effect is stated, return {"events":[]}. This is an extraction aid, not medical advice.

Run it anywhere (GGUF)

GGUF builds of this model, for llama.cpp, Ollama and LM Studio:

  • ade-extract-3b-v3-Q4_K_M.gguf (Q4_K_M, 1.80 GB)
  • ade-extract-3b-v3-Q8_0.gguf (Q8_0, 3.06 GB)
llama-cli -m ade-extract-3b-v3-Q4_K_M.gguf -p "Hello"   # llama.cpp
ollama run hf.co/M37labsorg/ade-extract-3b-v1:Q4_K_M   # Ollama

In LM Studio, search for the repository or load the .gguf file.

Licence & attribution

This model is a fine-tune of mlx-community/Qwen2.5-3B-Instruct-4bit and is subject to its licence: Qwen Research licence (https://huggingface.co/Qwen/Qwen2.5-3B-Instruct/blob/main/LICENSE).

What it asks of you: Research and non-commercial use only; a commercial use needs a licence from Alibaba Cloud.

See LICENSE-BASE-MODEL.md, and the base model's own licence files where they could be included, in this folder.

Intended use & limitations

A small model fine-tuned for one narrow task on a few thousand examples. It makes mistakes, including confident ones. Check its outputs, and do not use it on its own for medical, legal, financial or safety-critical decisions.

Downloads last month
74
Safetensors
Model size
3B params
Tensor type
U32
·
F16
·
MLX
Hardware compatibility
Log In to add your hardware

4-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for M37labsorg/ade-extract-3b-v1

Base model

Qwen/Qwen2.5-3B
Adapter
(7)
this model