Documentation
¶
Overview ¶
Package calculator The Calculator Tool is a utility within the Atomic Agents ecosystem designed for performing a variety of mathematical calculations. It's essentially a wrapper around the sympy library to allow for expression-based calculations.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Input ¶
type Input struct {
schema.Base
// Expression Mathematical expression to evaluate. For example, '2 + 2'.
Expression string `json:"expression" jsonschema:"title=expression,description=Mathematical expression to evaluate. For example, '2 + 2'."`
// Params represents expressions's parameters
Params map[string]interface{} `json:"params,omitempty" jsonschema:"title=params,description=Parameters for the expression."`
}
Input Tool for performing calculations. Supports basic arithmetic operations like addition, subtraction, multiplication, and division, as well as more complex operations like exponentiation and trigonometric functions. Use this tool to evaluate mathematical expressions.
type Output ¶
type Output struct {
schema.Base
// Result Result of the calculation
Result interface{} `json:"result,omitempty" jsonschema:"title=result,description=Result of the calculation."`
}
Output Schema for the output of the CalculatorTool
Click to show internal directories.
Click to hide internal directories.