Skip to main content
Glama

get_code_examples

Search documentation for code examples matching your query. Get working examples for Griptape patterns like RAG pipelines, custom tools, or workflows.

Instructions

Search for code examples related to a topic.

Finds code snippets from the documentation that match your query. Useful for finding working examples of Griptape patterns.

Args: topic: What you want examples of (e.g. "RAG pipeline", "custom tool", "workflow")

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topicYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

With no annotations provided, the description bears full burden but only states it finds code snippets. It does not disclose behavioral traits like output format, result limits, or permissions. The docstring provides example values but not behavioral context.

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 concise with 4 sentences, front-loading the core purpose. The docstring for the parameter is clearly separated. No wasted words, though could be slightly more structured.

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

Completeness4/5

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

Given the tool has one required parameter and an output schema (indicating return values are defined), the description is sufficiently complete for a simple search tool. It covers the core functionality and provides an example.

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

Parameters4/5

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

Despite 0% schema description coverage, the description compensates with a clear docstring for the 'topic' parameter, including example values. This adds meaningful semantics beyond the schema type definition.

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 clearly states the tool searches for code examples related to a topic, using a specific verb ('Search') and resource ('code examples'). It distinguishes itself from siblings like 'search_docs' by focusing on code snippets.

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 description implies usage for finding working examples of Griptape patterns but lacks explicit when-to-use guidance or alternatives. It does not specify when not to use this tool versus other search tools.

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

Install Server

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/KianSalem/griptape-mcp'

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