# Together AI Sandboxes Skill for Claude Code > Skill that teaches Claude Code Together AI's sandbox API. Execute Python code in managed remote sandboxes with stateful sessions, file I/O, and isolated environments. ## Install Save the content below to `.claude/skills/` or append to your `CLAUDE.md`: ## Quick Use ```bash npx skills add togethercomputer/skills ``` ## What is This Skill? This skill teaches AI coding agents how to use Together AI's managed sandboxes for remote code execution. Run Python code in isolated, stateful environments with file I/O, package installation, and session persistence. **Answer-Ready**: Together AI Sandboxes Skill for coding agents. Remote Python execution in managed environments. Stateful sessions, file I/O, package installation, and isolation. Part of official 12-skill collection. **Best for**: AI agents needing safe remote code execution. **Works with**: Claude Code, Cursor, Codex CLI. ## What the Agent Learns ### Create & Execute ```python from together import Together client = Together() # Create sandbox session sandbox = client.sandboxes.create() # Execute code result = sandbox.execute("print(2 + 2)") print(result.output) # "4" # Stateful — variables persist sandbox.execute("x = 42") result = sandbox.execute("print(x * 2)") print(result.output) # "84" ``` ### Install Packages ```python sandbox.execute("!pip install pandas numpy") sandbox.execute("import pandas as pd; df = pd.DataFrame({'a': [1,2,3]}); print(df)") ``` ### File Operations ```python # Upload files to sandbox sandbox.upload("data.csv", csv_content) # Download results result = sandbox.download("output.png") ``` ### Key Features | Feature | Details | |---------|---------| | Language | Python | | State | Persistent across calls | | Packages | pip install supported | | File I/O | Upload/download | | Isolation | Secure container | ## FAQ **Q: How long do sessions last?** A: Sessions persist until explicitly closed or timeout (configurable). ## Source & Thanks > Part of [togethercomputer/skills](https://github.com/togethercomputer/skills) — MIT licensed. ## 快速使用 ```bash npx skills add togethercomputer/skills ``` ## 什么是这个 Skill? 教 AI Agent 使用 Together AI 的沙箱 API,在远程隔离环境中执行 Python 代码。 **一句话总结**:Together AI 沙箱 Skill,远程 Python 执行,有状态会话 + 文件 I/O + 包安装,官方出品。 ## 来源与致谢 > [togethercomputer/skills](https://github.com/togethercomputer/skills) — MIT --- Source: https://tokrepo.com/en/workflows/5086f64d-852f-4737-81ec-0018d6118a06 Author: Agent Toolkit