Show HN:Graph2agent,让 Agent 读懂 Mermaid 图表
英文标题:🔶 Show HN: Graph2agent; Mermaid diagrams, explained for agents
Graph2agent 是一个面向 Agent 的 Mermaid 图表解释方案,可将图中的节点、分支和连线关系以隐藏在渲染后 Markdown 中的注释形式提供给 Agent。示例中,工具识别出名为 `Authorized?` 的分支节点,并提取其通往 `API` 和 `Reject` 的“yes”“no”标签关系。该说明同时强调,图形结构本身并不能证明实际运行时的决策语义。对于需要让 AI Agent 理解流程图、决策树和系统架构图的开发者而言,这种方式可补充视觉图表难以直接被模型可靠解析的结构化上下文。
打开原文相关 3 · 机会 1
99.6 KB
中文
◌ Agent 说明 · 隐藏在渲染后的 Markdown 中
<!-- graph2agent:begin …
Branch candidate: `Authorized?`.
`Authorized?` points to `API`, labeled “yes”.
`Authorized?` points to `Reject`, labeled “no”.
Terminal nodes: `API` and `Reject`.
Shape does not prove runtime decision semantics.
graph2agent:end -->
English / 原文
◌ Agent explanation · hidden in rendered Markdown
<!-- graph2agent:begin …
Branch candidate: `Authorized?`.
`Authorized?` points to `API`, labeled “yes”.
`Authorized?` points to `Reject`, labeled “no”.
Terminal nodes: `API` and `Reject`.
Shape does not prove runtime decision semantics.
graph2agent:end -->