firstprompt
Anmelden
Alle Kurse

Lehrplan

0 / 40 · 0%
  • Anatomie eines Prompts7m
  • Genauigkeit als Hebel6m
  • Kontextfenster und /clear5m
  • Slash-Befehle5m
  • @file und @directory5m
  • Modul 2 im Rückblick3m
  • CheckpointQuiz + live stellen
0/40

Du liest als Gast – dein Fortschritt wird nur auf diesem Gerät gespeichert.

Dashboard/Modul 2/Lektion 3
KostenlosDein erster Prompt

Kontextfenster und /clear

5 Min. Lesezeit·Lektion 3 aus Dein erster Prompt

Lieber anhören

Kontextfenster und /clear

2:14 · die gesprochene Version dieser Lektion

0:002:14

Claude re-reads your whole conversation every time it answers. That running history is the context window, and keeping it tidy is one of the quiet skills that separates a smooth session from a frustrating one.

What is in there

Everything from this session: every message you sent, every file Claude read, every command it ran. It is large, but not infinite, and everything in it competes for attention.

Your files on disk are not the context. Clearing the conversation never deletes your work.

What it looks like when it goes wrong

Two symptoms, and once you know them you will spot them immediately:

  • Claude keeps referring to something you finished twenty minutes ago.
  • You ask for a small change and it edits files you were not talking about.

Both mean the same thing: the old work is still in the window, and it is pulling on every answer.

The fix: one task per conversation

Starts a new conversation with empty context. Your files are untouched.

/clear

Finished styling your page and now want to add a new section? /clear first. It is the cheapest quality upgrade available, and beginners almost never use it.

Keep the context while you are iterating on the same thing — that history is exactly what lets Claude build on what it just did. Clear it when you genuinely switch tasks.

When you want to keep going, but the session is long

Sometimes you are still on the same task and the conversation has simply got long. You do not want to lose it.

Summarizes the conversation so far to free up room, and keeps going.

/compact

/clear throws the conversation away. /compact compresses it and carries on. When you are unsure which you want, ask yourself whether you would miss the history — if yes, compact.

Try it now

Do two unrelated things, badly, on purpose.

  1. Start Claude and ask it to change the colours on your page.
  2. Without clearing, ask it to write a completely unrelated file: with five items.

Übung

Probier diese Lektion in einem geführten Terminal aus.

Nächste

Slash-Befehle

shopping-list.md
  • Now ask: "make the heading bigger."
  • Watch whether it stays on the page or drifts toward the shopping list. Then /clear, ask the same thing, and see the difference.

    What you just learned

    • The context window is Claude's memory of this session, not your files.
    • A cluttered context makes Claude drift toward old, finished work.
    • /clear between unrelated tasks. One task per conversation.
    • /compact when you are on the same task but the conversation has grown long.

    Next: the handful of slash commands worth memorising.

    Lernfortschritt

    0

    0 / 40

    Lektionen

    In diesem Modul

    Dein erster Prompt

    1. 1Anatomie eines Prompts7m
    2. 2Genauigkeit als Hebel6m
    3. 3Kontextfenster und /clear5m
    4. 4Slash-Befehle5m
    5. 5@file und @directory5m
    6. 6Modul 2 im Rückblick3m
    Checkpoint starten