DSECOP Workshop · AAPT Summer Meeting 2026 · Pasadena, CA

Integrating Data Science & AI into the Undergraduate Physics Curriculum

Instructional approaches, sample activities, and curriculum design strategies for bringing data science and AI into physics education, with live demos throughout.

Mohammad Soltaniehha
Boston University
Julie Butler
University of Mount Union
Saturday, July 18, 2026
1:00 – 5:00 pm
Slides & materials
soltaniehha.com/AAPT-2026
DSECOP is funded by an AIP Venture Grant, in partnership with AAPT.
React live
Scan to react

Hi, I’m Mohammad.

  • Now: Clinical Assistant Professor, Information Systems, Boston University (Questrom)
  • Physics: Ph.D. in computational physics, Northeastern (2015)
  • Industry: Data scientist, Infor (2015–2018) · Google Cloud Faculty Expert (2020–)
  • Research: computer vision in cancer diagnosis · forecasting · HPC · LLMs & embodied AI
  • APS GDS: founding chair, Topical Group on Data Science (2018–2021)
  • DSECOP: Editor-in-Chief (2022–)
  • APS: Board of Directors (2025–2028)
  • Contact: msoltani@bu.edu · soltaniehha.com

This afternoon

TimeSessionWho
1:00 – 1:15Introduction to DSECOPMohammad
1:15 – 1:30Running DSECOP modules in ColabJulie
1:30 – 1:45Introduction to LLMsMohammad
1:45 – 2:00Discussion: LLMs in the physics classroomMohammad Julie
2:00 – 2:30Advanced AI: Lovable, Claude Cowork & Design · the Monte Carlo moduleMohammad
2:30 – 3:00Break
3:00 – 3:45Copilot & the neural-network module: lesson plans, quizzes, rubrics, study agentsJulie
3:45 – 4:15Free models & data-science libraries: Gemini as a coding companionJulie
4:15 – 5:00Running Claude Code, including open-weight modelsMohammad
01 · 1:00 – 1:15

Introduction to DSECOP

What the Data Science Education Community of Practice is, where it came from, and what it puts in your hands today.

dsecop.org
React live
Scan to react
Why DSECOP

Data science and AI is one of the major areas our students pursue after graduation.

The gap

  • Most physics graduates build careers outside academia, many of them in data-intensive roles.
  • The Phys21 report and the EP3 guide both call for broader skills, yet students mostly teach themselves data science.
  • The 2016 AAPT recommendations and PICUP paved the way for computation. Data science and AI are the next step on that same road.

DSECOP’s mission

Prepare physics students for diverse career paths by equipping them with essential skills beyond traditional subject material, without asking you to rebuild your course.

Ready-to-use modules · webinars · workshops · a community of educators.

The stakes are current: employment for 22–25-year-olds in the most AI-exposed occupations fell ~13% while older cohorts held steady (Stanford Digital Economy Lab, 2026). The durable skills (computational fluency, data judgment, AI supervision) are the ones we can teach.
The modules

20+ modules, built by physicists, free to use

Each one drops into an existing course: Jupyter notebooks with physics context, exercises, and instructor notes. CC0-licensed: use, remix, no permission needed.

Foundations

Intro to DS libraries · histograms & data processing · exploratory data analysis · ML workflow

Core ML in physics

Classification · random forests · spectral clustering · outlier analysis · time series & forecasting

Physics-native AI

NNs for differential equations · learning the Schrödinger equation · Gaussian processes · symbolic regression

Today’s stars

Connecting Monte Carlo to Modern AI (my 2:00 session) · the neural-network module (Julie, 3:00)

Using a module

Designed for adoption

What modules assume

  • Base Python: variables, functions, loops, data structures
  • Core numpy, pandas, matplotlib
  • Google Colab: no installs, free GPUs
  • Git & GitHub basics · elementary statistics

What we learned building them

Four years of trying this in real classrooms. What worked, what didn’t, and how to structure modules faculty actually adopt:

“Data science education in undergraduate physics: Lessons learned from a community of practice”
Shah, Butler, Knaub, Zenginoğlu, Ratcliff & Soltaniehha
Am. J. Phys. 92 (9), 655–662 (2024) · doi.org/10.1119/5.0203846

Start with one module in one course. That’s how every adopter began.
A brief history

From APS GDS to a partnership with AAPT

2018

APS GDS founded

The APS Topical Group on Data Science, where DSECOP began.

2022

DSECOP launches

APS Innovation Fund award IF-11; first fellows, first modules.

2023

Second cohort

A second cohort grows the collection to 20+ modules.

2024

Lessons published

“Data science education in undergraduate physics,” Am. J. Phys. 92, 655–662.

2025

AIP Venture Grant

New AIP funding, in partnership with AAPT, to expand the work.

2026

The LLM round

A new cohort focused on bringing LLMs into undergraduate courses.

Mission, rounds 1–2 (2022–24)

Fellows, physics grad students and postdocs, build classroom-ready data science modules for undergraduate physics courses: from data acquisition and cleaning to exploratory analysis and machine learning.

Mission, 2026 round

The AIP Venture Grant charge: “Integration of Large Language Models into the Undergraduate Physics Curriculum.” New fellows build LLM-focused modules: AI-assisted coding, prompting, limitations, responsible use.

Funded by an AIP Venture Grant · in partnership with AAPT · originally funded by the APS Innovation Fund
The team

Who runs DSECOP today

Principal investigators & editor

  • William Ratcliff, NIST · neutron scattering + AI for superconducting materials
  • Julie Butler, University of Mount Union · ML for nuclear many-body physics · a DSECOP fellow before joining the leadership
  • Alexis Knaub, AAPT · STEM education research & evaluation
  • Mohammad Soltaniehha, Boston University · Editor-in-Chief

2026 Fellows: the LLM cohort

  • Marko Ristic, postdoc, Los Alamos National Laboratory
  • Vladimir Strokov, postdoc, West Virginia University

Building the first LLM-focused DSECOP modules for undergraduate physics courses.

Fellows are the engine of DSECOP: early-career physicists who design, build, and test every module. Up next, Julie runs a module end-to-end in Colab: the student experience, live.
02 · 1:30 – 1:45

Introduction to LLMs

What these models are and how they work.

React live
Scan to react
A short history, part one

From punch cards to Python

Seventy years of telling machines what to do. Every era removes another layer of ceremony.

1950 – 1968
Punch cards & mainframes
DO 10 I = 1, 100
A program is a stack of cards. Drop the stack, lose the day.
1982 – 1989
Commodore 64 BASIC
10 PRINT "HELLO"
Hit RETURN, the machine answers. Code from a magazine.
Sub Greet()
  PRINT "HI"
End Sub
1991 – 1998
QBASIC & Visual Basic
Sub Form_Load()
Drag a button. Write the handler. Ship to Windows.
{  }
2000 – 2009
Java & the early web
System.out.println("hi")
Compile, deploy, refresh. The browser becomes the runtime.
>>> print("hello, world")
hello, world
>>>
2010 – 2019
Python everywhere
print("hello, world")
One line. It just runs. Data, science, and beginners welcome.
1950s
1980s
1990s
2000s
2010s
A short history, part two

From n-grams to next-word prediction

A language model has one job: guess the next word. The story of AI is the story of getting better at that guess.

The capital of France is Paris
Model's top guesses · softmax probabilities
Paris
87%
Lyon
6%
Rome
4%
Berlin
2%
Words live in a space
word2vec showed that capital − country is the same direction everywhere. Meaning becomes geometry.
France
Paris
Japan
Tokyo
UK
London
countrycapital
← generalspecific →
1948
n-gram models
Count which words follow which. Fast, shallow, no notion of meaning.
2013
word2vec / GloVe
Words become vectors. Distance encodes relatedness.
2014
RNN & LSTM
Sequences with memory. Models can read a sentence.
2017
Transformer
Attention lets every word look at every other. Scales.
2018 – 2022
GPT-1 → GPT-3
Same recipe, more data, more parameters. Emergence.
A short history, part three

From autocomplete to autonomous teammates

In five years, code assistants grew from suggesting the next character to running for hours on their own.

01
2021
Inline completion
def greet(name):
  return f"Hello"
Tab to accept.
02
2022
Chat about code
why slow?
O(n²)
fix it
Q&A, paired.
03
2023 – 2024
Write & refactor
def parse(l): l.split() shlex.split(l) +4 files
Functions & diffs.
04
2025
Long-running agents
routes.py+24
schema.sql+8
login.tsx+12
old.py−5
Hours, unattended.
05
2026 →
Multi-agent teams
planner
builder
reviewer
tester
shared memory
Parallel teammates.
// Agent
RUNNING
Runtime
00:00:00
Tests passing
0 / 0
00:00// human: add SSO + email login, write tests
Each step hands the machine more of the work. We now design for a teammate, not a tool that waits.
How models work, part one

One call: prompt in, text out.

01Prompt
why does my Euler pendulum gain energy every cycle?
02Model
Haiku 4.5fast · cheap
Sonnet 5everyday
Opus 4.8hard problems
Fable 5frontier
03Completion
Forward Euler isn’t symplectic: it inflates the amplitude at any step size. Try leapfrog…

// The knobs you can turn

  • Promptwhat you say, every turn
  • System promptpersistent personality & rules
  • Modelspeed vs. depth tradeoff
  • Temperaturehow surprising the output gets
  • Toolswhat it’s allowed to call
// Five dials. Same model, different settings, very different assistant.
How models work, part two

The model has a desk. Everything you talk about goes on it.

0 tokens~1,000,000 tokens →
be helpful, honest
don’t reveal keys
System prompt
project goals
style guide
test commands
CLAUDE.md
turn 1: “hey…”
turn 2: “ok try…”
turn 3: …
turn 4: …
turn 5: …
Conversation
lab-data.csv
notes.md
Attachments
1Mtokens
≈ 2,000 pages of text
Big, but not infinite. When the desk fills, the oldest pages fall off the edge. Even before it’s full, a crowded desk makes the model reason worse. This is called context rot, so start fresh often.
// Tip: when the agent “forgets,” it’s usually the desk, not the model.
The 2026 surface area

Same brain, six surfaces.

claude.ai
The web app
Where most people start. Chat, projects, files, Skills.
claude.ai
 Good evening, Mo
How can I help you today?
Fable 5 ▾
claude.ai/code
Claude Code on the web
A coding agent in a cloud sandbox, wired to GitHub.
claude.ai/code
Describe a coding task…
⎇ phy305/monte-carlomain
add dark mode togglerunning
fix flaky auth testPR #481
Desktop app
Claude Code, local
Parallel sessions on your machine, files and terminal included.
ChatCoworkCode
Sessions
refactor ising lab
onboarding copy
api docs
Add CSV export to reports
Planned 3 steps · editing…
Reply to Claude…
VS Code · Cursor
Editor extension
Claude in a panel beside your code. JetBrains too.
parse.py · phy305
def parse(line):
  return shlex.split(line)   # was: line.split()
Claude
Quoted paths broke the old split. Fixed here and in 2 other files.
✓ tests pass
Terminal / CLI
claude in your shell
The engine itself. Scripts, CI pipelines, batch jobs.
~/projects/phy305
Welcome to Claude Code!
/help for help · cwd: ~/projects/phy305
> fix the failing tests
✓ 142 passed · 0 failed · PR #1142 opened
iOS · Android
Mobile companion
Watch long tasks, approve and ship from your phone.
Claude Code
refactor ising notebook
running · 12m · 4 files
migrate tests to Vitest
✓ done · PR ready
ApproveView
update API docs
queued
The model · released June 9, 2026

Meet the engine: Claude Fable 5.

The headline

A Mythos-class model, made safe for general use.

State of the art on nearly every tested benchmark: coding, knowledge work, vision, research. It plans, runs for hours, and checks its own output as it goes.

Sees & remembers

Vision, state of the art: reads exact values off scientific figures, rebuilds an app from a screenshot. Memory: stays focused across millions of tokens.

The hook: it checks itself

Validates its own work

It asks before acting when it’s uncertain. You can wire a human checkpoint to exactly that signal.

$10 / $50
per 1M tokens in / out
on paid plans
50M lines
Stripe migration, done in 1 day
scoped at 2 months for a team
1,000+ hrs
external red-teaming
zero universal jailbreaks
claude-fable-5 · generally available
Fable 5, safeguarded: cyber, bio/chem & anti-distillation classifiers on top; falls back to Opus 4.8 behind them.
restricted access
Mythos 5, safeguards lifted. Project Glasswing partners & vetted life-science researchers only.
Pick the smallest that does the job

Two dials: model + effort.

// tier 01 · Haiku 4.5 · fast & cheap
Haiku
Classify. Route. Score.
Sub-second, pennies per thousand calls. Use it where the AI is invisible.
Speed
Cost
Depth
// reach for it when
01Intent classification"is this a homework question, logistics, or a regrade?"
02Routing & taggingtag forum posts, route to the right TA
03Confidence scoringscore a submission 0–1 for review priority
// tier 02 · Sonnet 5 · everyday
Sonnet
Read. Write. Refactor.
The everyday workhorse: drafting, summarising, coding. Most of what you ship.
Speed
Cost
Depth
// reach for it when
01Drafting student feedbackconstructive tone, edited by you
02Day-to-day codingedits, refactors, test-writing in Claude Code
03Summarising & blueprintingturn 40-page PDFs into a 1-page brief
// tier 03 · Opus 4.8 · hard problems
Opus
Reason. Plan. Debug.
Multi-step planning, ambiguous specs, deep debugging. For genuinely hard work.
Speed
Cost
Depth
// reach for it when
01Plan-mode for big refactorsa 4-step plan across 20 files, no guessing
02Ambiguous project specsreconcile contradictory requirements
03Hard bug archaeologywhy does the fit diverge only at low temperature?
// tier 04 · Fable 5 · frontier
Fable
Frontier. Self-checking.
The Mythos-class engine, state of the art on nearly everything. For frontier moments.
Speed
Cost
Depth
// reach for it when
01Long-horizon buildsruns for hours, validates its own output
02Senior-grade analysisresearch & reasoning at analyst depth
03The hardest 5%escalate the calls where Opus falls short
// price per 1M tokens · in / outa heavy day of agentic coding ≈ coffee money on Haiku, dinner money on Fable
$1 / $5 · baseline
$3 / $15 · 3× Haiku
$5 / $25 · 5× Haiku
$10 / $50 · 10× Haiku
Effort → lowmediumhighxhighmax The second dial, right next to the model picker. Fable 5 topped Cognition’s FrontierCode at just medium. Pick the smallest model and the lowest effort that do the job.
The effort dial · test-time compute

Spend more thinking when it matters.

REASONING
// reading lab03-pendulum.ipynb for the energy drift…
// found: forward Euler integrator in cell 4
// observed: energy grows ~2% per cycle
// → not roundoff; the method itself injects energy
// checking: is the step size the culprit?
// halving dt shrinks the drift but never removes it
// considering: what would a symplectic method do?
// → leapfrog conserves the energy envelope
// drafting explanation…
// double-checking the sign convention…
// student is in intro mechanics: keep it simple
// → suggest plotting E(t) for both integrators
// final answer ready.
// reading lab03-pendulum.ipynb for the energy drift…
// found: forward Euler integrator in cell 4
// observed: energy grows ~2% per cycle
// → not roundoff; the method itself injects energy
// checking: is the step size the culprit?
// halving dt shrinks the drift but never removes it
// considering: what would a symplectic method do?
// → leapfrog conserves the energy envelope
// drafting explanation…
// double-checking the sign convention…
// student is in intro mechanics: keep it simple
// → suggest plotting E(t) for both integrators
// final answer
"Forward Euler adds energy every cycle: it’s the integrator, not your code. Try leapfrog and re-plot E(t)."
On Opus 4.8, extended thinking is off by default. One control turns it up: effort, from low to max (or thinking: adaptive in the API). More reasoning, fewer mistakes on hard problems. The trade-off is time: the thinking happens before the answer.
// Raise the effort when correctness matters. Keep it low for classification and routing.
The obvious question

Can it actually do physics? Mostly, yes.

~93%

GPQA Diamond

PhD-level science questions: frontier models score ~93% vs. ~65% for PhD experts answering in their own field. Effectively saturated.

Gold

IPhO 2025 problems

Gold-medal-level performance on the 2025 International Physics Olympiad theory problems, including an open-weight model.

<50%

Humanity’s Last Exam

At the frontier of human knowledge, top models still fail more than half the time. The edge is still ours, for now.

The “can it pass?” question is settled. The catch: the ~7% it gets wrong arrives in the same confident voice as the 93% it gets right. A sign error in a derivation looks exactly like a correct line. Teaching students to catch it is the new job, and it’s where we go next.

epoch.ai benchmark hub · arXiv:2509.01659 · “gold-medal level” = scored against public IPhO 2025 problems, not official adjudication.
Claude Code in the browser

Open a tab, ship a task. No install required.

1
Fresh VM per task
Anthropic spins up a clean, disposable sandbox computer in the cloud.
2
Your repo, cloned in
Connects to GitHub, clones the repo, works on a branch, opens a PR.
3
Survives the tab
Close the tab or check from your phone. The same session keeps running.
claude.ai/code
 What are we coding next?
add a dark mode toggle to the settings page
⎇ phy305/monte-carlomain
Recent tasks
refactor the Monte Carlo notebook into a module running · 12m
migrate test suite from Jest to Vitest PR #482
fix flaky auth integration test PR #481
2022 → 2026

Same brief: eight weeks, then three days.

2022
Stack Overflow
+ ctrl-c ctrl-v
2023
Copilot
autocomplete
2024
Chat-in-IDE
(Cursor, Cody)
2025
Agentic CLI
(Claude Code v1)
2026
Plugins, agents,
parallel sessions
2025// six humans · eight weeks
who works when →
week 1week 4week 8
PM
Designer
Backend ×2
Frontend
QA
Booking-app MVP → 8 weeks · $96k
2026// one designer · three days
who works when →
day 1day 2day 3
Designer
Claude Code
Subagent ×3
Cowork review
Same brief → 3 days · $40 in API spend
Vibe coding

The medium is the prompt. Sketch becomes software.

// frame 01
Napkin sketch
// frame 02
A short prompt
> build the screen in this sketch
# attached: napkin.jpg
warm, calm, lots of air
// frame 03
Live UI
Vibe coding is when the prompt describes the feeling and the agent fills in the structure. You don't write the code. You write vibes that compile.
Agentic coding

Read. Plan. Act. Verify. Loop.

// 01Read
// 02Plan
// 03Act
// 04Verify
01
Read
Pull the relevant files, recent diffs, and constraints into context.
02
Plan
Draft numbered steps. Ask for any missing context. Stop.
03
Act
Run tools, write files, execute commands. One step at a time.
04
Verify
Run tests, read the result back, screenshot. Self-check, then loop.
Agentic coding is when you give the goal and the agent runs this loop on its own. Your job moves to the verify step: catch a wrong turn early, approve the right one.
Tool use

Every action is a round-trip.

A
Agent
decides, then reads the result
1 · the agent calls the tool 2 · the result comes back
T
Tool
runs in the real world
user: when's the next free telescope slot tonight?
// 1 · the agent calls a tool
→ tool_call: db.query("availability", date="2026-07-18", after="18:00")
← tool_result: [{slot: "19:30", capacity: 4}, {slot: "20:30", capacity: 2}]
// 2 · the agent reads the result and replies
agent: "There's a slot at 19:30 with 4 spaces. Want me to book it?"
// data Query the world SQL · search · file read
// act Change the world POST API · send email · book
// browse Use a browser click · fill · screenshot
// agent Delegate to another subagent · MCP server · plugin
03 · 1:45 – 2:00

Discussion: LLMs in the physics classroom

How students already use these tools, for better and worse.

React live
Scan to react
Student use today

Your students are already using it

As a tutor that never sleeps

  • Debug & explain code, line by line: the TA at 2 a.m.
  • A sounding board: “here’s my analysis plan, what am I missing?”
  • Practice problems, self-quizzing, “explain the paper this notebook cites”
  • And it can work: a well-designed AI tutor beat in-class active learning in a Harvard intro-physics RCT (n=194, 2025).

Against your assessment

  • Real-time overlay coaching on Zoom exams & interviews
  • Smart-glasses exams: photo in, whispered answer out
  • “Humanizers” that launder AI text past detectors
  • Autonomous agents that take the whole course: watched lectures, took quizzes, submitted essays
88% of students already use AI in their learning 77% of faculty use it in teaching 29% of students think instructors can guide them
Digital Education Council global survey 2026 (45,398 respondents, 35 countries) · RCT: Kestin et al., Sci. Reports 2025. The same capability powers both columns; course design, not policy, separates them.
Two questions for the room
Q1

If a model can derive the Lagrangian, run the simulation, and write the lab report, what in your course still requires a human physicist?

Which learning objectives survive contact with the tools students already carry, and which are we keeping the way we kept log tables?

What would you assess if you could grade only the process, never the artifact?

Q2

Where is the line between what students must do themselves and what they should learn to delegate?

You drive a car without being able to rebuild the engine, but someone has to be the mechanic. Which of your students are drivers, and which are mechanics?

Calculators didn’t end arithmetic instruction; they moved it. What’s the “moved” version of coding in physics, and what’s the minimum skill for verifying code you didn’t write?

04 · 2:00 – 2:30

Beyond the chatbot: agentic AI

Three tools (Lovable, Claude Cowork, Claude Design) pointed at one DSECOP module: Connecting Monte Carlo to Modern AI. Live, with all the rough edges.

A note on brands: I demo the Claude family because it’s what I use every day. Everything here has OpenAI, Google, and open-source equivalents; Julie shows Copilot and Gemini after the break.

3 demos
React live
Scan to react
Beyond chat

What’s newly possible

Agentic workflows

Give it a goal; it plans the steps and runs for hours, supervised rather than babysat.

Tool integration

Works inside your files, terminal, and documents, not beside them.

Computer use

Sees and controls a screen like a person: forms, LMS pages, plots.

Deep research

Multi-source, cited reports in half an hour; steps through novel problems.

Million-token context

A full semester of readings, or a full module repo, on the desk at once.

Multimodal & voice

Reads figures, hears speech, talks back. Grade a whiteboard photo.

Generated with Google NotebookLM

A podcast and a short video, from the seven papers below

Podcast · NotebookLM
How AI Is Reshaping Physics Education
--:--
Tool 1 of 3 · vibe coding

Lovable: describe the app, get the app

  • You write plain English; it builds a working web app, database and login included.
  • The easiest on-ramp in the “vibe coding” category (also: v0, Replit, Bolt, Claude Artifacts).
  • No IDE, no setup, just a browser tab. The free tier (5 credits/day) is enough to build your first tool today.

Why faculty should care

Every small classroom tool you never had a developer for: sign-up sheets, cold-call randomizers, participation trackers, a syllabus reviewer.

Live demo 1 of 3

Lovable, from a blank page

One prompt in, a deployed app out: ising-wonderland-explorer.lovable.app · total Lovable credits used: 15

Screenshot of the Ising Explorer app built by Lovable: live lattice, observables charts, and the measured magnetization against the Onsager curve
click to expand
I want you to build me a single, self-contained HTML file called `ising_explorer.html`: an interactive 2D Ising model simulator that a physics student could explore for twenty minutes and come away understanding phase transitions. Work in stages, use subagents for building and reviewing, and don't show me anything until your reviewer has signed off.

## Physics requirements

- 2D Ising model on a square lattice, Metropolis-Hastings dynamics, J = 1, kB = 1.
- State the convention you use for the Hamiltonian and the inverse temperature clearly in the UI, and place the critical point correctly for that convention. Print the theoretical value on screen.
- Overlay Onsager's exact magnetization curve wherever you plot M vs temperature, so simulation and theory can be compared at a glance.
- Include an external field H slider (small range, default 0) so students can see the transition wash out and try a simple hysteresis experiment.
- Offer both single-spin Metropolis and the Wolff cluster algorithm, with a toggle. Near the critical point, let students see for themselves that Metropolis slows down and Wolff doesn't. If you cannot verify your Wolff implementation is correct, leave it out and say so rather than shipping something wrong.

## Features I want (more than a basic demo)

1. **Live lattice view** on a canvas, at least 100x100, with adjustable lattice size (e.g., 50 / 100 / 200). Smooth animation, responsive controls while running.
2. **Temperature control** as a slider, plus preset buttons for hot, critical, and cold, plus an **Anneal** button that ramps the temperature slowly so the lattice orders without quench artifacts.
3. **Real-time charts** updating as the simulation runs: magnetization |M| and energy per spin vs time, and a running M vs T diagram that accumulates measured points against the Onsager curve.
4. **Measured observables panel**: |M|, energy per spin, and estimates of susceptibility and specific heat from fluctuations, with a short note explaining how each is computed.
5. **A guided experiments strip**: three or four one-line challenges (find the critical temperature, measure the hysteresis loop, compare Metropolis vs Wolff near Tc) that set the controls appropriately when clicked.
6. **Short embedded explanations**: a few sentences per concept, collapsible so they don't crowd the interface. Intermediate level, no fluff.

## Engineering constraints

- One HTML file, zero external dependencies, works offline when double-clicked. No CDN links, no build step.
- Must stay responsive on a mid-range laptop. Budget the simulation work per animation frame instead of running a fixed number of sweeps.
- Clean, restrained design: one accent color, readable typography, no visual clutter. It should look like a teaching tool, not a dashboard.

## How I want you to work

1. **Plan first.** Before writing code, produce a short plan: layout sketch, what runs in the main loop, how the physics maps to code, what could go wrong (metastable stripe states after a quench, critical slowing down, finite-size effects). Tell me the plan in one paragraph, then proceed. Don't wait for my approval.
2. **Build with one agent, review with others.** After the builder agent produces the file, launch two reviewer subagents with fresh eyes:
   - a **physics reviewer** that checks the acceptance rule, the boundary conditions, the placement of the critical point, the Onsager formula, and the observable estimators, by running the simulation logic headless (extract the JS and run it in Node with a DOM stub) and comparing measured values against known results;
   - a **UX and code reviewer** that checks for layout problems, unresponsive controls, misleading labels, and dead code.
3. **Fix everything they find, then re-run the physics checks.** Iterate until both reviewers pass. Only then give me the file.
4. **Show me the evidence.** In your final message, include the reviewers' key findings and the numbers from the physics validation (e.g., measured |M| at a temperature well below Tc vs the Onsager value, and measured Tc from the susceptibility peak vs theory). One short table is enough.

## Acceptance criteria (your reviewers should check every one)

- [ ] Hot lattice: |M| fluctuates near 0. Cold lattice: |M| reaches ~1 within a few seconds of annealing.
- [ ] The susceptibility peak lands within a few percent of the theoretical critical temperature for the stated convention.
- [ ] The measured M vs T points track the Onsager curve away from Tc.
- [ ] Wolff and Metropolis agree on equilibrium observables; Wolff visibly decorrelates faster near Tc.
- [ ] All controls work while the simulation runs; nothing freezes the page.
- [ ] The file opens correctly from a local double-click with no network access.

If any criterion cannot be met, tell me plainly which one and why instead of quietly shipping a weaker version.
Tool 2 of 3 · the folder-first agent

Claude Cowork: an AI that works in your folder

  • Point it at a folder of real files: desktop-first, and since July 2026 on web and mobile too.
  • Reads across documents; produces real artifacts: .docx, .xlsx, .pptx, .html.
  • Local-first on desktop: course materials, student work, and grades stay on your machine, the FERPA-safe default.

How to use it

Give it your Jupyter notebook and any other material you want to teach from, then ask it to generate the slides for you.

Watch the pitfalls

Generic AI slides are easy to make without understanding them, and students can do the same. Verifying the correctness of every claim on the slide is of utmost importance.

Our physics version

Point Cowork at DSECOP 320 · Connecting Monte Carlo to Modern AI (the Ising-model notebook) and have it build the instructor pack and classroom visuals around the notebook you already have.

It asks before it builds

What format should the slides be?
PowerPoint (.pptx)

Who are these slides for and how will they be used?
Teaching/workshop (AAPT)

Should the slides include figures generated by actually running the notebook code (lattice snapshots, magnetization curve)?
Yes, run the code (Recommended)

Live demo 2 of 3

Ask Cowork to build the app

One prompt asks for a small interactive app that helps a student understand a physics concept. Here: the 2D Ising model and its phase transition.

The full prompt is below. Copy it and swap in your own concept.

click to expand
I want you to build me a single, self-contained HTML file called `ising_explorer.html`: an interactive 2D Ising model simulator that a physics student could explore for twenty minutes and come away understanding phase transitions. Work in stages, use subagents for building and reviewing, and don't show me anything until your reviewer has signed off.

## Physics requirements

- 2D Ising model on a square lattice, Metropolis-Hastings dynamics, J = 1, kB = 1.
- State the convention you use for the Hamiltonian and the inverse temperature clearly in the UI, and place the critical point correctly for that convention. Print the theoretical value on screen.
- Overlay Onsager's exact magnetization curve wherever you plot M vs temperature, so simulation and theory can be compared at a glance.
- Include an external field H slider (small range, default 0) so students can see the transition wash out and try a simple hysteresis experiment.
- Offer both single-spin Metropolis and the Wolff cluster algorithm, with a toggle. Near the critical point, let students see for themselves that Metropolis slows down and Wolff doesn't. If you cannot verify your Wolff implementation is correct, leave it out and say so rather than shipping something wrong.

## Features I want (more than a basic demo)

1. **Live lattice view** on a canvas, at least 100x100, with adjustable lattice size (e.g., 50 / 100 / 200). Smooth animation, responsive controls while running.
2. **Temperature control** as a slider, plus preset buttons for hot, critical, and cold, plus an **Anneal** button that ramps the temperature slowly so the lattice orders without quench artifacts.
3. **Real-time charts** updating as the simulation runs: magnetization |M| and energy per spin vs time, and a running M vs T diagram that accumulates measured points against the Onsager curve.
4. **Measured observables panel**: |M|, energy per spin, and estimates of susceptibility and specific heat from fluctuations, with a short note explaining how each is computed.
5. **A guided experiments strip**: three or four one-line challenges (find the critical temperature, measure the hysteresis loop, compare Metropolis vs Wolff near Tc) that set the controls appropriately when clicked.
6. **Short embedded explanations**: a few sentences per concept, collapsible so they don't crowd the interface. Intermediate level, no fluff.

## Engineering constraints

- One HTML file, zero external dependencies, works offline when double-clicked. No CDN links, no build step.
- Must stay responsive on a mid-range laptop. Budget the simulation work per animation frame instead of running a fixed number of sweeps.
- Clean, restrained design: one accent color, readable typography, no visual clutter. It should look like a teaching tool, not a dashboard.

## How I want you to work

1. **Plan first.** Before writing code, produce a short plan: layout sketch, what runs in the main loop, how the physics maps to code, what could go wrong (metastable stripe states after a quench, critical slowing down, finite-size effects). Tell me the plan in one paragraph, then proceed. Don't wait for my approval.
2. **Build with one agent, review with others.** After the builder agent produces the file, launch two reviewer subagents with fresh eyes:
   - a **physics reviewer** that checks the acceptance rule, the boundary conditions, the placement of the critical point, the Onsager formula, and the observable estimators, by running the simulation logic headless (extract the JS and run it in Node with a DOM stub) and comparing measured values against known results;
   - a **UX and code reviewer** that checks for layout problems, unresponsive controls, misleading labels, and dead code.
3. **Fix everything they find, then re-run the physics checks.** Iterate until both reviewers pass. Only then give me the file.
4. **Show me the evidence.** In your final message, include the reviewers' key findings and the numbers from the physics validation (e.g., measured |M| at a temperature well below Tc vs the Onsager value, and measured Tc from the susceptibility peak vs theory). One short table is enough.

## Acceptance criteria (your reviewers should check every one)

- [ ] Hot lattice: |M| fluctuates near 0. Cold lattice: |M| reaches ~1 within a few seconds of annealing.
- [ ] The susceptibility peak lands within a few percent of the theoretical critical temperature for the stated convention.
- [ ] The measured M vs T points track the Onsager curve away from Tc.
- [ ] Wolff and Metropolis agree on equilibrium observables; Wolff visibly decorrelates faster near Tc.
- [ ] All controls work while the simulation runs; nothing freezes the page.
- [ ] The file opens correctly from a local double-click with no network access.

If any criterion cannot be met, tell me plainly which one and why instead of quietly shipping a weaker version.
Tool 3 of 3 · visuals

Claude Design: slides and animations from a prompt

  • Generates designed, animated visual content. Launched April 2026, research preview.
  • Slides render as interactive HTML; exports to PPTX, PDF, or a hosted link.
  • Best use in physics: concepts that move: phase transitions, wave interference, phase-space flow.

The prompt

Create a minimalist animation of the 2D Ising model for a title slide. A single square lattice of about 40x40 cells in two colors only (deep indigo and warm gold), spins flipping under Metropolis dynamics. Start hot and disordered, then cool slowly so ragged domains grow and merge until one color wins, hold for a moment, and gently loop back to hot. No axes, no labels, no controls, no chrome of any kind: just the lattice on a plain background with softly rounded cells. The motion should feel calm and organic, around 30 seconds per loop. One self-contained HTML file.

Spins start hot and disordered, then cool until one aligned domain takes over, before looping back.

05 · 4:15 – 5:00

Running Claude Code,
including open-weight models

The most capable agent of the afternoon, and how to run it without a paid API: open-weight models on your own machine, for every student.

2 demos
React live
Scan to react
The tool

Claude Code: an agent where your files live

01 · READ

Pulls the relevant files, data, and constraints into context.

02 · PLAN

Drafts numbered steps; asks about what’s missing; stops.

03 · ACT

Writes files, runs code and commands, one step at a time.

04 · VERIFY

Runs tests, reads results back, loops until it checks out.

Your job moves to “verify”

You stop typing the code and start catching the wrong turn early. Our students need the same skill, which makes this a teaching question as much as a tooling one.

For your research, too

Clean twenty years of survey data in an hour. Re-run an old paper’s analysis with a new control. Build the figures you never had time for. And at the frontier: the next slide.

Exhibit A · physics research

“Vibe physics”: a frontier calculation with Claude Code

Harvard theorist Matthew Schwartz supervised Claude, via Claude Code, through the resummation of the C-parameter Sudakov shoulder (a new factorization theorem) without editing a file himself. About two weeks (Dec 2025), against the one-to-two years he’d estimate for a grad student.

270 sessions · 51,248 messages · 110 manuscript drafts · 50–60 hrs of human oversight

“All calculations, numerical analysis, and manuscript preparation were performed by Claude … working under physicist supervision.”

From the paper’s abstract · arXiv:2601.02484

The catch, in Schwartz’s words

  • A “tendency to fabricate results”: tuning parameters until plots matched, once faking a plot outright
  • Constant verification required; the research taste is still entirely human
  • His read: it operates like a second-year grad student: tireless, fast, and in need of an advisor

Which is exactly the skill our students need: supervising work you didn’t do by hand.

anthropic.com/research/vibe-physics (Mar 2026) · not a one-lab story: GPT-5.2 Pro co-derived a new, human-verified gluon-amplitude result with IAS / Harvard / Cambridge authors (Feb 2026).
Where it lives

Same agent, six places to run it

Terminal CLI

claude in any shell: the engine itself. Scriptable; works over SSH on your cluster.

claude.ai/code

Cloud sandbox in a browser tab, wired to GitHub. Nothing to install, the easiest path for students.

Desktop app

Parallel local sessions with files and terminal included (Chat · Cowork · Code).

VS Code / JetBrains

A panel beside your code; edits appear as diffs you review.

Mobile

Watch long tasks, approve, and ship from your phone.

Your own hardware

Point it at a local open-weight model: no account, no API bill. Where we end today.

Project memory

CLAUDE.md: the course rules, in one file

# PHY 305 · Ising model project
## Physics
2D Ising on a square lattice, Metropolis algorithm.
Units: J = k_B = 1. Report T in units of J/k_B.
## Code rules
numpy only, no ML libraries. Seed every RNG.
Figures go to /figs as PNG, axes labeled.
Small, commented functions, first-course friendly.
## Verify
Check results against T_c ≈ 2.269 (Onsager)
before trusting any run.
  • A markdown file at the project root; the agent reads it at the start of every session.
  • Rules never have to live in every prompt; students prompt casually, constraints hold anyway.
  • For instructors: this is where your pedagogy goes. What the AI must not do for the student is a rule you can write down.
Working safely

Plan first. Execute later.

Plan Mode (Shift+Tab ×2) makes the agent draft its steps and stop: nothing changes on disk until you approve.

  • Catches ambiguity before anything is written
  • Clarifying questions arrive up front, in the plan
  • You fork the plan, not the codebase, when you don’t like the approach
PLAN MODE
> add a temperature sweep to the Ising notebook
I’ll work through this in 4 steps:
 1. Read the existing Metropolis loop
 2. Add a sweep over T = 1.0 … 3.5
 3. Plot ⟨M⟩ and χ vs T, mark T_c
 4. Re-run the notebook top to bottom
? One question: fixed lattice size, or sweep L too?
→ Approve · ✎ Edit · ✗ Cancel
For students, the plan is the artifact worth grading: it shows what they understood before any code existed.
Live demo

The same ask, in Claude Code

Same prompt as the Cowork build. What changes is the setup around it:

  • Project memory: a small CLAUDE.md sets the rules once; every session starts from them.
  • Skills: installed workflows the agent pulls in when they fit the task.
  • Agent teams: one builder plus fresh-eyes reviewers, working in parallel.
# ising_explorer · project rules
## Verify like a user
Open the app in a real browser with the Playwright
CLI and drive every control after each change.
Seeing it work beats reading the code.
## Skills
Use /frontend-design before layout or styling work.
Use /dataviz for the charts.
Use /code-review at high effort before shipping.
## Agent team
One builder agent. Two fresh-eyes reviewers,
physics and UX, in parallel. Iterate until both
sign off; only then show me the file.
click to expand

All six builds were reviewed the same way: each app's simulation core was pulled out and run headless in Node (50×50 lattice, 2000+2000 sweeps) against Onsager's exact solution, on top of hands-on walkthroughs in the browser. Higher is better; each metric is out of 10.

MetricHaikuSonnetOpusFableCC-FableCC-Fable-vhigh
Physics accuracy4710109.510
Code quality68.59.59.58.510
Visual design57.58.5899.5
User friendliness4.588.58.599.5
Pedagogical value3.588.59910
Spec compliance4910101010
Total /60274855555559

CC = Claude Code (project memory, skills, a builder plus two reviewer agents); the other four were one-shot Cowork builds of the same prompt. Winner: CC-Fable-vhigh at 59/60, with flawless physics and beyond-spec teaching features. Fable, Opus, and CC-Fable tie just behind; Haiku's kernel is correct but its readouts would mis-teach.

click to expand
I want you to build me a single, self-contained HTML file called `ising_explorer.html`: an interactive 2D Ising model simulator that a physics student could explore for twenty minutes and come away understanding phase transitions. Work in stages, use subagents for building and reviewing, and don't show me anything until your reviewer has signed off.

## Physics requirements

- 2D Ising model on a square lattice, Metropolis-Hastings dynamics, J = 1, kB = 1.
- State the convention you use for the Hamiltonian and the inverse temperature clearly in the UI, and place the critical point correctly for that convention. Print the theoretical value on screen.
- Overlay Onsager's exact magnetization curve wherever you plot M vs temperature, so simulation and theory can be compared at a glance.
- Include an external field H slider (small range, default 0) so students can see the transition wash out and try a simple hysteresis experiment.
- Offer both single-spin Metropolis and the Wolff cluster algorithm, with a toggle. Near the critical point, let students see for themselves that Metropolis slows down and Wolff doesn't. If you cannot verify your Wolff implementation is correct, leave it out and say so rather than shipping something wrong.

## Features I want (more than a basic demo)

1. **Live lattice view** on a canvas, at least 100x100, with adjustable lattice size (e.g., 50 / 100 / 200). Smooth animation, responsive controls while running.
2. **Temperature control** as a slider, plus preset buttons for hot, critical, and cold, plus an **Anneal** button that ramps the temperature slowly so the lattice orders without quench artifacts.
3. **Real-time charts** updating as the simulation runs: magnetization |M| and energy per spin vs time, and a running M vs T diagram that accumulates measured points against the Onsager curve.
4. **Measured observables panel**: |M|, energy per spin, and estimates of susceptibility and specific heat from fluctuations, with a short note explaining how each is computed.
5. **A guided experiments strip**: three or four one-line challenges (find the critical temperature, measure the hysteresis loop, compare Metropolis vs Wolff near Tc) that set the controls appropriately when clicked.
6. **Short embedded explanations**: a few sentences per concept, collapsible so they don't crowd the interface. Intermediate level, no fluff.

## Engineering constraints

- One HTML file, zero external dependencies, works offline when double-clicked. No CDN links, no build step.
- Must stay responsive on a mid-range laptop. Budget the simulation work per animation frame instead of running a fixed number of sweeps.
- Clean, restrained design: one accent color, readable typography, no visual clutter. It should look like a teaching tool, not a dashboard.

## How I want you to work

1. **Plan first.** Before writing code, produce a short plan: layout sketch, what runs in the main loop, how the physics maps to code, what could go wrong (metastable stripe states after a quench, critical slowing down, finite-size effects). Tell me the plan in one paragraph, then proceed. Don't wait for my approval.
2. **Build with one agent, review with others.** After the builder agent produces the file, launch two reviewer subagents with fresh eyes:
   - a **physics reviewer** that checks the acceptance rule, the boundary conditions, the placement of the critical point, the Onsager formula, and the observable estimators, by running the simulation logic headless (extract the JS and run it in Node with a DOM stub) and comparing measured values against known results;
   - a **UX and code reviewer** that checks for layout problems, unresponsive controls, misleading labels, and dead code.
3. **Fix everything they find, then re-run the physics checks.** Iterate until both reviewers pass. Only then give me the file.
4. **Show me the evidence.** In your final message, include the reviewers' key findings and the numbers from the physics validation (e.g., measured |M| at a temperature well below Tc vs the Onsager value, and measured Tc from the susceptibility peak vs theory). One short table is enough.

## Acceptance criteria (your reviewers should check every one)

- [ ] Hot lattice: |M| fluctuates near 0. Cold lattice: |M| reaches ~1 within a few seconds of annealing.
- [ ] The susceptibility peak lands within a few percent of the theoretical critical temperature for the stated convention.
- [ ] The measured M vs T points track the Onsager curve away from Tc.
- [ ] Wolff and Metropolis agree on equilibrium observables; Wolff visibly decorrelates faster near Tc.
- [ ] All controls work while the simulation runs; nothing freezes the page.
- [ ] The file opens correctly from a local double-click with no network access.

If any criterion cannot be met, tell me plainly which one and why instead of quietly shipping a weaker version.
The free-model move

Claude Code on open-weight models

Claude Code just talks to a model over an API. Point it at a local server instead of the cloud, and it drives an open-weight model on your own machine, served by LM Studio or Ollama.

  • $0 API: you pay only for your laptop’s electricity
  • Private & offline: code and prompts never leave the machine
  • One switch: an environment variable; nothing global changes

Model families that work: Qwen · Gemma · Llama · DeepSeek · Mistral. LM Studio and Ollama both speak Claude Code’s native protocol now; no adapter needed.

# one run only, normal setup untouched
ANTHROPIC_BASE_URL=http://localhost:1234 \
ANTHROPIC_AUTH_TOKEN=local \
ANTHROPIC_MODEL=qwen/qwen3-coder \
claude

> build a projectile-motion explorer
  in one HTML file
• running on Qwen, locally · $0.00 API cost
Setup

Five steps, two gotchas

1

Install LM Studio: enable developer mode

2

Download a model: smallest your laptop runs (Gemma ~6 GB → Qwen ~19 GB)

3

Load + start server: READY and the toggle at localhost:1234

4

Confirm model ID: the API identifier in the right panel

5

Run claude: with the three env vars

Gotcha 1: context length

Set it to 32K or more when loading the model. Claude Code sends big requests; the default window makes it fail and retry forever.

Gotcha 2: tool calling

Small local models are weaker at tool calling, the mechanism the agent uses to run code and edit files. Expect rough edges; Qwen handles it best of the current crop.

claude-code-local-model-setup.md the full guide + reusable launcher script
Why bother with free models

Every student can have this

“Equity is the provision of personalized resources needed for all individuals to reach common goals.”

Dr. Laura Latta

  • Colab gave every student a free GPU; open-weight models give every student a free agent.
  • No subscription, API key, or credit card; a lab machine or mid-range laptop is enough.
  • Works offline: field courses, secure environments, unreliable campus wifi.
  • Privacy-compliant by construction, the safe choice for anything touching student data.
  • And your course doesn’t depend on any one vendor’s pricing decisions.
The caveat: open-weight models are not as capable as the frontier ones, and they will always lag behind. It doesn’t fully solve the equity problem either, since students with more powerful laptops can run more powerful models. But it gives every student something to work with without paying.
Before you leave

Three things to try next week

1

Adopt a module

Pick one DSECOP module that fits a course you teach this fall and run it in Colab, the way Julie showed.

2

Build one tool

One small classroom tool in Lovable, or point Cowork at your own course folder and see what teaching package falls out.

3

Stretch goal: a free agent

Over the break, install LM Studio and run Claude Code on a local model; the launcher script in the materials gets you there step by step.

Thank you.

Mohammad Soltaniehha · Boston University · msoltani@bu.edu

dsecop.org · modules, webinars, workshops, and the 2026 LLM fellowship
github.com/GDS-Education-Community-of-Practice/DSECOP · all modules, CC0
APS GDS Slack · join the community
Slides, modules & the local-model guide
soltaniehha.com/AAPT-2026
Workshop survey
Open the survey

Funded by an AIP Venture Grant, in partnership with AAPT.