You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit f471c89
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: lectures/lec_08_pandas.qmd
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -397,14 +397,14 @@ Session VI gave you the basics, so here is why it sometimes fails.
397
397
398
398
## How it was trained
399
399
400
-
-**Pre-training**: predict the next token over massive text, where the [weights]{.highlight} inside get adjusted. Applying them afterwards (called *inference*) is much cheaper
400
+
-**Pre-training**: predicting the next token over massive text sets the [weights]{.highlight}. Using them later (*inference*) is much cheaper
401
401
-**Fine-tuning**: curated examples teach it to follow instructions
402
402
-**RLHF** (reinforcement learning from human feedback): humans rank answers and it learns to prefer the ranked-higher ones
403
-
- Its knowledge has an end date, the [knowledge cutoff]{.highlight}: after it, it guesses fluently or uses web search. And it inherits the [biases]{.highlight} of the text it read!
403
+
- Its knowledge ends at the [knowledge cutoff]{.highlight}: after that, it guesses fluently or searches the web. It also inherits the [biases]{.highlight} of the text it read
404
404
405
405
. . .
406
406
407
-
Every stage rewards *sounding* right. Verifacation is your job (at least for now), and step 3 of the verify workflow is how.
407
+
Every stage rewards *sounding* right. Verification is your job (for now), and step 3 of the verify workflow is how.
408
408
409
409
## Disclosure: say what the AI did
410
410
@@ -459,12 +459,12 @@ Open the agent panel (the sparkle icon, bottom right), pick **Mistral Vibe**, an
459
459
460
460
> *In `lab_08_dataroom.py`, fill in `revenue_by_zone` in Task 4: a dict, zone name to euros, from the DataFrame `clean`. Change nothing else.*
461
461
462
-
1.**Read it**: Zed shows the changes as a *diff*, old lines red, new lines green. Read it **before** you accept
462
+
1.**Read it**: Zed shows a *diff*, old lines red, new lines green. Read it **before** you accept
463
463
2.**Run it**, then **test it** on a case where you know the answer
464
464
465
465
. . .
466
466
467
-
More on how gAI works and how you can use it even better in Session X. Today it is a tool you supervise.
467
+
Session X shows how an agent works. Today you supervise it.
Copy file name to clipboardExpand all lines: lectures/lec_10_projects.qmd
+48-44Lines changed: 48 additions & 44 deletions
Original file line number
Diff line number
Diff line change
@@ -37,7 +37,7 @@ format:
37
37
38
38
## The deal closes
39
39
40
-
The checkpoint is behind you, and so, it turns out, is the startup. Overnight rival chain **MunchCorp** stopped competing and made an offer: they're **buying the company.** The investor read the term sheet, did the math against her own, and told you to take it: her money would have bought growth, theirs buys the whole shop.
40
+
The checkpoint is behind you, and so is the startup. Overnight rival chain **MunchCorp** stopped competing and made an offer: they're **buying the company.** The investor read the term sheet, did the math against her own, and told you to take it: her money would have bought growth, theirs buys the whole shop.
41
41
42
42
. . .
43
43
@@ -49,7 +49,7 @@ No cliff-edge growth chart with a chopped axis. Just data that survived a second
49
49
50
50
## The handover
51
51
52
-
Tobi's job today is to hand over the **data room**: the folder with every file the company ever built. You know that folder. It's `python-labs`, two labs later.
52
+
Tobi's job today is to hand over the **data room**: the folder with every file the company ever built.
53
53
54
54
. . .
55
55
@@ -62,19 +62,15 @@ MunchCorp's lawyer opens it and asks two questions:
62
62
63
63
Nobody can say. A folder shows what is in it **now**, and nothing about how it got there. Today you give a folder a **history**, with a tool called [git]{.highlight}.
64
64
65
-
## Your exit package
65
+
## The exit package
66
66
67
67
Every acquisition comes with an exit package. Here's yours: you don't join MunchCorp. You **spin off your own idea** and build it.
68
68
69
69
. . .
70
70
71
71
- The tools are the ones professionals use: uv and Zed have been on your laptop since Session VII, **git and GitHub** join them today
72
72
- The work is a real project, built in a group of three, over the next weeks
73
-
- Today we set up the repo; the building starts here
74
-
75
-
. . .
76
-
77
-
Let's get you kitted out.
73
+
- Today we set up the repo as the building starts there
78
74
79
75
# [The Project]{.flow} {.title}
80
76
@@ -90,19 +86,18 @@ Over the next weeks you build and present **one real project**.
90
86
. . .
91
87
92
88
:::{.callout-tip}
93
-
Pick something you're **actually interested in**. You'll spend real hours on it. Curiosity is the fuel that carries a project past the boring middle.
94
-
:::
89
+
Pick something you're **actually interested in**. You'll spend real hours on it.
95
90
96
91
## How it counts
97
92
98
93
- Project **and** presentation together are worth **40 of the 100** course points, judged on scope, work and presentation. Everyone in a group gets the same points
99
94
- Your **commit history counts**: it's the evidence of *how* the work happened, which the final state alone can't show. Commit small and often (git block, shortly)
100
-
-**Sessions XI and XII are supervised work sessions**: I'm in the room while you build, so bring your questions
95
+
-**Sessions XI and XII are supervised work sessions**: I'm in the room while you build, so you can ask your questions
101
96
102
97
. . .
103
98
104
99
:::{.callout-note}
105
-
The project need not be flawless; an unfinished one can be presented too. Show that you scoped it realistically, built it in the open, and can explain your own code. That's the bar.
100
+
The project need not be flawless, an unfinished one can be presented too! Show that you scoped it realistically, built it in the open, and can explain your own code.
106
101
:::
107
102
108
103
## Games you can play at the demo
@@ -144,7 +139,7 @@ The project need not be flawless; an unfinished one can be presented too. Show t
144
139
## Your own idea
145
140
146
141
- It is the **best choice**, once I approve it. **Make it ambitious**
147
-
-Bring it to me today, and we settle scope and feasibility together
142
+
-Tell it to me today, and we settle scope and feasibility together
148
143
- Every idea on the menu in full, with its core, its stretch and the work for three people: [Project Ideas](../general/project-ideas.qmd)
149
144
150
145
# [Form your group]{.flow} {.title}
@@ -158,16 +153,16 @@ You build your project with the agent, and the agent lives in Zed. So **every gr
158
153
159
154
## Take ~25 minutes
160
155
161
-
Right now, in the room:
156
+
Right now:
162
157
163
-
-**Find your two partners.** No group yet? **Come to the front**, I'll match you
164
-
-**Pick a direction** from the menu, or bring your own
165
-
- Talk it through: what's the *core* you can definitely finish, what's a *bonus* if time allows?
158
+
-**Find your two partners.** No group yet? **Ask me**, I'll match you
159
+
-**Pick a direction** from the provided ideas, or bring your own
160
+
- Talk it through!
166
161
167
162
. . .
168
163
169
164
:::{.callout-tip}
170
-
**A good outcome by the end of this block:** a one-sentence pitch ("we're building X that does Y for Z"), a name for the project, and a decision on who owns the shared repo (the owner creates it in the git block; the partners clone). The sentence keeps you honest about scope; the name goes on the repo in a minute.
165
+
**A good outcome by the end of this block:** a one-sentence pitch ("we're building X that does Y for Z"), a name for the project, and a decision on who owns the shared repo (the owner creates it in the git block; the partners clone).
171
166
:::
172
167
173
168
# [Your First Repo]{.flow} {.title}
@@ -185,12 +180,12 @@ gh auth status
185
180
. . .
186
181
187
182
:::{.callout-important}
188
-
**Missed Session IX, or the login has gone?**Don't burn the session fighting it. Sit with a partner whose laptop works and follow along on the slides. The [one-time setup](../general/git-basics.qmd#one-time-setup) takes ten minutes, at the break or with me in Session XI. Nobody's project stalls on a login.
183
+
**Missed Session IX, or the login has gone?** Sit with a partner whose laptop works and follow along on the slides. The [one-time setup](../general/git-basics.qmd#one-time-setup) takes ten minutes, at the break or with me in Session XI.
189
184
:::
190
185
191
186
## Your project starts on GitHub
192
187
193
-
Everyone, right now, a **practice repo**. On [github.com](https://github.com) click **New repository**, then:
188
+
Everyone, right now, create a **practice repo**. On [github.com](https://github.com) click **New repository**, then:
194
189
195
190
-**Name**: `python-practice`
196
191
-**Private**; tick **Add a README file**
@@ -200,11 +195,11 @@ Everyone, right now, a **practice repo**. On [github.com](https://github.com) cl
200
195
201
196
. . .
202
197
203
-
That's a **repository**: a folder git watches, with its whole history. So far it lives only on GitHub. Next we bring it down.
198
+
That's a **repository**: a folder git watches, with its whole history. So far it is only on GitHub.
204
199
205
200
## Bring it down: clone
206
201
207
-
In Zed's command palette (`Cmd/Ctrl+Shift+P`): **`git: clone`**, paste the URL, and pick the folder that `python-labs`sits in, so the repo lands **next to**`python-labs` and not inside it. Zed opens the new folder as your workspace: the file tree on the left shows `README.md` and `.gitignore`.
202
+
In Zed's command palette (`Cmd/Ctrl+Shift+P`): **`git: clone`**, paste the URL, and pick the parent folder that your course code sits in, so the repo lands **next to**it and not inside it. Zed opens the new folder as your workspace: the file tree on the left shows `README.md` and `.gitignore`.
Everything from here on happens **inside this folder**: git, uv, the AI. If Zed ever shows an empty file tree, **File → Open Folder** and pick the cloned folder itself, not the one above it.
213
+
Everything from here on happens **inside this folder**: git, uv, the AI. If Zed ever shows an empty file tree, **File → Open Folder** and pick the cloned folder itself.
219
214
:::
220
215
221
216
## Make it a Python project: `uv init`
@@ -232,7 +227,7 @@ uv run python main.py
232
227
. . .
233
228
234
229
:::{.callout-note}
235
-
**`--no-package`** keeps it a flat folder of scripts, like `python-labs`, which the same command made in Session VII; without it, uv builds an installable package layout you don't need yet. And no `git init`: the folder came from GitHub, it **is** a git repository already.
230
+
**`--no-package`** keeps it a flat folder of scripts. Without it, uv builds an installable package layout you don't need yet. And no `git init`: the folder came from GitHub, it **is** a git repository already.
236
231
:::
237
232
238
233
## Same agent, new folder
@@ -241,7 +236,7 @@ Part III **encourages** AI, and your agent is already here: Mistral Vibe works i
241
236
242
237
> *Explain what `main.py` does, then add a one-line comment at the top that says so. Don't change anything else.*
243
238
244
-
This time, **watch the panel while it works:** what does Vibe do before it shows you a change? Then read the diff before you accept it, as always.
239
+
This time, **watch the panel while it works:** what does Vibe do before it shows you a change? Then read the diff before you accept it.
245
240
246
241
. . .
247
242
@@ -251,7 +246,7 @@ The disclosure rule applies from today: your repo's `README.md` says **which too
251
246
252
247
## Inside the panel: a model in a loop
253
248
254
-
- Mistral Vibe is an [agent]{.highlight}: the language model you met in Session VI, wired into a loop with tools
249
+
- Mistral Vibe is an [agent]{.highlight}, wired into a loop with tools
255
250
- The model **proposes** an action: read a file, edit a line, run a command
256
251
- The tool **runs** it, the result **feeds back**, and it proposes again, until the goal is met
257
252
- No magic, and no memory between sessions
@@ -260,6 +255,16 @@ The disclosure rule applies from today: your repo's `README.md` says **which too
260
255
261
256
Every failure mode from Sessions VI and VIII applies at every step, and a loop gives them many steps to compound in. The diff you just read is the guardrail.
262
257
258
+
## One prompt, no feedback
259
+
260
+
Ethan Mollick, an entrepreneurship professor, gave Anthropic's model Fable 5.2 a single prompt: *"create the most impressive thing I can share with people when you launch."* He gave no feedback after that [@mollick_fable_2026].
261
+
262
+
[Watch what it made, to the end](https://www.oneusefulthing.org/p/fable-52-and-jagged-agi)
263
+
264
+
. . .
265
+
266
+
Mollick also found some misses. Fable's first course website was "accurate and joyless", and "the AI did not notice these problems itself." Noticing stays your job (at least for now).
267
+
263
268
# [Git]{.flow} {.title}
264
269
265
270
## The five words
@@ -274,7 +279,7 @@ Git has a small vocabulary. These five cover all this project needs:
274
279
275
280
. . .
276
281
277
-
Two of them you've already done: the repo exists, and you cloned it. The other three now, **live, in your practice repo**. Mistakes are cheap when the repo is five minutes old.
282
+
Two of them you've already done: the repo exists, and you cloned it. The other three now, **live, in your practice repo**.
278
283
279
284
## Your first commit
280
285
@@ -314,7 +319,7 @@ Two commits in, the folder has a history. Read it:
314
319
git log --oneline
315
320
```
316
321
317
-
One line per commit, newest first: a short ID and the message. Yours sits on top of GitHub's `Initial commit`. On github.com, **Commits** (top right of the file list) shows the same list with author and time; click a commit to see what it changed.
322
+
One line per commit, newest first: a short ID and the message. Yours sits on top of GitHub's `Initial commit`. On github.com, **Commits** (top right of the file list) shows the same list with author and time, click a commit to see what it changed.
318
323
319
324
. . .
320
325
@@ -359,39 +364,33 @@ Cloning brings the whole project, its history and the connection to GitHub; the
359
364
360
365
All of you have now pushed and pulled in the real repo. On github.com, **Commits** shows every name.
361
366
362
-
. . .
363
-
364
-
:::{.callout-note}
365
-
**Clock ran out?** This step can wait: inviting and cloning works just as well at the start of **Session XI**, with me in the room.
366
-
:::
367
-
368
367
## How we work together
369
368
370
-
Three people, one repo. Four habits keep it painless:
369
+
Three people, one repo. Four habits keep it easy:
371
370
372
371
-**Pull before you start.**`git: pull` first, every session: this alone prevents almost every problem
373
372
-**Commit small and often.** Clear messages, no giant commits
374
-
-**A conflict? Call me.** If git marks a clash, don't fix it alone in week one. Bring it to class
373
+
-**A conflict? Call me.** If git marks a clash, don't fix it alone in week one. Ask me!
375
374
-**Never force anything.** No `--force`, no "force push", ever
376
375
377
376
. . .
378
377
379
378
:::{.callout-note}
380
-
Everything today (the actions, the terminal equivalents, the setup, and a **cheatsheet table**) lives on the [Git Basics](../general/git-basics.qmd) page. When today's follow-along is a fading memory, that's the page you reopen.
379
+
Everything today (the actions, the terminal equivalents, the setup, and a **cheatsheet table**) lives on the [Git Basics](../general/git-basics.qmd) page.
381
380
:::
382
381
383
382
# [Send-off]{.flow} {.title}
384
383
385
384
## The road to the finish
386
385
387
-
-**Session XI**: work session, plus one short segment: why AI text now carries a watermark, and why that makes your README disclosure standard practice
388
-
-**Session XII**: work session, plus teaching your agent your project's rules
389
-
-**Session XIII**: Demo Day, and where this course hands you over to your thesis
386
+
-**Session XI**: work session, plus teaching your agent your project's rules
387
+
-**Session XII**: work session, plus why AI text now carries a watermark, and what AI means for your first job
388
+
-**Session XIII**: Final presentations
390
389
391
390
. . .
392
391
393
392
:::{.callout-tip}
394
-
Between now and then, the repo tells your story. Commit as you go. A steady history is worth more than a heroic final night.
393
+
Between now and then, the repo tells your story. Commit as you go!
395
394
:::
396
395
397
396
# [Demo Day]{.flow} {.title}
@@ -405,16 +404,21 @@ Between now and then, the repo tells your story. Commit as you go. A steady hist
405
404
## What to show
406
405
407
406
-**The thing running.** The output, and the command that produces it
408
-
-**How you worked.** Open the repo: the commit history instead of describing it
409
407
-**Your AI disclosure.** Which tool, what for, what you verified yourself
410
408
-**What went wrong.** Where you had to step in, what cost you an hour
411
409
412
410
. . .
413
411
414
-
Your machine, your repo, your demo: it must run from the clone on the room's projector.
415
-
412
+
Your computer, your repo, your demo: it must run in class.
416
413
## The reference pages
417
414
418
415
::: {.callout-note}
419
416
The [Git Basics](../general/git-basics.qmd) page is the reference version of everything we did live today. The setup from Session VII lives on [Installing Python](../general/uv.qmd) and [AI Tools](../general/ai-tools.qmd).
0 commit comments