pub struct FederatedSubgraphExpander<E: EndpointExecutor> { /* private fields */ }Expand description
Expands subgraphs across multiple SPARQL endpoints concurrently and merges
the results into a single KnowledgeGraph.
Implementations§
Source§impl<E: EndpointExecutor + 'static> FederatedSubgraphExpander<E>
impl<E: EndpointExecutor + 'static> FederatedSubgraphExpander<E>
Sourcepub fn new(config: FederatedGraphRAGConfig, executor: Arc<E>) -> Self
pub fn new(config: FederatedGraphRAGConfig, executor: Arc<E>) -> Self
Create a new expander with the given config and executor
Sourcepub async fn expand_federated(
&self,
seeds: &[ScoredEntity],
endpoints: Option<&[String]>,
) -> GraphRAGResult<KnowledgeGraph>
pub async fn expand_federated( &self, seeds: &[ScoredEntity], endpoints: Option<&[String]>, ) -> GraphRAGResult<KnowledgeGraph>
Expand subgraphs for the given seed entities across all active endpoints.
Queries are issued concurrently (bounded by config.max_concurrency).
If config.partial_results_ok is true, endpoint failures are logged but
do not abort the overall operation.
Auto Trait Implementations§
impl<E> Freeze for FederatedSubgraphExpander<E>
impl<E> RefUnwindSafe for FederatedSubgraphExpander<E>where
E: RefUnwindSafe,
impl<E> Send for FederatedSubgraphExpander<E>
impl<E> Sync for FederatedSubgraphExpander<E>
impl<E> Unpin for FederatedSubgraphExpander<E>
impl<E> UnsafeUnpin for FederatedSubgraphExpander<E>
impl<E> UnwindSafe for FederatedSubgraphExpander<E>where
E: RefUnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more