Par François Pachet et Pierre Roy.
Constraints 16(2), 148–172 (2011). DOI: 10.1007/s10601-010-9101-4.
Lire l’article (PDF) · Version de l’éditeur (DOI) · Projet Contraintes de Markov
À propos de l’article
Les modèles de Markov peuvent apprendre le style d’une séquence à partir d’exemples. Cet article cherche comment préserver ce style tout en donnant à l’utilisateur le contrôle du résultat. Un musicien peut, par exemple, souhaiter qu’une mélodie générée se termine sur une note précise.
Nous formulons la génération comme un problème de satisfaction de contraintes. On peut ainsi imposer des propriétés à la séquence et comparer les solutions grâce aux probabilités du modèle de Markov. L’article décrit des formulations pour les modèles d’ordre fixe et d’ordre variable.
Résumé original (en anglais)
Markov chains are a well known tool to model temporal properties of many phenomena, from text structure to fluctuations in economics. Because they are easy to generate, Markovian sequences, i.e. temporal sequences having the Markov property, are also used for content generation applications such as text or music generation that imitate a given style. However, Markov sequences are traditionally generated using greedy, left-to-right algorithms. While this approach is computationally cheap, it is fundamentally unsuited for interactive control. This paper addresses the issue of generating steerable Markovian sequences. We target interactive applications such as games, in which users want to control, through simple input devices, the way the system generates a Markovian sequence, such as a text, a musical sequence or a drawing. To this aim, we propose to revisit Markov sequence generation as a branch and bound constraint satisfaction problem (CSP). We propose a CSP formulation of the basic Markovian hypothesis as elementary Markov Constraints (EMC). We propose algorithms that achieve domain-consistency for the propagators of EMCs, in an event-based implementation of CSP. We show how EMCs can be combined to estimate the global Markovian probability of a whole sequence, and accommodate for different species of Markov generation such as fixed order, variable-order, or smoothing. Such a formulation, although more costly than traditional greedy generation algorithms, yields the immense advantage of being naturally steerable, since control specifications can be represented by arbitrary additional constraints, without any modification of the generation algorithm. We illustrate our approach on simple yet combinatorial chord sequence and melody generation problems and give some performance results.
Résumé de François Pachet et Pierre Roy, reproduit à partir de l’article des auteurs en accès libre sous licence CC BY-NC 2.0.
Code et exemples
Le dépôt GitHub de Snarky contient une implémentation Python de l’approche de génération de Markov sous contraintes présentée dans cet article, avec des exemples exécutables de séquences d’accords de blues et de génération mélodique.