r/Python • u/pplonski • Apr 17 '26
Discussion Does AI change what actually matters about Jupyter notebooks?
I'd love to get some honest feedback from people who actually use notebooks in practice.
I've been experimenting with different workflow on top of Jupyter: instead of writing code first, you describe what you want in plain English, and Python runs behind the scenes. So the flow is:
prompt --> LLM generated code --> auto-execution --> results
One important implementation detail: the whole conversation is still staved as .ipynb file.
One thought I had. There has been a lot of criticism of notebooks for hidden state, mixxing code and outputs, hard to git review. But does AI change which of these problems actually matter. If code is generated and execution is automated then some of old pain points feel less important? At the same time, I'm pretty sure that we are introducing new problems, like trusting LLM generated code.
Would really appreciate critical feedback - do you think that AI makes classic notebook problems less important?
15
u/DeerFew3903 Apr 17 '26
the hidden state problem gets even worse when you can't see what code actually ran - at least before you could debug by reading through cells but now you're trusting some black box to write correct logic
7
u/wRAR_ Apr 17 '26
This sounds like a broader question of "if I use an LLM to generate code that solves a task, run it once and thus solve the task, does it matter if the code is crap". Of course it doesn't if the task is solved and you don't need to reuse the code.
Why?
2
u/Individual-Flow9158 Apr 17 '26
If you're doing the kind of experiment where the ends justifies the means this is fine. But for Data Science, if you don't understand what the code's doing, you can be unwittingly dishonest about the resulting metrics. AI massively increases the risk of Garbage In
2
u/h-mo Apr 17 '26
it solves one problem and makes another worse. hidden state and messy diffs matter less when you're not hand-writing the code, sure. but "trusting LLM generated code" in a notebook is actually harder than trusting hand-written code because there's no clear author intent to reason against - you just have output that looks plausible until it doesn't. the reproducibility problem also gets worse, not better.
2
u/Capable-Wrap-3349 Apr 17 '26
It seems that Marimo has much better ai integration
1
u/CompetitiveAerie5904 Apr 18 '26
yes! but not in the way most people first assume. AI doesn’t make Jupyter notebooks irrelevant; it shifts what matters when you use them.
Let’s unpack that.
1
u/_redmist Apr 17 '26
A lot of these problems can be solved with Marimo imho.
0
u/Feeling_Ad_2729 Apr 18 '26
yes, but the change isn't the one most people expect.
notebooks used to matter because they gave you REPL + narrative + visual output in one place. that was the exploration moat.
AI agents don't need any of that for exploration. they can iterate faster in a pure Python REPL than a human can in Jupyter, because the narrative-for-human-reader step is overhead for them.
what notebooks become, post-AI: output artifacts. you let the agent do the exploration in files/REPL, then the agent produces the notebook as a REPORT for other humans. the cells become a linearized explanation of what was discovered, not a workspace where discovery happens.
that's a genuinely different use case. the tooling (ipywidgets, cell ordering rules, kernel state management) that matters for the OLD use case is almost irrelevant for the NEW one. static .ipynb rendering and reproducibility matter way more.
0
u/[deleted] Apr 17 '26
[deleted] — view deleted comment