Is Function Or Decorated • AI Agents Framework

is_function_or_decorated: Checks if the given object is a function or has a __call__ method.

is_function_or_decorated

Method

</div>

This is a method of the AgentsGenerator class in the agents_generator module.

Checks if the given object is a function or has a __call__ method.

Signature

python
def is_function_or_decorated(obj: Any) -> Any

Parameters

ParamField Any

The object to be checked.

Returns

ResponseField Any

True if the object is a function or has a __call__ method, False otherwise.

Uses

  • inspect.isfunction

Source

View on GitHub

praisonai/agents_generator.py at line 220