YouTube2Text

Steering Claude Code Through Hours-Long Sessions: Plan Mode, Compact, Rewind, Goals — Transcript

by Claude · 731 words · 110 segments · language en · Watch on YouTube

Full transcript

  1. 0:02You can prompt Claude and watch it
  2. 0:03finish a quick task, but running a long
  3. 0:05one is much harder. Refactoring across a
  4. 0:07dozen files or implementing a new
  5. 0:09feature can take hours, and if you
  6. 0:10aren't steering Claude in the right
  7. 0:11direction, it can potentially take
  8. 0:13longer. But, there are many ways to help
  9. 0:15Claude during these long sessions.
  10. 0:18There are two important habits. The
  11. 0:20first is to scope the work before Claude
  12. 0:22starts. So, if you use plan mode, Claude
  13. 0:24will do the research in read-only mode
  14. 0:26and hand you a plan.
  15. 0:28Once the plan has been provided,
  16. 0:29actually read through it. The more
  17. 0:31thorough the plan, the less likely that
  18. 0:32you're going to have hiccups when Claude
  19. 0:34executes. And when it comes to revising
  20. 0:36the plan, just ask Claude to add it
  21. 0:38where you want. It's much faster to
  22. 0:39iterate over a plan than it is to simply
  23. 0:42hope for the best. The second habit is
  24. 0:44to steer Claude in the right direction.
  25. 0:46And here are some ways that you can do
  26. 0:47that.
  27. 0:49Compact summarizes your conversation and
  28. 0:51uses that as a new context while
  29. 0:53deleting the old, freeing up your
  30. 0:55context window. However, there is a risk
  31. 0:57that something important will be
  32. 0:59removed, causing Claude to drift in the
  33. 1:01wrong direction. So, when you do the
  34. 1:02compact command, add in the changes you
  35. 1:04want. And adding instructions after the
  36. 1:06command tells Claude how to summarize.
  37. 1:08So, if you were done debugging a while
  38. 1:09ago, but want to just focus on those API
  39. 1:11changes, well, here you can do that.
  40. 1:15When Claude goes down the wrong path,
  41. 1:17you don't have to prompt your way out of
  42. 1:19it. Rewind brings you to the last
  43. 1:20checkpoint. To open it, double tap
  44. 1:22escape on an empty prompt, and you'll
  45. 1:24get the rewind menu. Every user prompt
  46. 1:27creates a checkpoint that you can revert
  47. 1:28back to with different options. One, you
  48. 1:31can restore the code, conversation, or
  49. 1:33both. Two, summarize from here will
  50. 1:35summarize everything after the
  51. 1:37checkpoint. Great if you had a side
  52. 1:39conversation and just want to free up
  53. 1:40some space. And summarize up to here
  54. 1:42will summarize everything before the
  55. 1:44checkpoint. So, this is great if you
  56. 1:46want to summarize a long setup phase,
  57. 1:48but keep the implementation parts.
  58. 1:51When we talk about steering, we assume
  59. 1:53that you are hands-on. If you want
  60. 1:55something a little bit more autonomous,
  61. 1:57there is the goal and loop.
  62. 1:59Goal sets a completion condition. You
  63. 2:01describe what done looks like and Claude
  64. 2:03keeps working across turns until a fast
  65. 2:06evaluator confirms that those conditions
  66. 2:07have been met. Instead of just stopping
  67. 2:10for the first time it thinks it's
  68. 2:11finished. So for example, I could do
  69. 2:13slash goal, all tests in source billing
  70. 2:15pass and the type checker reports zero
  71. 2:17errors. Doing slash goal clear will
  72. 2:19cancel it. And one constraint here is
  73. 2:21that the evaluator only reads the
  74. 2:23transcript, so the condition has to be
  75. 2:25checkable from the output that Claude
  76. 2:26produces, like the test results that it
  77. 2:28ran. Loop runs a prompt on an interval
  78. 2:30between turns fixed or self-paced. Use
  79. 2:33it to pull something external like a CI
  80. 2:35run or a deploy and act when the state
  81. 2:37changes. You can press escape to stop
  82. 2:39it.
  83. 2:41So our steering metaphor assumes one
  84. 2:43steering wheel in one car, but when
  85. 2:45we're working with multiple agents on
  86. 2:47the same code base, we don't want to
  87. 2:48have two steering wheels in one car.
  88. 2:51Well, that's just unsafe.
  89. 2:52This is where work trees come in. It
  90. 2:54prevents two or more Claude sessions
  91. 2:56from fighting over files in a
  92. 2:57repository. This prevents conflicts by
  93. 2:59having three independent file trees. On
  94. 3:02exit, a clean work tree is auto removed.
  95. 3:04A dot work tree include file at the repo
  96. 3:06root lists get ignored files to copy
  97. 3:08into each work tree, which is useful for
  98. 3:11a environment variable file or a local
  99. 3:13configuration that you need but don't
  100. 3:15want to commit into the version control.
  101. 3:23When it comes to handling long Claude
  102. 3:24code sessions, scope your work first and
  103. 3:26then steer. Direct your compaction so
  104. 3:28the summary keeps what matters. Use the
  105. 3:30rewind menu to course correct. Set a
  106. 3:32goal when you can describe done better
  107. 3:33than you can describe the steps and run
  108. 3:35parallel work in work trees. Do that and
  109. 3:37you can trust a long run without
  110. 3:39babysitting it.

About this transcript

This page contains the full transcript of Steering Claude Code Through Hours-Long Sessions: Plan Mode, Compact, Rewind, Goals by Claude, generated from the public captions YouTube serves with the video. The transcript has 731 words across 110 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.

What you can do with it

Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to translate the transcript into 100+ languages.

Free YouTube transcript tool

YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, translation to 100+ languages, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.