3 practices, live from D1
Practices
Prompt-engineering best practices specific to tool/function description writing, grouped by category unless filtered. For general prompting techniques (not tool-description-specific), see subagentprompts.com.
| practice | description |
|---|---|
| Avoid ambiguous, overlapping tool sets | If two tools could plausibly both apply to the same request, the model has to guess -- and guesses are where tool-use errors come from. Where possible, consolidate near-duplicate tools into one tool with a parameter, or make the boundary between them explicit in both descriptions. |
| Explain when to use the tool -- and when not to | Beyond describing what a tool does, a good description tells the model the situations that should trigger it, and explicitly calls out situations where a similar-looking tool should be used instead, to prevent the model from picking the wrong one of several overlapping tools. |
| Prefer one tool, one clear responsibility | A tool that tries to do many unrelated things behind a single description and a large branching parameter set is harder for the model to invoke correctly than several smaller, single-purpose tools with tight, specific descriptions. |
Machine-readable version: GET /api/practices?category=scoping