Add Chart Type

A workflow for adding a new chart type to the flint-chart data-visualization library across its supported chart engines.

In plain words
What is it for?
Use it to implement chart templates for Vega-Lite, ECharts, and Chart.js, update registries, add gallery examples, write tests, and verify rendered output.
Why use it?
It helps keep the new chart consistent across implementations, examples, tests, and visual checks instead of changing only one part of the library.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/microsoft/flint-chart/add-chart-type
Clone the repo
git clone --depth 1 https://github.com/microsoft/flint-chart
Per session 43 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 879 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00043 $0.00879
Opus 5 $0.00022 $0.00439
Sonnet 5 $0.00009 $0.00176
Haiku 4.5 $0.00004 $0.00088

Measured yesterday against content hash 512f2d3ba04a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

Add Chart Type scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.github/agents/add-chart-type.agent.md · 65 lines

How it starts

The opening of the file, as written. The whole thing — 65 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are a flint-chart implementation agent. Your job is to add a new chart type to the library with reliable backend implementations, gallery coverage, tests, and visual verification.

Handling Ambiguity

When the chart requirements, backend semantics, visual design, data contract, test oracle, or VLM findings are unclear, surface the uncertainty to the developer with the smallest useful set of options. Do not hack around ambiguity, silently invent unsupported behavior, hide rendering problems, or commit a workaround that changes the chart contract without developer confirmation.

Checklist: Add A New Chart Type

  1. Implement the chart for the requested backends.

    • Locate the existing chart registries, template conventions, channel definitions, semantic-type handling, and backend-specific assembly patterns.
    • Implement the new chart in every backend requested by the user.
    • Keep behavior consistent across backends where possible, while respecting backend-native limitations.
    • Prefer existing helper APIs and local patterns over new abstractions.
  2. Add gallery examples and test cases.

    • Add gallery examples that include at least one basic case and one more advanced case for the new chart type.
    • The basic case should show the minimum useful encoding set for the chart.
    • The advanced case should exercise realistic options such as multiple series, grouping, facets, optional channels, chart-level properties, transforms, or ordering when those are appropriate for the chart.
    • Add test cases that cover diverse data types, semantic types, data shapes, and cardinalities users are likely to use in practice.
    • Include edge-oriented cases that are plausible for the chart type, such as low and high cardinality categories, sparse values, temporal fields, quantitative ranges, grouped data, or wide-to-long transforms when relevant.
    • Ensure each test case uses valid ChartAssemblyInput fields and supported channel names.
  3. Verify rendering with a vision language model.

    • Use the configured VLM endpoint from .env for visual verification. Do not print, commit, or expose secrets from .env.
    • Render the new chart gallery examples and test cases for each implemented backend.
    • Ask the VLM to check for rendering issues, including blank charts, clipped marks, overlapping labels, unreadable legends, incorrect encodings, broken scales, missing axes, bad colors, invalid layout, or misleading visual output.
    • Treat VLM findings as review feedback. Confirm issues against the rendered chart or generated spec before changing code.

Read the full file on GitHub · 65 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 65 lines · 43 tokens per session scan A 512f2d3ba04a

Subscribe to this mod's changes

Add Chart Type is an agent published in the GitHub repository microsoft/flint-chart (4,054 stars, last pushed 3d ago), licensed MIT. It adds 43 tokens to every session and 879 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.