JuliaHub is happy to announce Dyad, a new language to make hardware engineering as fast and easy as software engineering! Check out the release blog post!
What is Dyad in a nutshell?
It is a declarative physical modeling language, allowing the easy construction of complex multiphysics models by piecing together components from the provided model libraries (or your own model libraries!). It has a 1-1 relationship between code and graphical representations, which means the same model can be inspected and interacted with in both GUI (coming soon) and code. For the coding interface, JuliaHub has released the Dyad Studio extensions for VS Code, which offers easy interactions with the compiler, static analysis to ensure correctness of physical models, and ease of authentication into the JuliaHub registries for models and launching large-scale jobs on clusters. That last part is essential for some of our big differentiators, as you can build a big model on your computer but, with a click of a button, launch of a big multi-GPU job on the cloud to train a surrogate of your model for quicker inspection!
How does this relate to Julia?
You might think, oh no the JuliaHub people are working on a different language, not Julia? Well Dyad is actually quite related to Julia! The Dyad compiler lowers to Julia code, so if you know Julia SciML packages DifferentialEquations.jl and ModelingToolkit.jl you’ll feel right at home with its lowered representations. In addition, Dyad contains and interface for “custom analyses”, which means you can write dispatches in Julia which are then exposed as actions in the Dyad language and the coming GUI. Thus if you have some new fancy scientific machine learning workflow you’d like industrial companies to easily make use of, adding a little bit of Dyad bindings to your package suddenly exposes your new tools in these interfaces!
Why is a new language needed here?
There are a few reasons why we needed to create a new language for this. First of all, in order to achieve this goal of having the same code be both the backing of a graphical environment and be an accessible representation for modeling, it needs to be a declarative language. You can’t say “run this Turing machine in order to figure out how many resistors there are” if you want a GUI to be snappy! On top of that, we wanted to ensure that we could build responsive tooling that could perform static analyses instantly to alert about problems with units and incorrect physical corrections. This means that, while there are some declarative DSLs in Julia that are similar (notably @model
macro in ModelingToolkit.jl), moving this to be a Typescript-defined declarative language that lowers into Julia makes it so we can achieve these goals.
But all of the imperative behavior takes place in Julia. You adding new functions/operators, new analyses, data handling, etc. is all done by writing extensions in Julia. Also, the Dyad packages are Julia packages, but with a few extra requirements, and as such it also uses Pkg for all of its dependency management. Thus if you’re a Julia developer, then you’re already suited to be a Dyad developer!
What’s Next?
We have a lot more that is coming soon. In particular:
- New tooling around agentic and generative AI for modeling
- Targeting embedded systems
- The GUI
- SciML model discovery analysis pipelines
- Model-predictive control
- Model libraries: multibody, HVAC/fluids, etc.
So much more is coming soon. Stay tuned!
Where can I get more information?
Check out our documentation:
and get subscribed to our newsletter as we will be releasing a series (/barrage!) of blog posts as many things Dyad related are about to be released!