Switch language한국어
Back to the list

Why Coding Agents Lose Their Plan (and How a Todo Tool Fixes It)

TL;DR AI

Key summary

2 min read
  1. Language models lose focus on initial plans as conversation history grows, a phenomenon called instruction-following decay.

  2. A coding agent stores its plan only in transient reasoning, causing multi-step tasks to drift as context expands.

  3. The solution is a Todo tool: a TodoManager that holds up to 20 items with statuses and validates updates.

  4. The agent's todo handler parses JSON into TodoItem objects, updates the manager, and returns a rendered task list so the model sees the current plan in context.

Read the original