music21-score

Extract harmonies, melodic contours, and voice-leading violations from music21 scores.

33|6|Updated Mar 17, 2026
One-click install
npx skills add https://github.com/xjtulyc/awesome-rosetta-skills --skill music21-score
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: music21-score
Source: https://github.com/xjtulyc/awesome-rosetta-skills/tree/main/skills/16-art-music/music21-score
Command: npx skills add https://github.com/xjtulyc/awesome-rosetta-skills --skill music21-score

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill solves the problem of turning symbolic music files into actionable computational analysis results without manual, error-prone music-theory work.

Core Features & Use Cases

  • Score parsing & symbolic I/O: Load scores and interpret parts, measures, notes, and chords from common symbolic formats for downstream analysis.
  • Harmonic analysis (Roman numerals): Convert chord events into Roman-numeral labels relative to detected or provided keys for progression studies.
  • Melodic features & counterpoint checks: Compute melodic contour/interval statistics and detect parallel fifths or octaves between two voices for music-theory QA.
  • Corpus-based comparison: Use music21’s built-in corpora (e.g., Bach chorales) to search and compare patterns across works.

Quick Start

Use the music21-score skill to analyze the attached Bach chorale and output detected key, Roman-numeral harmonic progressions, and melodic contour features from its main voice.

Frequently Asked Questions about music21-score

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I extract Roman numerals from a MusicXML score?

To extract Roman numerals from a MusicXML score, load the symbolic file to parse Score, Part, and Measure objects, then convert chord events into Roman-numeral labels relative to detected keys for harmonic progression analysis.

Can music21 check for parallel fifths and octaves between voices?

Yes, music21 can check for parallel fifths and octaves by processing Note and Chord objects within Score streams, detecting voice-leading violations between two specified melodic lines for music-theory quality assurance.

What is the best way to analyze melodic contour and intervals in symbolic music?

The best way to analyze melodic contour is by parsing symbolic music scores with music21 to compute melodic interval statistics and extract progression labels for downstream statistical or visualization tasks.

How do I compare harmonic patterns across Bach chorales?

You can compare harmonic patterns across Bach chorales by using music21’s built-in corpora to load Score objects, extracting harmonies and Roman numerals, and performing corpus-based comparative studies.

Do I need MusicXML files to perform computational musicology with music21?

You need symbolic music files like MusicXML to construct music21 objects such as Score, Part, and Measure, which are required for deterministic parsing, feature extraction, and progression labeling in computational musicology workflows.