
Toby ColemanIf you are working on simulation, digital twins, or complex event-driven workflows, you likely know...
If you are working on simulation, digital twins, or complex event-driven workflows, you likely know the pain of managing state and data flow between dozens of disconnected components. Plugboard is a Python framework designed to solve exactly this problem.
In this post, we’ll look at what Plugboard does, real-world use cases, and how you can supercharge your development by combining it with AI using a custom prompt for your LLM of choice.
Plugboard is an event-driven modelling and orchestration framework built for Python. Think of it as a way to wire together different "components", which could be anything from a physics simulation to a machine learning model, so that they can communicate and react to each other in real-time.
It handles the heavy lifting of:
Because it is built on modern Python (asyncio, type hinting), it integrates seamlessly with the existing data science and engineering ecosystem. Use it to create robust, maintainable models for research or for live deployment.
Process modelling isn't just for academic simulations. Plugboard is designed for practical, data-intensive applications. Here are a few examples of what you can build:
The best way to dive in is through the official Plugboard Documentation.
The docs are comprehensive, offering:
One of the most powerful ways to build with Plugboard is to use it alongside an AI coding assistant like GitHub Copilot or Claude Code. However, general-purpose AI models don't always know the specific syntax and lifecycle methods of a new framework.
To bridge this gap, the Plugboard team has provided a custom instructions file specifically designed to teach AI models how to write models.
You can find the prompt file here: 👉 models.instructions.md
How to use it effectively:
Context is Key: When you are asking your AI assistant (like Copilot or Cursor) to generate a new component, reference this file. If you are coding with GitHub Copilot this will happen automatically when you create files in the examples folder. GitHub provide documentation on how to set this up for your own project repositories.
Provide clear instructions on what you want your model to do, and if possible detail the individual components it will need. For example, try the following to create a simple working process simulation:
Create a Plugboard model of a bathtub filling with water.
It should contain the following components:
* A tap, with a parameter for the inlet flow rate in litres per second,
* A bathtub with a parameter for the size in litres, and
* An overflow, which outputs the overflow rate in litres per second.
The simulation should run for 60 minutes at a resolution of 1 minute each step.
Log the bathtub level and overflow amount to a CSV using the DataWriter component.
The AI will quickly generate the model below, which you can iterate on and refine.

All Plugboard models can be exported in a simple YAML format, allowing you to save/version them, and transfer them to a different computing environment as your needs evolve.
Ready to start modelling? Check out the GitHub repository and give it a star!