Agent skill

Utils Cleanup Stale Sandboxes

by open-thoughts in open-thoughts/OpenThoughts-Agent

Delete stale Daytona sandboxes across ALL THREE orgs (DataComp, DataCompData, DataCompRL) in one pass.

Apache-2.0Auto-check passed

Install Utils Cleanup Stale Sandboxes

skills CLI
$ npx skills add open-thoughts/OpenThoughts-Agent --skill utils-cleanup-stale-sandboxes -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install open-thoughts/OpenThoughts-Agent utils-cleanup-stale-sandboxes --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/open-thoughts/OpenThoughts-Agent.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/utils-cleanup-stale-sandboxes .claude/skills/utils-cleanup-stale-sandboxes && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
utils-cleanup-stale-sandboxes
GitHub stars
301
Token cost
~819 tokens
SKILL.md length
224 words
Files
1
Skills in repo
44
Repo updated
First seen
Licence
Apache-2.0

At a glance

Delete stale Daytona sandboxes across ALL THREE orgs (DataComp, DataCompData, DataCompRL) in one pass.

  • The Daytona sandbox count is climbing (eval/datagen/RL sandboxes left behind after jobs finish)
  • SKILL.md covers When to use, The three orgs, How to invoke and Flags, plus 1 more section
  • Calls python; needs DAYTONA_API_KEY and DAYTONA_RL_API_KEY
  • A sweep flags stale sandboxes

What it does

Utils Cleanup Stale Sandboxes is an agent skill from open-thoughts/OpenThoughts-Agent. Delete stale Daytona sandboxes across ALL THREE orgs (DataComp, DataCompData, DataCompRL) in one pass. Runs scripts/daytona/cleanupstalesandboxes.py three times — once per org — each time setting the org's API key via --api-key-env so the script queries and deletes in the correct org. Default threshold is 60 minutes of inactivity; --delete actually removes them (dry run otherwise). Use when the Daytona sandbox count is climbing (eval/datagen/RL sandboxes left behind after jobs finish), when a sweep flags stale…

Its SKILL.md is about 820 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

The repository describes itself as: Data recipes and robust infrastructure for training AI agents. The licence is Apache-2.0.

When your agent uses it

  • The Daytona sandbox count is climbing (eval/datagen/RL sandboxes left behind after jobs finish)
  • A sweep flags stale sandboxes
  • Approaching the org snapshot/sandbox cap

Example prompts

  • “/utils-cleanup-stale-sandboxes”

Requirements

  • Python 3
  • A credential in DAYTONA_API_KEY
  • A credential in DAYTONA_DATA_API_KEY

What it can do on your machine

Read from SKILL.md and the folder at commit 3bd1917. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • python

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • DAYTONA_API_KEY
    • DAYTONA_RL_API_KEY
    • DAYTONA_DATA_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Utils Cleanup Stale Sandboxes loads about 819 tokens when it runs. Until then it costs about 154 tokens; SKILL.md has 224 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~154
When it runs · the whole SKILL.md, loaded when a task matches
~819

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from open-thoughts/OpenThoughts-Agent at commit 3bd1917, republished under its Apache-2.0 licence (© open-thoughts). 224 words, ~819 tokens.

Download SKILL.mdSave it as .claude/skills/utils-cleanup-stale-sandboxes/SKILL.md (or your agent's skills folder).
name
utils-cleanup-stale-sandboxes
description
Delete stale Daytona sandboxes across ALL THREE orgs (DataComp, DataCompData, DataCompRL) in one pass. Runs `scripts/daytona/cleanup_stale_sandboxes.py` three times — once per org — each time setting the org's API key via `--api-key-env` so the script queries and deletes in the correct org. Default threshold is 60 minutes of inactivity; `--delete` actually removes them (dry run otherwise). Use when the Daytona sandbox count is climbing (eval/datagen/RL sandboxes left behind after jobs finish), when a sweep flags stale sandboxes, or when approaching the org snapshot/sandbox cap.

utils-cleanup-stale-sandboxes

Delete stale Daytona sandboxes across the three orgs.

When to use

  • Daytona sandbox count is climbing — stale sandboxes left behind after eval / datagen / RL jobs finish.
  • A sweep flags stale sandboxes or the org approaches its cap.
  • Before a large eval, datagen, or RL launch.
  • Routine hygiene during heavy operations.

The three orgs

OrgAPI key env varTypical sandboxes
DataComp (main)DAYTONA_API_KEYEval (terminus-2 agent sandboxes)
DataCompDataDAYTONA_DATA_API_KEYDatagen (trace-generation rollouts)
DataCompRLDAYTONA_RL_API_KEYRL (SkyRL/GRPO agentic rollouts)

Source $DC_AGENT_SECRET_ENV to set all three variables. --api-key-env selects the org for each invocation.

How to invoke

Locally (Mac) — uses the otagent conda env's Python:

bash
set -a; source "${DC_AGENT_SECRET_ENV:?set DC_AGENT_SECRET_ENV to the secrets file first}"; set +a

PY=/Users/benjaminfeuer/miniconda3/envs/otagent/bin/python
SCRIPT=scripts/daytona/cleanup_stale_sandboxes.py
THRESHOLD=60   # minutes of inactivity

for KEY_ENV in DAYTONA_API_KEY DAYTONA_DATA_API_KEY DAYTONA_RL_API_KEY; do
    echo "============================================"
    echo "Org: $KEY_ENV"
    echo "============================================"
    $PY $SCRIPT --api-key-env "$KEY_ENV" --threshold "$THRESHOLD" --delete
    echo
done

Dry run: omit --delete.

bash
for KEY_ENV in DAYTONA_API_KEY DAYTONA_DATA_API_KEY DAYTONA_RL_API_KEY; do
    $PY $SCRIPT --api-key-env "$KEY_ENV" --threshold "$THRESHOLD"
done

Custom threshold — pass --threshold <minutes> (default 60):

bash
# Only clean sandboxes inactive for >2 hours
THRESHOLD=120

Flags

FlagDefaultPurpose
--deleteoff (dry run)Actually delete stale sandboxes
--threshold60Minutes of inactivity before a sandbox is considered stale
--api-key-envDAYTONA_API_KEYWhich env var holds the org's API key

Gotchas

  • Must source $DC_AGENT_SECRET_ENV first — all three DAYTONA_* env vars must be set before running the loop, or the script will exit with ERROR: ... not set in environment.
  • Run from the otagent env — the daytona SDK must be installed (it is in the otagent conda env; NOT in the base env). Use the full interpreter path /Users/benjaminfeuer/miniconda3/envs/otagent/bin/python.
  • RL (DAYTONA_RL_API_KEY) may have long-lived sandboxes. Raise its threshold if active sandboxes are selected.
  • Dry run first when unsure.

© open-thoughts, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/utils-cleanup-stale-sandboxes of open-thoughts/OpenThoughts-Agent.

Open the folder on GitHubat commit 3bd1917

Compare with similar skills

Utils Cleanup Stale Sandboxes next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Utils Cleanup Stale Sandboxes compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Utils Cleanup Stale Sandboxes this skillopen-thoughts/OpenThoughts-Agent301—~819Automated safety check: PassApache-2.0
Daytona Sandbox Operationsdifferent-ai/openwork24k—~917Automated safety check: PassCustom licence
Cleanupsimstudioai/sim30k—~1.4kAutomated safety check: PassApache-2.0
Agent Sandboxruvnet/ruflo74k3 repos~777Automated safety check: PassMIT
Sandbox Benchvercel/next.js143k—~4.1kAutomated safety check: PassMIT
Git Worktree Cleanuplobehub/lobehub83k—~2.8kAutomated safety check: PassCustom licence

Similar skills

  • Daytona Sandbox Operations

    different-ai/openwork

    Covers Daytona CLI setup, sandbox debugging, keeping a sandbox alive and which credentials the CLI uses, for when Daytona itself is the problem rather than the tests.

    24k GitHub stars~917 tokensUpdated today
    DevOps & CloudAuto-check passed
  • Cleanup

    simstudioai/sim

    Run all code quality skills — effects, memo, callbacks, state, React Query, emcn design review, url-state, comments, and test-audit — analyzing in parallel, then applying fixes sequentially

    30k GitHub stars~1.4k tokensUpdated today
    DevelopmentAuto-check passed
  • Agent Sandbox

    ruvnet/ruflo

    Agent skill for sandbox - invoke with $agent-sandbox. An agent skill from ruvnet/ruflo.

    74k GitHub starsUsed in 3 repos~777 tokens
    Auto-check passed
  • Sandbox Bench

    vercel/next.js

    Official

    Benchmark React or Next.js changes on Vercel Sandbox VMs with paired A/B statistics: react PR/commit vs base, or Next.js PR/commit vs base, measured end-to-end through the bench/render-pipeline app…

    143k GitHub stars~4.1k tokensUpdated today
    Data & AnalyticsAuto-check passed
  • Git Worktree Cleanup

    lobehub/lobehub

    Audits stale Git worktrees and branches with a bundled script, classifies each one, and deletes only after you approve the exact candidates.

    83k GitHub stars~2.8k tokensUpdated today
    DevelopmentAuto-check passed
  • A skill your agent uses when cleaning up old git worktrees, removing worktrees whose branches have merged or been abandoned, or dropping orphaned compdev Postgres databases.

    2k GitHub stars~1.8k tokensUpdated yesterday
    DevelopmentAuto-check: notes

More from open-thoughts/OpenThoughts-Agent

All 44 skills in this repo
  • Analyze Dataset Token Length

    open-thoughts/OpenThoughts-Agent

    Analyze the token length of an OT-Agent conversation-format (ShareGPT-style) dataset — the per-trace distribution (median/p90/max) and/or counts under a token threshold + a metadata predicate (e.g.

    301 GitHub stars~1.5k tokensUpdated 10 days ago
    Auto-check passed
  • Analyze Id Eval Ranking

    open-thoughts/OpenThoughts-Agent

    Given a list of models (HF name stubs) that have valid agentic ID eval scores in Supabase, build a ranking table: raw per-benchmark accuracy on the 3 ID benchmarks (SWE-Bench-100…

    301 GitHub stars~3.1k tokensUpdated 10 days ago
    Auto-check passed
  • Analyze Job History Iris

    open-thoughts/OpenThoughts-Agent

    Run the Iris harbor job-history analyzer (scripts/iris/analyzeirisharborjob.py) on a datagen/eval job and read its JSON sidecar for trustworthy throughput / preemption / productive-trial stats.

    301 GitHub stars~2.9k tokensUpdated 10 days ago
    Auto-check passed
  • Analyze Rl Behavior

    open-thoughts/OpenThoughts-Agent

    Run the full RL behavioral-analysis pipeline (scripts/analysis/analyzerlbehavior.py) on a trained RL model to understand WHAT changed vs its pre-RL baseline, WHY, whether it PERSISTS, and its EVAL…

    301 GitHub stars~4.2k tokensUpdated 10 days ago
    Auto-check passed
  • Analyze Training Run Iris

    open-thoughts/OpenThoughts-Agent

    Detailed health check for a Levanter/executor TRAINING run on the marin Iris cluster (e.g.

    301 GitHub stars~2k tokensUpdated 10 days ago
    Auto-check passed
  • Code Create Staged Plan

    open-thoughts/OpenThoughts-Agent

    DESIGN a non-trivial codebase change (Harbor / MarinSkyRL / vLLM / OT-Agent / LLaMA-Factory) as a dependency-ordered STAGED PLAN before writing code — a feature port, a multi-step fix with parity…

    301 GitHub stars~1.5k tokensUpdated 10 days ago
    Auto-check passed

Questions about Utils Cleanup Stale Sandboxes

What does Utils Cleanup Stale Sandboxes do?

Delete stale Daytona sandboxes across ALL THREE orgs (DataComp, DataCompData, DataCompRL) in one pass. Utils Cleanup Stale Sandboxes is an agent skill from open-thoughts/OpenThoughts-Agent. Delete stale Daytona sandboxes across ALL THREE orgs (DataComp, DataCompData, DataCompRL) in one pass.

When should I use Utils Cleanup Stale Sandboxes?

Utils Cleanup Stale Sandboxes fits situations like: the Daytona sandbox count is climbing (eval/datagen/RL sandboxes left behind after jobs finish); A sweep flags stale sandboxes; approaching the org snapshot/sandbox cap.

How do I install Utils Cleanup Stale Sandboxes in Claude Code?

Run `npx skills add open-thoughts/OpenThoughts-Agent --skill utils-cleanup-stale-sandboxes -a claude-code`. Or copy the skill folder (.agents/skills/utils-cleanup-stale-sandboxes in open-thoughts/OpenThoughts-Agent) into .claude/skills/utils-cleanup-stale-sandboxes in your project. Claude Code loads it when a task matches its description.

How do I install Utils Cleanup Stale Sandboxes in Codex?

Run `npx skills add open-thoughts/OpenThoughts-Agent --skill utils-cleanup-stale-sandboxes -a codex`. Or copy the skill folder (.agents/skills/utils-cleanup-stale-sandboxes in open-thoughts/OpenThoughts-Agent) into .agents/skills/utils-cleanup-stale-sandboxes in your project. Codex loads it when a task matches its description.

Can I use Utils Cleanup Stale Sandboxes in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add open-thoughts/OpenThoughts-Agent --skill utils-cleanup-stale-sandboxes -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/utils-cleanup-stale-sandboxes, .gemini/skills/utils-cleanup-stale-sandboxes, .github/skills/utils-cleanup-stale-sandboxes and .opencode/skills/utils-cleanup-stale-sandboxes in your project.

What does Utils Cleanup Stale Sandboxes need to run?

Going by SKILL.md and its folder, Utils Cleanup Stale Sandboxes needs the command-line tools its instructions call (python) and credentials named DAYTONA_API_KEY, DAYTONA_RL_API_KEY and DAYTONA_DATA_API_KEY. Our summary lists: Python 3; A credential in DAYTONA_API_KEY; A credential in DAYTONA_DATA_API_KEY.

Does Utils Cleanup Stale Sandboxes access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Utils Cleanup Stale Sandboxes safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Utils Cleanup Stale Sandboxes use?

Utils Cleanup Stale Sandboxes is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Utils Cleanup Stale Sandboxes use?

About 819 tokens (SKILL.md is roughly 3.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Utils Cleanup Stale Sandboxes?

Skills that share tags, products or a category with Utils Cleanup Stale Sandboxes: Daytona Sandbox Operations (different-ai/openwork, 24k stars), Cleanup (simstudioai/sim, 30k stars), Agent Sandbox (ruvnet/ruflo, 74k stars) and Sandbox Bench (vercel/next.js, 143k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Utils Cleanup Stale Sandboxes?

open-thoughts (a GitHub organization) maintains it in open-thoughts/OpenThoughts-Agent, which has 301 GitHub stars. The repository holds 44 skills in this directory. The repository was last updated on September 28, 2026.

Source: open-thoughts/OpenThoughts-Agent on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.