A Rust implementation of the ChordPro and
iReal Pro chord chart formats. It reads
ChordPro files (parse to a structured AST, render to plain text, HTML, and
PDF), parses irealb:// URLs, renders iReal Pro charts to SVG / PNG / PDF,
and converts between ChordPro and iReal Pro.
ChordSketch is not a drop-in replacement for the Perl ChordPro
implementation. It parses every directive that ChordPro R6.101.0 does
except six obsolete ones, but its output is not identical to Perl's and it
offers fewer output formats. See
Known Deviations for the list.
Highlights
- Two chart formats, one engine. ChordPro and iReal Pro in, with conversion in both directions between them.
- Five output formats. Plain text, HTML and PDF for ChordPro; SVG, PNG and PDF for iReal Pro charts.
- ChordPro R6.101.0 coverage. Every directive is parsed except six obsolete ones.
- Runs where you work. A CLI, a desktop app, a browser Playground (WebAssembly), React / Vue / Svelte components, and bindings for Node.js, Python, Ruby, Swift and Kotlin.
- In your editor. VS Code, the JetBrains IDEs and Zed, plus an LSP server and an MCP server for AI assistants.
- Nothing leaves your device. No telemetry, no analytics, no account; see Privacy.
Quick start
Install the CLI (more install options below):
brew install --formula koedame/tap/chordsketch # macOS / Linux
cargo install chordsketch --locked # any platform with Rust 1.89+
Save a chart as song.cho:
{title: Amazing Grace}
[G]Amazing [G7]grace, how [C]sweet the [G]sound
Render it:
chordsketch song.cho # plain text, to the terminal
chordsketch -f pdf song.cho -o song.pdf
The plain-text output puts each chord over the lyric it belongs to:
Amazing Grace
G G7 C G
Amazing grace, how sweet the sound
Stability
ChordSketch is pre-1.0 and still in a validation phase. Until 1.0.0
ships, any release may break compatibility — public API items, rendered
output, CLI flags, binding surfaces, and the minimum supported Rust
version can all change in a 0.x bump, without a deprecation cycle.
Breaking changes are named in the CHANGELOG, and larger
ones get a guide under docs/migration/. Pin an exact
version if you depend on this crate today.
Try it Online
The Playground runs the engine
in your browser. The format toggle in the header switches between the
ChordPro text editor and the iReal Pro bar-grid GUI editor at runtime.
The same engine embedded through each UI package, one editable page per
binding: Vue and
Svelte. The ChordPro
playground is the @chordsketch/react surface.
Documentation
ChordSketch Docs —
embedding recipes for @chordsketch/react, per-component API
reference, and cross-binding render / transpose guides. The
canonical Markdown sources live under
docs/sdk/ and the docs site renders them
in-place.
Editor Integration
ChordSketch provides syntax highlighting and Language Server Protocol (LSP)
support for multiple editors: