MedicalGPT implements pretraining, SFT, RLHF, DPO, ORPO, GRPO, and OPD stages to adapt general LLMs to medical Q&A. Scripts and demos cover training, merging LoRA, RAG chat PDF, and Gradio serving.
Overview
MedicalGPT follows a ChatGPT-like training pipeline aimed at medical domain language models. Stages include continued pretraining, supervised fine-tuning, reward modeling, PPO, DPO, ORPO, GRPO, and on-policy distillation, with shell entry points under training/ and scripts/.
The project ships tools for LoRA merge, vocabulary expansion, dataset conversion, and agent tool-calling fine-tuning across several chat templates. Demo code covers inference, Gradio UI, FastAPI, RAG over files, and multi-GPU options with documented VRAM tables for common model sizes.
Published checkpoints and examples on Hugging Face illustrate medical chat quality; release notes track support for Llama, Qwen, Baichuan, Mixtral MoE, and newer families. training/ holds the core loops while demo/ shows deployment patterns.
Users bring base weights, datasets, and GPU resources; nothing positions the work as a hosted medical product. It is research and engineering tooling for teams building their own models.
Key features
- Multi-stage medical LLM training
- DPO ORPO GRPO and RLHF support
- LoRA and full-parameter training
- Tool-call agent fine-tuning
- RAG chat over documents
- Gradio and FastAPI demos
- Dataset and template tooling
Use cases
- Fine-tuning medical chat models
- Research on clinical QA LLMs
- Teaching LLM alignment pipelines