Xpersona
G

Guitar Chord

CLAWHUB · Unverified

Show ASCII guitar chord diagrams using the ascii_chord CLI tool. Use when asked how to play a guitar chord, or to show chord charts/diagrams for any chord na... Skill: Guitar Chord Owner: yzhong52 Summary: Show ASCII guitar chord diagrams using the ascii_chord CLI tool. Use when asked how to play a guitar chord, or to show chord charts/diagrams for any chord na... Tags: latest:2.0.4 Version history: v2.0.4 | 2026-04-08T18:03:59.146Z | user Rename skill display name from ascii-chord to guitar-chord v2.0.3 | 2026-03-22T18:00:56.003Z | user Add scripts/init.sh: sets up .gitigno

62
Rank
84
Safety
1.2k
Downloads

About

What it does, and when to use it.

Capability contract not published. No trust telemetry is available yet. 1.2K downloads reported by the source. Last updated 10/10/2026.

Avoid when

  • Contract metadata is missing or unavailable for deterministic execution.

Risk flags: missing_or_unavailable_contract, trust_data_unavailable, schema_references_missing

Install and run

Setup complexity: low.

clawhub skill install s17fyz8dd5jej8dw01yfc0q4rn83qpgh:ascii-chord
  1. Setup complexity is classified as HIGH. You must provision dedicated cloud infrastructure or an isolated VM. Do not run this directly on your local workstation.
  2. Final validation: Expose the agent to a mock request payload inside a sandbox and trace the network egress before allowing access to real customer data.

Contract: missing

curl -s "https://www.xpersona.co/api/v1/agents/clawhub-yzhong52-ascii-chord/snapshot"

Run-check

$0.02 USD

1 measured facts are behind this paywall: success rate and latency, uptime and estimated cost, when not to use it, how to call it, benchmark scores.

Agents pay $0.02 in USDC. A card payment is $0.50, the smallest a card allows.

Documentation

CLAWHUB

144,403 characters of source documentation, loaded on request.

Extracted files

5 files captured from the source.

SKILL.md

---
name: guitar-chord
description: Show ASCII guitar chord diagrams using the ascii_chord CLI tool. Use when asked how to play a guitar chord, or to show chord charts/diagrams for any chord name (e.g. E, B7, Am, C, G, Dm, etc.). Requires cargo (Rust toolchain) to be installed. The source code is bundled with this skill — build it with cargo from the skill directory.
metadata:
  openclaw:
    requires:
      bins:
        - cargo
    install:
      - type: shell
        label: "Post-install init (gitignore + pre-warm build)"
        script: "scripts/init.sh"
        note: "Creates .gitignore for /target and pre-builds the binary. Run once after install."
    sideEffects:
      note: >
        cargo build creates a target/ directory under the skill's source folder. These are normal
        Rust toolchain side effects and persist beyond a single invocation. If the Rust toolchain
        is not installed, installing rustup will modify the user's home directory (~/.cargo, ~/.rustup)
        and may update PATH.
---

# guitar-chord

Display ASCII guitar chord diagrams using [ascii_chord](https://github.com/ascii-music/ascii_chord) — an open-source Rust CLI (MIT license, authored by the same person as this skill).

The source code is **bundled with this skill** — no cloning needed.

## Required Tools

| Tool | Purpose | Check |
|---|---|---|
| **cargo / Rust** | Build and run the CLI | `cargo --version` |

### Installing Rust (if not already installed)

```bash
# macOS (Homebrew — recommended)
brew install rustup-init && rustup-init
```

Or download from [rustup.rs](https://rustup.rs).

> **Note:** Installing Rust via rustup creates `~/.cargo` and `~/.rustup` in your home directory and may modify your shell `PATH`.

## Post-Install Setup

After installing, run the init script once:

```bash
bash ~/.openclaw/workspace/skills/ascii-chord/scripts/init.sh
```

This will:
1. Create a `.gitignore` in the skill directory to exclude cargo build artifacts (`/target`) from git
2. Pre-warm the cargo build cache so the first chord lookup is fast

## First Run Warning

If you skip the init script, the **first `cargo run` will take 30–60 seconds** while cargo compiles the binary. This is normal — subsequent runs are fast (binary is cached in `target/`). Do not interrupt the first build.

## Diagram Legend

```
✕  = mute this string (don't play)
◯  = open string (play unfretted)
●  = fret this position (filled dot)
═  = nut (top of fretboard)
─  = fret wire
│  = string
```

Numbers on the left (when shown) indicate the starting fret position for higher-up chords.

## Usage

The skill directory contains the full Rust source. Run from there:

**Single chord:**
```bash
cd <skill_dir> && cargo run -- get <CHORD> 2>/dev/null
```

**Multiple chords side by side:**
```bash
cd <skill_dir> && cargo run -- list <CHORD1> <CHORD2> ... 2>/dev/null
```

**List all supported chords:**
```bash
cd <skill_dir> && cargo run -- all 2>/dev/null
```

> Replace `<skill_dir>` with the path 

readme.md

[![CI](https://github.com/yzhong52/ascii_chord/actions/workflows/rust.yml/badge.svg)](
  https://github.com/yzhong52/ascii_chord/actions?query=workflow%3Arust
)


# Ascii Chord

A command line tool for showing how to play guitar chords

## Usage

For a single chord:

```
$ aschord get G

This is how you play 'G' chord: 
    ◯ ◯ ◯  
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ ◯ │ │ │ │
├─┼─┼─┼─┼─┤
◯ │ │ │ │ ◯
└─┴─┴─┴─┴─┘
```

For multiple chords:

```
$ aschord list Em Esus4 Asus2 F
Em             Esus|Esus4     Asus2          F          
◯     ◯ ◯ ◯    ◯       ◯ ◯    ✕ ◯     ◯ ◯               
╒═╤═╤═╤═╤═╕    ╒═╤═╤═╤═╤═╕    ╒═╤═╤═╤═╤═╕    ╒═╤═╤═╤═╤═╕
│ │ │ │ │ │    │ │ │ │ │ │    │ │ │ │ │ │    ◯―――――――◯―◯
├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤
│ ◯ ◯ │ │ │    │ ◯ ◯ ◯ │ │    │ │ ◯ ◯ │ │    │ │ │ ◯ │ │
├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤
│ │ │ │ │ │    │ │ │ │ │ │    │ │ │ │ │ │    │ ◯ ◯ │ │ │
└─┴─┴─┴─┴─┘    └─┴─┴─┴─┴─┘    └─┴─┴─┴─┴─┘    └─┴─┴─┴─┴─┘
```

For different ways to play the same chord:

```
$ aschord list Bm --style full-names
B minor          B minor (no bar)
✕                ✕ ✕             
╒═╤═╤═╤═╤═╕      ╒═╤═╤═╤═╤═╕     
│ │ │ │ │ │      │ │ │ │ │ │     
├─┼─┼─┼─┼─┤      ├─┼─┼─┼─┼─┤     
――◯―――――――◯      │ │ │ │ │ ◯     
├─┼─┼─┼─┼─┤      ├─┼─┼─┼─┼─┤     
│ │ │ │ ◯ │      │ │ │ │ ◯ │     
├─┼─┼─┼─┼─┤      ├─┼─┼─┼─┼─┤     
│ │ ◯ ◯ │ │      │ │ ◯ ◯ │ │     
└─┴─┴─┴─┴─┘      └─┴─┴─┴─┴─┘     
```

For multiple chords with full names:

```
$ aschord list Em Esus4 Asus2 F --style full-names
E minor                        E suspended|E suspended 4ᵗʰ    A suspended 2ⁿᵈ                F          
◯     ◯ ◯ ◯                    ◯       ◯ ◯                    ✕ ◯     ◯ ◯                               
╒═╤═╤═╤═╤═╕                    ╒═╤═╤═╤═╤═╕                    ╒═╤═╤═╤═╤═╕                    ╒═╤═╤═╤═╤═╕
│ │ │ │ │ │                    │ │ │ │ │ │                    │ │ │ │ │ │                    ◯―――――――◯―◯
├─┼─┼─┼─┼─┤                    ├─┼─┼─┼─┼─┤                    ├─┼─┼─┼─┼─┤                    ├─┼─┼─┼─┼─┤
│ ◯ ◯ │ │ │                    │ ◯ ◯ ◯ │ │                    │ │ ◯ ◯ │ │                    │ │ │ ◯ │ │
├─┼─┼─┼─┼─┤                    ├─┼─┼─┼─┼─┤                    ├─┼─┼─┼─┼─┤                    ├─┼─┼─┼─┼─┤
│ │ │ │ │ │                    │ │ │ │ │ │                    │ │ │ │ │ │                    │ ◯ ◯ │ │ │
└─┴─┴─┴─┴─┘                    └─┴─┴─┴─┴─┘                    └─┴─┴─┴─┴─┘                    └─┴─┴─┴─┴─┘
```

Here is an example of using a [bar chord](https://en.wikipedia.org/wiki/Bar_chord) on the first (1st) fret for F and a [capo](https://en.wikipedia.org/wiki/Capo_(musical_device)) placed on the fourth (4th) fret for G#:

```
$ aschord list F G#
F              G#         
               ◯       ◯ ◯
╒═╤═╤═╤═╤═╕    ╒𝟺╤𝟺╤𝟺╤𝟺╤𝟺╕
◯―――――――◯―◯    │ │ │ ◯ │ │
├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤
│ │ │ ◯ │ │    │ ◯ ◯ │ │ │
├─┼─┼─┼─┼─┤    ├─┼─┼─┼─┼─┤
│ ◯ ◯ │ │ │    │ │ │ │ │ │
└─┴─┴─┴─┴─┘    └─┴─┴─┴─┴─┘
``

_meta.json

{
  "ownerId": "kn70ba16qvrfe1brpqvkfk4j6d82fjxr",
  "slug": "ascii-chord",
  "version": "2.0.4",
  "publishedAt": 1775671439146
}

all_supported_chords.md

# All Supported Chords
## A (A)
```
✕ ◯       ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ ◯ │
└─┴─┴─┴─┴─┘
```
## A♯ (A#)
```
✕          
╒═╤═╤═╤═╤═╕
――◯―――――――◯
├─┼─┼─┼─┼─┤
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ ◯ │
└─┴─┴─┴─┴─┘
```
## A augmented (A+)
```
✕ ◯        
╒═╤═╤═╤═╤═╕
│ │ │ │ │ ◯
├─┼─┼─┼─┼─┤
│ │ │ ◯ ◯ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ │ │
└─┴─┴─┴─┴─┘
```
## A raised 7ᵗʰ (Amaj7)
```
✕ ◯       ◯
╒═╤═╤═╤═╤═╕
│ │ │ ◯ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ ◯ │
└─┴─┴─┴─┴─┘
```
## A♯ raised 7ᵗʰ (A#maj7)
```
✕          
╒═╤═╤═╤═╤═╕
――◯―――――――◯
├─┼─┼─┼─┼─┤
│ │ │ ◯ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ ◯ │
└─┴─┴─┴─┴─┘
```
## A 6ᵗʰ (A6)
```
✕ ◯        
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ ◯ ◯
└─┴─┴─┴─┴─┘
```
## A 7ᵗʰ (shape 1) (A7)
```
✕ ◯   ◯   ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ ◯ │
└─┴─┴─┴─┴─┘
```
## A 7ᵗʰ (shape 2) (A7)
```
✕ ◯        
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ ◯ │
├─┼─┼─┼─┼─┤
│ │ │ │ │ ◯
└─┴─┴─┴─┴─┘
```
## A♯ 7ᵗʰ (A#7)
```
✕          
╒═╤═╤═╤═╤═╕
――◯―――◯―――◯
├─┼─┼─┼─┼─┤
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ ◯ │
└─┴─┴─┴─┴─┘
```
## A 9ᵗʰ (A9)
```
✕ ◯        
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ ◯ │
├─┼─┼─┼─┼─┤
│ │ │ │ │ ◯
├─┼─┼─┼─┼─┤
│ │ │ ◯ │ │
└─┴─┴─┴─┴─┘
```
## A minor (Am)
```
✕ ◯       ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ ◯ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
└─┴─┴─┴─┴─┘
```
## A♯ minor (A#m)
```
✕          
╒═╤═╤═╤═╤═╕
――◯―――――――◯
├─┼─┼─┼─┼─┤
│ │ │ │ ◯ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
└─┴─┴─┴─┴─┘
```
## A minor 7ᵗʰ (Am7)
```
✕ ◯   ◯   ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ ◯ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ │ │
└─┴─┴─┴─┴─┘
```
## A♯ minor 7ᵗʰ (A#m7)
```
✕          
╒═╤═╤═╤═╤═╕
――◯―――◯―――◯
├─┼─┼─┼─┼─┤
│ │ │ │ ◯ │
├─┼─┼─┼─┼─┤
│ │ ◯ │ │ │
└─┴─┴─┴─┴─┘
```
## A suspended (Asus)
```
✕ ✕       ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
├─┼─┼─┼─┼─┤
│ │ │ │ ◯ │
└─┴─┴─┴─┴─┘
```
## A suspended 2ⁿᵈ (Asus2)
```
✕ ◯     ◯ ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
└─┴─┴─┴─┴─┘
```
## A♯ suspended 2ⁿᵈ (A#sus2)
```
✕          
╒═╤═╤═╤═╤═╕
――◯―――――◯―◯
├─┼─┼─┼─┼─┤
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
└─┴─┴─┴─┴─┘
```
## A suspended 4ᵗʰ (Asus4)
```
✕ ◯       ✕
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
├─┼─┼─┼─┼─┤
│ │ │ │ ◯ │
└─┴─┴─┴─┴─┘
```
## A♯ suspended 4ᵗʰ (A#sus4)
```
✕          
╒═╤═╤═╤═╤═╕
――◯―――――――◯
├─┼─┼─┼─┼─┤
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
├─┼─┼─┼─┼─┤
│ │ │ │ ◯ │
└─┴─┴─┴─┴─┘
```
## A over C♯ (A/C#)
```
✕         ✕
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ ◯ │
├─┼─┼─┼─┼─┤
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ ◯ │ │ │ │
└─┴─┴─┴─┴─┘
```
## A over E (A/E)
```
◯ ◯       ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ ◯ │
└─┴─┴─┴─┴─┘
```
## A minor over C (Am/C)
```
✕         ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ ◯ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
├─┼─┼─┼─┼─┤
│ ◯ │ │ │ │
└─┴─┴─┴─┴─┘
```
## A minor over G (Am/G)
```
  ◯       ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ ◯ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯ │ │
├─┼─┼─┼─┼─┤
◯ │ │ │ │ │
└─┴─┴─┴─┴─┘
```
## A minor over F♯ (Am/F#)
```
  ✕       ◯
╒═╤═╤═╤═╤═╕
│ │ │ │ ◯ │
├─┼─┼─┼─┼─┤
◯ │ ◯ ◯ │ │
└─┴─┴─┴─┴─┘
```
## B (B)
```
✕ ✕        
╒═╤═╤═╤═╤═╕
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ │ │ │ ◯
├─┼─┼─┼─┼─┤
│ │ │ │ │ │
├─┼─┼─┼─┼─┤
│ │ ◯ ◯

CLAUDE.md

# ascii_chord — Claude Notes

## What this project is

A Rust CLI (`aschord`) that renders ASCII guitar chord diagrams in the terminal.

## Commands

```
aschord get G                          # single chord
aschord list C G7 Am E                 # row of chords
aschord list Bm --style full-names     # alternate name styles: short-names, full-names, both-names
aschord list -p 1 C E                  # padding between chords (default 4)
aschord all                            # print all chords
aschord all --save                     # write all_supported_chords.md (regenerate after chord changes)
```

Dev equivalents: `cargo run -- list C G Am E`, etc.

## Architecture

```
main.rs       — entry point, clap parsing
commands.rs   — GetArgs / ListArgs / AllArgs subcommands
chords.rs     — ALL_CHORDS static array + ALL_CHORDS_BY_SHORT_NAMES HashMap
chord.rs      — Chord struct, make_fretboard(), rendering logic
stitcher.rs   — row() — lays out multiple chords side by side into a 2D buffer
```

## How the fretboard renders (chord.rs)

`make_fretboard(num_frets)` generates the ASCII template dynamically. Each line (including `\n`) is exactly **12 chars wide**, giving a stride of **24 chars per fret** in the flat char array:

- Fret 1 → char offset 24 (`24 * 1`)
- Fret 2 → char offset 48 (`24 * 2`)
- Fret N → char offset `24 * N`

String positions within a fret row: string `i` → column `i * 2`.

`Chord.pattern` is a 6-char string: `x` = muted, `0` = open, `1`–`5` = fret number.

`Chord.fretboard()` auto-sizes to `self.max_fret()`. `fretboard_n(n)` renders at an explicit height (used by `stitcher::row()` so all chords in a row share the same height).

## Adding a new chord

Add a line to `ALL_CHORDS` in `chords.rs`:

```rust
Chord::new(&["ShortName"], "pattern", &["Full Name"], capo_option, barre_option),
```

Then regenerate `all_supported_chords.md`:

```
cargo run -- all --save
```

## After any rendering change

Update the examples in `readme.md` by running each command shown there and pasting the output.

Sponsored

Ads related to Guitar Chord and adjacent AI workflows.