alda-lang /alda
A music programming language for musicians. :notes:
★ 5,961⑂ 315👁 124⑃ 153● 323▤ 0
+0
Daily
5,961
stars
315
forks
124
watchers
153
prs
323
issues
0
releases
README
Installation
|
Docs
|
Changelog
|
Contributing
Join us on Slack!
Alda is a text-based programming language for music composition. It allows you
to compose and play back music using only your text editor and the command line.
alda
piano:
o3
g8 a b c d e f+ g | a b c d e f+ g4
g8 f+ e d c g/g/b/d/g
For more examples, see these example scores.
The language's design equally favors aesthetics, flexibility and ease of use.
(Why compose music this way instead of in a graphical sheet music notation
program? See [this blog post][alda-blog-post] for a brief history and
rationale.)
[alda-blog-post]: https://blog.djy.io/alda-a-manifesto-and-gentle-introduction/
Features
Easy to understand, markup-like syntax.
Designed for musicians who don't know how to program, as well as programmers
who don't know how to music.
A score is a text file that can be played using the alda command-line tool.
Interactive REPL lets you enter Alda code and hear the
results in real time.
Supports writing music
programmatically (for algorithmic
composition, live coding, etc.)
Create MIDI music using any of the instruments in the [General MIDI Sound
Set][gm-sound-set]
[gm-sound-set]: http://www.midi.org/techspecs/gm1sound.php
Planned
If you'd like to help, come on in -- the water's fine!
Run Alda in the browser
Define and use waveform synthesis instruments
Export to MusicXML for interoperability with other music software
Improve Raspberry Pi support
Installation
See [the official website][alda-install] for instructions to install the latest
release of Alda.
[alda-install]: https://alda.io/install
Building from source
Another option is to build Alda from source. Alda consists of two components:
the client (written in Go) and the player (written in Kotlin/Java).
bash
Clone the repo
git clone https://github.com/alda-lang/alda.git
cd alda
Build the client and player executables
client/bin/build
player/bin/build
The executables are built in client/target and player/target, and the
output of the build commands shows you the path to the built executables, which
include builds for various OS/arch combinations.
For more details, see the READMEs in the client and
player directories.
Demo
For an overview of available commands and options:
alda --help
To play a file containing Alda code:
alda play --file examples/bach_cello_suite_no_1.alda
To play arbitrary code at the command line:
alda play --code "piano: c6 d12 e6 g12~4"
To start an interactive Alda REPL session:
alda repl
Documentation
Alda's documentation can be found here.
Contributing
We'd love your help -- Pull Requests welcome!
For more details on how you can contribute to Alda, see CONTRIBUTING.md.
Another way you can contribute is by [sponsoring Dave][gh-sponsor] in the
future development of Alda.
[gh-sponsor]: https://github.com/sponsors/daveyarwood
Support, Discussion, Camaraderie
Slack: Joining the AldTop issues
#405CLI output is wonky14 comments · 2021-10-22#491No sound on certain Linux distros8 comments · 2023-10-20#496[BUG] MIDI failure in JVM on fresh install cause alda and alda-player to both fail3 comments · 2024-02-27#528Request for an Alda language conformance test suite2 comments · 2026-10-03#510build with gradle v9 support2 comments · 2025-09-16
Discussions
#526Bipluk: In-browser Web MIDI patch librarian for vintage hardware synthesizers0 comments · 2026-09-11#504Support stdout as output1 comments · 2024-10-04#500The Alda Docs™ as a website? (for printing, etc)1 comments · 2024-04-18#499alda repl --server --host NOT listen on my specific host1 comments · 2024-03-25#498alda-player process initialize slowly1 comments · 2024-03-25#497Why alda-player has an expiry ? And Why Shutdown alda-player when finish play a *.alda file ?1 comments · 2024-03-23#494Cool Project 👌1 comments · 2024-01-28#485`pitch` behavior changed from Alda 1 to Alda 24 comments · 2023-05-23