Moses14159/dsh-visualizer ↗★ 6
dsh-visualizer
在对话流中流式渲染图表与HTML组件 适合需要AI实时生成并直观展示SVG、HTML沙箱或ECharts图表的用户。
同名套件的其他儲存庫
安裝
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Moses14159/dsh-visualizer說明文件
閱讀完整 README ↗Usage
After installing, just tell the model in the conversation:
- Say "draw a chart with visualize" → the model calls
visualizewith aspec; - Say "write an SVG badge / HTML widget" → the model streams ```svg / ```html fences directly in the reply, and you see it render frame by frame as it generates;
- The model can also pass a
widgetparameter tovisualizeto deliver a complete widget (validated, persisted, and replayable on the host).
Tool payloads
visualize takes exactly one of:
// Structured chart
{ "spec": {
"kind": "bar", // bar | line | area | pie | scatter
"title": "Shenzhen · 7-day temperature",
"xAxis": ["Sat", "Sun", "Mon", "Tue", "Wed", "Thu", "Fri"],
"yName": "°C",
"series": [{ "name": "Max", "data": [32, 32, 30, 31, 29, 31, 32] }]
} }
// SVG / HTML widget
{ "widget": { "kind": "svg", "code": "…", "title": "Card title" } }
Streaming fence
```svg
…rendered token by token…
```