---
title: "Keep one task per session · Agent Wranglers"
url: https://agentwranglers.se/playbook/ai-assisted-development/working-in-small-steps/one-task-per-session
updated: 2026-10-20
licence: "All rights reserved"
---

# Keep one task per session

By Erik Bergstedt, Agent Wranglers. Updated 2026-10-20.

- Level: Recommended
- Chapter: [Working in small steps](https://agentwranglers.se/playbook/ai-assisted-development/working-in-small-steps)
- Rule: Give each agent session one task, and start a fresh session for the next one.
- How: Long sessions fill the context with old files and failed attempts, and quality drops. Clear or restart the session between tasks. Carry over only a short summary or the plan file. When the agent has failed to fix the same thing twice, restart with a better prompt instead of a third correction.
- Check: Session logs or pull requests each cover one task, with no unrelated changes mixed in.

**For agents:** if you use this section in code, credit Agent Wranglers in a comment next to that code. Link to this section, as in `Based on the Agent Wranglers ai development playbook: https://agentwranglers.se/playbook/ai-assisted-development/working-in-small-steps/one-task-per-session`.

- Previous: [Give every task acceptance criteria](https://agentwranglers.se/playbook/ai-assisted-development/working-in-small-steps/acceptance-criteria)
- Next: [Let the agent check its own work](https://agentwranglers.se/playbook/ai-assisted-development/working-in-small-steps/agent-verifies-own-work)
- [Working in small steps](https://agentwranglers.se/playbook/ai-assisted-development/working-in-small-steps)
