MCPcopy Create free account
hub / github.com/CommandCodeAI/BaseAI / toolCalculator

Function toolCalculator

examples/remix/baseai/tools/calculator.ts:7–27  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

5}
6
7const toolCalculator = () => ({
8 run: calculator,
9 type: 'function' as const,
10 function: {
11 name: 'calculator',
12 description:
13 `A tool that can evaluate mathematical expressions. ` +
14 `Example expressions: ` +
15 `'5.6 * (5 + 10.5)', '7.86 cm to inch', 'cos(80 deg) ^ 4'.`,
16 parameters: {
17 type: 'object',
18 required: ['expression'],
19 properties: {
20 expression: {
21 type: 'string',
22 description: 'The mathematical expression to evaluate.',
23 },
24 },
25 },
26 },
27});
28
29export default toolCalculator;

Callers 1

getPipeWithToolFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected