Skip to main content
Glama

flompt

compile_prompt

Compile a list of blocks into a Claude-optimized structured XML prompt.

Takes the JSON returned by decompose_prompt (or manually crafted blocks)
and produces a ready-to-use XML prompt with a token estimate.

Args:
    blocks_json: JSON-stringified list of blocks.
                 Each block: {"type": "role|objective|...", "content": "...",
                              "label": "...", "description": "...", "summary": ""}

Returns:
    The compiled XML prompt with token estimate.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
blocks_jsonYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

TDQS

A4.1/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions the transformation and token estimate, but does not disclose potential side effects, permissions, error handling, or the fact that it is a pure read-only operation. For a compile tool, this is a notable gap.

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?

The description is well-structured and concise: a one-sentence purpose, a short explanation, and a clear Args/Returns breakdown. No unnecessary wording.

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?

With one parameter and an output schema, the description adequately covers both input and output. It could enumerate valid block types explicitly, but the reference to decompose_prompt and the partial list ('role|objective|...') gives enough context, and sibling list_block_types covers that.

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

Parameters5/5

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

The description provides a detailed structure for blocks_json, listing each block's fields (type, content, label, description, summary) and explaining it is a JSON string. This vastly exceeds the minimal schema ('type: string') and adds essential meaning for correct usage.

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 starts with a specific verb 'Compile' and resource 'list of blocks', clearly distinguishing it from siblings like decompose_prompt and list_block_types. It explicitly states the output is a Claude-optimized XML prompt with token estimate.

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

Usage Guidelines4/5

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

The description states it takes JSON returned by decompose_prompt, implying it's used after decomposition. However, it does not explicitly contrast with alternatives or provide when-not-to-use guidance, so there is clear context but no exclusions.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

TDQS

A4.4/5.0
Disambiguation5/5

Each tool has a unique role: decompose_prompt converts raw text to structured blocks, compile_prompt converts blocks to XML, and list_block_types provides reference metadata. No two tools serve the same function.

Naming Consistency5/5

All tool names follow a clear verb_noun pattern with snake_case: compile_prompt, decompose_prompt, list_block_types. The verbs are distinct and descriptive.

Tool Count5/5

With three tools, the server covers the essential workflow of decomposition, compilation, and type reference without redundancy. This is an appropriately scoped toolkit for a focused purpose.

Completeness5/5

The toolkit provides the full pipeline from raw prompt to compiled XML, plus the necessary reference for known block types. There are no obvious missing operations for the intended workflow.

Resources