langgoap.visualize

Contents

langgoap.visualize#

visualize(plan, *, format='auto', show_resources=True, show_schedule=True)[source]#

Render a Plan for display.

Return types:

  • format="ascii" or format="ascii_gantt" → always a str.

  • format="mermaid"IPython.display.Markdown if IPython is importable, otherwise a plain str.

  • format="gantt" → same detection rules as "mermaid".

  • format="dot"IPython.display.Image when IPython and the graphviz Python package with the dot binary are available. Otherwise returns the DOT source as str.

  • format="auto""mermaid" when IPython is available, "ascii" otherwise.

Parameters:
  • plan (Plan) – Plan to render.

  • format (VizFormat) – Output format selector.

  • show_resources (bool) – Forwarded to the underlying renderer.

  • show_schedule (bool) – Forwarded to the underlying renderer.

Returns:

Rendered output; exact type depends on format and the presence of IPython in the current environment.

Return type:

str | Any