GenAI.Tool (GenAI Core v0.3.2)

Copy Markdown

Represents a function that can be called by the model.

Summary

Types

t()

@type t() :: %GenAI.Tool{
  description: GenAI.Types.description(),
  finger_print: GenAI.Types.finger_print(),
  handle: GenAI.Types.node_handle(),
  id: GenAI.Types.node_id(),
  inbound_links: GenAI.Types.link_map(),
  meta: nil | map() | keyword(),
  name: GenAI.Types.name(),
  outbound_links: GenAI.Types.link_map(),
  parameters: term(),
  vsn: float()
}

Functions

apply_node_directives(this, graph_link, graph_container, session, context, options)

description(graph)

Callback implementation for GenAI.Graph.NodeBehaviour.description/1.

description(graph, default)

Callback implementation for GenAI.Graph.NodeBehaviour.description/2.

from_json(json_string)

Extract function from json.

from_yaml(yaml_string)

Extract function from yaml.

handle(graph)

Callback implementation for GenAI.Graph.NodeBehaviour.handle/1.

handle(graph, default)

Callback implementation for GenAI.Graph.NodeBehaviour.handle/2.

id(graph)

Callback implementation for GenAI.Graph.NodeBehaviour.id/1.

inspect_custom_details(subject, opts)

See GenAI.Graph.NodeProtocol.DefaultProvider.inspect_custom_details/2.

inspect_full_detail(subject, opts)

See GenAI.Graph.NodeProtocol.DefaultProvider.inspect_full_detail/2.

inspect_high_detail(subject, opts)

See GenAI.Graph.NodeProtocol.DefaultProvider.inspect_high_detail/2.

inspect_low_detail(subject, opts)

See GenAI.Graph.NodeProtocol.DefaultProvider.inspect_low_detail/2.

inspect_medium_detail(subject, opts)

See GenAI.Graph.NodeProtocol.DefaultProvider.inspect_medium_detail/2.

name(graph)

Callback implementation for GenAI.Graph.NodeBehaviour.name/1.

name(graph, default)

Callback implementation for GenAI.Graph.NodeBehaviour.name/2.

new(options \\ nil)

Callback implementation for GenAI.Graph.NodeBehaviour.new/1.