← Master Index
Vol. 11 Module 11.5 Lecture

Open Source Models

Modern LLM Families

How This Lesson Fits the Module & Volume

This synthesis lecture consolidates Llama, Mistral/Mixtral, Qwen, DeepSeek, Gemma, Phi, and DBRX under the practical umbrella of open-source / open-weight models—and clarifies licensing language before the closed-source capstone.

Learning Objectives

By the end of this lesson, students should be able to:

  • Distinguish open source, open weights, and open science casually vs legally.
  • List advantages: customization, privacy, cost control, portability.
  • List responsibilities: ops, safety, licenses, evals.
  • Map PEFT/quantization/serving stack for open models.
  • Build a selection checklist across open families.
  • Prepare contrast with closed-source models next.
Definition

In LLM practice, open-weight models publish downloadable parameters (with a license). Some are also open source in the OSI sense; many are “source-available” or weight-available with restrictions. Curriculum shorthand says “open” but engineers must read the license.

Architecture & Lineage

Stage / modelPublicly known shiftCurriculum note
Early research dumpsFairseq/GPT-2 style releasesCulture of sharing
Llama waveOpen weights go mainstreamFine-tune explosion
Mistral/Qwen/DeepSeek/etc.Competitive open zooFamily specialization
MoE opens (Mixtral/DBRX)Sparse open scalingServing sophistication rises

Open vs Closed Positioning

You gain

  • Weight-level control
  • On-prem & air-gap options
  • Deep PEFT customization

You own

  • GPUs, scaling, uptime
  • Safety & red-teaming
  • License compliance

Watch language

  • Open weights ≠ OSI open source always
  • Use restrictions common
  • Training data rarely fully open

Typical Use Cases

Use caseWhy this familyWatch-outs
Regulated on-premData residency controlCapEx and talent needed
Heavy fine-tunesLoRA/QLoRA fleetsEval + drift monitoring
Cost at scaleOwn hardware amortizationEngineering time is a cost

Engineering Touchpoint

# Typical open-model adaptation sketch from peft import LoraConfig, get_peft_model from transformers import AutoModelForCausalLM base = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-7B-Instruct", device_map="auto") cfg = LoraConfig(r=16, lora_alpha=32, target_modules=["q_proj", "v_proj"]) model = get_peft_model(base, cfg) model.print_trainable_parameters()

Engineering Upsides

  • Customization and privacy potential
  • Vibrant tooling (vLLM, TGI, llama.cpp)
  • No single API vendor chokepoint

Engineering Trade-offs

  • Ops burden and safety load
  • License ambiguity if unread
  • Quality support varies by community
Common Misconception

“Open model means free of legal and safety duties.” You inherit license terms, export rules, and the duty to evaluate harmful outputs before shipping.

Knowledge Check

  1. Short Answer: What do open weights provide? Answer: Downloadable model parameters under a license.
  2. True/False: Open weights always equal OSI open source. Answer: False—licenses differ.
  3. Multiple Choice: A major open-model upside is: (a) on-prem customization, (b) mandatory vendor lock-in, (c) no need for evals, (d) deleting GPUs. Answer: (a).
  4. Short Answer: Name two open families from this module. Answer: Llama, Mistral, Qwen, DeepSeek, Gemma, Phi, DBRX, Mixtral...
  5. True/False: Self-hosting removes safety responsibilities. Answer: False.
  6. Multiple Choice: A common open adaptation stack includes: (a) LoRA + quantized serving, (b) only punch cards, (c) only CSS, (d) removing tokenizers. Answer: (a).
  7. Short Answer: What should you read before commercial use? Answer: The model license / acceptable use terms.
  8. True/False: Training data for open-weight LLMs is always fully published. Answer: False.
  9. Multiple Choice: Open MoE models often increase: (a) serving complexity, (b) automatic legal immunity, (c) zero VRAM use, (d) CNN-only limits. Answer: (a).
  10. Short Answer: What lecture contrasts this topic next? Answer: Closed Source Models.

Key Takeaways

  • Open weights enable control—and transfer ops/safety burden to you.
  • Say “open weights” carefully; read licenses.
  • PEFT + quantization + good serving unlock products.
  • Next: Closed Source Models (Vol 11 capstone).
Trainer’s Guide

License clinic: Compare two model cards’ redistribution clauses.
TCO sheet: API tokens vs GPU rental for 10M requests/month.

Recap: Open-weight LLMs trade vendor opacity for operator responsibility. Continue with Closed Source Models.