Home / Fundamentals and the agent loop
The task list and the status line
On the most recent models, the task list stays empty by default, with Claude managing multi step work without exposing it, while a status line configured by a script shows the active model, the context window and the session cost live.
The status line is a customisable bar that runs the shell script you configure, receiving the session's JSON data on its standard input. It appears in its own row, above the built in badges of the footer, without replacing them, and acts as a continuous reference point during a long session, where a task list acts as a reference point for a specific piece of multi step work.
An empty list by default on recent models
On Opus 4.8, Sonnet 5, Fable 5, Mythos 5 and later versions of these families, Claude Code tracks multi step work without a written checklist shown on screen, since the tool that would fill that list is not provided by default. To bring it back anyway on these models, one possible way is to set the environment variable CLAUDE_CODE_ENABLE_TODO_TOOLS=1 before launching the session, among other methods listed under the availability of the Task tool. On earlier models such as Opus 4.7, the behaviour remains a visible checklist, toggled by Ctrl+T, with up to five tasks shown and persistence across context compactions.
What the status line reads
A status line, declared through the statusLine setting, receives a complete JSON object on its standard input at every refresh, with specific fields, model.id and model.display_name for the active model, context_window.used_percentage and context_window.context_window_size for the context window, cost.total_cost_usd for the session cost calculated client side. A rate_limits block only appears for Claude.ai Pro and Max subscribers, or behind a gateway that sets a spending limit, and only after the session's first API response, with three possible windows, five hours, seven days, and a spending limit that additionally requires a recent version of the tool.
Here is an example that builds its own object in memory to illustrate the shape received by a status line script, without querying a real session:
node -e "const d={model:{display_name:'exemple'},context_window:{used_percentage:42,context_window_size:1000000},cost:{total_cost_usd:0.87}}; console.log(d.context_window.context_window_size)"
The command returns 1000000, exactly the field a status line script would read on an extended context window model.
This reference point takes on its full meaning once the context approaches its limit, a signal that calls for the cleanup command described in the lesson on essential slash commands rather than blindly carrying on with the session.
The context window size shown by the status line
Task list behaviour by model family
| Task list behaviour across two model families | Visible by default | How to restore it if needed |
|---|---|---|
| Opus 4.7 and earlier models | Yes, with Ctrl+T to toggle the display | Nothing to do, already active by default |
| Opus 4.8, Sonnet 5, Fable 5, Mythos 5 and more recent models | No, the list stays empty | Set the environment variable CLAUDE_CODE_ENABLE_TODO_TOOLS=1 |
A developer works on Sonnet 5 during a multi step refactoring session. She watches the Claude Code screen and notices that the area usually reserved for the task list stays empty throughout the session.
Write in one sentence what this situation establishes, and in one sentence what it does not establish.
What this establishes: The situation establishes that on this model, in this exact session, no visible checklist was produced during the multi step work.
What this does not establish: It does not establish that Claude did not track the multi step work internally, nor whether the environment variable that reactivates the list was set for this session or not.
The three most common miscalibrations
- Too broad It establishes that the task list has disappeared from Claude Code for good, whichever model is chosen.
- Too narrow It establishes only that the terminal window was too small to display the task list on this exact screen.
- Beside the point It shows that the refactoring task chosen had more steps than the average task given to Claude Code.
- On Opus 4.8, Sonnet 5, Fable 5, Mythos 5 and later versions, the task list stays empty by default because the tool that would fill it is not provided.
- Setting the environment variable CLAUDE_CODE_ENABLE_TODO_TOOLS=1 before launching the session restores the task list on these recent models.
- On earlier models such as Opus 4.7, Ctrl+T toggles the display of a list holding up to five tasks, persistent across compactions.
- A custom status line receives a complete JSON object on its standard input, with the active model, context usage and the session cost.
- The rate_limits block of a status line only appears for a Pro or Max subscription, or behind a gateway with a spending limit, and only after the first API response.
Open your Claude Code status line during a running session, identify the active model and the percentage of context used that are shown there, then note whether the task list area is empty or filled on the model you are using.
Every datable claim in this lesson links here to the public text behind it. A source that does not open proves nothing.
- Claude Code, interactive mode, footer shortcuts and badges consultée le 2026-09-02
- Claude Code, customisable status line, required script and JSON fields received consultée le 2026-09-02