PyTheory is a Python toolkit for exploring music theory, composing arrangements, synthesizing sound, and exporting musical ideas programmatically. It models concepts such as notes, intervals, scales, chords, keys, progressions, fretboards, modes, and multiple musical systems. A score API can combine melodic parts, bass lines, chords, drums, synthesis, effects, automation, and sequencing. Compositions can be played immediately or exported as MIDI for continued production in a digital audio workstation. The command-line interface includes chord analysis, progression generation, tuning, playback, live MIDI tools, and an interactive REPL. A browser playground provides access without installation, while optional integrations support Ableton Link and external MIDI input. The project also offers Claude Code skills for AI-assisted composition and analysis.

Features

  • Scales, chords, keys, and interval analysis
  • Multi-part score composition
  • Built-in synthesis, drums, and effects
  • MIDI generation and export
  • Interactive CLI and browser playground
  • Live MIDI, Ableton Link, and AI composition integrations

Project Samples

Project Activity

See All Activity >

Categories

Sound/Audio

License

MIT License

Follow pyTheory

pyTheory Web Site

Other Useful Business Software
Train ML Models With SQL You Already Know Icon
Train ML Models With SQL You Already Know

BigQuery automates data prep, analysis, and predictions with built-in AI assistance.

Build and deploy ML models using familiar SQL. Automate data prep with built-in Gemini. Query 1 TB and store 10 GB free monthly.
Start Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of pyTheory!

Additional Project Details

Programming Language

Python

Related Categories

Python Sound Audio

Registered

4 hours ago