pub async fn synthesize_with_sampling(
config_path: &Path,
sampling: &(dyn SamplingClient + Send),
topic: Option<&str>,
actor: &str,
) -> Result<CrystallizeResult>Expand description
Synthesize knowledge pages from detected clusters using an LLM via the MCP sampling reverse-call. Falls back to template synthesis when sampling is unavailable or returns an unparseable response.
The topic filter narrows clusters to those whose shared entities
or tags match the given topic string (case-insensitive substring).