News

PromptAgent turns text into graphs and back

A new PromptAgent demo turns text into knowledge graphs and reconstructs graph structure back into text with LLM prompting.

HumemAI · November 26, 2024
PromptAgent turns text into graphs and back

A new PromptAgent demo

We are publishing a new PromptAgent demo that shows two complementary workflows: text-to-graph, where an LLM extracts structured knowledge from text, and graph-to-text, where the system turns structured graph data back into readable language. This is the kind of interface layer we care about because it makes graph-native memory systems easier to inspect and easier to use.

What the demo shows

PromptAgent is built on top of the open-source HumemAI Python package. In the demo, we show how prompting can be used to extract relationships from text, serialize graph structure for an LLM, and convert structured output back into a useful textual representation.

The implementation uses property-graph infrastructure and keeps the graph as a first-class object rather than reducing everything to unstructured text. That keeps retrieval, inspection, and long-term memory organization explicit.

Between text and graphs

LLMs work well with text, while memory-heavy systems often need explicit structure for retrieval and reasoning. This demo explores how to connect the two.