Fine-Tuning & Optimizing Large Language Models
Keep adding new skills with 10,000+ programs for $239 (usually $399). Save now.
Fine-Tuning & Optimizing Large Language Models
This course is part of LLM Engineering: Prompting, Fine-Tuning, Optimization & RAG Specialization
Included with
Ask Coursera
Recommended experience
Recommended experience
What you'll learn
Apply transfer learning and parameter-efficient fine-tuning techniques (LoRA, adapters) to adapt pretrained LLMs for domain-specific tasks
Build end-to-end fine-tuning pipelines using Hugging Face Trainer APIs, including data preparation, hyperparameter tuning, and evaluation
Design and optimize LLM context using relevance selection, compression techniques, and scalable context engineering patterns
Optimize, deploy, monitor, and maintain fine-tuned LLMs using model compression, cloud inference, and continuous evaluation workflows
Skills you'll gain
Tools you'll learn
Details to know
January 2026
17 assignments
See how employees at top companies are mastering in-demand skills
Build your subject-matter expertise
- Learn new concepts from industry experts
- Gain a foundational understanding of a subject or tool
- Develop job-relevant skills with hands-on projects
- Earn a shareable career certificate
There are 5 modules in this course
This course provides a comprehensive, hands-on journey into model adaptation, fine-tuning, and context engineering for large language models (LLMs). It focuses on how pretrained models can be efficiently customized, optimized, and deployed to solve real-world NLP problems across diverse domains.
Through structured lessons, demonstrations, and practice assignments, you will learn how to apply transfer learning, parameter-efficient fine-tuning techniques, context engineering strategies, and optimization methods to build scalable and production-ready LLM systems. The course emphasizes both theoretical foundations and practical workflows using modern tooling such as Hugging Face, Trainer APIs, and model monitoring platforms. By the end of this course, you will be able to: - Explain the principles of transfer learning, model adaptation, and parameter-efficient fine-tuning for large language models - Fine-tune pretrained models using techniques such as LoRA and adapters for domain-specific and task-based applications - Design effective context engineering strategies, including context optimization, compression, and scalable context patterns - Evaluate fine-tuned models using task-appropriate metrics and perform error analysis - Optimize, deploy, monitor, and maintain fine-tuned models for efficient and cost-effective production use This course is ideal for machine learning engineers, AI practitioners, NLP developers, and data scientists who want to move beyond prompt-only interactions and gain practical expertise in adapting and deploying LLMs in real-world systems. A working knowledge of Python, machine learning fundamentals, and basic NLP concepts is recommended to get the most out of this course. Join us to master the end-to-end lifecycle of fine-tuning, optimizing, and operationalizing large language models—from pretrained foundations to scalable, production-ready AI solutions.
Explore how pretrained language models are adapted for new tasks using transfer learning techniques. Learn how parameter-efficient methods such as LoRA and adapters enable lightweight fine-tuning, and how domain-specific data improves model performance. By the end, you’ll understand how to customize large models efficiently while minimizing training cost and complexity.
What's included
13 videos5 readings4 assignments1 discussion prompt
13 videos•Total 78 minutes
- Specialization Introduction•7 minutes
- Course Introduction•4 minutes
- Introduction to Transfer Learning•6 minutes
- Demonstration: Exploring Pretrained Models on Hugging Face Hub•5 minutes
- Demonstration: Visualizing Model Layers and Parameters•5 minutes
- Introduction to PEFT, LoRA, and Adapters•7 minutes
- Demonstration: Fine-Tuning with LoRA on a Custom Dataset•6 minutes
- Demonstration: Adding Adapters LoRa for Lightweight Training•7 minutes
- Demonstration: Instruction-Based Fine-Tuning on a Custom Dataset•7 minutes
- Fine-Tuning for Custom Domains•6 minutes
- Demonstration: Domain-Specific Classification Fine-Tuning•7 minutes
- Demonstration: Domain-Specific Classification Fine-Tuning : Visualization•4 minutes
- Demonstration: Evaluating Fine-Tuned Model Accuracy•6 minutes
5 readings•Total 70 minutes
- Welcome to Fine-Tuning & Optimizing Large Language Models•15 minutes
- Foundations of Transfer Learning and Domain Adaptation•15 minutes
- Understanding LoRA and Adapter-Based Fine-Tuning for Large Models•15 minutes
- Best Practices for Domain Adaptation •15 minutes
- Module Summary : Understanding Model Adaptation and Transfer Learning•10 minutes
4 assignments•Total 48 minutes
- Knowledge Check: Understanding Model Adaptation and Transfer Learning•30 minutes
- Practice Knowledge Check: Fundamentals of Transfer Learning•6 minutes
- Practice Knowledge Check: Parameter-Efficient Fine-Tuning Techniques•6 minutes
- Practice Knowledge Check: Domain-Specific and Task-Based Adaptation•6 minutes
1 discussion prompt•Total 10 minutes
- Introduce Yourself•10 minutes
Dive into the end-to-end workflows required to fine-tune language models effectively. Learn how to prepare and tokenize datasets, configure training pipelines using the Hugging Face Trainer API, and optimize hyperparameters for better results. By the end, you’ll be able to train, evaluate, and publish fine-tuned models with confidence.
What's included
10 videos4 readings4 assignments
10 videos•Total 62 minutes
- Preprocessing and Cleaning Text for Fine-Tuning•7 minutes
- Demonstration: Tokenizing and Batching Datasets•6 minutes
- Demonstration: Dataset Splitting for Validation and Testing•6 minutes
- Setting Up Fine-Tuning Environments•7 minutes
- Demonstration: Configuring Trainer API for BERT Models•7 minutes
- Demonstration: Monitoring Training Loss and Accuracy•6 minutes
- Model Evaluation Metrics: F1, BLEU, ROUGE•6 minutes
- Demonstration: Visualizing Confusion Matrix for Performance•6 minutes
- Demonstration: Exporting and Uploading to Hugging Face Hub•6 minutes
- Demonstration: Evaluating models using DeepEval + ELO ranking•6 minutes
4 readings•Total 60 minutes
- Text Preprocessing Pipelines for Fine-Tuning Transformers•15 minutes
- Hyperparameter Optimization in Hugging Face Trainer•15 minutes
- Model Evaluation Metrics and Error Analysis for NLP Tasks•15 minutes
- Module Summary: Fine-Tuning Workflows and Hyperparameter Optimization•15 minutes
4 assignments•Total 48 minutes
- Knowledge Check: Fine-Tuning Workflows and Hyperparameter Optimization•30 minutes
- Practice Knowledge Check: Preparing and Tokenizing Data•6 minutes
- Practice Knowledge Check: Fine-Tuning Pipeline Setup•6 minutes
- Practice Knowledge Check: Evaluating Fine-Tuned Models•6 minutes
Explore how context influences LLM behavior and performance. Learn the fundamentals of context engineering, manage token limits, apply context compression techniques, and design scalable context patterns. By the end, you’ll understand how to structure and optimize context for reliable and production-ready LLM applications.
What's included
15 videos4 readings4 assignments
15 videos•Total 78 minutes
- Introduction to Context Engineering•5 minutes
- LLM Context Engineering Basics•5 minutes
- Comparing Prompt and Context Design•4 minutes
- Effective Context Writing•4 minutes
- Demonstration: Context Flow Visualization•6 minutes
- Demonstration: Comparing Prompt and Context Engineering for LLMs•5 minutes
- Token Limits in LLMs•4 minutes
- Context Relevance Selection•5 minutes
- Context Compression Techniques•5 minutes
- Demonstration: Context Compression in LLM System•6 minutes
- Task Isolation Strategies•5 minutes
- Common Context Errors•5 minutes
- Scalable Context Engineering•6 minutes
- Demonstration: Context Isolation Patterns for LLMs•6 minutes
- Demonstration: Scaling LLM with Production using Context Engineering•6 minutes
4 readings•Total 55 minutes
- Foundations of LLM Context Design•15 minutes
- Optimizing Context Windows•15 minutes
- Context Engineering Design Patterns•15 minutes
- Module Summary: Context Engineering for LLMs•10 minutes
4 assignments•Total 48 minutes
- Knowledge Check: Context Engineering for LLMs•30 minutes
- Practice Knowledge Check: LLM Context Fundamentals•6 minutes
- Practice Knowledge Check: Context Limits and Optimization•6 minutes
- Practice Knowledge Check: Context Patterns and Scalability•6 minutes
Learn how to optimize fine-tuned models for efficient inference and real-world deployment. Explore model compression techniques such as quantization and knowledge distillation, scaling strategies in cloud environments, and continuous monitoring practices. By the end, you’ll know how to deploy, scale, and maintain LLMs while controlling cost and performance.
What's included
13 videos4 readings4 assignments
13 videos•Total 72 minutes
- Model Compression Techniques•6 minutes
- Demonstration: Quantizing Model for Inference Speed - I•4 minutes
- Demonstration: Quantizing Model for inference Speed - II•5 minutes
- Demonstration: Knowledge Distillation for Model Compression•6 minutes
- Scaling and Cost Management in Cloud Environments•6 minutes
- Demonstration: Deploying on Hugging Face Inference API•7 minutes
- Demonstration: Monitoring Latency and Costs•6 minutes
- Continuous Evaluation and Model Versioning•6 minutes
- Demonstration: Tracking Metrics with MLflow - I•6 minutes
- Demonstration: Tracking Metrics with MLflow - II •5 minutes
- Demonstration: Tracking Metrics with MLflow - III•7 minutes
- Demonstration: Updating Models Using Incremental Retraining - I•5 minutes
- Demonstration: Updating Models Using Incremental Retraining - II•5 minutes
4 readings•Total 65 minutes
- Efficiency Optimization Techniques for Transformer Models•15 minutes
- Scaling Fine-Tuned Models for Production Inference•15 minutes
- Lifecycle Management for Deployed LLM Models•20 minutes
- Module Summary: Understanding Model Adaptation and Transfer Learning•15 minutes
4 assignments•Total 48 minutes
- Knowledge Check: Optimization, Compression, and Deployment•30 minutes
- Practice Knowledge Check: Model Optimization Techniques•6 minutes
- Practice Knowledge Check: Scaling Fine-Tuned Models•6 minutes
- Practice Knowledge Check: Monitoring and Maintaining Fine-Tuned Models•6 minutes
Apply everything you’ve learned through a hands-on practice project focused on fine-tuning and adapting an LLM end to end. Reflect on key concepts, complete the final graded assessment, and identify next steps for advancing your skills. By the end, you’ll be prepared to apply model adaptation techniques in real-world AI systems.
What's included
1 video1 reading1 assignment1 discussion prompt
1 video•Total 3 minutes
- Course Summary: Fine-Tuning & Optimizing Large Language Models•3 minutes
1 reading•Total 40 minutes
- Practice Project: Fine-Tuning and Adapting Domain-Specific LLMs•40 minutes
1 assignment•Total 30 minutes
- End Course Knowledge Check: Fine-Tuning & Optimizing Large Language Models•30 minutes
1 discussion prompt•Total 10 minutes
- Describe your Learning Journey•10 minutes
Earn a career certificate
Add this credential to your LinkedIn profile, resume, or CV. Share it on social media and in your performance review.
Explore more from Software Development
- Status: Free Trial
Course
- Status: Free Trial
- Status: FreeD
DeepLearning.AI
Project
- Status: Free Trial
Why people choose Coursera for their career
Frequently asked questions
This course teaches how to fine-tune, adapt, optimize, and deploy large language models for real-world applications.
It helps you move beyond prompt usage and gain hands-on expertise in production-grade LLM adaptation.
It is designed for ML engineers, AI practitioners, NLP developers, and data scientists.
More questions
Financial aid available,
