Skip to main content

duskfm

Endless music from lo-fi to synthwave, made on the spot: never the same twice, all day long.

Every sound is synthesized as it plays: an FM electric piano, a plucked-string guitar (fingerpicked or strummed), a kalimba, a vibraphone, a glassy bell, a soft choir "ooh", detuned pads, a polysynth, arpeggios, a synth lead, bass, a drum kit made of sweeps and noise, tape wobble, vinyl dust and rain.

Each section draws its own band from where the style dial is: a lead for the tune (never the same two sections running), something to play the chords, sometimes voices or an arpeggio. The weather and the record drift on their own too: a rainy stretch comes and goes, the dust thickens and clears. The status line names who's playing. No samples and nothing recorded, so the package is a few files of Python.

pip install duskfm
duskfm                    # lo-fi
duskfm synthwave          # or: lofi, chillhop, chillwave, synthwave, nightdrive, ambient

One dial from lo-fi to synthwave

--style runs from 0 (lo-fi) to 1 (synthwave), and everything blends along it:

lo-fi (0) chillwave (0.5) synthwave (1)
tempo 72–84, swung ~85–97 94–110, straight
harmony jazzy 7ths and 9ths (ii–V–I) dreamy maj9 and sus minor: i–VI–III–VII
keys FM electric piano piano, pads, a glassy bell polysynth, arpeggios, a lead
drums dusty boom-bap, lazy soft kick, rim, shaker punchy, 80s gated snare
texture crackle, tape wobble, dark haze, chorus bright, wide, big reverb
band electric piano, guitar, kalimba vibes, bell, guitar, voices polysynth, arps, synth lead, electric guitar

--energy runs from 0 (ambient: no drums, sparse) to 1 (driving). --drift lets both wander slowly on their own, so a long session moves through moods. The presets are points on the two dials (duskfm --help lists them).

It composes as it goes: chord progressions voiced smoothly from one to the next, melodies grown from short motifs and varied each time, sections that thin out and build back, a new key and tempo every few minutes. --seed replays a session you liked (the seed is shown when you quit).

While it plays

key
← → style: toward lo-fi, toward synthwave
↑ ↓ energy
+ − volume
] [ boost (3 dB a press)
r rain: off, light, heavy
d drift on or off
n on to the next section
1–6 the presets
space pause
q quit (it fades out)

Loud enough to drown out the room

  • --volume (0–100) is the ordinary level.
  • --boost DB (up to 18) is the maximizer behind it: the music is compressed and driven into a soft limiter, so it gets much louder without ever clipping. Your speakers' own limit still applies; this gets more out of it.
  • --rain adds a soft rain bed shaped to the frequencies speech lives in. Lo-fi is mellow and dark, which is lovely and also poor at covering voices; a little rain covers chatter better than a lot more volume, and spares your ears. A whole day at high volume is hard on hearing: reach for the rain first.

Playing it

On Linux it plays through paplay (PulseAudio, or PipeWire's pulse layer), pw-cat or aplay, whichever is there: nothing else to install. Over remote desktop (xrdp), sound comes through when the session has xrdp's PulseAudio or PipeWire module; if paplay works there, duskfm does. Elsewhere, pip install "duskfm[sounddevice]" uses PortAudio.

No sound where you are? Make a file and play it anywhere:

duskfm chillwave --render 3h -o afternoon.wav

--minutes 90 plays for a while and then fades out.

Development

python3 tests/test_duskfm.py: every preset renders clean audio at a steady level, a seed replays exactly, nothing loops, boost gets louder without clipping, and the player and command line work (no sound card needed). A GitHub release vX.Y.Z matching __version__ publishes to PyPI.

Metadata

Release files for duskfm 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for duskfm 0.3.1
File Size Uploaded Provenance Actions
duskfm-0.3.1.tar.gz 28.2 kB With provenance Details for duskfm-0.3.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for duskfm 0.3.1
File Interpreter ABI Platform Actions
duskfm-0.3.1-py3-none-any.whl Python 3 none any Details for duskfm-0.3.1-py3-none-any.whl

Total release size: 55.0 kB

Release files / duskfm-0.3.1.tar.gz

Download URL duskfm-0.3.1.tar.gz
Size 28.2 kB
Tags Source
SHA-256 checksum
How to use checksums
f34702e948e498c2fb6f991de6872f15634d6f6f1ae0ec79d4492f2743ed9a3d
BLAKE2b-256 checksum
How to use checksums
134f014db2f04dcfca33d2741e28ca89a38cc53370b749e0749a0f08cb30b206
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.

Transparency log

Release files / duskfm-0.3.1-py3-none-any.whl

Download URL duskfm-0.3.1-py3-none-any.whl
Size 26.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
666a87401e9436f20f580a89e6dd7f21f05e27d18d1fc64d71df90d57fa8d0e3
BLAKE2b-256 checksum
How to use checksums
71f9a065b470b371ee236161d8ca3313bd9c5e7fdd973eca11352eb1d7795810
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.

Transparency log

Security for duskfm 0.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for duskfm-0.3.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page