@zhangguiping-xydt

Chart

Chart generation plugin for OpenClaw — bar, line, pie, scatter, and area charts as SVG images

当前版本
v1.0.1
bundle-plugin社区source-linked

Chart Plugin for OpenClaw

Generate SVG charts from structured data — bar, line, pie, scatter, and area charts.

Install

openclaw plugins install clawhub:chart

Usage

Agent can call the chart tool with structured JSON:

{
  "type": "bar",
  "title": "Monthly Revenue",
  "labels": ["Jan", "Feb", "Mar", "Apr"],
  "series": [
    { "label": "Online", "values": [120, 150, 180, 210] },
    { "label": "Retail", "values": [80, 95, 110, 130] }
  ],
  "xLabel": "Month",
  "yLabel": "Revenue (K$)",
  "showLegend": true
}

Chart Types

TypeDescription
barGrouped bar chart with multi-series support
lineMulti-series line chart with data point markers
piePie chart with percentage labels
scatterScatter plot with multi-series support
areaArea chart with filled regions

Options

ParameterTypeRequiredDefaultDescription
typestringyes-Chart type: bar, line, pie, scatter, area
labelsstring[]yes-X-axis labels or pie segment names
seriesobject[]yes-Data series array
series[].labelstringyes-Series name shown in legend
series[].valuesnumber[]yes-Data values, one per label
series[].colorstringnoautoHex color (e.g. #4E79A7)
titlestringno-Chart title
widthintegerno800Image width (200-4000)
heightintegerno500Image height (200-4000)
xLabelstringno-X-axis label
yLabelstringno-Y-axis label
showLegendbooleannotrueShow legend (auto-hidden for single series)

Local Development

cd /path/to/openclaw
ln -sf /path/to/openclaw-chart-plugin extensions/chart
pnpm gateway:dev

Publish to ClawHub

npm install -g clawhub
clawhub login
clawhub package publish . --dry-run  # preview
clawhub package publish .            # publish

源码与版本

源码仓库

zhangguiping-xydt/openclaw-chart-plugin

打开仓库

源码提交

a4dbbcaa7940c14c7b7910715f3e171a6515e5ad

查看提交

安装命令

openclaw plugins install clawhub:chart-plugin

元数据

  • 包名: chart-plugin
  • 创建时间: 2026/05/28
  • 更新时间: 2026/05/28
  • 执行代码:
  • 源码标签: master

兼容性

  • 构建于 OpenClaw: 2026.5.27
  • 插件 API 范围: >=2026.5.26
  • 标签: latest
  • 文件数: 7