Skip to main content
Glama
smol-codeact-mcp

smol-codeact-mcp

by nanyun818

codeact_compile_stubs

Compile verbose OpenAI/MCP JSON tool schemas into compact Python CodeAct stubs and return token statistics, reducing schema overhead for coding agents.

Instructions

Compile verbose OpenAI/MCP JSON Tool Schemas into compact Python CodeAct stubs with token stats.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "schemas": "<schemas>"
    },
    "name": "codeact_compile_stubs"
  }
}

Input Schema

NameRequiredDescriptionDefault
schemasYesArray of JSON Tool Schema definitions.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.3/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden. It discloses only that the output includes stubs and token statistics; it does not say whether stubs are persisted to session state, whether the call is idempotent, whether it has any side effects, or what errors look like for malformed schemas.

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?

A single front-loaded sentence with no filler; every phrase contributes. It is terse rather than padded, though the terseness leaves gaps addressed in other dimensions.

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 one-parameter utility with no output schema, the description covers the core transformation adequately. It stops short of explaining the returned stub form beyond 'token stats' and omits any note on where compiled stubs live, which matters for chaining into codeact_execute.

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 100%, so the baseline is 3, but the description adds value by qualifying the accepted array as OpenAI/MCP JSON tool schema definitions, which is more specific than the schema's generic 'Array of JSON Tool Schema definitions.'

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

Purpose4/5

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

The description uses a specific verb ('Compile') and names both the input ('verbose OpenAI/MCP JSON Tool Schemas') and the output ('compact Python CodeAct stubs with token stats'). It is unambiguous against siblings like codeact_execute or codeact_reset_session, though it never explicitly states the relationship to those siblings.

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?

There is no explicit when-to-use or when-not-to-use guidance, and no mention that this should precede codeact_execute. The conversion intent implies a setup step, but the agent must infer that usage.

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