CodeInterpreterTool Class
- java.
lang. Object - com.
azure. ai. agents. models. Tool - com.
azure. ai. agents. models. CodeInterpreterTool
- com.
- com.
public final class CodeInterpreterTool
extends Tool
Code interpreter A tool that runs Python code to help generate a response to a prompt.
Constructor Summary
| Constructor | Description |
|---|---|
| CodeInterpreterTool() |
Creates an instance of Code |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
static
Code |
fromJson(JsonReader jsonReader)
Reads an instance of Code |
|
Auto |
getContainerAsAutoCodeInterpreterToolParameter()
Get the container property: The code interpreter container. |
| String |
getContainerAsString()
Get the container property: The code interpreter container. |
| String |
getDescription()
Get the description property: Deprecated. |
| String |
getName()
Get the name property: Deprecated. |
|
Map<String,Tool |
getToolConfigs()
Get the tool |
|
Tool |
getType()
Get the type property: The type property. |
|
Code |
setContainer(AutoCodeInterpreterToolParameter container)
Set the container property: The code interpreter container. |
|
Code |
setContainer(String containerId)
Set the container property: The code interpreter container. |
|
Code |
setDescription(String description)
Set the description property: Deprecated. |
|
Code |
setName(String name)
Set the name property: Deprecated. |
|
Code |
setToolConfigs(Map<String,ToolConfig> toolConfigs)
Set the tool |
|
Json |
toJson(JsonWriter jsonWriter) |
Methods inherited from Tool
Methods inherited from java.lang.Object
Constructor Details
CodeInterpreterTool
public CodeInterpreterTool()
Creates an instance of CodeInterpreterTool class.
Method Details
fromJson
public static CodeInterpreterTool fromJson(JsonReader jsonReader)
Reads an instance of CodeInterpreterTool from the JsonReader.
Parameters:
Returns:
Throws:
getContainerAsAutoCodeInterpreterToolParameter
public AutoCodeInterpreterToolParameter getContainerAsAutoCodeInterpreterToolParameter()
Get the container property: The code interpreter container. Can be a container ID or an object that specifies uploaded file IDs to make available to your code, along with an optional `memory_limit` setting. If not provided, the service assumes auto.
Returns:
getContainerAsString
public String getContainerAsString()
Get the container property: The code interpreter container. Can be a container ID or an object that specifies uploaded file IDs to make available to your code, along with an optional `memory_limit` setting. If not provided, the service assumes auto.
Returns:
getDescription
public String getDescription()
Get the description property: Deprecated. This property is deprecated and will be removed in a future version.
Returns:
getName
public String getName()
Get the name property: Deprecated. This property is deprecated and will be removed in a future version.
Returns:
getToolConfigs
public Map<String,ToolConfig> getToolConfigs()
Get the toolConfigs property: Deprecated. This property is deprecated and will be removed in a future version.
Returns:
getType
public ToolType getType()
Get the type property: The type property.
Overrides:
CodeInterpreterTool.getType()Returns:
setContainer
public CodeInterpreterTool setContainer(AutoCodeInterpreterToolParameter container)
Set the container property: The code interpreter container. Can be a container ID or an object that specifies uploaded file IDs to make available to your code, along with an optional `memory_limit` setting. If not provided, the service assumes auto.
Parameters:
Returns:
setContainer
public CodeInterpreterTool setContainer(String containerId)
Set the container property: The code interpreter container. Can be a container ID or an object that specifies uploaded file IDs to make available to your code, along with an optional `memory_limit` setting. If not provided, the service assumes auto.
Parameters:
Returns:
setDescription
public CodeInterpreterTool setDescription(String description)
Set the description property: Deprecated. This property is deprecated and will be removed in a future version.
Parameters:
Returns:
setName
public CodeInterpreterTool setName(String name)
Set the name property: Deprecated. This property is deprecated and will be removed in a future version.
Parameters:
Returns:
setToolConfigs
public CodeInterpreterTool setToolConfigs(Map<String,ToolConfig> toolConfigs)
Set the toolConfigs property: Deprecated. This property is deprecated and will be removed in a future version.
Parameters:
Returns:
toJson
public JsonWriter toJson(JsonWriter jsonWriter)
Overrides:
CodeInterpreterTool.toJson(JsonWriter jsonWriter)Parameters:
Throws: