Class CallableFunctionDeclaration (1.76.0)

CallableFunctionDeclaration(
 name: str,
 function: typing.Callable[[...], typing.Any],
 parameters: typing.Dict[str, typing.Any],
 description: typing.Optional[str] = None,
)

A function declaration plus a function.

Methods

CallableFunctionDeclaration

CallableFunctionDeclaration(
 name: str,
 function: typing.Callable[[...], typing.Any],
 parameters: typing.Dict[str, typing.Any],
 description: typing.Optional[str] = None,
)

Constructs a FunctionDeclaration.

from_func

from_func(
 func: typing.Callable[[...], typing.Any]
) -> vertexai.generative_models._generative_models.CallableFunctionDeclaration

Automatically creates a CallableFunctionDeclaration from a Python function.

The function parameter schema is automatically extracted.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.