- Duale AI
- Documentation
- Agent harness
Agent harness: Task execution model and Tool Call outcomes
Explains the Duale AI Task execution model, Tool Call outcomes, and how to separate capability, authority, and Effect.
This page covers the Agent harness execution model, Task lifecycle, Tool Call outcomes, and the distinction between capability, authority, and Effect.
- Task lifecycle from request to outcome.
- Execution model terms and definitions.
- Tool Call outcomes and recommended next actions.
- Capability, authority, and Effect separation.
- Continuation Tasks and Recall behavior.
Summaries were generated by AI.
Duale AI runs Tasks for your application. You submit an objective with its starting material, an answer format, and a deadline. The Task works toward that objective with Tools, and your application receives one outcome. The Agent harness is how Tasks behave; it is not a service or an API resource that you call.
A Task uses Tools from three places: Built-in Tools that Duale AI supplies, SDK Tools that your application serves, and MCP Tools from the servers you connect. A Task request carries no Tool definitions and cannot add, remove, or narrow Tools. The model chooses which Tool to use, and an available Tool can go unused. Tools explains each source.
An Agent is software that works toward an objective on behalf of an accountable person or organization. An Agent Identity supplies the credentials, attribution, and Platform permissions that an application uses. It does not define the application’s behavior. Identity owns credentials and access; your application keeps any behavior-version records it needs.
Follow one Task from request to outcome
Your application generates and keeps the Task ID, can show streamed answer text, and serves the Tool requests for its SDK Tools. It receives exactly one Task Outcome: a completed answer, a failure, or a stopped Task. The requested answer format or schema applies to the completed answer. A Tool Call or a Tool Result alone does not prove that an external operation succeeded.
Task execution explains the deadline, Stop, and delegated work. The SDK reference defines the submission, streaming, result, and Stop methods.
Use the current execution model
Use response.next() when you want a new instruction to build on an earlier Task. The continuation has its own result,
deadline, and Stop. Context continuity explains the inherited history and
independent branches. Start a new Task with ask() when you do not want the request to inherit that Task history. A
new Task inherits nothing, but Recall can still find earlier Tasks of the same Agent Identity.
Read a Tool Call outcome
Every Tool Call ends with one outcome. The outcomes mean the same for Built-in Tools, SDK Tools, and MCP Tools, and the Dashboard Task view shows the outcome of each Tool Call.
- Outcome
- Succeeded
- What it means
- The Tool reported a result.
- What to do
- Use the result. Verify any material change at the system that owns it.
- Outcome
- Failed
- What it means
- The Tool ran and did not succeed, including when the target refused the request.
- What to do
- Fix the cause. Repeat the operation only when a repeat is safe.
- Outcome
- Outcome unknown
- What it means
- The Tool stopped before it knew whether its effect happened, for example when a request timed out after it was sent to its target.
- What to do
- Read the destination system before you repeat or compensate the operation.
- Outcome
- Blocked
- What it means
- Duale AI refused or limited the request under a policy, a safety rule, or a limit, for example a disabled MCP Connection or a refused package.
- What to do
- Change the request, the policy, or the limit.
The Task view shows Timed out for a Tool Call that did not answer in time. A timeout does not confirm whether the Tool succeeded, so its outcome is Outcome unknown: read the destination system before any repeat. Tools Analytics adds categories for MCP Connections and a confirmed success rate: Operate Tools defines them. A Tool Result is a report, not proof that an Effect occurred.
Separate capability, authority, and Effect
These properties answer different questions:
- Property
- Autonomy
- Question it answers
- Which actions can the application choose without a fresh external decision?
- Property
- Capability
- Question it answers
- Which operations can it request through its available Tools?
- Property
- Platform access authorization
- Question it answers
- Which Platform resources does the caller have permission to use?
- Property
- External-action authority
- Question it answers
- Which action and arguments does the customer system permit?
- Property
- Effect
- Question it answers
- Which state change actually occurred?
- Property
- Impact
- Question it answers
- What consequence can that change have for people, systems, or the business?
An Action is an attempted operation. An Effect is a state change that actually occurs; an External Effect occurs outside the Platform. A read-only Task can choose many actions, while one Tool Call can send a message or delete information. Make the required authorization or approval part of the Tool or external system before it acts.
In ask(action=...), the word “action” supplies an instruction and contextual material. It does not report an
operation that has occurred. The effect field on a Library Grant means allow or deny; it is an access decision.
Continue with the owner of the next question:
- Task execution for deadlines, Stop, delegated work, and the Dashboard Task view.
- Context continuity for continuations and Recall.
- Tools for Built-in Tools, SDK Tools, and MCP Connections.
- Code Execution for bounded Python or JavaScript work within a Task.
- Libraries and Model routing for data and model capabilities.
- Secure integration for authorization, duplicate attempts, and uncertain external changes.