Skip to content

feat(gemini): omit empty properties object for no-parameter tools #1641

@bug-ops

Description

@bug-ops

Follow-up from PR #1635 (Gemini Phase 3 tool use).

When converting a tool with no parameters, convert_tool_definitions() produces parameters: {type: OBJECT, properties: {}}. The Gemini API accepts this, but it is cleaner to omit the parameters field entirely for no-parameter tools.

Evaluate whether omitting parameters is correct per the Gemini function calling spec and update the conversion logic if so.

Part of #1592.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions