data_visualization

A guide to displaying data as charts, tables, and live visual widgets with PyWry and Plotly. Plotly is a Python library for creating interactive charts.

In plain words
What is it for?
Use it to create line or bar charts, show them as widgets, update their data or layout, and configure different styles for light and dark themes.
Why use it?
It gives a consistent way to create and update charts without rebuilding an entire widget for every visual change. It also explains how charts can follow light and dark interface themes.

Skill for Claude CodeCodex

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 skills/deeleeramone/pywry/data_visualization
Any agent
npx skills add deeleeramone/PyWry --skill data_visualization
Clone the repo
git clone --depth 1 https://github.com/deeleeramone/PyWry

Made for: Claude Code, Codex.

Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,034 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.00000 $0.02034
Opus 5 $0.00000 $0.01017
Sonnet 5 $0.00000 $0.00407
Haiku 4.5 $0.00000 $0.00203

Measured 2d ago against content hash d1759181c824, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

data_visualization 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 2d ago.

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.

pywry/pywry/mcp/skills/data_visualization/SKILL.md · 283 lines

How it starts

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

Data Visualization

Best practices for creating charts, tables, and live data displays.

Plotly Charts

Creating a Chart

import plotly.express as px

# Create figure
df = pd.DataFrame({"x": [1, 2, 3], "y": [4, 5, 6]})
fig = px.line(df, x="x", y="y", title="My Chart")

# Show as widget
show_plotly(figure_json=fig.to_json(), title="Line Chart")

Updating a Chart

# Full update
new_fig = px.bar(df, x="category", y="value")
update_plotly(widget_id, figure_json=new_fig.to_json())

# Layout-only update (faster - doesn't re-render data)
layout_update = {"title": {"text": "Updated Title"}}
update_plotly(widget_id, figure_json=json.dumps({"layout": layout_update}), layout_only=True)

Theme Consistency

PyWry automatically switches Plotly charts between plotly_dark and plotly_white templates when the theme toggles. To customize per-theme styles while preserving automatic switching, use template_dark and template_light on PlotlyConfig:

from pywry import PlotlyConfig

config = PlotlyConfig(
    template_dark={"layout": {"paper_bgcolor": "#1a1a2e", "plot_bgcolor": "#16213e"}},
    template_light={"layout": {"paper_bgcolor": "#ffffff", "plot_bgcolor": "#f0f0f0"}},
)

show_plotly(figure_json=fig.to_json(), title="Themed Chart", config=config)

User values are deep-merged on top of the built-in base template — your overrides always win, and anything you don't set is inherited from the base.

Chart Sizing

# Let chart fill container
fig.update_layout(
    autosize=True,
    margin=dict(l=40, r=40, t=50, b=40),
)

# Or set explicit size
fig.update_layout(
    width=600,
    height=400,
)

AG Grid Tables

Creating a Table

import json

# Data as list of dicts
data = [
    {"name": "Alice", "age": 30, "city": "NYC"},
    {"name": "Bob", "age": 25, "city": "LA"},
]

# Show as AG Grid widget
show_dataframe(data_json=json.dumps(data), title="Users")

Theme Consistency

# AG Grid themes
# - ag-theme-quartz-dark (dark mode)
# - ag-theme-quartz (light mode)
# Widget auto-applies based on current theme

Read the full file on GitHub · 283 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. 2d ago First seen · 283 lines · 0 tokens per session scan A d1759181c824

Subscribe to this mod's changes

data_visualization is a skill published in the GitHub repository deeleeramone/PyWry (93 stars, last pushed 8d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 2,034 tokens. 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.

Related

Other skills, from other repositories

dashboard-design

Use this skill first when the user wants to design or plan a dashboard, especially Vizro dashboards. Enforces a 3-step workflow (requirements, layout, visualization) before implementation. Activate when the user asks to create, design, or plan a dashboard. For implementation, use the dashboard-build skill after…

mckinsey/vizro · 71 tokens

industry-chain

产业链下钻与不可替代性判定方法:以龙头为"需求入口"沿供应链逐层下钻(整机 / 龙头 → 部件 → 核心器件 → 材料 → 衬底与设备),用物理 / 材料约束(扩产周期、良率、认证周期、有无替代)当筛子找供给刚性的卡口;给每个标的贴不可替代性标签(techmoat / capacitymoat / both / 待补)并列证据;含"卡口越硬越贵"与预期差四问的校准。当任务涉及产业链位置、上下游、护城河、不可替代性、供给瓶颈、竞争格局时加载;单纯取数、估值计算、财报拆分等不涉及产业链结构的任务不要加载。只产出框架与证据表,不给投资动作建议。.

simonlin1212/Vibe-Research · 212 tokens

live-dashboard

Notion 风团队仪表板, KPI + 7 日 sparkline + activity feed + 任务表.

nexu-io/html-anything · 25 tokens

selecting-vizro-charts

Use this skill when choosing chart types, applying Plotly Express conventions, configuring colors, building KPI cards, or adding tables (AG Grid) to Vizro dashboards. Activate when the user asks which chart fits their data, needs custom chart functions, wants to set colors or palettes, is creating KPI metric cards, or…

mckinsey/vizro · 78 tokens

verify-changes

Verify a code change in this repo before committing or opening a PR. Use after editing collector (backend), web (frontend), shared package, or the Go agent — picks the minimal sufficient check set per touched area.

foru17/neko-master · 47 tokens

openai-docs

Use when the user asks how to build with OpenAI products or APIs and needs up-to-date official documentation with citations (for example: Codex, Responses API, Chat Completions, Apps SDK, Agents SDK, Realtime, model capabilities or limits); prioritize OpenAI docs MCP tools and restrict any fallback browsing to…

Soju06/codex-lb · 74 tokens