tools

package module
v0.21.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 12, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Package tools is the module overview for Scope's ready-to-assemble tools. It declares no API of its own; every capability lives in a subpackage.

This module implements executable capability only. The tool protocol, typed functions, and the registry belong to core/tool; schemas are derived by core/jsonschema. Every capability here is an ordinary core/tool.Tool, so a chat client, an Agent, or an MCP server consumes them through one contract.

Capabilities

  • shell: run a command and capture its output.
  • fs: read, write, edit, glob, and grep inside a fixed path authority.
  • textread: read text with line numbering and limits.
  • httpreq: issue an HTTP request against an explicit allowlist.
  • web: the neutral Searcher and Fetcher SPIs plus the search and fetch tools, with one provider package per vendor.
  • skills: expose an Agent Skills repository as a callable tool.

Two tiers

Every capability is split in two. The Tool tier faces the model: JSON in, JSON out, schema validation. The Backend Port tier does the work and holds all the domain logic — line numbering, binary detection, write locks, path authority. That split is what lets a remote or sandboxed backend answer a glob or grep in one round trip instead of listing and reading through the Tool tier.

Assembly

There is no global registry: a caller registers exactly the tools it wants. Every tool receives its executor or client explicitly. Filesystem roots, shell access, network clients, and other authorities are never inferred from nil or ambient process state.

Concurrency and limits

A tool may declare, per call, whether it can overlap others and what it conflicts on. Reads declare no conflict; an edit or write keys on its target path, so the loop parallelizes different files and serializes the same file. Output over a limit is truncated and marked, never turned into an error, so the model can decide what to do next.

Directories

Path Synopsis
Package fs exposes LLM-callable filesystem tools (read, write, edit, glob, grep) on top of minimal per-operation ports.
Package fs exposes LLM-callable filesystem tools (read, write, edit, glob, grep) on top of minimal per-operation ports.
Package httpreq exposes a single model-callable HTTP-request tool.
Package httpreq exposes a single model-callable HTTP-request tool.
Package shell exposes a single LLM-callable shell tool plus a small Executor SPI.
Package shell exposes a single LLM-callable shell tool plus a small Executor SPI.
Package skills exposes three LLM-callable tools that surface Agent Skills to a chat model through progressive disclosure.
Package skills exposes three LLM-callable tools that surface Agent Skills to a chat model through progressive disclosure.
Package textread provides bounded UTF-8 line scanning for filesystem adapters with different consumer result policies.
Package textread provides bounded UTF-8 line scanning for filesystem adapters with different consumer result policies.
web
Package web defines provider-neutral web search and page-fetching tools.
Package web defines provider-neutral web search and page-fetching tools.
brave
Package brave wires Brave's Web Search API into web.Searcher.
Package brave wires Brave's Web Search API into web.Searcher.
exa
Package exa integrates Exa's Search and Contents APIs with the provider-neutral web contracts.
Package exa integrates Exa's Search and Contents APIs with the provider-neutral web contracts.
firecrawl
Package firecrawl integrates Firecrawl's Search and Scrape APIs with the provider-neutral web contracts.
Package firecrawl integrates Firecrawl's Search and Scrape APIs with the provider-neutral web contracts.
jina
Package jina integrates Jina Search and Jina Reader with the provider-neutral web contracts.
Package jina integrates Jina Search and Jina Reader with the provider-neutral web contracts.
perplexity
Package perplexity wires Perplexity's Search API into web.Searcher.
Package perplexity wires Perplexity's Search API into web.Searcher.
serper
Package serper wires Serper's Google Search API into web.Searcher.
Package serper wires Serper's Google Search API into web.Searcher.
tavily
Package tavily integrates Tavily Search and Extract with the provider-neutral web contracts.
Package tavily integrates Tavily Search and Extract with the provider-neutral web contracts.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL