llama-stack-mirror/llama_stack/providers/utils
ehhuang ffe3d0b2cd
fix: nullable param type for function call (#2086)
Nullable param type is not supported, e.g. ['string', 'null'], since it
fails type validation.

Tests:
Run inference with

        messages:
- content: You are a helpful assistant that can use tools to get
information.
          role: system
        - content: What's the temperature in San Francisco in celsius?
          role: user
        tools:
        - function:
            description: Get current temperature for a given location.
            name: get_weather
            parameters:
              additionalProperties: false
              properties:
                location:
description: "City and country e.g. Bogot\xE1, Colombia"
                  type: string
                unit:
                  description: "Unit of temperature, default to celsius"
                  type: [string, "null"]  # <= nullable type
              required:
              - location
              type: object
          type: function

Co-authored-by: Eric Huang <erichuang@fb.com>
2025-05-01 13:17:36 -07:00
..
bedrock Fix precommit check after moving to ruff (#927) 2025-02-02 06:46:45 -08:00
common feat: [new open benchmark] BFCL_v3 (#1578) 2025-03-14 12:50:49 -07:00
datasetio refactor: extract pagination logic into shared helper function (#1770) 2025-03-31 13:08:29 -07:00
inference fix: nullable param type for function call (#2086) 2025-05-01 13:17:36 -07:00
kvstore chore: made inbuilt tools blocking calls into async non blocking calls (#1509) 2025-03-09 16:59:24 -07:00
memory fix(deps): move chardet and pypdf imports inline where used (#1434) 2025-03-06 17:09:14 -08:00
scoring feat: [New Eval Benchamark] IfEval (#1708) 2025-03-19 16:39:59 -07:00
telemetry feat: use same trace ids in stack and otel (#1759) 2025-03-21 15:41:26 -07:00
__init__.py API Updates (#73) 2024-09-17 19:51:35 -07:00
scheduler.py feat: Implement async job execution for torchtune training (#1437) 2025-04-14 08:59:11 -07:00