Skip to main content

Tools (Function Calling)

Tools define functions that can be invoked within the Spice runtime, either directly or by a language model (LLMs). These tools provide access to different functionalities and can be customized in the tools section of spicepod.yaml.

tools​

The tools section in your configuration specifies one or more tools available for use in the runtime.

Example:

tools:
- name: arpanet
from: websearch
description: "Search the web for information."
params:
engine: perplexity
perplexity_auth_token: ${ secrets:SPICE_PERPLEXITY_AUTH_TOKEN }

name​

A unique identifier for this tool.

from​

Defines the source of the tool, or the specific built-in tool to customise. See Available Tools for a list of available tools.

description​

Optional. A textual description of the tool's function.

params​

Optional. A map of key-value pairs for additional parameters specific to the tool.

dependsOn​

Optional. A list of dependencies that must be available before this tool can be used.