Skip to main content
Glama

代码语言迁移(按次计费)

codetrans

A 语言 → B 语言等价实现 + 依赖替换与行为差异清单。按次计费:业务成功才确认扣款,内容违规、模型超时或生成失败会自动全额退款。

Input Schema

NameRequiredDescriptionDefault
toYes目标语言。
codeYes要迁移的源代码,最多 20000 字符。
fromNo源语言,不填自动判断。
requestIdNo幂等键。同一次业务重试时复用同一个值,可避免重复扣费。

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations at all the description carries the full burden, and it does disclose genuinely non-obvious behavior: billing occurs per call, is only confirmed on business success, and is auto-refunded on content violation, model timeout, or generation failure. That is real value beyond the schema. Still missing are latency expectations and what the response payload looks like structurally.

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?

Two dense sentences, front-loaded with what is produced and then the billing/refund terms. No filler; the only shortfall is that the refund clause reads as marketing-adjacent rather than operative detail.

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?

No output schema exists, so the description must describe returns — and it does name the three deliverables (equivalent implementation, dependency replacements, behavioral differences). Combined with the full schema coverage this is close to complete; a note on output format or expected turnaround would close the gap.

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?

Schema description coverage is 100% with four parameters, so the baseline is 3. The description adds nothing about `from` auto-detection, the `to` enum, or the `requestId` idempotency key — all of that meaning already lives in the schema.

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?

States a concrete verb+resource: converts code from language A to language B, and additionally returns dependency replacements and a behavioral-difference list. That output shape distinguishes it from siblings like codegen or translate (natural language), though no sibling is named explicitly.

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?

Usage is only implied by the output description — an agent can infer this is for porting existing code to another language. There is no explicit when-to-use/when-not guidance, no pointer to alternatives such as codegen for new code or translate for prose, and no mention of input constraints (the 20000-character cap lives only in the schema).

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.