Skip to content

5300: Synthetic Data & Advanced Training

⏱ 5 min read·📅 Last updated: 2026-10-22

Module Overview

This module covers advanced training techniques including synthetic data generation, knowledge distillation, distributed training, and federated learning. You'll learn to train and deploy models at scale with limited resources.

Why This Matters:

  • Real data is expensive, private, or scarce
  • Synthetic data can augment or replace training data
  • Distributed training enables large-scale model training
  • Federated learning allows privacy-preserving model improvement

Learning Objectives

After completing this module, you will be able to:

  • Knowledge Distillation: Train smaller models using larger teacher models
  • Distributed Training: Configure multi-GPU and multi-node training
  • Federated Learning: Implement privacy-preserving distributed training
  • Synthetic Data: Generate training data from teacher model outputs
  • Self-Instruct & Collapse: Grow instruction pools from seeds and price the recursion's collapse tax
  • Advanced Optimization: Apply state-of-the-art training techniques

Module Contents

5301: Knowledge Distillation

Teacher-Student Training Paradigm

  • Distillation theory and objectives
  • Temperature-scaled softmax
  • Different distillation targets (logits, hidden states, attention)
  • Multi-teacher distillation
  • Evaluation of distilled models

Experiments:

  • Implement knowledge distillation
  • Train student model from teacher
  • Compare distillation strategies
  • Measure size vs quality tradeoffs

5302: Distributed Training

Orchestrating Distributed Training Runs

  • Distributed training strategies overview
  • K3s cluster training
  • Fine-tuning workflows
  • Orchestration with Ray
  • Monitoring, logging, and performance optimization

Experiments:

  • Set up DDP training
  • Implement FSDP for large models
  • Optimize communication overhead
  • Handle training failures

5303: Federated Learning

Privacy-Preserving Distributed Training

  • Federated learning fundamentals
  • Federated averaging (FedAvg)
  • The non-IID reality of client data
  • Privacy: what FedAvg does and does not give you
  • Federated LLM fine-tuning and orchestration with Flower

Experiments:

  • Implement federated averaging
  • Simulate federated training
  • Apply differential privacy
  • Analyze convergence

5304: Self-Instruct and Model Collapse

Growing Instruction Data Without Losing the Distribution

  • The self-instruct bootstrap: seed tasks, pool sampling, and the 0.7 similarity keep rule
  • Model collapse: fitting your own output is an absorbing process, tails first
  • The ten-percent real-data anchor and what its budget line flattens
  • Downstream evaluation: train on the mix, measure on a gold holdout
  • The campaign ledger: $1,603 to generate against $524,450 to write

Experiments:

  • Run the four-round bootstrap and read the filter-rejection curve
  • Walk the recursion and count the type extinction
  • Price the anchor against the collapse tax

Prerequisites

Before starting this module, ensure you have:

Review: PREREQUISITES.md for detailed requirements.

Assessment

Quiz

Practice Exercises

  • Format: Advanced training projects
  • Duration: 5 hours
  • Topics:
    • Implement knowledge distillation
    • Set up distributed training
    • Build federated learning system
    • Generate synthetic training data
  • Location: 5300: Synthetic Data Generation - Practice

This module connects to:

Time Commitment

Activity Time
5301: Knowledge Distillation 4 hours
5302: Distributed Training 4 hours
5303: Federated Learning 4 hours
5304: Self-Instruct and Model Collapse 4 hours
Quiz 30 minutes
Practice 5 hours
Total 21.5 hours

Resources

Essential Libraries:

  • PyTorch DDP / FSDP
  • DeepSpeed / Megatron
  • Flower (federated learning)
  • Hugging Face Accelerate

Essential Papers:

  • "Distilling the Knowledge in a Neural Network"
  • "DeepSpeed: System Optimizations for Training"
  • "Communication-Efficient Learning of Deep Networks"

Knowledge Distillation Comparison

Method Student Size Quality Training Time
Training from Scratch Any 100% High
Logit Distillation 50% 95-98% Medium
Hidden State Distillation 50% 96-99% High
Multi-Target Distillation 30% 92-96% High
Quantization + Distillation 25% 90-94% Medium

Distributed Training Strategies

Strategy Memory Efficiency Communication Best For
Data Parallel (DDP) Low Medium Small models
ZeRO-1 Medium Low Large models
ZeRO-2 High Medium Very large models
ZeRO-3 (FSDP) Very High High Huge models
Tensor Parallel High Low Model parallelism

Federated Learning Challenges

Challenge Description Solutions
Communication Network bottlenecks Compression, partial updates
Heterogeneity Different data distributions Personalization, robust aggregation
Privacy Data access restrictions Differential privacy, secure aggregation
Scalability Many clients Client selection, asynchronous updates

Synthetic Data Quality Metrics

Metric Description Good Range
Diversity Unique examples >90% unique
Coverage Concept coverage Matches real data
Accuracy Factual correctness >95%
Format Consistency Structure adherence >98%

Tips for Success

  1. Start simple: Basic distillation before complex methods
  2. Profile communication: Distributed training is often I/O bound
  3. Validate synthetic data: Always check quality before use
  4. Monitor convergence: Federated learning can be unstable
  5. Use existing tools: Don't rebuild distributed training frameworks

Common Pitfalls

  1. Temperature too low: Distillation loses teacher knowledge
  2. Student too small: Cannot capture teacher's knowledge
  3. Ignoring communication: Network overhead kills performance
  4. Poor synthetic data: Garbage in, garbage out
  5. Federating naively: Standard averaging fails with heterogeneous data

Model Compression Pipeline

Original Model (7B)
        ↓
    Pruning (removing weights)
        ↓
    Quantization (4-bit)
        ↓
    Knowledge Distillation
        ↓
Distilled Model (1B, 90%+ quality)

Synthetic Data Generation Pipeline

  1. Define Schema: What data do you need?
  2. Generate Examples: Use teacher LLM
  3. Validate Quality: Check accuracy and diversity
  4. Filter: Remove low-quality examples
  5. Balance: Ensure class balance
  6. Train: Use synthetic + real data mix

When to Use Each Technique

Scenario Recommended Approach
Deploy on mobile Quantization + Distillation
Limited labeled data Synthetic data generation
Privacy constraints Federated learning
Very large models Distributed training + FSDP
Rapid iteration Smaller student models

Next Module: 6100: Vector Embeddings

Previous Module: 5200: Alignment

Questions? Review the PREREQUISITES.md or check Phase 5 documentation.