Skip to main content
Glama

Chart color check

chart_colour_check
Read-only

Check a set of chart series colors. Pass colors (list or comma-separated string of hex, rgb(), hsl() or CSS names, up to 24), background (default #ffffff) and chartType (bar, line, area, pie, scatter, map and so on). Returns: contrast of each color against the background with the 3:1 minimum for graphics (WCAG 2.x non-text contrast) and the nearest passing shade; pairwise color distance (CIE76 delta E) under typical vision, protanopia, deuteranopia, tritanopia (Machado et al. 2009 model) and grayscale, flagging pairs below 10 for filled marks or 15 for thin marks (working conventions, not standards); duplicate colors; a count warning past seven categorical hues; and a direct-labeling recommendation when there are more than four series. Also lists which colors of the Wong palette (Bang Wong, Points of view: Color blindness, Nature Methods, 2011) stay at 3:1 on your background. Pure computation.

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": {
      "colors": "<colors>"
    },
    "name": "chart_colour_check"
  }
}

Input Schema

NameRequiredDescriptionDefault
colorsYesSeries colors, as a list or comma-separated string.
chartTypeNobar, column, line, area, pie, scatter, map, stacked...
backgroundNoChart background color. Default #ffffff.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / background / description
      Previous value: -"Chart background colour. Default #ffffff."New value: +"Chart background color. Default #ffffff."
    • changedInput schema / properties / colors / description
      Previous value: -"Series colours, as a list or comma-separated string."New value: +"Series colors, as a list or comma-separated string."
  2. Added

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already cover readOnly/destructive/openWorld, so the description's job is to add depth – and it does: it discloses the full return payload, the specific standards used (WCAG 2.x non-text 3:1), the CVD simulation model (Machado et al. 2009), the ad-hoc pair-distance thresholds (10 filled / 15 thin, explicitly flagged as conventions not standards), and states it is pure computation with no side effects. That is unusually rich behavioral disclosure.

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?

Inputs are front-loaded ahead of the long results list, so an agent gets the call shape first. The returns sentence is a dense run-on enumerating six or seven distinct checks with citations, which is information-dense rather than padded, but could have been broken into a short bulleted structure for faster scanning.

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 no output schema, the description carries the return-value burden and does so thoroughly, listing every check and its threshold. It is slightly short of complete because it never says how chartType changes the 10-vs-15 pair threshold, nor how findings are shaped/ordered in the response.

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; the description earns above that by adding facts absent from the schema – the 24-color cap, the accepted color syntaxes (hex, rgb(), hsl(), CSS names), and the string-vs-list flexibility. It does not explain how chartType influences the filled-vs-thin threshold, which is the one semantic link left implicit.

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 opens with a precise verb+resource ('Check a set of chart series colors') and then enumerates exactly what it evaluates (contrast, pairwise delta E under multiple CVD models, duplicates, palette counts). This is clearly distinguishable from generic siblings like check_contrast or colour_palette_brief_check because it is scoped to chart series colors and chart-specific thresholds.

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 implied by the input contract: pass series colors and a chart type to validate a chart palette. However, it never states when NOT to use it (e.g. for text contrast use check_contrast, for picking a chart form use chart_chooser), and with over 130 siblings an explicit alternative would have been valuable. The closest thing to guidance is 'Pure computation', which speaks to safety, not selection.

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.

Resources