calculate
Perform mathematical calculations including addition, subtraction, multiplication, division, power, square root, and modulo on two numbers.
Instructions
Perform a mathematical calculation.
Args: operation: The math operation (add, subtract, multiply, divide, power, sqrt, modulo) a: The first number b: The second number (not used for sqrt)
Returns: The calculation result as a string
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"operation": "<operation>",
"a": "<a>"
},
"name": "calculate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| a | Yes | ||
| b | No | ||
| operation | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |