This page documents the format and content of a
TOOL.md file. A TOOL.md is the technical
specification that the agent reads to understand a
tool's contract: what it does, how to invoke it, what
it returns, and what can go wrong.
A TOOL.md is required for every tool in the lab. The
format is consistent across all tools; this makes it
easy for the agent to read a new tool's TOOL.md and
know what to expect.
A real-world example. torrent-finder searches for
movies/series via BitTorrent.
# Tool Spec: torrent-finder## PurposeSearch for movies/series via BitTorrent and outputmagnet URLs. The Coordinator runs this to find content,presents results, opens chosen magnet in Transmission.## Commands### `search <query>`- Input: search query (movie/series name + quality filters)- Output: list of magnets with source and title- Sources: solidtorrents.net, 1377x.to, bt4g.com- Filter results by quality: 4K, 1080p, HDR, DV, x265, x264### `open --magnet <url>`- Input: full magnet URL- Output: opens in Transmission (macOS `open` command)- Optional `--dry-run` to preview without opening## Data flow```textUser query (e.g., "Snatch 2000 4K") ↓Build search URLs for each source ↓HTTP GET with browser-like headers ↓Extract magnets from HTML (regex) ↓Filter by quality ↓Return results```## Configuration| Variable | Default | Purpose || ------------------ | ----------- | -------------------------------- || `TORRENT_SOURCES` | (3 sources) | The sources to query. || `TORRENT_TIMEOUT` | `30` | Per-request timeout in seconds. || `TORRENT_UA` | (random) | The user agent string. |## Dependencies- `requests>=2.28`: HTTP client.- `beautifulsoup4>=4.11`: HTML parsing.- `lxml>=4.9`: XML/HTML parser.## TestsThe tests are in `tests/`. The test command is`pytest tests/`. The tests use mocked HTTP responses toavoid hitting the real sources.## Failure modes| Failure | Result || -------------------------------- | --------------------------------------- || All sources are unreachable | Return an empty list with a warning. || No results match the query | Return an empty list. || Source returns 4xx | Skip the source; try the next one. || Source returns 5xx | Retry once; skip if still failing. || Magnet URL is malformed | Skip the entry; log the issue. |
The SKILL.md file is the activation file. It is
loaded by the Coordinator's skill loader when the
user's request matches the skill's trigger phrases.
The format is:
---name: <skill-name>description: <One-paragraph description.>---# <Skill Name>## When to Use This Skill[Trigger phrases and conditions.]## Workflow1. Step 12. Step 23. ...## Inputs[What the skill needs.]## Outputs[What the skill produces.]## Failure modes[What can go wrong.]
The name and description fields in the YAML
frontmatter are the trigger phrases the Coordinator
uses. The body is the workflow the Coordinator
follows.