KS
Killer-Skills

chart-visualization — how to use chart-visualization how to use chart-visualization, chart-visualization setup guide, chart-visualization alternative, chart-visualization vs AntV, chart-visualization install, what is chart-visualization, chart-visualization for AI agents, data visualization with chart-visualization, chart-visualization workflow

v1.0.0
GitHub

About this Skill

Perfect for Data Analysis Agents needing advanced chart visualization capabilities for user intent and data characteristics. chart-visualization is a skill that enables AI assistants to recommend and generate appropriate data visualizations, such as line, area, column, and bar charts, based on user intent and data analysis.

Features

Analyzes user intent and data characteristics to select suitable chart types
Supports time-series data visualization using Line and Area charts
Enables categorical comparison using Column and Bar charts
Facilitates proportion analysis using Pie charts
Generates distribution analysis using Histogram, Boxplot, and Violin charts

# Core Topics

antvis antvis
[0]
[0]
Updated: 3/6/2026

Quality Score

Top 5%
33
Excellent
Based on code quality & docs
Installation
SYS Universal Install (Auto-Detect)
Cursor IDE Windsurf IDE VS Code IDE
> npx killer-skills add antvis/GPT-Vis/references/radar.md

Agent Capability Analysis

The chart-visualization MCP Server by antvis is an open-source Categories.community integration for Claude and other AI agents, enabling seamless task automation and capability expansion. Optimized for how to use chart-visualization, chart-visualization setup guide, chart-visualization alternative.

Ideal Agent Persona

Perfect for Data Analysis Agents needing advanced chart visualization capabilities for user intent and data characteristics.

Core Value

Empowers agents to generate informative data visualizations using suitable chart types such as Line, Area, Column, Bar, Pie, Histogram, Boxplot, and Violin charts, leveraging user intent and data characteristics for optimal representation, and supporting various data formats.

Capabilities Granted for chart-visualization MCP Server

Automating chart type selection for time-series data
Generating column charts for categorical comparisons
Creating pie charts for proportion analysis

! Prerequisites & Limits

  • Requires data characteristics analysis
  • Limited to predefined chart types
Project
SKILL.md
13.1 KB
.cursorrules
1.2 KB
package.json
240 B
Ready
UTF-8

# Tags

[No tags]
SKILL.md
Readonly

Chart Visualization Skill

Workflow

This skill helps AI assistants recommend and generate appropriate data visualizations. The workflow consists of three main steps:

  1. Intent Recognition & Chart Selection: Analyze the user's intent and data characteristics to select the most suitable chart type

    • Time-series data → Line, Area charts
    • Categorical comparison → Column, Bar charts
    • Proportion analysis → Pie chart
    • Distribution analysis → Histogram, Boxplot, Violin charts
    • Relationship/Flow → Sankey chart
    • Multi-dimensional comparison → Radar chart
    • Other specific needs → Funnel, Waterfall, Liquid, WordCloud, Treemap, Venn, etc.
  2. Syntax Generation: Generate GPT-Vis syntax based on the selected chart type and provided data

  3. Code Generation: Generate renderable code for the target framework (HTML, React, or Vue)

Supported Chart Types

名称别名英文名适用场景分析意图
折线图线图Line Chart时间序列数据,展示趋势变化趋势分析、对比
柱形图柱状图Column Chart分类数据比较对比、分布、排名
条形图横向柱状图Bar Chart分类数据比较,标签较长对比、分布、排名
饼图饼状图Pie Chart显示部分占整体的比例占比、成分
面积图区域图Area Chart时间序列,强调趋势和总量趋势分析、对比
散点图-Scatter Chart显示两个变量的关系相关性分析、分布
双轴图组合图Dual-Axes Chart同时展示两个不同量级的数据多维对比、趋势分析
直方图-Histogram显示数据分布分布分析
箱线图盒须图Boxplot显示数据分布和异常值分布分析、异常检测
雷达图蜘蛛图Radar Chart多维度数据对比多维对比
漏斗图-Funnel Chart展示流程转化率流程分析、转化分析
瀑布图-Waterfall Chart显示累计效应增减变化分析
水波图进度球Liquid Chart显示百分比或进度进度展示、占比
词云图词云Word Cloud展示文本词频词频分析、热点展示
小提琴图-Violin Chart显示数据分布密度分布分析
韦恩图文氏图Venn Chart显示集合关系集合交并关系
矩阵树图树状图Treemap显示层级数据占比层级占比、结构分析
桑基图-Sankey Chart展示流量流向流向分析
表格数据表Table展示详细数据明细数据展示、查找
总结摘要-Summary文本总结内容内容总结

GPT-Vis Syntax

GPT-Vis 使用简洁的类 Markdown 语法来描述图表配置,使 AI 更容易生成。基本结构如下:

vis [chart-type]
data
  - [field1] [value1]
    [field2] [value2]
[optional-property] [value]

Syntax 特点

  • 简洁易读: 类 Markdown 的缩进语法,易于 AI 生成
  • 流式友好: 支持逐 token 渲染,适合流式输出
  • 容错性强: 能优雅处理不完整数据
  • 类型安全: 每个图表有明确的数据结构

Framework Integration

GPT-Vis 支持在 HTML、React 和 Vue 中使用,提供统一的 API 来渲染 Syntax。

HTML / Vanilla JavaScript

html
1<!DOCTYPE html> 2<html> 3 <head> 4 <script src="https://unpkg.com/@antv/gpt-vis/dist/umd/index.min.js"></script> 5 </head> 6 <body> 7 <div id="container"></div> 8 <script> 9 const gptVis = new GPTVis.GPTVis({ 10 container: '#container', 11 width: 600, 12 height: 400, 13 }); 14 15 const visSyntax = ` 16vis line 17data 18 - time 2020 19 value 100 20 - time 2021 21 value 120 22 - time 2022 23 value 150 24title 年度趋势 25`; 26 27 gptVis.render(visSyntax); 28 </script> 29 </body> 30</html>

React

jsx
1import { GPTVis } from '@antv/gpt-vis'; 2import { useEffect, useRef } from 'react'; 3 4function ChartComponent({ visSyntax }) { 5 const containerRef = useRef(null); 6 const gptVisRef = useRef(null); 7 8 useEffect(() => { 9 if (containerRef.current && !gptVisRef.current) { 10 gptVisRef.current = new GPTVis({ 11 container: containerRef.current, 12 width: 600, 13 height: 400, 14 }); 15 } 16 }, []); 17 18 useEffect(() => { 19 if (gptVisRef.current && visSyntax) { 20 gptVisRef.current.render(visSyntax); 21 } 22 }, [visSyntax]); 23 24 return <div ref={containerRef}></div>; 25} 26 27// 使用示例 28const visSyntax = ` 29vis column 30data 31 - category A产品 32 value 30 33 - category B产品 34 value 50 35title 产品销量 36`; 37 38<ChartComponent visSyntax={visSyntax} />;

Vue

vue
1<template> 2 <div ref="containerRef"></div> 3</template> 4 5<script setup> 6import { ref, onMounted, watch } from 'vue'; 7import { GPTVis } from '@antv/gpt-vis'; 8 9const props = defineProps({ 10 visSyntax: String, 11}); 12 13const containerRef = ref(null); 14let gptVis = null; 15 16onMounted(() => { 17 gptVis = new GPTVis({ 18 container: containerRef.value, 19 width: 600, 20 height: 400, 21 }); 22 23 if (props.visSyntax) { 24 gptVis.render(props.visSyntax); 25 } 26}); 27 28watch( 29 () => props.visSyntax, 30 (newSyntax) => { 31 if (gptVis && newSyntax) { 32 gptVis.render(newSyntax); 33 } 34 }, 35); 36</script> 37 38<!-- 使用示例 --> 39<ChartComponent :vis-syntax="visSyntax" />

流式渲染支持

GPT-Vis 天然支持流式渲染,可以逐步接收 AI 生成的 Syntax:

javascript
1import { GPTVis, isVisSyntax } from '@antv/gpt-vis'; 2 3const gptVis = new GPTVis({ 4 container: '#container', 5 width: 600, 6 height: 400, 7}); 8 9let buffer = ''; 10 11// 当 AI 流式输出 token 时 12function onToken(token) { 13 buffer += token; 14 if (isVisSyntax(buffer)) { 15 gptVis.render(buffer); 16 } 17}

Syntax Examples

Line Chart (折线图)

适用场景: 时间序列数据,展示趋势变化

Syntax 示例:

vis line
data
  - time 2020
    value 100
  - time 2021
    value 120
  - time 2022
    value 150
title 年度数据趋势

详细用法参考: references/line.md

Column Chart (柱形图)

适用场景: 分类数据比较

Syntax 示例:

vis column
data
  - category A产品
    value 30
  - category B产品
    value 50
  - category C产品
    value 20
title 产品销量对比

详细用法参考: references/column.md

Bar Chart (条形图)

适用场景: 分类数据比较,标签较长

Syntax 示例:

vis bar
data
  - category 产品类别A
    value 30
  - category 产品类别B
    value 50
  - category 产品类别C
    value 20

详细用法参考: references/bar.md

Pie Chart (饼图)

适用场景: 显示部分占整体的比例

Syntax 示例:

vis pie
data
  - category 类别A
    value 30
  - category 类别B
    value 50
  - category 类别C
    value 20

详细用法参考: references/pie.md

Area Chart (面积图)

适用场景: 时间序列,强调趋势和总量

Syntax 示例:

vis area
data
  - time 2020
    value 100
  - time 2021
    value 120
  - time 2022
    value 150

详细用法参考: references/area.md

Scatter Chart (散点图)

适用场景: 显示两个变量的关系

Syntax 示例:

vis scatter
data
  - x 1
    y 2
  - x 2
    y 4
  - x 3
    y 3

详细用法参考: references/scatter.md

Dual-Axes Chart (双轴图)

适用场景: 同时展示两个不同量级的数据

Syntax 示例:

vis dual-axes
data
  - category 1月
    value 100
    count 10
  - category 2月
    value 120
    count 15
  - category 3月
    value 150
    count 12

详细用法参考: references/dual-axes.md

Histogram (直方图)

适用场景: 显示数据分布

Syntax 示例:

vis histogram
data
  - value 10
  - value 12
  - value 15
  - value 18
  - value 20

详细用法参考: references/histogram.md

Boxplot (箱线图)

适用场景: 显示数据分布和异常值

Syntax 示例:

vis boxplot
data
  - category A
    value 10
  - category A
    value 15
  - category A
    value 20
  - category B
    value 12
  - category B
    value 18

详细用法参考: references/boxplot.md

Radar Chart (雷达图)

适用场景: 多维度数据对比

Syntax 示例:

vis radar
data
  - dimension 维度1
    value 80
  - dimension 维度2
    value 90
  - dimension 维度3
    value 70

详细用法参考: references/radar.md

Funnel Chart (漏斗图)

适用场景: 展示流程转化率

Syntax 示例:

vis funnel
data
  - stage 访问
    value 1000
  - stage 注册
    value 500
  - stage 购买
    value 100

详细用法参考: references/funnel.md

Waterfall Chart (瀑布图)

适用场景: 显示累计效应

Syntax 示例:

vis waterfall
data
  - category 初始
    value 100
  - category 增加
    value 50
  - category 减少
    value -30

详细用法参考: references/waterfall.md

Liquid Chart (水波图)

适用场景: 显示百分比或进度

Syntax 示例:

vis liquid
data
  - value 0.65

详细用法参考: references/liquid.md

Word Cloud (词云图)

适用场景: 展示文本词频

Syntax 示例:

vis word-cloud
data
  - word 数据
    value 100
  - word 可视化
    value 80
  - word 图表
    value 60

详细用法参考: references/word-cloud.md

Violin Chart (小提琴图)

适用场景: 显示数据分布密度

Syntax 示例:

vis violin
data
  - category A
    value 10
  - category A
    value 15
  - category A
    value 20

详细用法参考: references/violin.md

Venn Chart (韦恩图)

适用场景: 显示集合关系

Syntax 示例:

vis venn
data
  - sets A
    size 10
  - sets B
    size 8
  - sets A,B
    size 3

详细用法参考: references/venn.md

Treemap (矩阵树图)

适用场景: 显示层级数据占比

Syntax 示例:

vis treemap
data
  - category 分类A
    value 30
  - category 分类B
    value 50
  - category 分类C
    value 20

详细用法参考: references/treemap.md

Sankey Chart (桑基图)

适用场景: 展示流量流向

Syntax 示例:

vis sankey
data
  - source A
    target B
    value 10
  - source B
    target C
    value 5
  - source A
    target C
    value 5

详细用法参考: references/sankey.md

Table (表格)

适用场景: 展示详细数据明细

Syntax 示例:

vis table
data
  - 姓名 张三
    年龄 25
    城市 北京
  - 姓名 李四
    年龄 30
    城市 上海

详细用法参考: references/table.md

Summary (总结摘要)

适用场景: 数据报告生成、洞察结论呈现、叙事性数据展示

Syntax 示例:

# Q4 销售分析报告

## 核心指标
[2024 年 Q4](time_desc),公司[销售额](metric_name)达到[¥523 万](metric_value, origin=5230000),
较上季度[增长 15.2%](ratio_value, origin=0.152, assessment="positive")。

## 关键发现
- [新客户数](metric_name):[1,234](metric_value, origin=1234),环比增长[8.3%](ratio_value, origin=0.083)
- [客户留存率](metric_name):[89.5%](ratio_value, origin=0.895)
- [平均订单金额](metric_name):[¥4,567](metric_value, origin=4567)

其中,[线上渠道](dim_value)贡献了[68%](contribute_ratio, origin=0.68)的销售额。

详细用法参考: references/summary.md

Best Practices

  1. 选择合适的图表类型

    • 时间序列优先使用折线图或面积图
    • 分类比较优先使用柱形图或条形图
    • 占比分析使用饼图(分类不超过 5 个)
    • 多维对比使用雷达图
  2. 数据要求

    • 确保数据字段与图表类型匹配
    • 数值字段必须是数字类型
    • 分类字段必须是文本类型
  3. 避免误用

    • 不要用饼图展示趋势
    • 不要用折线图展示无序分类
    • 不要在数据量过大时使用饼图

References

详细的图表知识、使用方法、数据要求和更多示例,请参考 references/ 目录中的各图表文档。每个文档包含:

  • 图表属性和基础概念
  • 适用和不适用场景
  • 详细的数据要求和类型定义
  • 多个实际使用示例

Related Skills

Looking for an alternative to chart-visualization or building a Categories.community AI Agent? Explore these related open-source MCP Servers.

View All

widget-generator

Logo of f
f

widget-generator is an open-source AI agent skill for creating widget plugins that are injected into prompt feeds on prompts.chat. It supports two rendering modes: standard prompt widgets using default PromptCard styling and custom render widgets built as full React components.

149.6k
0
Design

chat-sdk

Logo of lobehub
lobehub

chat-sdk is a unified TypeScript SDK for building chat bots across multiple platforms, providing a single interface for deploying bot logic.

73.0k
0
Communication

zustand

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication

data-fetching

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication