AS AgentScopeAPI 手册 / API Reference

RunPythonToolRequest

public record RunPythonToolRequest( @JsonProperty(required = true, value = "code") @JsonPropertyDescription("Python code to be executed") String code )
源码Source io/agentscope/runtime/engine/agents/saa/tools/base/BasePythonRunner.java:61–69

承载运行 Python 工具请求数据的记录类型。位于 io.agentscope.runtime.engine.agents.saa.tools.base 包。核心成员包括 code、RunPythonToolRequest。

A record in io.agentscope.runtime.engine.agents.saa.tools.base that carries data used when components lets agents invoke external capabilities under control. Declared in io.agentscope.runtime.engine.agents.saa.tools.base.

记录组件摘要Record Component Summary

组件Component类型Type说明Description
codeString
执行 `code` 方法。
Performs the code operation.

构造器摘要Constructor Summary

构造器Constructor说明Description
public RunPythonToolRequest(String code)
初始化 `RunPythonToolRequest` 实例。
Creates a new instance.

记录组件详情Record Component Detail

code

String code

执行 code 方法。

Performs the code operation.

源码Source io/agentscope/runtime/engine/agents/saa/tools/base/BasePythonRunner.java:61–69

构造器详情Constructor Detail

RunPythonToolRequest

public RunPythonToolRequest(String code)

初始化 RunPythonToolRequest 实例。

Creates a new instance.

参数Parameters
名称Name类型Type说明Description
codeStringcode(类型 `String`)。The code.
源码Source io/agentscope/runtime/engine/agents/saa/tools/base/BasePythonRunner.java:66–68
基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.