refined tool use

This commit is contained in:
2025-01-04 13:31:16 +01:00
parent 7d60d9bd00
commit 8c00a6c326
6 changed files with 46 additions and 37 deletions

View File

@@ -45,13 +45,13 @@ def test_math_solver_2():
def test_math_solver_3a():
result = tool_functions.math_evaluate("solve 2*x + 3*y = 7 and x - y = 1 for x, y")
assert result == "solved equation system for x=2 and y=1"
assert result == "Solved equation system 2*x + 3*y = 7 and x - y = 1 for x=2 and y=1."
def test_math_solver_3b():
result = tool_functions.math_evaluate("solve 2*x + 3*y = 7, x - y = 1 for x and y")
assert result == "solved equation system for x=2 and y=1"
assert result == "Solved equation system 2*x + 3*y = 7 and x - y = 1 for x=2 and y=1."
def test_math_solver_4():
result = tool_functions.math_evaluate("solve 2*x**3 + 3*y = 7 and x - y = 1 for x, y")
assert result == "solved equation system for x=~1.421 and y=~0.421"
assert result == "Solved equation system 2*x**3 + 3*y = 7 and x - y = 1 for x=~1.421 and y=~0.421."