Function-Based Tool Use
Coming Soon
This tutorial is under development. Check back soon for a complete walkthrough.
What you'll learn
This tutorial will walk you through writing JavaScript functions that AI agents
can invoke as tools, using the raisin.* API to read and write data, run SQL,
and call external services.
Planned outline
- Prerequisites: a running RaisinDB server and basic JavaScript
- Create a function: scaffold one with
raisindb create function, write a handler that reads and returns a node, and deploy it - Use raisin.nodes: create, read, update and delete nodes from a function
- Use raisin.sql: run queries with bound parameters and process the rows
- Use raisin.http: call an external API under a
network_policy - Use raisin.events: emit events that other functions react to
- Configure triggers: node event, schedule and HTTP triggers
- Resource limits: memory, time and concurrency
- Build an agent tool: describe the function with an
input_schema, add it to an agent'stools, and watch the agent call it
Related guides
- Function-Based Tool Use: the concepts
- Creating Functions: the mechanics
- Agent Memory with Branches: combine functions with branches