---
source: https://iinventedlight.com/library/notes/writing-tool-descriptions.md
title: "Write a tool name, description, and argument schema the model can use"
license: CC-BY-4.0
license_url: https://creativecommons.org/licenses/by/4.0/
source_license: "MIT (OpenAI Agents SDK docs); Apache-2.0 (MCP specification); prose restates cited source lines in own words"
license_family: mixed-green
attribution: "Summary by iinventedlight (AI-assisted). Sources: OpenAI Agents SDK, Tools, MIT; Model Context Protocol, Tools specification, Apache-2.0."
author: "iinventedlight (synthesis of cited sources); text drafted with AI assistance"
date: 2026-11-22
status: published
approved_by: "Cole Withington, 2026-11-27 14:30 PT: \"Yes, publish all of that now\""
checked_on: 2026-11-22
as_of: 2026-11-22
confidence: medium
untested: "Not reproduced (2026-11-22). Official docs and source files were read; no test suite, server, or API call was run for this note."
category: coverage-gaps
topic_area: "how-to: writing tool descriptions and schemas"
tags: [agents, tools, mcp, json-schema, descriptions]
client: Librarian
sources:
  - id: S1
    title: "Tools"
    publisher: OpenAI Agents SDK
    url: https://github.com/openai/openai-agents-python/blob/main/docs/tools.md
    accessed: 2026-11-22
    license: "MIT"
  - id: S2
    title: "Tools"
    publisher: Model Context Protocol
    url: https://modelcontextprotocol.io/specification/2025-11-25/server/tools
    accessed: 2026-11-22
    license: "Apache-2.0"
---
# Write a tool name, description, and argument schema the model can use
**Answer:** Give every tool a unique name, a clear description, and a schema for its arguments. In the OpenAI Agents SDK, the function's docstring can supply that description. In MCP, the name plus metadata describes the schema.

## Why it matters

Tools let agents take actions such as fetching data or calling APIs. When you wrap a Python function as a tool, the tool description will be taken from the docstring of the function. You can provide a description instead. Descriptions for each input are taken from the docstring of the function, unless disabled. The input schema is created from the function's arguments.

The Model Context Protocol allows servers to expose tools that language models can invoke. Each tool is uniquely identified by a name and includes metadata describing its schema. Tool names **SHOULD** be unique within a server. Tool names **SHOULD** be considered case-sensitive. If a tool fails, clients **SHOULD** provide tool execution errors to language models to enable self-correction.

- `Name plus description` The model uses both to decide whether to call the tool
- `Argument schema` Built from the function's arguments and docstring
- `Unique, case-sensitive names` Tool names **SHOULD** be unique within a server

## See also

- [ao-mcp-tools-list-and-call](https://iinventedlight.com/library/notes/ao-mcp-tools-list-and-call/)
- [building-an-mcp-server](https://iinventedlight.com/library/notes/building-an-mcp-server/)
- [human-in-the-loop-approvals](https://iinventedlight.com/library/notes/human-in-the-loop-approvals/)

## Claims

- id: C1
  claim: A function tool can take its description from the function's docstring.
  source: S1
  evidence: "Tool description will be taken from the docstring of the function"

- id: C2
  claim: The input schema can be created automatically from the function's arguments.
  source: S1
  evidence: "The schema for the function inputs is automatically created from the function's arguments"

- id: C3
  claim: An MCP tool is identified by a name plus metadata that describes its schema.
  source: S2
  evidence: "Each tool is uniquely identified by a name and includes metadata describing its schema."

## Sources

- [S1] Tools. OpenAI Agents SDK. https://github.com/openai/openai-agents-python/blob/main/docs/tools.md . License: MIT. Accessed 2026-11-22.

- [S2] Tools. Model Context Protocol. https://modelcontextprotocol.io/specification/2025-11-25/server/tools . License: Apache-2.0. Accessed 2026-11-22.

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: OpenAI Agents SDK, Tools, MIT; Model Context Protocol, Tools specification, Apache-2.0. Text was condensed and changed from the originals.

---

Agents: [/agents.md](/agents.md) | [/.well-known/agent-library.json](/.well-known/agent-library.json).
