Skip to main content
Glama

clear_task_instance

Clear a failed Airflow task instance to retry it without restarting the entire DAG, useful for transient errors like network timeouts.

Instructions

Clear a task instance to retry it without re-triggering the entire DAG.

Use this when a task failed due to a transient issue (e.g. network timeout, temporary S3 error) and you want to retry just that task and optionally all tasks downstream of it.

Args: dag_id: The DAG identifier. dag_run_id: The run ID. task_id: The task to clear/retry. env: Target environment — 'dev', 'uat', 'test', or 'prod'. IMPORTANT: Do NOT guess or default. Ask the user which environment if not specified. include_downstream: If True, also clear all downstream tasks (default: False).

Returns confirmation with the list of cleared task instances.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dag_idYes
dag_run_idYes
task_idYes
envNo
include_downstreamNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes the tool's purpose (clearing for retry), scope (task vs. entire DAG), and important behavioral constraints (the IMPORTANT note about not guessing/defaulting on environment). It doesn't cover rate limits or authentication needs, but provides substantial operational context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is perfectly structured and front-loaded: purpose statement first, usage guidelines second, parameter details third, return information last. Every sentence earns its place, with no wasted words. The IMPORTANT warning is appropriately emphasized without disrupting flow.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (mutation operation with 5 parameters), no annotations, and 0% schema coverage, the description provides complete operational context. It covers purpose, usage scenarios, all parameter semantics, and mentions the return format. The existence of an output schema means the description doesn't need to detail return values.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description fully compensates by providing detailed semantic information for all parameters. It explains what each parameter represents (dag_id, dag_run_id, task_id), provides the enum values for 'env' with critical usage guidance, and clarifies the default behavior and meaning of 'include_downstream'.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('clear a task instance to retry it') and distinguishes it from alternatives by specifying it doesn't 're-trigger the entire DAG'. It provides a precise verb+resource combination that differentiates it from sibling tools like 'trigger_dag' or 'cancel_job_run'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly states when to use this tool ('when a task failed due to a transient issue') and provides concrete examples (network timeout, temporary S3 error). It also clarifies the scope ('retry just that task and optionally all tasks downstream'), giving clear context for decision-making.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/SrujanReddyKallu2024/MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server