flexeval.classes.tool_call#

Classes

ToolCall(**kwargs)

Holds a single component of a single turn Corresponds to one output of a node in LangGraph or one Turn in jsonl

class flexeval.classes.tool_call.ToolCall(**kwargs)[source]#

Bases: BaseModel

Holds a single component of a single turn Corresponds to one output of a node in LangGraph or one Turn in jsonl

additional_kwargs = <TextField: ToolCall.additional_kwargs>#
args = <TextField: ToolCall.args>#
dataset = <ForeignKeyField: ToolCall.dataset>#
function_name = <TextField: ToolCall.function_name>#
get_dict_representation() dict[source]#

Get a dictionary representation of the content of this toolcall, suitable for passing to function metrics that need a standard Python data structure representation of a tool call.

Keys in returned dictionary are role, content (for the response content), function_name, and args.

id = <IntegerField: ToolCall.id>#
message = <ForeignKeyField: ToolCall.message>#
metrics_list#

!! processed by numpydoc !!

response_content = <TextField: ToolCall.response_content>#
thread = <ForeignKeyField: ToolCall.thread>#
tool_call_id = <TextField: ToolCall.tool_call_id>#
turn = <ForeignKeyField: ToolCall.turn>#