tufte-claude-skill  by aref-vc

Claude Code skill for Tufte-compliant data visualization

Created 1 month ago
274 stars

Top 94.0% on SourcePulse

GitHubView on GitHub
Project Summary

Summary

This Claude Code skill automatically transforms natural language requests for charts into visualizations adhering to Edward Tufte's principles of effective data display. It targets users seeking to enhance chart clarity and data-ink ratio, offering a distilled application of Tufte's foundational concepts to combat common AI-generated chart flaws.

How It Works

The skill intercepts chart-related prompts within Claude Code, applying a structured methodology. It references Tufte's ten core principles, selects appropriate chart types based on data characteristics via a decision table, and systematically removes non-data-ink elements (e.g., excessive frames, redundant labels, 3D effects) using a defined "kill list." Output is generated as self-contained HTML/SVG or within a React environment using Recharts and D3, with a final validation checklist.

Quick Start & Requirements

  • Install: Clone the repository into your Claude Code skills directory: git clone https://github.com/aref-vc/tufte-claude-skill.git ~/.claude/skills/tufte. Claude Code auto-loads the skill on next launch.
  • Prerequisites: Claude Code installed. No additional dependencies are required for the skill's core functionality.
  • Links:
    • Repository: https://github.com/aref-vc/tufte-claude-skill
    • Interactive Gallery: before-after.html
    • Cheatsheet: cheatsheet.html / cheatsheet.pdf
  • Note: weasyprint (pip install weasyprint) is needed to regenerate the cheatsheet PDF from its HTML source.

Highlighted Details

  • Tufte Principles: Implements ten principles derived from Tufte's seminal works, focusing on maximizing data-ink ratio, graphical integrity, and clarity.
  • Automated Transformation: Demonstrates significant visual improvements through before-and-after examples, converting common AI chart defaults (e.g., 3D bars, framed line charts, rainbow heatmaps) into Tufte-optimized formats like sorted dot plots, sparklines, and sequential single-hue tables.
  • Flexible Output: Supports generation of self-contained HTML/SVG files or integration into React applications using Recharts and D3.
  • Configurable Strictness: Operates with Tufte principles as the default but allows user overrides for specific chart types (e.g., pie charts) while noting the Tufte alternative.

Maintenance & Community

Contributions are welcomed via pull requests, with suggestions for expanding chart type support and output presets for other visualization libraries. Specific community channels (e.g., Discord, Slack) or maintainer details are not provided.

Licensing & Compatibility

The project is released under the MIT License, permitting free use, modification, and distribution. Tufte's book quotations are included under fair use for educational purposes. The license appears compatible with commercial applications.

Limitations & Caveats

The skill is designed specifically for quantitative data visualizations and does not apply to non-data graphics like flowcharts or illustrations. While user overrides are supported, the skill's primary function is strict adherence to Tufte's guidelines, potentially requiring explicit requests to deviate. The PDF generation for the cheatsheet requires an external Python library.

Health Check
Last Commit

3 weeks ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
27 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.