Tools

A tool is the unit the agent loop calls when the model decides it needs to act in the world. { name, description, parameters, execute }. The model picks a tool based on its instructions, the user's message, and the tools available to that agent.

TAI tools and MCP. Native tools are in-process TypeScript objects with JSON-Schema parameters. TAI can also connect to configured MCP servers, discover their tools, and register them into the same per-agent tool catalog. See MCP servers.

How to enable

Each tool has a tools.<name> block in config.yaml. Set enabled: true to turn it on:

yaml
tools:
  exec:
    enabled: true
    allowedCommands: [git, pnpm, node, tsc]
  write:
    enabled: true
    allowedPrefixes: [data/, output/]
  web_search:
    enabled: true
    provider: brave
    apiKey: ${BRAVE_API_KEY}
  browser_mediator:
    enabled: true
    egressAllowList: [amazon.com, wikipedia.org]
    vaultEnabled: true
  discord_dm:
    enabled: true

To restrict which agents can call a tool, list it in the agent's tools: array. An agent with no tools: list inherits every enabled tool.

Built-in catalog

Memory and knowledge

Read Memory for how these stores relate.

ToolVerbsNotes
memoryread, write, append, list, searchFile-shaped notes in the agent's context dir. Scopes: profile, global, knowledge.
recallnote, query, search, list, deleteThe structured tier. Short notes with tags and embeddings.
core_memoryappend, replace, read, clearAlways-injected text the agent maintains as its working summary.
factsset, get, delete, queryStructured (category, entity, key, value) facts.

File system and shell

ToolWhat it doesNotes
readRead a file's contents.allowedPrefixes: config to scope.
writeCreate or overwrite a file.allowedPrefixes: config.
execRun a shell command.allowedCommands: allowlist. Honors sandbox config.

Web

ToolWhat it doesNotes
web_fetchFetch a URL, extract plain text.Aware of browser-mediator sessions: refuses when an active mediator session disallows the host.
web_searchBrave Search API.Requires apiKey: ${BRAVE_API_KEY}.

Tasks and projects

Read Tasks & projects for the backend story.

ToolWhat it does
tasksCreate, update, delete, comment on project tasks.
task_queryFilter tasks by status, assignee, tags, text.
projectsList, register, switch projects.
documentsDocument store. PDF and image OCR via optional peers.

Integrations (Google)

ToolVerbsSetup
gmailsearch, read, mark_seen, sendRequires the gog CLI installed and ${GOG_KEYRING_PASSWORD} set. Account in tools.gmail.account. Send is opt-in per agent (add gmail to the agent's tools: allowlist deliberately).
google_calendarlist_events, search, create_event, delete_eventSame gog CLI.
google_driveupload, list, searchSame gog CLI.

Browser

ToolWhat it doesNotes
browserGeneric Playwright browser. Navigate, click, type, screenshot.Requires playwright peer dep.
browser_mediatorBounded browser with egress allow-list, vault refs, output sanitiser, always-HITL gates.Provided by @tailored-ai/browser-mediator. Prefer this over browser for agent-driven web flows.

Delegation and control

ToolWhat it does
delegateCall another agent synchronously (or async=true for background).
task_statusList or inspect background tasks started by async delegate.
claude_codeDelegate to the Claude Code CLI as a sub-agent.
ask_userBlock the loop and prompt the user for input. Works in CLI and Discord.
load_skillLazy-load a Skill into the current loop.
run_workflowTrigger a Workflow.

Outbound push

ToolWhat it does
discord_dmSend a Discord DM to the configured owner. The right channel for unsolicited "FYI" pings from online agents.
request_actionEnqueue a high-risk action (purchase, form submit) to the trusted-actions gateway for human approval.
check_action_statusPoll a previously-enqueued action's status.
md_to_pdfConvert a markdown file to PDF. Requires md-to-pdf peer dep.

Admin and introspection

ToolWhat it does
adminRead or update agent configuration at runtime. Restricted to write-permitted agents.
resource_adminInstall, list, remove skills and workflows.
sleepBlock the loop for N seconds. Useful in workflow steps.
current_datetimeReturns the current local datetime.
uptimeReturns the agent process uptime.
git_logReturns recent git log entries from the current project.
ip_infoReturns the agent's public IP and geo.

Restricting per agent

By default an agent inherits every enabled tool. Narrow with the agent's tools: array:

yaml
agents:
  researcher:
    tools: [web_search, web_fetch, recall, memory]
    # exec, write, browser, etc. are unavailable to this agent

Give each agent the tools its role needs. Tool schemas consume context and selection accuracy varies by model, but there is no universal useful cutoff; measure with the model and prompts you deploy.

Custom tools

For tools that wrap a shell command, no TypeScript needed. The custom_tools: block in config.yaml takes a name, a command, a description, and a parameter schema. See Custom tools.

Plugin tools

Tools shipped as npm packages plug in through the plugins: config block. See Plugins.

Writing tools in code

See Extending in code for the Tool interface and how to add a tool by forking the monorepo or by writing a plugin.

The Tool interface

For reference:

ts
import type { Tool, ToolContext, ToolResult } from "@tailored-ai/core";

export const myTool: Tool = {
  name: "my_tool",
  description: "Does something useful in one sentence.",
  parameters: {
    type: "object",
    properties: {
      input: { type: "string", description: "The input." },
    },
    required: ["input"],
  },
  async execute(args, context: ToolContext): Promise<ToolResult> {
    return { success: true, output: `Result: ${args.input}` };
  },
};

ToolContext gives access to the active session id, project id, db reference, and runtime accessor. The optional destroy?() hook fires on hot reload, when the tool is being replaced.