theHarmonicAlgorithm-3.0.0: Real-time harmonic progression generation for TidalCycles live performance
Safe HaskellSafe-Inferred
LanguageHaskell2010

Harmonic.Evaluation.Analysis.Markov

Description

This module is used exclusively during data ingestion (app/Main.hs) to compute transition probabilities from the YCACL corpus. These probabilities are stored as edge weights in the Neo4j graph database.

This module is NOT used in the runtime generation path. At runtime, transition weights are read from Neo4j edges by Harmonic.Evaluation.Database.Query.

Academic Lineage

Data Science In The Creative Process (South, 2018), Section: Markov module. The Markov chain approach resolves "Generative Uninspiration" — the problem of manually traversing exhaustive overtone combination charts — by training transition probabilities on the Yale Classical Archives Corpus (Bach chorales and other composers).

Synopsis

Documentation

type Edge = (Cadence, Cadence) Source #

Representation of a transition between cadences.

type TransitionCounts = Map Edge Double Source #

Raw observed counts per edge, before normalisation.

transitionCounts :: [Cadence] -> TransitionCounts Source #

Count each adjacent pair in a cadence sequence. Ingestion-only: the live generator reads edge weights from Neo4j rather than recomputing these.

transitionProbabilities :: [Cadence] -> Map Edge Double Source #

Normalise transitionCounts into per-source transition probabilities, so the outgoing edges of each cadence sum to 1.