Expand description
All wiring for the optional RAG server lives in this module — config
reading, client construction (client) and the background sync loop
(sync). Everything talks to the server through crate::server_client;
the rest of the TUI only consumes these helpers and renders status.
Enums§
- RagStatus
- RAG connection status surfaced in the footer.
Disabled(no server configured) is never sent — the loop simply doesn’t start — so the footer shows nothing.
Functions§
- rag_
client - Builds a
RagClientfor the current vault from config, orNonewhen no server URL is configured. Shared by every RAG query surface. - rag_
configured - Whether a RAG server is configured (drives showing the semantic surface at all). Reachability is a separate, runtime concern.
- spawn_
rag_ sync - Spawns the background sync loop for
vaultif a RAG server is configured. Returns the task handle (abort it when the vault is rebuilt), orNonewhen the feature is off. Status is delivered to the UI viaAppEvent::RagStatus.