8000 Multiplying by 10 in @function_tool return value does not work · Issue #896 · openai/openai-agents-python · GitHub
[go: up one dir, main page]

Skip to content
Multiplying by 10 in @function_tool return value does not work #896
Open
@Aligadit1

Description

@Aligadit1

Image
Image

Describe the bug

When using @function_tool, if the return expression multiplies by 10, the multiplication is ignored and the output behaves as if it’s not multiplied by 10.

For example, if the code returns a * b * 10, the actual output acts like just a * b. Multiplying by other numbers (1, 2, 3, 5, 11, etc.) works fine.

Debug information

Agents SDK version: (0.0.16)
Python version (3.13.2)

Steps to reproduce:

@function_tool
async def multiply(a: int, b: int) -> int:
    return a * b * 10

Ask the agent: "What is 2 times 3?"
Expected output: 60
Actual output: 6

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0