代码解释器
在沙箱中运行 Python,仅在宿主显式启用时注册。
由固定提交的图表源码生成(
1aa5e22)。工具说明保留模型实际收到的英文原文,不做翻译。code_interpreter
Execute Python code in an isolated sandbox with numpy and pandas available and outbound network disabled. Read inputs from $INPUT_DIR and write files you want returned into $OUTPUT_DIR.
参数
| 字段 | 类型 | 必填 | 约束 | 说明 |
|---|---|---|---|---|
code | string | 是 | min length 1 | Python source to execute. Only the standard library plus numpy and pandas are available. |
files | object[] | — | max items 16 | |
files[].name | string | — | min length 1; max length 255 | |
files[].content | string | — | — | |
files[].encoding | enum | — | one of "utf8", "base64" | |
timeoutMs | integer | — | ≥ 1; ≤ 60000 |
最小输入 · 仅含必填字段,占位值由 schema 推导。
{
"code": "<code>"
}JSON Schema
…