Skip to main content
Glama

maid_generate_stubs

Generate test stubs from a manifest to create boilerplate test files and class structures for test automation.

Instructions

Generate test stubs from a manifest using MAID Runner.

When to use:

  • Phase 2 (Planning): After creating manifest, generate test file skeleton

  • Jumpstarting tests: Create boilerplate test structure from manifest

  • Consistency: Ensure test file naming matches manifest conventions

What it generates:

  • Test file with naming pattern: tests/test_task_XXX_*.py

  • Test class structure based on expectedArtifacts

  • Import statements for artifacts being tested

  • Placeholder test methods for each artifact

Tips:

  • Run after creating/updating a manifest

  • Generated stubs are starting points - add assertions

  • Test file is added to manifest's readonlyFiles automatically

Args: ctx: MCP context containing session and roots information manifest_path: Path to the manifest JSON file

Returns: GenerateStubsResult with generation outcome

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
manifest_pathYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
successYes
manifest_pathYes
generated_filesYes
errorsYes
Behavior4/5

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

No annotations provided, so description carries full burden. It describes what is generated (naming, class structure, imports, placeholder methods) and that the test file is automatically added to the manifest's readonlyFiles. Lacks details on error handling but is sufficiently transparent.

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

Conciseness5/5

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

Well-structured with clear sections (When to use, What it generates, Tips, Args, Returns). Every sentence adds value; no wasted words.

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

Completeness5/5

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

Given the output schema exists, the description appropriately explains the generation outcome. The tool's single parameter is well-contextualized, and the usage guidance makes it easy for an agent to decide when to use this tool.

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?

Schema coverage is 0%, but the description includes an 'Args' section that explains 'manifest_path: Path to the manifest JSON file', adding meaning beyond the schema's type-only 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 'Generate test stubs from a manifest using MAID Runner.' It specifies the verb and resource, and the tool's purpose is distinct from sibling tools like 'maid_validate' or 'maid_snapshot'.

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

Usage Guidelines5/5

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

Explicitly lists when to use (Phase 2 Planning, jumpstarting tests, consistency) and provides tips (run after creating/updating manifest). Differentiates itself well without needing to list exclusions.

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/mamertofabian/maid-runner-mcp'

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