sandboxed-exec
Skill9 starsChanged 3 months agoMITView on GitHub
In this repository109 other files it gives its agents.
- AGENTS.mdAGENTS.md
- docs/agents.mdAGENTS.md
- agent/CLAUDE.mdCLAUDE.md
- CLAUDE.mdCLAUDE.md
- router/CLAUDE.mdCLAUDE.md
- .agents/skills/llms.txtllms.txt
- agent-harnessSkill
- auto-fixSkill
- brain-dumpSkill
- industrial-brutalist-uiSkill
- changelog-enforcerSkill
- checkpoint-strategySkill
- context-primeSkill
- cooldown-resumeSkill
- council-reviewSkill
- data-quality-auditSkill
- debug-tracerSkill
- dependency-auditSkill
- deslopSkill
- docs-syncSkill
- duplicate-threadSkill
- email-triageSkill
- fabric-patternsSkill
- feature-flagSkill
- git-hygieneSkill
- graphifySkill
- implementation-plannerSkill
- insightsSkill
- issue-resolverSkill
- learn-ruleSkill
- local-ai-querySkill
- lr-schedule-advisorSkill
- minimalist-uiSkill
- modularity-reviewSkill
- full-output-enforcementSkill
- parallel-agentsSkill
- parallel-worktreesSkill
- prompt-librarySkill
- prompt-transparencySkill
- pro-workflowSkill
- redesign-existing-projectsSkill
- release-readinessSkill
- replay-learningsSkill
- repo-memory-updaterSkill
- repowise-intelligenceSkill
- researchSkill
- resource-panelSkill
- risky-module-reviewSkill
- scope-guardSkill
- self-improveSkill
- session-handoffSkill
- skill-composerSkill
- smart-commitSkill
- high-end-visual-designSkill
- stitch-design-tasteSkill
- system-prompt-auditSkill
- task-alive-updatesSkill
- task-scoperSkill
- design-taste-frontendSkill
- test-first-executorSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 4
Run shell commands or code snippets in an isolated subprocess environment, preventing side effects from leaking into the host workspace.
- Distinctive: line 60
Never pass host secrets or API keys into the sandbox unless explicitly needed.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Skill: sandboxed-exec
Purpose
Run shell commands or code snippets in an isolated subprocess environment, preventing side effects from leaking into the host workspace. Mirrors the "Modal Sandbox" pattern described in the OpenAI Agents SDK blog post — give an agent a safe "home computer" to work on.
When to Use
- You need to run untrusted or exploratory code (e.g. test a one-off script, validate a dependency, try a risky refactor) without touching the real working tree.
- You want to verify that generated code actually executes before committing it.
- You need a clean-room environment (fresh temp dir, isolated env vars) for reproducible testing.
How It Works
- Creates a temporary directory as the sandbox root.
- Copies (or writes) the target files into the sandbox.
- Executes the requested command inside that directory with a sanitised environment.
- Captures stdout, stderr, and exit code.
- Reports results back — nothing is written to the real workspace unless explicitly requested.
Usage
@sandboxed-exec
command: <shell command to run>
files: <optional list of workspace-relative files to copy into sandbox>
write_back: <true|false — default false>Example — validate a generated script before saving
@sandboxed-exec
command: python validate.py
files: [scripts/validate.py, data/sample.json]
write_back: falseExample — run tests in isolation
@sandboxed-exec
command: npm test
files: [src/, package.json, tsconfig.json]
write_back: falseSteps (for Claude to follow)
- Identify the command and files from the invocation.
- Create sandbox:
SANDBOX=$(mktemp -d) - Copy files into
$SANDBOXpreserving relative paths. - Execute with a clean environment:
cd "$SANDBOX" && env -i HOME="$SANDBOX" PATH="/usr/local/bin:/usr/bin:/bin" <command> - Capture exit code, stdout, stderr.
- Report full output. If
write_back: trueand exit code is 0, copy results back to workspace. - Cleanup sandbox dir.
Security Notes
- Never pass host secrets or API keys into the sandbox unless explicitly needed.
write_backdefaults tofalse— always confirm before overwriting workspace files.- For long-running or GPU-intensive tasks, see the
parallel-agentsskill instead.
Output Format
SANDBOX RESULT
==============
Exit code : 0
Command : <command>
Stdout :
<stdout>
Stderr :
<stderr>
Write-back: false (no workspace files modified)Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

