convert_unit
Convert any value between units of length, weight, volume, or temperature (e.g., km to miles, Celsius to Fahrenheit) to resolve unit-math errors in calculations.
Instructions
Convert a value between units of length, weight, volume, or temperature (fixes LLM unit-math errors)
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": {
"value": "<value>",
"fromUnit": "<fromUnit>",
"toUnit": "<toUnit>"
},
"name": "convert_unit"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| value | Yes | ||
| toUnit | Yes | e.g. "mi", "kg", "fahrenheit", "l" | |
| fromUnit | Yes | e.g. "km", "lb", "celsius", "gal" |