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 gopichand55k/MedIntel-AI:Q8_0
# Run inference directly in the terminal:
llama cli -hf gopichand55k/MedIntel-AI:Q8_0
Install from WinGet (Windows)
winget install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama serve -hf gopichand55k/MedIntel-AI:Q8_0
# Run inference directly in the terminal:
llama cli -hf gopichand55k/MedIntel-AI:Q8_0
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git
cd llama.cpp
cmake -B build
cmake --build build -j --target llama-app
# Start a local OpenAI-compatible server with a web UI:
./build/bin/llama serve -hf gopichand55k/MedIntel-AI:Q8_0
# Run inference directly in the terminal:
./build/bin/llama cli -hf gopichand55k/MedIntel-AI:Q8_0
Use Docker
docker model run hf.co/gopichand55k/MedIntel-AI:Q8_0
Quick Links

MedIntel-AI

MedIntel-AI is a lightweight medical Q&A assistant built on Qwen2.5-0.5B-Instruct, fine-tuned with QLoRA on the MedQuAD (Medical Question Answering Dataset) and designed to run locally alongside a Retrieval-Augmented Generation (RAG) pipeline.

Domain & Purpose

MedIntel-AI targets the clinical and consumer health information domainโ€”covering disease symptoms, causes, treatments, and medication guidance.

  • Knowledge Grounding: In full application mode (app.py), user queries are grounded against structured medical retrieval stores (MedQuAD, DailyMed, and WHO datasets) via all-MiniLM-L6-v2 embeddings before generation.
  • Edge & Local Inference: Using a 0.5B parameter backbone (531 MB in Q8_0 GGUF) enables fast, private, offline medical Q&A on consumer laptops and edge hardware.

Medical Disclaimer: MedIntel-AI is intended for educational and research purposes only. It is not a substitute for professional medical advice, diagnosis, or treatment. Always consult a qualified healthcare provider regarding any medical condition.

Benchmark: Base Model vs. MedIntel-AI

Evaluated locally on 10 clinical Q&A prompts (max_new_tokens=128, temperature=0.2, repetition_penalty=1.15, float16):

Benchmark Comparison

Metric Base Qwen2.5-0.5B-Instruct MedIntel-AI (Fine-Tuned)
Medical Keyword Accuracy 88.3% 72.2%
Avg Output Tokens 113.1 110.5
Inference Speed 80.2 tok/s 79.8 tok/s

Note: Merging LoRA weights preserves identical inference speed (~80 tok/s). Standalone 0.5B fine-tuning narrows phrasing compared to the general instruct base; for production accuracy, run MedIntel-AI with its RAG retrieval pipeline enabled.

Usage

Run with Transformers

import torch
from transformers import AutoModelForCausalLM, AutoTokenizer

repo_id = "gopichand55k/MedIntel-AI"
tokenizer = AutoTokenizer.from_pretrained(repo_id)
model = AutoModelForCausalLM.from_pretrained(repo_id, dtype=torch.float16, device_map="auto")

messages = [
    {"role": "system", "content": "You are MedIntel-AI, a concise medical Q&A assistant."},
    {"role": "user", "content": "What are the symptoms of Type 2 diabetes?"},
]

text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer(text, return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=150, temperature=0.2, do_sample=True, repetition_penalty=1.15)
print(tokenizer.decode(outputs[0][inputs.input_ids.shape[1]:], skip_special_tokens=True))

Run GGUF Locally with Ollama

Download medintel-qwen2.5-0.5b-q8_0.gguf from this repo and create the Ollama model:

huggingface-cli download gopichand55k/MedIntel-AI medintel-qwen2.5-0.5b-q8_0.gguf --local-dir .
ollama create medintel -f Modelfile
ollama run medintel

Run the Full Local RAG App

streamlit run app.py
Downloads last month
161
Safetensors
Model size
0.5B params
Tensor type
F16
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for gopichand55k/MedIntel-AI

Quantized
(403)
this model