openai · OpenAI Platform Docs
Local shell
Teaches how to implement a continuous execution loop that allows an AI agent to send shell commands to a local machine, execute them via a runtime, and return the output to the model.
Derived skill
Files assembled from official documentation
Viewing SKILL.md
Local shell
Teaches how to implement a continuous execution loop that allows an AI agent to send shell commands to a local machine, execute them via a runtime, and return the output to the model.
When To Use
Use when you need to build an agentic workflow that can autonomously run terminal commands, test code, or manage local system processes through a build-test-run loop.
Reference Files
| File | Contains | Use For |
|---|---|---|
SKILL.md | Entry point: scope, routing table, and workflow. | Start here. |
docs/local-shell-workflow-guide.md | A guide explaining how the local shell tool allows agents to execute shell commands on a provided machine and its current deprecation status. | Questions about a guide explaining how the local shell tool allows agents to execute shell commands on a provided machine and its cur... |
examples/local-shell-openai-platform-docs-local-shell.python | A Python script demonstrating how to use the local shell tool with the OpenAI client to execute shell commands. | Exact payloads, commands, or snippets shown in A Python script demonstrating how to use the local shell tool with the OpenAI client to execute shell commands. |
What This Skill Covers
- The local shell tool is outdated. For new use cases, use the shell tool with GPT-5.1 instead. Learn more.
- Main sections:
How it works,Example workflow,Best practices,Error handling.
Workflow
- Open the most relevant file under
docs/for the exact documented workflow and wording. - Open
schemas/files for exact structured contracts. - Open
examples/files for concrete requests, commands, snippets, and manifests. - Do not add behavior or configuration that is not present in the attached source files.
Canonical source: https://developers.openai.com/api/docs/guides/tools-local-shell.md
