Skip to main content

Module render

Module render 

Source
Expand description

Turning retrieval results into text an LLM can use.

The daemon answers in JSON built for programs: record ids, distances, nested traversal nodes. Handing that to a model wastes context on syntax and buries the parts that matter. Everything here renders the same data as compact prose-with-structure, keeps the numbers a reader would act on (retrieval score, similarity, edge confidence, utility) and drops the ones nobody reads.

Every renderer is total: an empty result set produces guidance about what to try next, not an empty string.

Functions§

entities
Entity search results.
episodes
Episode search results.
query_result
Hybrid query results: entities, then the episodes behind them.
status
Graph counts.
traversal
A traversal tree rooted at one entity.