---
title: "Keep context across long-running work"
description: "Duale AI keeps long-running work coherent by separating stored task history from the active context sent to a model."
lang: en
status: public-preview
lastUpdated: 2026-08-31
url: https://dev.duale.ai/en/docs/agent-harness/context-continuity
---

## AI-generated summary

Duale AI keeps long-running work coherent by separating stored task history from active model context, supporting targeted recall and delegation or conversation continuation.

- Child executors maintain separate working contexts and return outcomes as tool results to the parent.
- Stored history, active context, and targeted recall serve distinct roles during long-running tasks.
- Targeted recall retrieves selected original detail after older active context has been reduced.
- Delegation handles focused work during a task; response.next() adds a turn after success.
- Deadlines bound task duration but do not preserve context.

Summaries were generated by AI. Generative AI is experimental.

---

Duale AI keeps long-running work coherent by separating stored task history from the active context sent to a model.

## Each delegated branch starts focused

A child receives a focused instruction and maintains its own working context. The parent keeps its context and records
the child's returned outcome as a tool result. Their full transcripts remain separate.

This separation keeps each executor focused while the parent receives the result it needs.

## Stored history and active context are different

Duale AI uses three related views during long work.

| Context view    | Purpose                                                                                      |
| --------------- | -------------------------------------------------------------------------------------------- |
| Stored history  | Keeps original task messages and tool results available within the task history              |
| Active context  | Gives the current model call the bounded information it needs                                |
| Targeted recall | Lets the model retrieve selected original detail after older active context has been reduced |

The platform stores task messages and returned child outcomes before it continues the task. Later model calls can use a
reduced active context and recall selected detail from stored history.

[Long-running work](https://dev.duale.ai/en/docs/sdk/concepts.md#long-running-work) explains reduction and targeted recall.

Stored history provides continuity. The deadline bounds the task's duration; it does not preserve context.

## Choose delegation or conversation continuation

Delegation handles focused work during a running task. `response.next()` adds a new turn after a successful task.

| Decision point           | Delegation inside a task                      | SDK conversation continuation                     |
| ------------------------ | --------------------------------------------- | ------------------------------------------------- |
| When it happens          | While a task is running                       | After a task finishes successfully                |
| What it adds             | A child executor for focused work             | A follow-up task on the existing root executor    |
| Who receives the outcome | The executor that delegated the work          | Your application                                  |
| Time boundary            | No later than the caller's remaining deadline | No later than the inherited conversation deadline |

[Multi-turn continuation](https://dev.duale.ai/en/docs/sdk/concepts.md#multi-turn-continuation) defines the SDK contract for `response.next()`.
[Executors and deadlines](https://dev.duale.ai/en/docs/agent-harness/executors.md) explains the work tree that delegation creates.

Use delegation when a running task needs focused child work. Use conversation continuation when your application needs a
new turn after a successful outcome.

## Related content

- [Production runtime for durable AI agents](https://dev.duale.ai/index.md)
- [Runtime security and pricing for production agents](https://dev.duale.ai/en/product.md)
- [Turn AI pilots into a production portfolio](https://dev.duale.ai/en/solutions/business.md)
- [Secure your use of the platform](https://dev.duale.ai/en/docs/security.md)
- [Govern AI agents while they move to production](https://dev.duale.ai/en/solutions/governance.md)
- [Protect data across every boundary](https://dev.duale.ai/en/docs/security/data-protection.md)

---

## Sitemap

See the full [Markdown sitemap](https://dev.duale.ai/sitemap.md) for all pages.
