GenAI.Graph.MermaidProtocol.Helpers (GenAI Core v0.2.0)

Helpers for generating Mermaid graphs using the GenAI.Graph.MermaidProtocol protocol.

Link to this section Summary

Functions

Return the diagram type.

Indent a string by a given depth.

Format id for mermaid compatibility.

Link to this section Functions

Link to this function

diagram_type(options)

@spec diagram_type(options :: term()) :: atom()

Return the diagram type.

Link to this function

indent(string, depth \\ 1)

@spec indent(string :: String.t(), depth :: integer()) :: String.t()

Indent a string by a given depth.

@spec mermaid_id(term()) :: term()

Format id for mermaid compatibility.