ModelScope ms-swift: local setup and fine-tuning tutorial
Learn to install ms-swift, fine-tune a model with LoRA, and chat with its checkpoint on Ubuntu using an RTX 6000 with 48 GB VRAM.
Player not loading? Watch on YouTube
This tutorial, uploaded on July 6, 2025, walks through installing ModelScope ms-swift and fine-tuning a local LLM. The source supplies no recording date or ms-swift version, so the setup reflects the upload's period rather than a confirmed current release.
The presenter uses Ubuntu and an NVIDIA RTX 6000 with 48 GB of VRAM. After preparing a virtual environment, he installs ms-swift with pip and explains the CLI training options. The example uses LoRA, Chinese and English Alpaca data plus self-cognition samples, BF16 precision, and one training epoch. He also covers a LoRA rank of eight, alpha of 32, gradient accumulation over 16 steps, and a 2,048-token input limit. The workflow downloads the base model and datasets before training; it is not an offline installation.
The presenter reports that fine-tuning finishes in about seven minutes on his setup. He describes the model in the demonstration as having seven billion parameters. This timing is a reported result for that run, not a general hardware requirement or benchmark.
The next steps load the saved checkpoint for interactive chat and explain export to Hugging Face or ModelScope. The tutorial ends with the web UI on localhost port 7860, where the presenter shows training settings and discusses inference and evaluation.