Practical Implementation of LoRA Fine-Tuning (1) – Training Instruction Models

Practical Implementation of LoRA Fine-Tuning (1) - Training Instruction Models

In the previous article, we introduced the principles of LoRA fine-tuning. In this issue, we will get hands-on with supervised fine-tuning (SFT) of a basic pre-trained model, transforming it into an instruction model capable of interacting with users in a dialogue system. LoRA Fine-Tuning Principles JunJun AI, WeChat Official Account: JunJun AI. What exactly is … Read more

Detailed Explanation of LoRA Code

Click “Read the original text” to go directly to the official GitHub. The following code implements the LoRA (Low-Rank Adaptation) technique, which fine-tunes pre-trained models without significantly increasing the number of parameters. Here, I will explain the function and role of each part in detail: Core Class: LoRALayer This is the base class for all … Read more

P-Tuning and LoRA Fine-Tuning for ChatGLM3-6B

P-Tuning and LoRA Fine-Tuning for ChatGLM3-6B

1. Environment Preparation Install Dependencies conda create -n glm3-pfinetune python=3.10 -y conda activate glm3-pfinetune pip install torch torchvision torchaudio –index-url https://download.pytorch.org/whl/cu118 pip install transformers==4.36.2 pip install datasets accelerate peft bitsandbytes pip install tqdm Download the GLM3-6B Model Model address (the open-source model is released by Tsinghua KEG):👉 <span>THUDM/glm-3-6b</span> (available on Hugging Face, requires <span>transformers>=4.34</span>) 2. … Read more

Understanding Large Model Fine-Tuning: What Are the Differences Between SFT and LoRA?

Understanding Large Model Fine-Tuning: What Are the Differences Between SFT and LoRA?

In the application of large models, “fine-tuning” is a crucial step to adapt general models to specific scenarios — for example, enabling ChatGPT to write product copy or allowing LLaMA to answer industry-specific questions, both of which rely on fine-tuning. However, many people confuse SFT and LoRA, two core technologies: both are based on optimizing … Read more

Humanoid Robot Learns to Swing in 20 Minutes! Stanford University Releases Open-Source Soft-Hardware Collaborative System RTR | CoRL 2025

Humanoid Robot Learns to Swing in 20 Minutes! Stanford University Releases Open-Source Soft-Hardware Collaborative System RTR | CoRL 2025

RTR Team Submission Intelligent Gorilla Robot Compilation Author Introduction:The co-first authors of this article are Hu Kaizhe, a PhD student from Tsinghua University’s Institute for Interdisciplinary Information Research, and PhD students Shi Haochen from Stanford University, C. Karen Liu, and Shuran Song.The article was completed during Hu Kaizhe’s visit to Stanford University. The corresponding authors … Read more

Introduction to AdaLoRA: Adaptive Weight Matrix Fine-Tuning for Large Models

Introduction to AdaLoRA: Adaptive Weight Matrix Fine-Tuning for Large Models

Introduction: AdaLoRA addresses the issue of manually selecting the low-rank parameter r in LoRA and implements dynamic adjustments to all key parts of the model (including FFN), comprehensively enhancing model capabilities. Issues with LoRA LoRA allows for the original model parameters to remain unchanged while training a “small patch” (low-rank matrix ΔW) that is added … Read more

Best Practices for AI Agent Development

Best Practices for AI Agent Development

Best Practices for AI Agent Development With the maturity of large language models and tool ecosystems, AI Agents are transitioning from “concept demonstrations” to “enterprise-level implementations.” However, building a reliable, efficient, secure, and sustainably evolving intelligent system requires adherence to a set of proven best practices. The following are the top ten best practices for … Read more

Full Fine-tuning vs LoRa Fine-tuning: Which Approach is More Suitable for You in the Era of Large Models?

Full Fine-tuning vs LoRa Fine-tuning: Which Approach is More Suitable for You in the Era of Large Models?

In the rapidly evolving landscape of Large Language Models (LLMs), how to efficiently adapt models to specific tasks or domains has become a core concern for every AI developer and enterprise. Fine-tuning has emerged as a crucial method for enhancing model performance, leading to various technical paths in recent years. Among them, Full Fine-tuning and … Read more

Understanding LoRA: A Cost-Effective Method for AI Adaptation in Just Ten Minutes

Understanding LoRA: A Cost-Effective Method for AI Adaptation in Just Ten Minutes

It’s not difficult at all; a good paper will make you soar. I will use many examples to help you understand it instantly, so don’t be afraid! Here’s a tip: You can skip the parts you don’t want to read, take what you need, and finishing reading is more important than understanding everything. If you … Read more

Detailed Steps for Fine-Tuning Large Models with LoRA

Detailed Steps for Fine-Tuning Large Models with LoRA

📚 Fine-Tuning Series Articles Understanding the Development and Evolution of Fine-Tuning Technology Estimated reading time: 5 minutes With the widespread application of large-scale Transformer models (such as GPT, LLaMA, ViT), the computational and storage costs of fine-tuning large models have become limiting factors. LoRA, as a Parameter-Efficient Fine-Tuning (PEFT) technique, effectively reduces resource consumption by … Read more