Skip to main content
Glama

darken_palette

把一套浅色配色推导成深色版本:按固定规则重排明度与饱和度,并返回每对颜色的实测对比度。可用 slug 取库里配色,也可直接传 roles。

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "darken_palette"
  }
}

Input Schema

NameRequiredDescriptionDefault
slugNo配色 slug,如 jing-hu-lan
rolesNo直接传角色色值,如 {"bg":"#faf8f2","text":"#2b2b2b","primary":"#1989ea"};与 slug 二选一
platformNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It usefully discloses that the transformation is deterministic ("按固定规则") and that the response includes measured contrast per pair. It does not say whether any stored palette is mutated, what happens if both slug and roles are supplied, or how the derived result is returned, leaving meaningful behavioral gaps.

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 tightly packed sentences that front-load the transformation and then the input modes; almost no filler. Slightly dense but every clause carries information.

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 derivation tool with no output schema, the description does say the response contains per-pair measured contrast, which is the key return-value signal. But the undocumented platform parameter and unanswered questions about output shape and side effects leave it short of complete.

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 coverage is 67%, and the description reinforces the slug-vs-roles alternative and the fact that slug pulls from the library. The roles example lives in the schema, not the description. Critically, the platform parameter (with its enum) is never mentioned in the description, so its meaning must be inferred entirely from 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?

The description states a specific verb+resource: derive a dark palette from a light one via fixed lightness/saturation rules and return measured contrast per color pair. That is materially more specific than a name restatement. It does not explicitly name a sibling it is not (e.g., suggest_palette, check_contrast), so it stops short of 5.

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?

"可用 slug 取库里配色,也可直接传 roles" tells the agent the two input modes and implies they are alternatives, which is useful invocation guidance. However, it gives no when-to-use/when-not versus the relevant siblings (check_contrast, suggest_palette), so the routing guidance is implied rather than explicit.

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.