Index

Grammars, Music, and Formal Languages

This series of articles explores an unusual territory: where formal language theory meets algorithmic music. The common thread is BP2SC, a transpiler that converts musical grammars from the Bol Processor into SuperCollider patterns.

Each article is designed to be accessible without academic prerequisites, yet rigorous enough to serve as a reference. The series can be read in order or independently depending on your interests.


Series I — Introduction

Before diving into theory, let’s set the scene. Why this project exists, what tools it uses, and what problem it aims to solve.

  • I1) Why I created a bridge between two worlds : Discover why I created BP2SC, the bridge between Bol Processor 3 and SuperCollider. Connects formal musical grammars and real-time synthesis for limitless creativity.
  • I2) Bol Processor : Discover the Bol Processor, Bernard Bel’s musical grammar system. Explore its impact on polymetry, Indian music, and algorithmic composition.
  • I3) SuperCollider : Introduction to SuperCollider, the programming language dedicated to sound. Patterns, live coding, real-time synthesis: discover why we chose it for BP2SC.
  • I4) Introduction to MIDI : Explore the MIDI protocol: grasp its principles, strengths, and limitations. Uncover why this 40-year-old standard remains the cornerstone of digital music.
  • I5) MusicXML : Discover MusicXML, the standard format for exchanging digital scores. Learn how it encodes notes, measures, and key signatures for software interoperability.

Series L — Formal Languages

The theoretical foundation of the project. From the Chomsky hierarchy to formal semantics, these articles build step by step the foundations needed to understand how a language works.

  • L0) The Map of Formalisms : Explore the map of formal language formalisms. Understand how syntax, semantics, and concurrency apply to BP3. Essential guide for the L series.
  • L1) Chomsky Hierarchy Explained Simply : Dive into Chomsky’s hierarchy! Discover the 4 types of languages, from regular to recursively enumerable. Essential for understanding language and tool design.
  • L2) Context-Free Grammars : Dive into Context-Free Grammars (CFG) and understand how compilers and parsers interpret the syntax of programming languages. Essential for every developer!
  • L3) EBNF : What is EBNF? Discover this standard meta-language for describing language syntax (Python, JSON…). Learn its operators and key role. Master EBNF!
  • L4) What is an AST? : Explore compilers! Learn what an AST (Abstract Syntax Tree) is, how it simplifies your code, and its key role in compilation. Essential for any developer.
  • L5) The Three Semantics : Discover the 3 formal semantics: operational, denotational, axiomatic. Learn how they define program meaning and select the best approach for your projects.
  • L6) SOS for Dummies : Structural Operational Semantics (SOS) is crucial for understanding language execution. This detailed guide reveals its principles and practical applications.
  • L7) Denotational Semantics : Denotational semantics interprets programs as mathematical functions. Discover this powerful approach to analyze, prove, and optimize the behavior of your code.
  • L8) Axiomatic Semantics : Axiomatic semantics uses pre/postconditions to prove program correctness. Discover Hoare triples, loop invariants, and practical applications.
  • L9) Beyond Chomsky : Beyond Chomsky, explore mildly context-sensitive languages. Discover TAG, CCG, and their crucial importance for natural language and music. An essential article!
  • L10) Attribute Grammars : Knuth’s attribute grammars enrich syntax trees with computable properties. Explore synthesized and inherited attributes, and their link to BP3 flags.
  • L11) Beyond the Three Semantics : Classical semantics have limits. Discover advanced semantics: translational, process, and algebraic. Give meaning to compilers, concurrent systems, and data types.
  • L12) Petri Nets and Process Algebras : Discover how Petri nets and process algebras (CCS, CSP) model concurrency and musical polymetry. An essential guide for formalizing music.
  • L13) Generate or Recognize : Discover the duality of formal grammars: why generating and analyzing are not symmetrical. A key challenge at the intersection of computer science, AI, and music.
  • L14) The Direction of Parsing : Generation is always top-down. Parsing (LL, LR) has a unique directional freedom. Discover this fundamental asymmetry, essential for compilers.
  • L15) The Formulas of Asymmetry : Why is generating simpler than analyzing? Discover the formulas of generation-parsing asymmetry: complexity, Catalan numbers, and surprisal.
  • L16) The Paradox of Bidirectionality : Despite 50 years, bidirectionality in reversible grammars remains rare. Discover why asymmetry is structural and requires a declarative approach in NLP.
  • L17) The Complexity Matrix : The complexity matrix dissects generation-recognition asymmetry. Explore 6 sub-problems, differential coupling, and sign reversal. Essential reading!
  • L18) Le renversement de signe : Le slogan « générer est facile, analyser est difficile » est faux. La génération sous contrainte sémantique peut être exponentielle, voire NP-complète, dépassant le parsing.
  • L19) Le P-chain : Le P-chain révolutionne la psycholinguistique : votre cerveau prédit en produisant pour comprendre. L’erreur de prédiction est le moteur de l’apprentissage. Découvrez ce modèle unifié !
  • L20) L’inférence : L’inférence grammaticale : le défi ultime. Impossible (Gold), dure comme casser RSA, elle est le cas extrême de la reconnaissance. Apprendre, c’est compresser.
  • L21) The Economy of Laziness and the Ecological Oracle : Explore a groundbreaking thesis on grammar learning. The economy of laziness and the ecological oracle, driving prediction error, reveal a unique process. Click now!

Series M — Music

The bridge between language theory and music. Formats, paradigms, hierarchical structures: how formal concepts apply to sound.

  • M1) MIDI under the Formal Microscope : MIDI, a formal language? Explore its place in Chomsky’s hierarchy, the lack of full specification, and its implications for musical representation. A must-read!
  • M2) MusicXML Under the Formal Microscope : Discover why MusicXML, despite its formal XSD grammar and its Chomsky Type 2 position, has no musical generative power. A paradox to explore!
  • M3) The Paradigms of Musical Representation : Explore the six musical representation paradigms, from wave to meaning. Discover how these abstraction levels stack and why some tools are more powerful.
  • M4) Generative Grammars and Music : Discover how generative grammars, from Chomsky to GTTM and BP3, have revealed the hidden rules of music. Understand how our brain structures sounds.
  • M5) Polymetry : Polymetry: multiple metrics superimposed. Discover why MIDI and MusicXML struggle to represent it, with roots in African, Indian, and Western music.
  • M6) Hierarchical structure in music : GTTM demystified: explore the hierarchical structure in music according to Lerdahl and Jackendoff. Understand the 4 pillars of our musical perception.
  • M7) The Landscape of Formal Music Languages : Discover 20+ formal music languages, from Csound to TidalCycles. Genealogy, comparative table, and BP3’s unique position. An essential guide!
  • M12) From structure to sound : Discover how BP3, a unique generative language, manages musical abstraction layers, from structure to sound. A practical example with flamenco rumba.

Series B — BP3

A deep dive into BP3 language mechanics: probabilities, alphabets, derivation rules.


Series S — BPscript


Reading Paths

“I want to understand the project” — Start with the Introduction series (I1 → I5), then explore freely.

“I’m interested in language theory” — L0 (overview), then the fundamentals (L1 → L4), then semantics (L5 → L8, L11).

“I’m interested in languages beyond Chomsky” — L9 (TAG, CCG, MCFG), L10 (Knuth’s attributes), L12 (concurrency and processes).

“The generation/analysis asymmetry intrigues me” — The quadrilogy: L13 (duality) → L14 (LL vs LR) → L15 (formulas) → L16 (paradox). Prerequisites: L1, L2.

“I want to understand BP3” — Read L1 and L2 first, then the BP3 series in order (B1 → B8, B12). For an overview of PROD/ANAL/TEMP modes, go directly to B8.

“Music and formal languages” — M1 and M2 (formats under the microscope), M3 (the 6 paradigms), M4 (grammars and music), M6 (GTTM), M12 (from structure to sound).


Additional Resources

Glossary — All technical terms explained.


60 articles published — Last update: 2026-05-21