Advanced NLP · BSc Level

Large
Language
Models

Foundations to Advanced Systems

An advanced bachelor's course covering the full LLM stack — from Transformer architecture and pretraining through fine-tuning, RAG, agentic systems, and responsible deployment at scale. Designed for students who want to build real-world AI systems.

7 Weeks Python · PyTorch · HuggingFace Advanced Level Project-Based WBAI068-05 · 5 ECTS · Ocasys ↗
7
Weeks
6
Core Objectives
6
Application Domains
LLM
Primary Domain

Skills &
Prior Knowledge

This course assumes a strong technical foundation. Students should arrive comfortable with deep learning, NLP fundamentals, and Python at an advanced level. It builds on Natural Language Processing and Introduction to Machine Learning. The bars below indicate the expected entry-level proficiency — this is a fast-paced, advanced bachelor's course with no ramp-up on basics.

Python & PyTorch Advanced
Deep Learning Fundamentals Advanced
NLP Foundations (from NLP course) Intermediate–Advanced
Linear Algebra & Probability Advanced
Transformer Architecture Intermediate
Git, CLI & Cloud Computing Intermediate
Recommended entry level versus expected exit level (0 to 100): Python / PyTorch 90 to 97; Deep Learning 85 to 95; NLP Foundations 80 to 95; Linear Algebra 82 to 90; Transformers 65 to 95; Git / Cloud 70 to 88.

Core Learning
Outcomes

Master Transformer Architecture
Gain deep understanding of self-attention, multi-head attention, positional encoding, and the design choices that make modern LLMs work at scale.
Implement Advanced Techniques
Apply Retrieval-Augmented Generation (RAG) for factual grounding and parameter-efficient fine-tuning methods like LoRA, QLoRA, and instruction tuning.
Optimise for Scale
Understand system-level optimisations for training and serving: distributed training, gradient checkpointing, model quantisation, and efficient inference.
Build Agentic Frameworks
Design and deploy agentic LLMs that leverage tool use, function calling, memory systems, and multi-agent orchestration for complex task completion.
Develop Real-World Applications
Integrate LLM-powered solutions across domains — from enterprise chatbots and code assistants to domain-specific RAG systems and multimodal pipelines.
Analyse Ethical Implications
Critically assess and mitigate bias, hallucination, data privacy risks, and the broader societal impact of deploying large-scale AI language systems.

7-Week
Course Plan

Click any week to expand ↓
Lecture Topics
  • Evolution of LMs: statistical → neural → Transformers → LLMs
  • Emergent capabilities of LLMs
Lab / Deliverable
  • Interact with an LLM (GPT, LLaMA, etc.) across multiple tasks
  • Write a reflection: "Where does the model excel? Where does it fail?"
Key Readings
Jurafsky & Martin, Speech and Language Processing — LLM overview

Bender et al. (2021), On the Dangers of Stochastic Parrots
Lecture Topics
  • Transformer architecture: attention, positional encoding, feedforward layers
  • Model scaling laws: data, parameters, compute
  • Advances beyond vanilla Transformers: MoE, Mamba, RWKV, RAG
Lab / Deliverable
  • Implement scaled dot-product attention in PyTorch
  • Compare inference speed of small vs. medium pre-trained models
Key Readings
Vaswani et al. (2017), Attention Is All You Need

Kaplan et al. (2020), Scaling Laws for Neural Language Models
Lecture Topics
  • Tokenisation: BPE, WordPiece, SentencePiece
  • Pre-training objectives: masked LM, next-token prediction
  • Fine-tuning strategies: supervised fine-tuning (SFT), domain adaptation
  • RLHF: reward modelling, preference optimisation
Lab / Deliverable
  • Fine-tune a small pre-trained model on a custom task
  • Experiment with prompt-tuning vs. fine-tuning; compare results
Key Readings
Raffel et al. (2020), T5: Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer

Ouyang et al. (2022), Training language models to follow instructions with human feedback
Lecture Topics
  • Challenges: cost, latency, memory
  • Model compression: quantisation, pruning, distillation
  • Parameter-efficient tuning: LoRA, adapters, PEFT
Lab / Deliverable
  • Apply quantisation on a small model
  • Compare memory use and speed before vs. after LoRA tuning
Key Readings
Hu et al. (2021), LoRA: Low-Rank Adaptation of Large Language Models
Lecture Topics
  • Prompting strategies: zero-shot, one-shot, few-shot
  • Advanced prompting: Chain-of-Thought, Self-Consistency, Tree-of-Thoughts
Lab / Deliverable
  • Design prompts for reasoning, summarisation, and creative writing
  • Evaluate prompt effectiveness across models systematically
Key Readings
Wei et al. (2022), Chain-of-Thought Prompting Elicits Reasoning in Large Language Models
Lecture Topics
  • What knowledge LLMs store vs. what they infer
  • Logical, mathematical, and commonsense reasoning
  • Augmenting reasoning: retrieval-augmented generation (RAG), external tools
  • Evaluation of reasoning abilities
Lab / Deliverable
  • Build a retrieval-augmented QA pipeline
  • Compare LLM-only vs. LLM + retrieval performance
Key Readings
Karpas et al. (2022), MRKL Systems: A modular, neuro-symbolic architecture

Lewis et al. (2020), Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks
Lecture Topics
  • Text + Vision: CLIP, Flamingo, GPT-4V
  • Speech + Text: Whisper, AudioLM
  • Video, code, and beyond: multimodal reasoning
  • Emerging research directions & open challenges
Lab / Deliverable
  • Run inference with a vision-language model on visual QA tasks
  • Explore multimodal reasoning: image + text prompting
Key Readings
Radford et al. (2021), Learning Transferable Visual Models From Natural Language Supervision (CLIP)

Alayrac et al. (2022), Flamingo: a Visual Language Model for Few-Shot Learning

Real-World
LLM Applications

Content Creation & Generation
Automating articles, marketing copy, social media posts, and creative writing. LLMs serve as powerful co-authors — accelerating ideation, drafting, and editing workflows at scale.
Customer Service & Support
Intelligent chatbots and virtual assistants delivering 24/7 support, resolving complex queries in natural language, and routing escalations — dramatically reducing response times and costs.
Code Generation & Assistance
Helping developers write, debug, review, and document code more efficiently. Tools like GitHub Copilot and Cursor suggest completions, explain unfamiliar codebases, and generate test suites.
Scientific & Medical Research
Accelerating literature review, hypothesis generation, and clinical decision support. Domain-specific LLMs (Med-PaLM, BioGPT) are transforming how researchers navigate vast knowledge bases.
Enterprise Knowledge Management
RAG-powered internal search, document Q&A, and knowledge base assistants that let employees query company documents, policies, and reports in natural language — with answers grounded in source documents to reduce hallucination.
Multilingual & Cross-lingual AI
Breaking language barriers through machine translation, cross-lingual retrieval, and multilingual chatbots. Modern LLMs enable fluent communication and information access across dozens of languages.

Responsible LLMs &
Societal Impact

The power of large language models comes with serious responsibility. This course treats ethics not as an afterthought but as a core technical and intellectual discipline — with responsible deployment at scale integrated across the curriculum rather than left to a single module.

Bias and Fairness
LLMs inherit and can amplify biases embedded in pretraining data — affecting hiring tools, medical advice systems, and content moderation. We study detection methods, de-biasing techniques at the data, training, and inference levels, and the structural limits of purely technical fixes.
Data Privacy and Consent
LLMs trained on web-scale data raise critical questions about data privacy, memorisation of personal information, and extraction attacks. We cover GDPR compliance, ethical data sourcing, differential privacy, and the risks of training data regurgitation.
Hallucination and Misinformation
LLMs can generate confident but factually incorrect outputs — a phenomenon with serious consequences in medical, legal, and educational contexts. We analyse hallucination causes, grounding techniques (RAG, RLHF), and evaluation frameworks for factual accuracy.
Environmental Sustainability
Training and serving frontier LLMs carries enormous computational and carbon costs. We discuss efficiency research (PEFT, distillation, quantisation), responsible compute reporting, and the imperative for sustainable scaling practices in both academia and industry.
Responsible AI Framework
Fairness
Equitable outputs across demographic groups and languages
Transparency
Model cards, datasheets, and explainable decisions
Privacy
Data minimisation, anonymisation, GDPR compliance
Accountability
Clear responsibility chains for AI system outcomes
Societal Benefit
Designing LLM systems that advance human welfare equitably