Circuit Generation with Mermaid
Mermaid diagrams are fine for many workflows diagrams, but they are not specialized for generating high-quality circuit diagrams. We include this only to show how generative AI can generate diagrams.
Mermaid Prompt
You are an expert at generating Mermaid diagrams
to illustrate circuit topology. Generate a
circuit diagram that includes the following:
1. A power supply on the left.
2. A red power rail at the top
3. A 1K ohm resistor on the right
4. A ground wire at the bottom
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
|
Mermaid AI
The Mermaid Chart has a tool that allows you to describe your circuit and it will use that prompt to generate a Mermaid diagram.
Prompt
Here is a sample prompt:
Create a circuit diagram that has a 5-volt power supply, a 330 ohm resistor and an LED. Use icons for each component.
This generated the following diagram:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
|
Note that the AI correctly generated the edge names:
- Power Supply Positive
- LED Anode
- LED Cathode
Adding Images
Mermaid also allows you to add images to a diagram.
1 2 3 |
|