Working with Diagrams
Visualise what your agent (or process) actually does
Every user-defined agent and process can have a diagram — an AI-generated map of the data and actions involved. It's the fastest way to see, at a glance, what an agent touches and how it interacts with the user, the ERP.net Domain API, and its capabilities.
What's in the diagram
The diagram shows:
- The end user and the agent itself.
- The Domain API entities mentioned in the instructions (customers, orders, items, document types, etc.).
- Each active capability (email, calendar, knowledge search, sub-agents, …).
- Labelled arrows for the actions performed and the data exchanged between them.
The AI picks the best Mermaid diagram type per agent — flowchart, sequence, or state — based on what fits the agent's behavior.
Generating and refreshing
- The first time you open the diagram, click Generate. After that, the diagram is cached on the agent and loads instantly.
- A Stale badge appears when something the diagram depends on has changed since it was last generated — instructions, base agent, capabilities, greeting, or description. Click Refresh to bring it up to date.
- Only the owner can generate or refresh. Shared users always see the latest cached version.
Regenerate options
Opening Regenerate reveals two preferences that are saved on the agent and travel with version history:
- Rendering hints — free-text guidance for layout, grouping, or emphasis (e.g. "always group ERP entities together", "put the user on the left"). These shape how the diagram is drawn, not what it's about.
- Allow colors — on by default. When on, the AI may color nodes and edges and tries to pick combinations readable in both light and dark themes. Turn it off to fall back to the branded theme palette.
You can also set both from chat by asking the Agent Builder — for example "stop using colors in the diagram" or "always group ERP entities together".
Regenerate from scratch
If you've accumulated hints over time and want a clean slate, use Regenerate from scratch. A confirmation dialog warns you that stored hints will be cleared and the diagram rebuilt without them. Use this when previous hints are pulling the layout in directions you no longer want.
Navigating the diagram
- Zoom in / out, Fit to window, Reset, and Pan are all available from the diagram controls.
- The zoom level is remembered per agent and travels with version history, so restoring an older version brings back its view as well.
Fullscreen, print, and PNG export
- Fullscreen opens the diagram in a dedicated overlay, useful for screen-sharing and reviewing complex flows.
- Print renders an A4 page suitable for handouts.
- PNG export composes a self-contained A4 portrait image with the agent's name, description, and your company name, then downloads it. Great for documentation, decks, and email.
Diagrams for Processes
Processes use the same diagram tools — and the diagram is usually the point of a Process. If you want to capture an SOP, a checklist, or a flow without anything runnable behind it, create a Process and let the Builder produce its diagram.
Diagrams on the Agents page
The Gallery view of the Agents page shows each agent's latest diagram as a thumbnail. Agents with no diagram yet show a "No diagram yet" placeholder — open the agent and generate one to populate the thumbnail. Shared agents show their owner's diagram (read-only).
Tips
- Specific instructions = richer diagrams. Naming concrete entities, document types, and actions gives the AI more material to draw.
- Refresh after meaningful changes. Small tweaks can wait; rework or new capabilities are worth a refresh.
- Use hints to stabilise layout. If the AI keeps re-arranging the same flow, lock it in with one short hint instead of regenerating until you get lucky.
- Export before big edits. A quick PNG export is a cheap "before" snapshot.