CLEAN
CONTEXT

how to run Claude Code for days
without remembering anything

Jan Mikeš

YOUR LONGEST
CLAUDE CODE SESSION?

hands up. keep them up.

act 0 · hook

MY RECORD:

I DON'T KNOW.
I DON'T WANT
TO REMEMBER.

act 0 · hook

ONE SESSION, LAST WEEK

42work packages
3milestones
0lines of code I wrote
1paste
act 1 · what happened

TO ME, THAT WAS JUST A WEEK

then I mentioned it to a friend.

"WAIT.
HOW DID YOU
DO THAT?"

that reaction is the only reason
this talk exists.

act 1 · what happened

THE CONVERSATION
IS NOT
THE MEMORY.

memory = PROGRESS.md + git history + CLAUDE.md

act 1 · what happened

THE SHAPE

            ORCHESTRATOR      ← reads only the ledger
         (never reads code)   ~6-10k tokens / package
                  │
       ┌──────────┼──────────┐
       ▼          ▼          ▼
  implementer  reviewer  architect
    (fresh)    (fresh)  (read-only)
       │
       ▼
  PROGRESS.md ── commit ── push
act 1 · what happened

YOU DON'T NEED TO
REMEMBER
ANY OF THIS.

Claude Code will do all of it for you.

the trick is on the last slide.
that's the one you photograph.

act 2 · the release

FASTEN SEATBELTS

cruising altitude · 8 rules · 4 minutes

preflight

LAUNCH

# survive a dropped terminal / closed SSH
$ tmux new -s claude

# stop the machine sleeping — macOS.
# Linux: systemd-inhibit · Windows: powercfg / caffeine
$ caffeinate -dimsu

$ claude --permission-mode bypassPermissions
act 3 · fly-by
01 / 08 · cruising

THE BOSS NEVER
OPENS THE REPO

the orchestrator — the one session you actually talk to

"You never write source code yourself."

its context stays flat forever

act 3 · fly-by
02 / 08 · cruising

FRESH CONTEXT PER
UNIT OF WORK

"Delegate the WP to the implementer
 subagent (fresh context)"

quality dies past ~100–150k tokens

act 3 · fly-by
03 / 08 · cruising

STATE LIVES
IN FILES

"Read only PROGRESS.md
 and subagent reports"

files survive compaction. chat doesn't

act 3 · fly-by
04 / 08 · cruising

NEVER TRUST
THE REPORT

"Verify independently in your own shell"

agents report optimistically

act 3 · fly-by
05 / 08 · cruising

A DIFFERENT AGENT
REVIEWS THE WORK

"REQUEST_CHANGES → new round (max 3),
 then BLOCKED"

bounded loops. nothing fixes forever

act 3 · fly-by
06 / 08 · cruising

PUSH AFTER
EVERY PACKAGE

"push to origin/main immediately"

a crash costs one package, not a day

act 3 · fly-by
07 / 08 · cruising

WRITE THE RESUME
NOTE EARLY

"Before the conversation grows long…
 after any compaction, READ IT FIRST"

this is the whole survival mechanism

act 3 · fly-by
08 / 08 · descending

BLOCKED ≠ STOPPED

"move on to other WPs, stop only
 when no WP can proceed"

there is no "ask Jan". Jan is asleep

act 3 · fly-by

TURBULENCE

AUTOCOMPACT
IS NOT THE ENEMY.

it will happen. several times.
IT'S SUPPOSED TO.

worst case = one repeated review round
nothing commits until it's green
act 4 · turbulence

THERE IS NO
AUTOPILOT LIMIT

no budget cap.
no per-agent limit.
no "stop at $200".

API:          $500 – $2000
Subscription: you stall until reset

WE ARE THE BRAKE.

act 4 · turbulence

IT WILL LAND EARLY

not a crash. it decides it has done "enough".

  "I have completed the implementation!"

SO YOU DEFINE "DONE".

# the only exit condition, in the prompt
loop until every WP is DONE or BLOCKED

# and enforce it, so it cannot opt out
Stop hook: refuse to stop while TODO remains
act 4 · turbulence

THINGS THAT KILLED
MY SESSION

…that's why the launch slide had tmux and caffeinate.

act 4 · turbulence

AND THE REST OF THE BILL

BLAST RADIUS bypass = it can run anything
QUALITY DRIFT fresh context forgets your conventions
TESTS LIE weak assertions pass verify AND review
THE PLAN IS A GUESS 42 packages ordered before any code ran

it degrades gracefully. it does not degrade to zero.

act 4 · turbulence · CUT IF LONG

QUICK — NAME THREE
OF THE EIGHT RULES.

exactly. and it doesn't matter.

act 5 · landing

THE ONLY SLIDE THAT MATTERS

$ claude

> i want a long-running, several-days
  autonomous session with clean context.
  write me the prompt for my task.
…or scan the QR on the next slide
act 5 · landing

CLAUDE CLAUDING

it knows its own subagents
it knows its own hooks
it knows its own compaction
it knows its own failure modes

DON'T ASK ME.
STOP COLLECTING PROMPTS.
ASK CLAUDE HOW TO CLAUDE.

act 5 · landing
QR code to techmeetup-43-1.janmikes.cz

techmeetup-43-1.
janmikes.cz

full deck · the full prompt · the 8 rules

(you didn't need to write any of it down)

so — who's beating
the record tonight?

1 / 26
speaker notes — press N to hide

enter space next slide

backspace previous slide

N speaker notes

O jump to slide

F fullscreen

T light / dark theme

home end first / last slide

? close this help