scheduled-task-resilience

scheduled-task-resilience is a skill for Claude Code, Codex from desplega-ai/agent-swarm. It costs 48 tokens per session (1,796 once invoked), scanned A, original, MIT.

Rules for safely polling scheduled jobs and waiting for long-running work such as CI, builds, deployments, or browser tasks.

In plain words
What is it for?
Use them when checking asynchronous APIs or waiting for scheduled tasks, especially when the operation may take several minutes.
Why use it?
They reduce the risk of lost work, duplicate results, heartbeat failures, and sessions ending while an external job is still running.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use them when checking asynchronous APIs or waiting for scheduled tasks, especially when the operation may take several minutes.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/desplega-ai/agent-swarm/scheduled-task-resilience
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add desplega-ai/agent-swarm --skill scheduled-task-resilience
Clone the repo
git clone --depth 1 https://github.com/desplega-ai/agent-swarm

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for scheduled-task-resilience

README.md
[![agentmods](https://agentmods.dev/badge/skills/desplega-ai/agent-swarm/scheduled-task-resilience/github.svg)](https://agentmods.dev/skills/desplega-ai/agent-swarm/scheduled-task-resilience)
Your own site
<a href="https://agentmods.dev/skills/desplega-ai/agent-swarm/scheduled-task-resilience"><img src="https://agentmods.dev/badge/skills/desplega-ai/agent-swarm/scheduled-task-resilience/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for scheduled-task-resilience

Your own site · 80×15
<a href="https://agentmods.dev/skills/desplega-ai/agent-swarm/scheduled-task-resilience"><img src="https://agentmods.dev/badge/skills/desplega-ai/agent-swarm/scheduled-task-resilience.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 48 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,796 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00048 $0.01796
Opus 5 $0.00024 $0.00898
Sonnet 5 $0.00010 $0.00359
Haiku 4.5 $0.00005 $0.00180

Measured 12d ago against content hash f57f5f4157c0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

scheduled-task-resilience scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

templates/skills/scheduled-task-resilience/SKILL.md · 103 lines

How it starts

The opening of the file, as written. The whole thing — 103 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Scheduled Task Resilience

Use these rules whenever a scheduled or regular task polls or waits on a long-running operation. They prevent heartbeat collisions, lost work, duplicate delivery, and sessions that fail after holding an external job open too long.

Rule 1 — Never use ScheduleWakeup with delaySeconds >= 300

The runtime heartbeat staleness threshold may sit near the same window as the model prompt-cache TTL. Sleeping for five minutes or longer can therefore look like a dead worker and cause the heartbeat sweep to fail the task mid-poll.

Instead:

  • For waits under four minutes, run one bounded sleep of at most 240 seconds followed by a single status check, as one shell call, then return control to the agent turn.
  • Never batch sleeps into a single shell invocation. A loop of five 240-second sleeps blocks the session for twenty minutes with no opportunity to record progress — the same staleness failure ScheduleWakeup causes, just spelled differently.
  • Between cycles, record progress as described in Rule 3, then start the next cycle in the next turn.
  • For genuinely long waits such as CI builds, releases, or deploys, prefer a durable workflow or a follow-up task over ScheduleWakeup.

Aggregate every check run before you decide the poll is over. Reading a single row such as .[0].state reports one check and can look terminal while another required check is still pending or failing.

# ONE cycle per agent turn. Resolve PR_NUMBER from the current task or repository context.
sleep 240
if out=$(gh pr checks "$PR_NUMBER" --json name,state,bucket \
      --jq 'if   any(.[]; .bucket == "pending") then "PENDING"
            elif any(.[]; .bucket == "fail" or .bucket == "cancel") then "FAILING"
            else "PASSED" end' 2>&1); then
  echo "$out"
else
  case "$out" in
    *"no checks reported"*) echo "PENDING" ;;  # no check contexts yet — not a failure
    *) echo "$out" >&2; exit 1 ;;              # real gh error: auth, network, bad PR
  esac
fi

Read the full file on GitHub · 103 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 103 lines · 48 tokens per session scan A f57f5f4157c0

Subscribe to this mod's changes

scheduled-task-resilience is a skill published in the GitHub repository desplega-ai/agent-swarm (761 stars, last pushed yesterday), licensed MIT. It adds 48 tokens to every session and 1,796 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

skill-creator

Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy.

bytedance/deer-flow · 64 tokens

consulting-analysis

Use this skill when the user requests to generate, create, or write professional research reports including but not limited to market analysis, consumer insights, brand analysis, financial analysis, industry research, competitive intelligence, investment due diligence, or any consulting-grade analytical report. This…

bytedance/deer-flow · 110 tokens

ppt-generation

Use this skill when the user requests to generate, create, or make presentations (PPT/PPTX). Creates visually rich slides by generating images for each slide and composing them into a PowerPoint file.

bytedance/deer-flow · 44 tokens

systematic-literature-review

Use this skill when the user wants a systematic literature review, survey, or synthesis across multiple academic papers on a topic. Also covers annotated bibliographies and cross-paper comparisons. Searches arXiv and outputs reports in APA, IEEE, or BibTeX format. Not for single-paper tasks — use academic-paper-review…

bytedance/deer-flow · 73 tokens

academic-paper-review

Use this skill when the user requests to review, analyze, critique, or summarize academic papers, research articles, preprints, or scientific publications. Supports comprehensive structured reviews covering methodology assessment, contribution evaluation, literature positioning, and constructive feedback generation.…

bytedance/deer-flow · 95 tokens

code-documentation

Use this skill when the user requests to generate, create, or improve documentation for code, APIs, libraries, repositories, or software projects. Supports README generation, API reference documentation, inline code comments, architecture documentation, changelog generation, and developer guides. Trigger on requests…

bytedance/deer-flow · 88 tokens