What is Sardine?
For my research project, I chose the live coding platform Sardine. I decided to go with Sardine because it stands out as a relatively new and exciting option built with Python. Sardine is a live coding environment and library for Python 3.10 and above. What sets Sardine apart is its focus on modularity and extensibility. Key components like clocks, parsers, and handlers are designed to be easily customized and extended. Think of it as a toolkit that allows you to build your own personalized live coding setup. It allows the customisation of IO logic, without the need to rewrite or refactor low-level system behaviour.
In its complete form, Sardine is designed to be a flexible toolkit for building custom live coding environments. The core components of Sardine are:
- A Scheduling System: Based on asynchronous and recursive function calls.
- A Modular Handler System: Allowing the addition/removal of various inputs/outputs (e.g., OSC, MIDI).
- A Pattern Language: A general-purpose, number-based algorithmic pattern language.
- For example, a simple pattern might look like this:
D('bd sn hh cp', i=i)
- For example, a simple pattern might look like this:
- The FishBowl: A central environment for communication and synchronization between components.
However, configuring and using the full Sardine environment can be complex. This is where Sardine Web comes in. Sardine Web is a web-based text editor and interface built to provide a user-friendly entry point into the Sardine ecosystem. It simplifies the process of writing, running, and interacting with Sardine code.

The Creator: Raphaël Maurice Forment
Sardine was created by Raphaël Maurice Forment, a musician and live-coder from France, based in Lyon and Paris. Raphaël is not a traditional programmer but has developed his skills through self-study, embracing programming as a craft practice. He is currently pursuing his PhD at the Jean Monnet University of Saint-Etienne, focusing on live coding practices. His work involves building musical systems for improvisation, and he actively participates in concerts, workshops, and teaching live coding both in academic and informal settings.
Sardine began as a side project to demonstrate techniques for his PhD dissertation, reflecting his interest in exploring new ways to integrate programming with musical performance. Raphaël’s background in music and his passion for live coding have driven the development of Sardine, aiming to create a flexible tool that can be adapted to various artistic needs.
My Live Demo
To demonstrate Sardine in action, I created a simple piece that highlights its scheduling and pattern language capabilities.

In this code snippet I used two different types of senders (d for Player and D for swim) where Player used for shorthand pattern creation, and @swim used for fundamental mechanism to create patterns.
Sardine in the Context of Live Coding
Sardine builds upon the ideas of existing Python-based live coding libraries like FoxDot and TidalVortex. However, it emphasizes flexibility and encourages users to create their own unique coding styles and interfaces. It tries to avoid enforcing specific ‘idiomatic patterns’ of usage, pushing users to experiment with different approaches to live performance and algorithmic music.
The creators of Sardine were also inspired by the Cookie Collective, a group known for complex multimedia performances using custom setups. This inspired the idea of a modular interface that could be customized and used for jam-ready synchronization. By allowing users to define their own workflows and interfaces, Sardine fosters a culture of experimentation and innovation within the live coding community.