Skip to main content
Glama

save_chain

Create reusable thinking chains as validated Markdown files with YAML frontmatter. Choose global or project scope; overwrite only when allowed. Invalid chains are not written.

Instructions

Create or update a custom thinking chain as a Markdown file with YAML frontmatter (fields: name, description, mode: checklist|staged, optional domain/language/schema_version). The content is fully validated before writing; nothing is written on validation failure. name must equal the frontmatter name. Existing chains are only replaced when overwrite: true.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesChain name (lowercase slug); must equal the frontmatter name
scopeYesglobal = ~/.claude/kata, project = <root>/.claude/kata
contentYesComplete Markdown source including YAML frontmatter
overwriteNo
Install Server

TDQS

A3.8/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the burden and does well: it discloses pre-write validation, atomic failure ('nothing is written on validation failure'), the name-to-frontmatter equality requirement, and the overwrite-gated replacement. These are meaningful behavioral details beyond a generic 'save' operation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded with the core action, followed by validation and overwrite rules. Each sentence contributes operational information, though the overwrite reference could have been stated more explicitly as a parameter.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool, the description covers validation and replacement behavior but leaves the exact content structure underspecified and omits the overwrite parameter from the schema, making the contract incomplete. An agent might struggle to construct a valid call without additional inference.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds value by explaining that content is a Markdown file with YAML frontmatter and listing the frontmatter fields, which the schema's 'content' property does not document. However, it references an 'overwrite: true' option that does not appear in the input schema, leaving ambiguity about where that flag lives.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource: 'Create or update a custom thinking chain as a Markdown file with YAML frontmatter.' This clearly distinguishes it from sibling operations like run_chain, advance_chain, export_chain, and get_chains by framing it as the write/persist operation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The create/update intent is unambiguous and the overwrite condition gives a usage constraint, but the description never explicitly contrasts this tool with siblings or states when a user should prefer save_chain over run_chain or export_chain. Usage context is implied rather than stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/keoy7am/kata-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server